-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Added simple CI file * rename file * rename branch * comment flake8 * Fixed issues for ruff/flake added pytest into CI * This is to test whether ruff will fail * Okay, ruff failed, now fixing * add formatting check * ruff chack fixed for quote preservation * Split into multiple steps * Formatting fix * Fix ruff issues * Fix ruff format * iSort enable * Tests moved to its own folder * Bump version package * Bump version package - configuration * Added workflow to commit bump version * reusable workflow * temporary set bumpversion to always run * temporary set bumpversion to always run: remove if * added commit all files * only on merge * remove map files to reduce pack size * exclude tests from distribution * 3.9 ruff
- Loading branch information
1 parent
010cd95
commit 430e3ed
Showing
110 changed files
with
933 additions
and
467 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,14 @@ | ||
[tool.bumpversion] | ||
current_version = "1.6.2" | ||
tag = "True" | ||
|
||
[[tool.bumpversion.files]] | ||
filename = "setup.py" | ||
search = "{current_version}" | ||
replace = "{new_version}" | ||
|
||
[[tool.bumpversion.files]] | ||
filename = "pycrunch/version.py" | ||
regex = "True" | ||
search = "version_info = dict\\(major=(?P<major>\\d+), minor=(?P<minor>\\d+), patch=(?P<patch>\\d+)\\)" | ||
replace = "version_info = dict(major={new_major}, minor={new_minor}, patch={new_patch})" |
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,37 @@ | ||
name: Bump Version on PR Merge | ||
|
||
on: | ||
pull_request: | ||
types: [closed] | ||
branches: | ||
- master | ||
|
||
|
||
|
||
jobs: | ||
version-bump: | ||
if: github.event.pull_request.merged == true | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Check out code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.9' # Specify the Python version | ||
|
||
- name: Install bump-my-version | ||
run: pip install bump-my-version | ||
|
||
- name: Bump version | ||
run: bump-my-version bump patch # Adjust the bump command as needed | ||
|
||
- name: Commit and push changes | ||
run: | | ||
git config --local user.email "action@github.com" | ||
git config --local user.name "GitHub Action" | ||
git add -A | ||
git commit -m "Bump version" | ||
git push |
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,37 @@ | ||
# This workflow will install Python dependencies, run tests and lint with a single version of Python | ||
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python | ||
|
||
name: Python application | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
dependencies-ruff-pytest: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Set up Python 3.9 | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: "3.9" | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install ruff | ||
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi | ||
- name: Lint with ruff (`ruff check --preview`) | ||
run: | | ||
ruff check --preview | ||
- name: ruff format (`ruff format --preview --diff --check`) | ||
run: | | ||
ruff format --preview --diff --check | ||
- name: Test with pytest | ||
run: | | ||
pytest -k "not test_exceptional_situation" |
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,2 +1,4 @@ | ||
include pycrunch/log_configuration.yaml | ||
recursive-include pycrunch/web-ui * | ||
|
||
recursive-exclude pycrunch_tests * |
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
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
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
Oops, something went wrong.