-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #882 from kedhammar/ci
CI pt. 1: Configuration
- Loading branch information
Showing
6 changed files
with
90 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Lint code | ||
on: [push, pull_request] | ||
|
||
jobs: | ||
# Use ruff to check for code style violations | ||
ruff-check: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.12" | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install ruff | ||
- name: ruff --> Check for style violations | ||
# Configured in pyproject.toml | ||
run: ruff check . | ||
|
||
# Use ruff to check code formatting | ||
ruff-format: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.12" | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install ruff | ||
- name: ruff --> Check code formatting | ||
run: ruff format --check . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,20 @@ | ||
d3/ | ||
jquery/ | ||
__pycache__/ | ||
.DS_Store | ||
.ruff_cache/ | ||
.vscode/ | ||
*.orig | ||
*.pyc | ||
*.swp | ||
*~ | ||
build/ | ||
d3/ | ||
dist/ | ||
status.egg-info/ | ||
run_dir/settings.yaml | ||
tests/test_items.yaml | ||
.DS_Store | ||
run_dir/qc_reports/ | ||
jquery/ | ||
Pipfile | ||
Pipfile.lock | ||
run_dir/settings/ | ||
*.swp | ||
*.orig | ||
run_dir/genosqlrc.yaml | ||
run_dir/qc_reports/ | ||
run_dir/settings.yaml | ||
run_dir/settings/ | ||
status.egg-info/ | ||
tests/test_items.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,13 @@ | ||
channels: | ||
- conda-forge | ||
dependencies: | ||
- python=3.12 | ||
- 'conda-forge::pango>=1.42.0' | ||
- 'conda-forge::pandas>=1.3.2' | ||
- conda-forge::psycopg2 | ||
- conda-forge::open-fonts | ||
- conda-forge::xorg-libxrender | ||
- conda-forge::xorg-libxext | ||
- conda-forge::xorg-libxau | ||
- pango>=1.42.0 | ||
- pandas>=1.3.2 | ||
- psycopg2 | ||
- open-fonts | ||
- xorg-libxrender | ||
- xorg-libxext | ||
- xorg-libxau | ||
- pip: | ||
- '-r requirements.txt' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# === LINTING ================================================================ | ||
|
||
[tool.ruff.lint] | ||
select = [ | ||
# Ruff default rules | ||
# ------------------------------ | ||
"E4", # pycodestyle Imports | ||
"E7", # pycodestyle Statements | ||
"E9", # pycodestyle Runtime | ||
"F", # Pyflakes | ||
|
||
# Additional Comment | ||
# ------------------------------------------------------ | ||
"I", # isort Best-practice sorting of imports | ||
"UP", # pyupgrade Make sure syntax is up-to-date | ||
] | ||
ignore = [ | ||
"E402", # Module level import not at top of file | ||
"E722", # Do not use bare 'except' | ||
"E741", # Ambiguous variable name | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,3 @@ | ||
ipdb | ||
ruff | ||
selenium |