Skip to content

Commit

Permalink
Bring back black and prefer make lint over a custom action
Browse files Browse the repository at this point in the history
  • Loading branch information
stchris committed Jun 16, 2023
1 parent 37399fc commit a82df09
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,11 @@ jobs:
- name: Install development dependencies
run: make dev

- name: Run linter (ruff)
uses: chartboost/ruff-action@v1
- name: Check code formatting
run: make format-check

- name: Run linter
run: make lint

- name: Run aleph tests
run: make ALEPH_TAG=${GITHUB_SHA} test
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Aleph uses two main branches. The **develop** branch is for any new work that ne

### Code Formatting and Linting

We use automatic code formatters and linters to keep our code consistent and to spot bugs and style issues early in the process. For Python code, we use [ruff](https://beta.ruff.rs/). Our JavaScript code base uses [Prettier](https://prettier.io) and [ESLint](https://eslint.org/).
We use automatic code formatters and linters to keep our code consistent and to spot bugs and style issues early in the process. For Python code, we use [black](https://black.readthedocs.io/en/stable/) and [ruff](https://beta.ruff.rs/). Our JavaScript code base uses [Prettier](https://prettier.io) and [ESLint](https://eslint.org/).

When you open a pull request, your changes are automatically checked for consistency with our code formatting and linting rules. You can also run the checks in your local development environment. If you aren’t familiar with these tools yet, don’t worry. You can open a pull request even if your changes don’t pass these checks.

Expand Down
6 changes: 6 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,15 @@ lint:
lint-ui:
$(UIDOCKER) npm run lint

format:
black aleph/

format-ui:
$(UIDOCKER) npm run format

format-check:
black --check aleph/

format-check-ui:
$(UIDOCKER) npm run format:check

Expand Down

0 comments on commit a82df09

Please sign in to comment.