Skip to content

Commit c8eccca

Browse files
committed
github actions workflow wip
1 parent d7fac7d commit c8eccca

File tree

7 files changed

+129
-192
lines changed

7 files changed

+129
-192
lines changed

.circleci/config.yml

Lines changed: 0 additions & 143 deletions
This file was deleted.

.github/workiflows/python.yaml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: python
2+
on:
3+
push:
4+
5+
jobs:
6+
tests:
7+
runs-on: ubuntu-latest
8+
strategy:
9+
matrix:
10+
python-version: ["3.7", "3.11"]
11+
defaults:
12+
run:
13+
working-directory: python
14+
15+
steps:
16+
- uses: actions/checkout@v3
17+
- name: setup
18+
uses: actions/setup-python@v4
19+
with:
20+
python-version: ${{ matrix.python-version }}
21+
- name: install
22+
run: |
23+
python -m pip install --upgrade pip
24+
python -m pip install -r ci_requirements.txt
25+
- name: test
26+
run: |
27+
pytest --cov=covertable
28+
- name: codecov
29+
uses: codecov/codecov-action@v3
30+
with:
31+
token: ${{ secrets.CODECOV_TOKEN }}
32+
verbose: true
33+
34+
release:
35+
needs: tests
36+
runs-on: ubuntu-latest
37+
defaults:
38+
run:
39+
working-directory: python
40+
if: github.ref == 'refs/heads/master'
41+
name: npm upload
42+
steps:
43+
- uses: actions/checkout@v3
44+
- name: setup
45+
uses: actions/setup-python@v4
46+
with:
47+
python-version: 3.11
48+
- name: install
49+
run: |
50+
python -m pip install --upgrade pip
51+
python -m pip install -r ci_requirements.txt
52+
- name: build
53+
run: |
54+
python ./setup.py sdist bdist_wheel
55+
twine upload dist/* --non-interactive --skip-existing
56+
- name: upload
57+
run: twine upload dist/* --non-interactive --skip-existing
58+
env:
59+
TWINE_USERNAME: __token__
60+
TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}

.github/workiflows/typescript.yaml

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
name: typescript
2+
on:
3+
push:
4+
5+
jobs:
6+
tests:
7+
runs-on: ubuntu-latest
8+
defaults:
9+
run:
10+
working-directory: typescript
11+
12+
steps:
13+
- uses: actions/checkout@v3
14+
- name: setup
15+
uses: actions/setup-node@v3
16+
with:
17+
node-version: "16"
18+
- name: cache
19+
uses: actions/cache@v3
20+
with:
21+
path: |
22+
node_modules
23+
key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
24+
- name: install
25+
run: |
26+
npm install
27+
- name: test
28+
run: |
29+
npm test -- --coverage
30+
npm run codecov
31+
- name: codecov
32+
uses: codecov/codecov-action@v3
33+
with:
34+
token: ${{ secrets.CODECOV_TOKEN }}
35+
verbose: true
36+
37+
release:
38+
needs: tests
39+
runs-on: ubuntu-latest
40+
defaults:
41+
run:
42+
working-directory: typescript
43+
44+
if: github.ref == 'refs/heads/master'
45+
name: npm upload
46+
steps:
47+
- uses: actions/checkout@v3
48+
- name: setup
49+
uses: actions/setup-node@v3
50+
with:
51+
node-version: "16"
52+
- name: cache
53+
uses: actions/cache@v3
54+
with:
55+
path: |
56+
node_modules
57+
key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
58+
- name: upload
59+
run: |
60+
npm install
61+
npm run build
62+
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > .npmrc
63+
npm run publish || true

README.rst

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,3 @@ History
200200
:1.0.x:
201201

202202
- First release 🎉
203-
204-
.. note::
205-
206-
It moved from `twopairs`.

python/ci_requirements.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
tox
1+
pytest
2+
pytest-cov
23
setuptools
34
wheel
45
twine
6+
black

python/pytest.ini

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[pytest]
2+
python_files = tests.py
3+

python/tox.ini

Lines changed: 0 additions & 44 deletions
This file was deleted.

0 commit comments

Comments
 (0)