Skip to content

Commit 74444dd

Browse files
authored
chore: rework dev setup (#214)
* chore: rework dev setup * chore: remove changelog from package description
1 parent 7c9aba7 commit 74444dd

18 files changed

Lines changed: 119 additions & 211 deletions

.flake8

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
[flake8]
2+
extend-ignore =
3+
E501
4+
extend-exclude =
5+
docs

.github/ISSUE_TEMPLATE.md

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

.github/workflows/code_style.yml

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

.github/workflows/lint.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Lint
2+
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
7+
8+
jobs:
9+
pre-commit:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v3
13+
14+
- name: Setup python
15+
uses: actions/setup-python@v4
16+
with:
17+
python-version: 3.x
18+
19+
- name: Install dependencies
20+
run: pip install pre-commit
21+
22+
- name: Run pre-commit
23+
run: pre-commit run --all-files --show-diff-on-failure

.github/workflows/release-please.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1+
name: Release please
2+
13
on:
24
push:
3-
branches:
4-
- main
5-
name: release-please
5+
branches: [main]
66

77
jobs:
88
release-please:

.github/workflows/release.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,10 @@ jobs:
1313
- name: Set up Python
1414
uses: actions/setup-python@v4
1515
with:
16-
python-version: "3.x"
16+
python-version: 3.x
1717

1818
- name: Install dependencies
19-
run: |
20-
pip install --upgrade pip
21-
pip install --upgrade build twine
19+
run: pip install build twine
2220

2321
- name: Build
2422
run: python3 -m build
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: "Close stale issues"
1+
name: Close stale issues
22

33
on:
44
schedule:
Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,29 @@
1-
name: Unit Tests
1+
name: Test
22

3-
on: [push, pull_request]
3+
on:
4+
push:
5+
branches: [main]
6+
pull_request:
47

58
jobs:
6-
build:
9+
test:
710
runs-on: ubuntu-latest
11+
812
strategy:
913
matrix:
1014
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]
15+
1116
name: Python ${{ matrix.python-version }}
1217
steps:
1318
- uses: actions/checkout@v3
19+
1420
- name: Setup python
1521
uses: actions/setup-python@v4
1622
with:
1723
python-version: ${{ matrix.python-version }}
18-
architecture: x64
24+
1925
- name: Install dependencies
20-
run: |
21-
python -m pip install --upgrade pip
22-
pip install -r requirements/test.txt
23-
pip install tox tox-gh-actions
24-
sudo apt install build-essential
25-
- name: Test with tox
26+
run: pip install tox tox-gh-actions
27+
28+
- name: Run tox
2629
run: tox
27-
env:
28-
PLATFORM: ${{ matrix.platform }}

.gitlab-ci.yml

Lines changed: 20 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,29 @@
1+
default:
2+
tags:
3+
- cloud-integrations
4+
15
stages:
26
- test
37

4-
.tests_template: &tests_template
5-
before_script:
6-
- pip install tox
7-
- apk add build-base git
8+
pre-commit:
89
stage: test
9-
script: tox
10-
tags:
11-
- hc-bladerunner
12-
13-
python37:
14-
<<: *tests_template
15-
image: python:3.7-alpine
16-
script: tox -e py37
17-
18-
python38:
19-
<<: *tests_template
20-
image: python:3.8-alpine
21-
script: tox -e py38
2210

23-
python39:
24-
<<: *tests_template
25-
image: python:3.9-alpine
26-
script: tox -e py39
11+
image: python:3.11-alpine
12+
before_script:
13+
- apk add build-base git
14+
- pip install pre-commit
15+
script:
16+
- pre-commit run --all-files --show-diff-on-failure
2717

28-
python310:
29-
<<: *tests_template
30-
image: python:3.10-alpine
31-
script: tox -e py310
18+
test:
19+
stage: test
3220

33-
python311:
34-
<<: *tests_template
35-
image: python:3.11-alpine
36-
script: tox -e py311
21+
parallel:
22+
matrix:
23+
- python_version: ["3.7", "3.8", "3.9", "3.10", "3.11"]
3724

38-
test-style:
39-
<<: *tests_template
40-
image: python:3.9-alpine
25+
image: python:${python_version}-alpine
26+
before_script:
27+
- pip install tox
4128
script:
42-
- tox -e pre-commit
29+
- tox -e ${python_version}

.pre-commit-config.yaml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ repos:
3838
rev: 5.12.0
3939
hooks:
4040
- id: isort
41-
args: [--profile=black]
4241

4342
- repo: https://github.com/psf/black
4443
rev: 23.3.0

0 commit comments

Comments
 (0)