From 37369c532e2ec40e90e75a6ccfd2efb3e264a2c5 Mon Sep 17 00:00:00 2001 From: Alan Pinkert Date: Tue, 10 Oct 2023 22:12:50 -0400 Subject: [PATCH] Added makefile to rules engine (#91) * added makefile * refactored github actions * refactored github actions * renamed make file --- .github/workflows/test-rules-engine.yml | 25 ++++--------------------- rules-engine/Makefile | 22 ++++++++++++++++++++++ 2 files changed, 26 insertions(+), 21 deletions(-) create mode 100644 rules-engine/Makefile diff --git a/.github/workflows/test-rules-engine.yml b/.github/workflows/test-rules-engine.yml index 2d286c0c..aa53d26a 100644 --- a/.github/workflows/test-rules-engine.yml +++ b/.github/workflows/test-rules-engine.yml @@ -24,8 +24,7 @@ jobs: python-version: ${{ matrix.python-version }} - name: Check style run: | - isort --check . - black --check . + make lint mypy: runs-on: ubuntu-latest strategy: @@ -40,7 +39,7 @@ jobs: python-version: ${{ matrix.python-version }} - name: Check typing run: | - mypy . + make mypy pytest: runs-on: ubuntu-latest strategy: @@ -55,22 +54,7 @@ jobs: python-version: ${{ matrix.python-version }} - name: Run tests run: | - pytest - pydocstyle: - runs-on: ubuntu-latest - strategy: - matrix: - python-version: ["3.10"] - - steps: - - uses: actions/checkout@v3 - - name: Set up environment - uses: "./.github/actions/setup-rules-engine" - with: - python-version: ${{ matrix.python-version }} - - name: Run tests - run: | - pydocstyle . + make test build: runs-on: ubuntu-latest strategy: @@ -85,5 +69,4 @@ jobs: python-version: ${{ matrix.python-version }} - name: Build wheel run: | - pip install -q build - python -m build \ No newline at end of file + make build diff --git a/rules-engine/Makefile b/rules-engine/Makefile new file mode 100644 index 00000000..9cd87a24 --- /dev/null +++ b/rules-engine/Makefile @@ -0,0 +1,22 @@ +black: + black --check . + +isort: + isort --check . + +pydocstyle: + pydocstyle . + +lint: black isort pydocstyle + +mypy: + mypy . + +test: + pytest . + +build: + pip install -q build + python -m build + +all: lint mypy test build