Skip to content

Commit 7f0bdd0

Browse files
committed
Configuring with plone.meta
1 parent 707cc32 commit 7f0bdd0

File tree

10 files changed

+196
-79
lines changed

10 files changed

+196
-79
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 & 9 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,24 +25,21 @@ on:
2525

2626
jobs:
2727
qa:
28-
uses: plone/meta/.github/workflows/qa.yml@main
29-
test:
30-
uses: plone/meta/.github/workflows/test.yml@main
28+
uses: plone/meta/.github/workflows/[email protected]
3129
coverage:
32-
uses: plone/meta/.github/workflows/coverage.yml@main
30+
uses: plone/meta/.github/workflows/coverage.yml@2.x
3331
dependencies:
34-
uses: plone/meta/.github/workflows/dependencies.yml@main
32+
uses: plone/meta/.github/workflows/dependencies.yml@2.x
3533
release_ready:
36-
uses: plone/meta/.github/workflows/release_ready.yml@main
34+
uses: plone/meta/.github/workflows/release_ready.yml@2.x
3735
circular:
38-
uses: plone/meta/.github/workflows/circular.yml@main
36+
uses: plone/meta/.github/workflows/circular.yml@2.x
3937

4038
##
4139
# To modify the list of default jobs being created add in .meta.toml:
4240
# [github]
4341
# jobs = [
4442
# "qa",
45-
# "test",
4643
# "coverage",
4744
# "dependencies",
4845
# "release_ready",

.github/workflows/test-matrix.yml

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
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.13", "6.2 on py3.13", "py313-plone62"]
23+
- ["3.10", "6.2 on py3.10", "py310-plone62"]
24+
25+
runs-on: ${{ matrix.os[1] }}
26+
if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name
27+
name: ${{ matrix.config[1] }}
28+
steps:
29+
- uses: actions/checkout@v5
30+
with:
31+
persist-credentials: false
32+
- name: Set up Python
33+
uses: actions/setup-python@v6
34+
with:
35+
python-version: ${{ matrix.config[0] }}
36+
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+
##
45+
- name: Pip cache
46+
uses: actions/cache@v4
47+
with:
48+
path: ~/.cache/pip
49+
key: ${{ runner.os }}-pip-${{ matrix.config[0] }}-${{ hashFiles('setup.*', 'tox.ini') }}
50+
restore-keys: |
51+
${{ runner.os }}-pip-${{ matrix.config[0] }}-
52+
${{ runner.os }}-pip-
53+
- name: Install dependencies
54+
run: |
55+
python -m pip install --upgrade pip
56+
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
62+
- name: Test
63+
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+
##

.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: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
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 = "6e36bcc4"
6+
commit-id = "2.2.2"
7+
8+
[tox]
9+
test_matrix = {"6.2" = ["*"]}
710

811
[flake8]
912
extra_lines = """

.pre-commit-config.yaml

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
ci:
55
autofix_prs: false

pyproject.toml

Lines changed: 14 additions & 6 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,<77"]
5+
requires = ["setuptools>=68.2,<80", "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
##
@@ -71,7 +71,7 @@ target-version = ["py38"]
7171
##
7272

7373
[tool.codespell]
74-
ignore-words-list = "discreet,ist,"
74+
ignore-words-list = "discreet,assertin,thet,ist,"
7575
skip = "*.po,"
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)