Skip to content

Commit 7c91767

Browse files
committed
Configuring with plone.meta
1 parent 63b5fc6 commit 7c91767

File tree

11 files changed

+226
-90
lines changed

11 files changed

+226
-90
lines changed

.editorconfig

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Generated from:
2-
# https://github.com/plone/meta/tree/main/config/default
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
33
# See the inline comments on how to expand/tweak this configuration file
44
#
55
# EditorConfig Configuration file, for more details see:
@@ -13,7 +13,8 @@
1313
root = true
1414

1515

16-
[*] # For All Files
16+
[*]
17+
# Default settings for all files.
1718
# Unix-style newlines with a newline ending every file
1819
end_of_line = lf
1920
insert_final_newline = true
@@ -33,7 +34,8 @@ indent_size = 4
3334
# 2 space indentation
3435
indent_size = 2
3536

36-
[*.{json,jsonl,js,jsx,ts,tsx,css,less,scss}] # Frontend development
37+
[*.{json,jsonl,js,jsx,ts,tsx,css,less,scss}]
38+
# Frontend development
3739
# 2 space indentation
3840
indent_size = 2
3941
max_line_length = 80

.flake8

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Generated from:
2-
# https://github.com/plone/meta/tree/main/config/default
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
33
# See the inline comments on how to expand/tweak this configuration file
44
[flake8]
55
doctests = 1

.github/dependabot.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Generated from:
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
3+
# See the inline comments on how to expand/tweak this configuration file
4+
version: 2
5+
updates:
6+
7+
- package-ecosystem: "github-actions"
8+
directory: "/"
9+
schedule:
10+
# Check for updates to GitHub Actions every week
11+
interval: "weekly"

.github/workflows/meta.yml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Generated from:
2-
# https://github.com/plone/meta/tree/main/config/default
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
33
# See the inline comments on how to expand/tweak this configuration file
44
name: Meta
55
on:
@@ -25,22 +25,21 @@ on:
2525

2626
jobs:
2727
qa:
28-
uses: plone/meta/.github/workflows/qa.yml@main
28+
uses: plone/meta/.github/workflows/qa.yml@2.x
2929
test:
30-
uses: plone/meta/.github/workflows/test.yml@main
30+
uses: plone/meta/.github/workflows/test.yml@2.x
3131
coverage:
32-
uses: plone/meta/.github/workflows/coverage.yml@main
32+
uses: plone/meta/.github/workflows/coverage.yml@2.x
3333
release_ready:
34-
uses: plone/meta/.github/workflows/release_ready.yml@main
34+
uses: plone/meta/.github/workflows/release_ready.yml@2.x
3535
circular:
36-
uses: plone/meta/.github/workflows/circular.yml@main
36+
uses: plone/meta/.github/workflows/circular.yml@2.x
3737

3838
##
3939
# To modify the list of default jobs being created add in .meta.toml:
4040
# [github]
4141
# jobs = [
4242
# "qa",
43-
# "test",
4443
# "coverage",
4544
# "dependencies",
4645
# "release_ready",

