Skip to content

Commit

Permalink
Move from config-visualizer
Browse files Browse the repository at this point in the history
  • Loading branch information
fsimonis committed Apr 11, 2024
0 parents commit bc95b64
Show file tree
Hide file tree
Showing 16 changed files with 1,436 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .codespellrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[codespell]
ignore-words-list = precice
29 changes: 29 additions & 0 deletions .github/workflows/pythonpublish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Upload Python Package

on:
push:
tags:
- v*

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v1
with:
python-version: '3.x'
- name: Install dependencies
uses: BSFishy/pip-action@v1
with:
packages: |
twine
build
- name: Build and publish
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
run: |
pyproject-build
twine upload dist/*
54 changes: 54 additions & 0 deletions .github/workflows/run-checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Run checks
on:
push:
pull_request:

concurrency:
group: check-${{ github.ref }}
cancel-in-progress: true

jobs:
precommit:
name: pre-commit
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Setup python
uses: actions/setup-python@v5
with:
python-version: '3.10'
check-latest: true
- name: Install pre-commit
run: pip install pre-commit
- name: Run checks
run: pre-commit run -a -v
- name: Git status
if: always()
run: git status
- name: Full diff
if: always()
run: git diff
tox:
name: test python ${{ matrix.py }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
py:
- "3.12"
- "3.11"
- "3.10"
steps:
- uses: actions/checkout@v4
- name: Setup python for test ${{ matrix.py }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.py }}
- name: Install dependencies
run: sudo apt -yy update && sudo apt -yy install libgirepository1.0-dev build-essential libbz2-dev libreadline-dev libssl-dev zlib1g-dev libsqlite3-dev wget curl llvm libncurses5-dev libncursesw5-dev xz-utils tk-dev libcairo2-dev
- name: Install tox
run: python -m pip install tox-gh>=1.2
- name: Setup test suite
run: tox -vv --notest
- name: Run test suite
run: tox --skip-pkg-install
14 changes: 14 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Compiled python modules.
*.pyc

# Setuptools distribution folder.
/dist/

# Python egg metadata, regenerated from source files by setuptools.
/*.egg-info

# pipx
/build/

# tox working dir
/.tox/
23 changes: 23 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
repos:
# Official repo for default hooks
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: 'v4.3.0'
hooks:
- id: check-xml
- id: check-merge-conflict
- id: mixed-line-ending
- id: trailing-whitespace
- id: end-of-file-fixer
# black repo for python formatting
- repo: https://github.com/ambv/black
rev: 22.12.0
hooks:
- id: black
- repo: https://github.com/codespell-project/codespell
rev: v2.2.2
hooks:
- id: codespell
- repo: https://github.com/tox-dev/tox-ini-fmt
rev: 1.3.1
hooks:
- id: tox-ini-fmt
Loading

0 comments on commit bc95b64

Please sign in to comment.