Skip to content

Commit eaa6e17

Browse files
committed
Configuring with plone.meta
1 parent f8c037c commit eaa6e17

File tree

5 files changed

+36
-25
lines changed

5 files changed

+36
-25
lines changed

.github/workflows/test-matrix.yml

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,23 +21,27 @@ jobs:
2121
# [Python version, visual name, tox env]
2222
- ["3.13", "6.2 on py3.13", "py313-plone62"]
2323
- ["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.9", "6.0 on py3.9", "py39-plone60"]
27-
- ["3.13", "6.0 on py3.13", "py313-plone60"]
2824

2925
runs-on: ${{ matrix.os[1] }}
3026
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
3127
name: ${{ matrix.config[1] }}
3228
steps:
33-
- uses: actions/checkout@v4
29+
- uses: actions/checkout@v5
3430
with:
3531
persist-credentials: false
3632
- name: Set up Python
37-
uses: actions/setup-python@v5
33+
uses: actions/setup-python@v6
3834
with:
3935
python-version: ${{ matrix.config[0] }}
4036
allow-prereleases: true
37+
38+
##
39+
# Add extra configuration options in .meta.toml:
40+
# [github]
41+
# extra_lines_after_os_dependencies = """
42+
# _your own configuration lines_
43+
# """
44+
##
4145
- name: Pip cache
4246
uses: actions/cache@v4
4347
with:
@@ -50,5 +54,19 @@ jobs:
5054
run: |
5155
python -m pip install --upgrade pip
5256
pip install tox
57+
- name: Initialize tox
58+
# the bash one-liner below does not work on Windows
59+
if: contains(matrix.os, 'ubuntu')
60+
run: |
61+
if [ `tox list --no-desc -f init|wc -l` = 1 ]; then tox -e init;else true; fi
5362
- name: Test
5463
run: tox -e ${{ matrix.config[2] }}
64+
65+
66+
##
67+
# Add extra configuration options in .meta.toml:
68+
# [github]
69+
# extra_lines = """
70+
# _your own configuration lines_
71+
# """
72+
##

.meta.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,10 @@
33
# See the inline comments on how to expand/tweak this configuration file
44
[meta]
55
template = "default"
6-
commit-id = "2.0.1.dev0"
6+
commit-id = "2.2.2"
7+
8+
[tox]
9+
test_matrix = {"6.2" = ["*"]}
710

811
[pre_commit]
912
extra_lines = """

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ repos:
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

@@ -32,7 +32,7 @@ repos:
3232
# """
3333
##
3434
- repo: https://github.com/PyCQA/flake8
35-
rev: 7.2.0
35+
rev: 7.3.0
3636
hooks:
3737
- id: flake8
3838

@@ -62,7 +62,7 @@ repos:
6262
hooks:
6363
- id: check-manifest
6464
- repo: https://github.com/regebro/pyroma
65-
rev: "4.2"
65+
rev: "5.0"
6666
hooks:
6767
- id: pyroma
6868
- repo: https://github.com/mgedmin/check-python-versions

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# 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,<77", "wheel"]
5+
requires = ["setuptools>=68.2,<80", "wheel"]
66

77
[tool.towncrier]
88
directory = "news/"

tox.ini

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -11,25 +11,17 @@ envlist =
1111
py312-plone62
1212
py311-plone62
1313
py310-plone62
14-
py313-plone61
15-
py312-plone61
16-
py311-plone61
17-
py310-plone61
18-
py313-plone60
19-
py312-plone60
20-
py311-plone60
21-
py310-plone60
22-
py39-plone60
2314
dependencies
2415

2516

2617
##
2718
# Add extra configuration options in .meta.toml:
2819
# - to specify a custom testing combination of Plone and python versions, use `test_matrix`
20+
# Use ["*"] to use all supported Python versions for this Plone version.
2921
# - to specify extra custom environments, use `envlist_lines`
3022
# - to specify extra `tox` top-level options, use `config_lines`
3123
# [tox]
32-
# test_matrix = {"6.2" = ["3.13", "3.12"], "6.1" = ["3.10", "3.9"]}
24+
# test_matrix = {"6.2" = ["3.13", "3.12"], "6.1" = ["*"]}
3325
# envlist_lines = """
3426
# my_other_environment
3527
# """
@@ -119,8 +111,6 @@ set_env =
119111
deps =
120112
{[test_runner]deps}
121113
plone62: -c https://dist.plone.org/release/6.2-dev/constraints.txt
122-
plone61: -c https://dist.plone.org/release/6.1-dev/constraints.txt
123-
plone60: -c https://dist.plone.org/release/6.0-dev/constraints.txt
124114

125115
##
126116
# Specify additional deps in .meta.toml:
@@ -161,6 +151,7 @@ set_env = {[base]set_env}
161151
deps =
162152
{[test_runner]deps}
163153
-c https://dist.plone.org/release/6.2-dev/constraints.txt
154+
164155
commands = {[test_runner]test}
165156
extras = {[base]extras}
166157

@@ -186,6 +177,7 @@ deps =
186177
{[test_runner]deps}
187178
coverage
188179
-c https://dist.plone.org/release/6.2-dev/constraints.txt
180+
189181
commands = {[test_runner]coverage}
190182
extras = {[base]extras}
191183

@@ -198,7 +190,6 @@ deps =
198190
build
199191
towncrier
200192
-c https://dist.plone.org/release/6.2-dev/constraints.txt
201-
202193
commands =
203194
# fake version to not have to install the package
204195
# we build the change log as news entries might break
@@ -229,7 +220,6 @@ deps =
229220
pipdeptree
230221
pipforester
231222
-c https://dist.plone.org/release/6.2-dev/constraints.txt
232-
233223
commands =
234224
# Generate the full dependency tree
235225
sh -c 'pipdeptree -j > forest.json'

0 commit comments

Comments
 (0)