Skip to content

Commit

Permalink
Refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
jfnavarro committed Jan 7, 2025
1 parent 766ad6f commit 1bef5bd
Show file tree
Hide file tree
Showing 65 changed files with 4,259 additions and 3,117 deletions.
1 change: 0 additions & 1 deletion .coverage

This file was deleted.

25 changes: 25 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:

1. Command executed
2. Environment used
3. Some data to reproduce the problem
4. User

**Expected behavior**
A clear and concise description of what you expected to happen.

**Additional context**
Add any other context about the problem here.
8 changes: 8 additions & 0 deletions .github/ISSUE_TEMPLATE/custom.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
name: Custom issue template
about: Describe this issue template's purpose here.
title: ''
labels: ''
assignees: ''

---
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: ''
assignees: ''

---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
16 changes: 16 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Description

Please include a summary of the changes and the related issue.
Please also include relevant motivation and context.
List any dependencies that are required for this change.

Fixes # (issue)

## Type of change

Please delete options that are not relevant.

- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
- [ ] This change requires a documentation update
66 changes: 66 additions & 0 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: dev build CI

# Controls when the action will run.
on:
# Triggers the workflow on push or pull request events
push:
branches:
- '*'
pull_request:
branches:
- '*'
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

# contains 3 jobs: test, publish_dev_build and notification
jobs:
test:
# The type of runner that the job will run on
strategy:
matrix:
python-versions: ['3.9', '3.10', '3.11']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}

# 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
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-versions }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox tox-gh-actions poetry
- name: test with tox
run: tox

publish_dev_build:
# if test failed, we should not publish
needs: test
# you may need to change os below
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # fetch all commits/branches for mike
- uses: actions/setup-python@v5
with:
python-version: '3.12'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install poetry tox tox-gh-actions
- name: build documentation
run: |
poetry install -E doc
poetry run mkdocs build
git config --global user.name Docs deploy
git config --global user.email docs@dummy.bot.com
poetry run mike deploy -p "`poetry version --short`.dev"
poetry run mike set-default -p "`poetry version --short`.dev"
57 changes: 17 additions & 40 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ __pycache__/
# C extensions
*.so

# cythonized files
stpipeline/common/*.c

# Distribution / packaging
.Python
env/
Expand Down Expand Up @@ -46,52 +43,32 @@ htmlcov/
.cache
nosetests.xml
coverage.xml
*,cover
*.cover
.hypothesis/
.pytest_cache/
pytest-report.xml

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# pyenv
.python-version
# mkdocs documentation
/site

# celery beat schedule file
celerybeat-schedule
# mypy
.mypy_cache/

# SageMath parsed files
*.sage.py
# IDE settings
.vscode/

# dotenv
.env
# mkdocs build dir
site/

# virtualenv
.venv
venv/
ENV/
# vscode extension - local history
.history/

# Spyder project settings
.spyderproject
# Cache
__pycache__

# Rope project settings
.ropeproject
# OSX
.DS_Store
43 changes: 43 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
repos:
- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.5.4
hooks:
- id: forbid-crlf
- id: remove-crlf
- id: forbid-tabs
exclude_types: [csv, tsv]
exclude: makefile
- id: remove-tabs
exclude_types: [csv, tsv]
exclude: makefile
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.1.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-merge-conflict
- id: pretty-format-json
args: [--autofix]
- id: check-yaml
args: [--unsafe]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.1.14
hooks:
- id: ruff
args: [--fix]
- id: ruff-format
- repo: https://github.com/macisamuele/language-formatters-pre-commit-hooks
rev: v2.12.0
hooks:
- id: pretty-format-yaml
args: [--autofix, --indent, '2']
- repo: local
hooks:
- id: mypy
name: mypy
entry: mypy
exclude: ^tests
language: python
types: [python]
require_serial: true
verbose: true
34 changes: 0 additions & 34 deletions .travis.yml

This file was deleted.

3 changes: 0 additions & 3 deletions AUTHORS

This file was deleted.

5 changes: 5 additions & 0 deletions AUTHORS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
## Author:
- Jose Fernandez Navarro <jc.fernandez.navarro@gmail.com>

## Contributors:
- Erik Borgström <erik.borgstrom@scilifelab.se>
Loading

0 comments on commit 1bef5bd

Please sign in to comment.