Skip to content

Commit

Permalink
Merge pull request #153 from dschick/develop
Browse files Browse the repository at this point in the history
New stable major release
  • Loading branch information
dschick authored Feb 1, 2024
2 parents ddeade1 + 59b015f commit b71c583
Show file tree
Hide file tree
Showing 44 changed files with 4,512 additions and 26,538 deletions.
8 changes: 6 additions & 2 deletions .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
[bumpversion]
current_version = 1.5.0
current_version = 2.0.1
commit = True
tag = False
tag = True
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)
serialize =
{major}.{minor}.{patch}

[bumpversion:file:./setup.py]
search = version='{current_version}'
replace = version='{new_version}'

[bumpversion:file:./udkm1Dsim/__init__.py]

[bumpversion:file:./docs/source/conf.py]
16 changes: 15 additions & 1 deletion .flake8
Original file line number Diff line number Diff line change
@@ -1,3 +1,17 @@
[flake8]
max-line-length=99
ignore = E121, E123, E126, E133, E226, E241, E242, E402, E704, W503, W504, W505 and W605
ignore =
E121,
E123,
E126,
E133,
E226,
E241,
E242,
E402,
E704,
W503,
W504,
W505,
W605
exclude = docs,build,dist
53 changes: 53 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: CI

on:
push:
branches:
- develop
pull_request:
branches:
- develop
- master

jobs:
python-ci:
runs-on: ${{ matrix.os }}
strategy:
matrix:
python-version: ["3.9", "3.9", "3.10", "3.11"]
os: [ubuntu-latest, macOS-latest, windows-latest]
env:
OS: ${{ matrix.os }}
PYTHON: ${{ matrix.python-version }}
name: CI workflow
steps:
- name: checkout source repo
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: "Installs dependencies"
run: |
# Upgrade pip
python3 -m pip install --upgrade pip
# Install build deps
pip install setuptools pytest pytest-cov flake8 ipython
# Install the package from setup.py
pip install .
- name: linting flake8
run: |
flake8
- name: Generate coverage report
run: |
pytest --cov=./udkm1Dsim --cov-report=xml test/
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
env_vars: OS, PYTHON
fail_ci_if_error: true
file: ./coverage.xml
flags: unittests
name: codecov-umbrella
verbose: false
44 changes: 44 additions & 0 deletions .github/workflows/upload-to-pypi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# This is a basic workflow to help you get started with Actions

name: pipy

# Controls when the action will run.
on:
# Triggers the workflow when a release is created
push:
tags:
- '*'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "upload"
upload:
# The type of runner that the job will run on
runs-on: ubuntu-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4

# Sets up python
- uses: actions/setup-python@v5
with:
python-version: 3.9

# Install dependencies
- name: "Installs dependencies"
run: |
python3 -m pip install --upgrade pip
python3 -m pip install setuptools wheel twine
# Build and upload to PyPI
- name: "Builds and uploads to PyPI"
run: |
python3 setup.py sdist bdist_wheel
python3 -m twine upload dist/*
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPITOKEN }}
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,15 @@ docs/source/**/.ipynb_checkpoints
# dask worker space
docs/source/**/dask-worker-space

# cached simulation results
docs/source/**/cache

# vscode
.vscode

#hypothesis
.hypothesis

# codecov
coverage.xml
.coverage
28 changes: 28 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-20.04
tools:
python: "3.9"

# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docs/source/conf.py

# If using Sphinx, optionally build your docs in additional formats such as PDF
formats:
- pdf
- epub

# Optionally declare the Python requirements required to build your docs
python:
install:
- requirements: docs/requirements.txt
- method: pip
path: .
22 changes: 0 additions & 22 deletions .travis.yml

This file was deleted.

147 changes: 0 additions & 147 deletions CONTRIBUTING.md

This file was deleted.

11 changes: 0 additions & 11 deletions MANIFEST.in

This file was deleted.

Loading

0 comments on commit b71c583

Please sign in to comment.