Skip to content
This repository has been archived by the owner on Mar 8, 2024. It is now read-only.

Commit

Permalink
reworking local dev, adding nix stuff, reworking ci/cd, fixing archiv…
Browse files Browse the repository at this point in the history
…es for python 3.8+
  • Loading branch information
jpetrucciani committed Aug 3, 2021
1 parent d87fa9d commit f159ec3
Show file tree
Hide file tree
Showing 26 changed files with 164 additions and 437 deletions.
1 change: 1 addition & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
use nix
29 changes: 29 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
name: Upload Python Package

on:
release:
types: [created]

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: set up python
uses: actions/setup-python@v2
with:
python-version: '3.x'
- name: install dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
sed -i -E "s#VERSION#${GITHUB_REF/refs\/tags\//}#g" ./setup.py
sed -i -E "s#VERSION#${GITHUB_REF/refs\/tags\//}#g" ./archives/globals.py
- name: build and publish
env:
TWINE_USERNAME: ${{ secrets.PYPI_USER }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: |
python setup.py sdist bdist_wheel
twine upload dist/*
38 changes: 29 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,49 @@
name: test

on: [push, pull_request]
on: [push]

jobs:
archives:
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v2
- uses: jpetrucciani/archives-check@master
with:
path: 'archives/'
prospector:
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v2
- uses: jpetrucciani/prospector-check@master
mypy:
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v2
- uses: jpetrucciani/mypy-check@master
black:
runs-on: ubuntu-18.04
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v2
- uses: jpetrucciani/black-check@master
with:
path: 'archives/'
tests:
runs-on: ubuntu-20.04
needs: [archives, mypy, prospector, black]
strategy:
matrix:
python-version: ['3.6', '3.7', '3.8', '3.9']
name: python ${{ matrix.python-version }} tests
steps:
- uses: actions/checkout@v2
- name: setup python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
architecture: x64
- name: install requirements
run: |
pip install -r requirements.txt
pip install -r requirements.dev.txt
- name: run Tox
run: tox -e py
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -107,4 +107,7 @@ ENV/

# End of https://www.gitignore.io/api/python
old/
test_credentials.json
test_credentials.json

.vscode/
.direnv/
2 changes: 2 additions & 0 deletions .prospector.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ pylint:
- no-self-use
- unused-argument
- wrong-import-order
- unsubscriptable-object

options:
max-args: 20
Expand All @@ -44,6 +45,7 @@ pep8:
- N802
- N807
- W503
- E203
options:
max-line-length: 100
single-line-if-stmt: n
Expand Down
24 changes: 0 additions & 24 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2019 Jacobi Petrucciani
Copyright (c) 2021 Jacobi Petrucciani

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
2 changes: 2 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
include README.md
include requirements.txt
15 changes: 0 additions & 15 deletions Pipfile

This file was deleted.

Loading

0 comments on commit f159ec3

Please sign in to comment.