.github/workflows/test-matrix.yml

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
# Generated from:
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
3+
# See the inline comments on how to expand/tweak this configuration file
4+
name: Tests
5+
6+
on:
7+
push:
8+
9+
jobs:
10+
build:
11+
permissions:
12+
contents: read
13+
pull-requests: write
14+
strategy:
15+
# We want to see all failures:
16+
fail-fast: false
17+
matrix:
18+
os:
19+
- ["ubuntu", "ubuntu-latest"]
20+
config:
21+
# [Python version, visual name, tox env]
22+
- ["3.14", "6.2 on py3.14", "py314-plone62"]
23+
- ["3.10", "6.2 on py3.10", "py310-plone62"]
24+
- ["3.13", "6.1 on py3.13", "py313-plone61"]
25+
- ["3.10", "6.1 on py3.10", "py310-plone61"]
26+
- ["3.13", "6.0 on py3.13", "py313-plone60"]
27+
- ["3.10", "6.0 on py3.10", "py310-plone60"]
28+
29+
runs-on: ${{ matrix.os[1] }}
30+
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
31+
name: ${{ matrix.config[1] }}
32+
steps:
33+
- uses: actions/checkout@v6
34+
with:
35+
persist-credentials: false
36+
- name: Set up Python
37+
uses: actions/setup-python@v6
38+
with:
39+
python-version: ${{ matrix.config[0] }}
40+
allow-prereleases: true
41+
42+
##
43+
# Add extra configuration options in .meta.toml:
44+
# [github]
45+
# extra_lines_after_os_dependencies = """
46+
# _your own configuration lines_
47+
# """
48+
##
49+
- name: Pip cache
50+
uses: actions/cache@v5
51+
with:
52+
path: ~/.cache/pip
53+
key: ${{ runner.os }}-pip-${{ matrix.config[0] }}-${{ hashFiles('setup.*', 'tox.ini') }}
54+
restore-keys: |
55+
${{ runner.os }}-pip-${{ matrix.config[0] }}-
56+
${{ runner.os }}-pip-
57+
- name: Install dependencies
58+
run: |
59+
python -m pip install --upgrade pip
60+
pip install tox
61+
- name: Initialize tox
62+
# the bash one-liner below does not work on Windows
63+
if: contains(matrix.os, 'ubuntu')
64+
run: |
65+
if [ `tox list --no-desc -f init|wc -l` = 1 ]; then tox -e init;else true; fi
66+
- name: Test
67+
run: tox -e ${{ matrix.config[2] }}
68+
69+
70+
##
71+
# Add extra configuration options in .meta.toml:
72+
# [github]
73+
# extra_lines = """
74+
# _your own configuration lines_
75+
# """
76+
##

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Generated from:
2-
# https://github.com/plone/meta/tree/main/config/default
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
33
# See the inline comments on how to expand/tweak this configuration file
44
# python related
55
*.egg-info
@@ -20,6 +20,8 @@ __pycache__/
2020
.tox
2121
.vscode/
2222
node_modules/
23+
forest.dot
24+
forest.json
2325

2426
# venv / buildout related
2527
bin/

.meta.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# Generated from:
2-
# https://github.com/plone/meta/tree/main/config/default
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
33
# See the inline comments on how to expand/tweak this configuration file
44
[meta]
55
template = "default"
6-
commit-id = "5d3e918e"
6+
commit-id = "2.5.1"
77

