Skip to content

Commit 4b5d248

Browse files
authored
chore: Update release flow and drop python 3.7 (#157)
1 parent d4836f4 commit 4b5d248

File tree

55 files changed

+250
-189
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+250
-189
lines changed

.github/workflows/codecov.yml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,14 @@ jobs:
1212
strategy:
1313
fail-fast: false
1414
matrix:
15-
python-version: [ 3.7, 3.8, 3.9, "3.10"]
15+
python-version: [ 3.8, 3.9, "3.10"]
1616
requirements-file: [
1717
dj22_cms37.txt,
1818
dj22_cms38.txt,
1919
dj22_cms39.txt,
20-
dj30_cms37.txt,
21-
dj30_cms38.txt,
22-
dj30_cms39.txt,
23-
dj31_cms38.txt,
24-
dj31_cms39.txt,
2520
dj32_cms39.txt,
2621
dj32_cms310.txt,
22+
dj32_cms311.txt,
2723
]
2824
os: [
2925
ubuntu-20.04,

.github/workflows/lint-pr.yml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: "Lint PR"
2+
3+
# Validates PR titles against the conventional commit spec
4+
# https://github.com/commitizen/conventional-commit-types
5+
6+
on:
7+
pull_request_target:
8+
types:
9+
- opened
10+
- edited
11+
- synchronize
12+
13+
jobs:
14+
main:
15+
name: Validate PR title
16+
runs-on: ubuntu-latest
17+
steps:
18+
- uses: amannn/action-semantic-pull-request@v4
19+
env:
20+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,4 @@ jobs:
4040
uses: liskin/gh-problem-matcher-wrap@v1
4141
with:
4242
linters: isort
43-
run: isort -c -rc -df djangocms_bootstrap4
43+
run: isort --check --diff djangocms_bootstrap4
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Publish Python 🐍 distributions 📦 to pypi
2+
3+
on:
4+
release:
5+
types:
6+
- published
7+
8+
jobs:
9+
build-n-publish:
10+
name: Build and publish Python 🐍 distributions 📦 to pypi
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@master
14+
- name: Set up Python 3.9
15+
uses: actions/setup-python@v1
16+
with:
17+
python-version: 3.9
18+
19+
- name: Install pypa/build
20+
run: >-
21+
python -m
22+
pip install
23+
build
24+
--user
25+
- name: Build a binary wheel and a source tarball
26+
run: >-
27+
python -m
28+
build
29+
--sdist
30+
--wheel
31+
--outdir dist/
32+
.
33+
34+
- name: PyPI - Publish distribution 📦
35+
if: startsWith(github.ref, 'refs/tags')
36+
uses: pypa/gh-action-pypi-publish@release/v1
37+
with:
38+
user: __token__
39+
password: ${{ secrets.PYPI_API_TOKEN }}
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Publish Python 🐍 distributions 📦 to TestPyPI
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
build-n-publish:
10+
name: TestPyPI - Build and publish Python 🐍 distributions 📦
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@master
14+
- name: Set up Python 3.9
15+
uses: actions/setup-python@v1
16+
with:
17+
python-version: 3.9
18+
19+
- name: Install pypa/build
20+
run: >-
21+
python -m
22+
pip install
23+
build
24+
--user
25+
- name: Build a binary wheel and a source tarball
26+
run: >-
27+
python -m
28+
build
29+
--sdist
30+
--wheel
31+
--outdir dist/
32+
.
33+
34+
- name: Publish distribution 📦 to Test PyPI
35+
uses: pypa/gh-action-pypi-publish@release/v1
36+
with:
37+
user: __token__
38+
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
39+
repository_url: https://test.pypi.org/legacy/
40+
skip_existing: true

.pre-commit-config.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
ci:
2+
autofix_commit_msg: |
3+
ci: auto fixes from pre-commit hooks
4+
5+
for more information, see https://pre-commit.ci
6+
autofix_prs: false
7+
autoupdate_commit_msg: 'ci: pre-commit autoupdate'
8+
autoupdate_schedule: monthly
9+
110
repos:
211
- repo: https://github.com/asottile/pyupgrade
312
rev: v2.29.0

djangocms_bootstrap4/contrib/bootstrap4_card/migrations/0001_initial.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,7 @@
55
import djangocms_bootstrap4.fields
66
from djangocms_bootstrap4.constants import TAG_CHOICES
77

8-
from ..constants import (
9-
CARD_ALIGNMENT_CHOICES, CARD_INNER_TYPE_CHOICES, CARD_TAG_CHOICES,
10-
CARD_TYPE_CHOICES,
11-
)
8+
from ..constants import CARD_ALIGNMENT_CHOICES, CARD_INNER_TYPE_CHOICES, CARD_TAG_CHOICES, CARD_TYPE_CHOICES
129
from ..models import CARD_COLOR_STYLE_CHOICES, CARD_TEXT_STYLES
1310

1411

djangocms_bootstrap4/contrib/bootstrap4_card/models.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,7 @@
66
from djangocms_bootstrap4.constants import COLOR_STYLE_CHOICES
77
from djangocms_bootstrap4.fields import AttributesField, TagTypeField
88

9-
from .constants import (
10-
CARD_ALIGNMENT_CHOICES, CARD_INNER_TYPE_CHOICES, CARD_TYPE_CHOICES,
11-
)
9+
from .constants import CARD_ALIGNMENT_CHOICES, CARD_INNER_TYPE_CHOICES, CARD_TYPE_CHOICES
1210

1311

1412
# cards allow for a transparent color

djangocms_bootstrap4/contrib/bootstrap4_carousel/migrations/0001_initial.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,7 @@
1111
import djangocms_bootstrap4.fields
1212
from djangocms_bootstrap4.constants import TAG_CHOICES
1313

14-
from ..constants import (
15-
CAROUSEL_PAUSE_CHOICES, CAROUSEL_RIDE_CHOICES, CAROUSEL_TEMPLATE_CHOICES,
16-
)
14+
from ..constants import CAROUSEL_PAUSE_CHOICES, CAROUSEL_RIDE_CHOICES, CAROUSEL_TEMPLATE_CHOICES
1715

1816

1917
class Migration(migrations.Migration):

djangocms_bootstrap4/contrib/bootstrap4_carousel/models.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@
1313
from djangocms_bootstrap4.fields import AttributesField, TagTypeField
1414

1515
from .constants import (
16-
CAROUSEL_ASPECT_RATIO_CHOICES, CAROUSEL_PAUSE_CHOICES,
17-
CAROUSEL_RIDE_CHOICES, CAROUSEL_TEMPLATE_CHOICES,
16+
CAROUSEL_ASPECT_RATIO_CHOICES, CAROUSEL_PAUSE_CHOICES, CAROUSEL_RIDE_CHOICES, CAROUSEL_TEMPLATE_CHOICES,
1817
)
1918

2019

0 commit comments

Comments
 (0)