88
[github]
99
jobs = [

.pre-commit-config.yaml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
11
# Generated from:
2-
# https://github.com/plone/meta/tree/main/config/default
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
33
# See the inline comments on how to expand/tweak this configuration file
44
ci:
55
autofix_prs: false
66
autoupdate_schedule: monthly
77

88
repos:
99
- repo: https://github.com/asottile/pyupgrade
10-
rev: v3.15.0
10+
rev: v3.21.2
1111
hooks:
1212
- id: pyupgrade
13-
args: [--py38-plus]
13+
args: [--py310-plus]
1414
- repo: https://github.com/pycqa/isort
15-
rev: 5.13.2
15+
rev: 8.0.1
1616
hooks:
1717
- id: isort
18-
- repo: https://github.com/psf/black
19-
rev: 24.1.1
18+
- repo: https://github.com/psf/black-pre-commit-mirror
19+
rev: 26.1.0
2020
hooks:
2121
- id: black
2222
- repo: https://github.com/collective/zpretty
23-
rev: 3.1.0
23+
rev: 3.1.1
2424
hooks:
2525
- id: zpretty
2626
# Various test failures when we change xml and html.
@@ -34,7 +34,7 @@ repos:
3434
# """
3535
##
3636
- repo: https://github.com/PyCQA/flake8
37-
rev: 7.0.0
37+
rev: 7.3.0
3838
hooks:
3939
- id: flake8
4040

@@ -46,7 +46,7 @@ repos:
4646
# """
4747
##
4848
- repo: https://github.com/codespell-project/codespell
49-
rev: v2.2.6
49+
rev: v2.4.1
5050
hooks:
5151
- id: codespell
5252
additional_dependencies:
@@ -60,20 +60,20 @@ repos:
6060
# """
6161
##
6262
- repo: https://github.com/mgedmin/check-manifest
63-
rev: "0.49"
63+
rev: "0.51"
6464
hooks:
6565
- id: check-manifest
6666
- repo: https://github.com/regebro/pyroma
67-
rev: "4.2"
67+
rev: "5.0.1"
6868
hooks:
6969
- id: pyroma
7070
- repo: https://github.com/mgedmin/check-python-versions
71-
rev: "0.22.0"
71+
rev: "0.24.0"
7272
hooks:
7373
- id: check-python-versions
7474
args: ['--only', 'setup.py,pyproject.toml']
7575
- repo: https://github.com/collective/i18ndude
76-
rev: "6.1.0"
76+
rev: "6.3.0"
7777
hooks:
7878
- id: i18ndude
7979

news/+meta.internal

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Update configuration files.
2+
[plone devs]

pyproject.toml

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Generated from:
2-
# https://github.com/plone/meta/tree/main/config/default
2+
# https://github.com/plone/meta/tree/main/src/plone/meta/default
33
# See the inline comments on how to expand/tweak this configuration file
44
[build-system]
5-
requires = ["setuptools>=68.2"]
5+
requires = ["setuptools>=68.2,<83", "wheel"]
66

77
[tool.towncrier]
88
directory = "news/"
@@ -37,7 +37,7 @@ showcontent = true
3737

3838
[[tool.towncrier.type]]
3939
directory = "tests"
40-
name = "Tests"
40+
name = "Tests:"
4141
showcontent = true
4242

4343
##
@@ -60,7 +60,7 @@ profile = "plone"
6060
##
6161

6262
[tool.black]
63-
target-version = ["py38"]
63+
target-version = ["py310"]
6464

6565
##
6666
# Add extra configuration options in .meta.toml:
@@ -71,7 +71,7 @@ target-version = ["py38"]
7171
##
7272

7373
[tool.codespell]
74-
ignore-words-list = "discreet,"
74+
ignore-words-list = "discreet,assertin,thet,"
7575
skip = "*.po,*.po,*.min.js,*.graffle,src/diazo/tests/conditional-drop-in-append*"
7676
##
7777
# Add extra configuration options in .meta.toml:
@@ -119,6 +119,7 @@ Zope = [
119119
'Products.CMFCore', 'Products.CMFDynamicViewFTI',
120120
]
121121
python-dateutil = ['dateutil']
122+
pytest-plone = ['pytest', 'zope.pytestlayer', 'plone.testing', 'plone.app.testing']
122123

123124
##
124125
# Add extra configuration options in .meta.toml:
@@ -133,20 +134,27 @@ python-dateutil = ['dateutil']
133134
[tool.check-manifest]
134135
ignore = [
135136
".editorconfig",
137+
".flake8",
136138
".meta.toml",
137139
".pre-commit-config.yaml",
138-
"tox.ini",
139-
".flake8",
140+
"dependabot.yml",
140141
"mx.ini",
142+
"tox.ini",
141143

142144
]
145+
143146
##
144147
# Add extra configuration options in .meta.toml:
145148
# [pyproject]
146149
# check_manifest_ignores = """
147150
# "*.map.js",
148151
# "*.pyc",
149152
# """
153+
# check_manifest_extra_lines = """
154+
# ignore-bad-ideas = [
155+
# "some/test/file/PKG-INFO",
156+
# ]
157+
# """
150158
##
151159

152160

0 commit comments

Comments
 (0)