Skip to content

Commit 46a3c01

Browse files
committed
Configuring with plone.meta
1 parent 59c9e57 commit 46a3c01

File tree

11 files changed

+685
-162
lines changed

11 files changed

+685
-162
lines changed

.editorconfig

Lines changed: 25 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
1-
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+
#
25
# EditorConfig Configuration file, for more details see:
3-
# https://EditorConfig.org
6+
# http://EditorConfig.org
47
# EditorConfig is a convention description, that could be interpreted
58
# by multiple editors to enforce common coding conventions for specific
69
# file types
@@ -10,7 +13,8 @@
1013
root = true
1114

1215

13-
[*] # For All Files
16+
[*]
17+
# Default settings for all files.
1418
# Unix-style newlines with a newline ending every file
1519
end_of_line = lf
1620
insert_final_newline = true
@@ -19,17 +23,34 @@ trim_trailing_whitespace = true
1923
charset = utf-8
2024
# Indent style default
2125
indent_style = space
26+
# Max Line Length - a hard line wrap, should be disabled
27+
max_line_length = off
2228

2329
[*.{py,cfg,ini}]
2430
# 4 space indentation
2531
indent_size = 4
2632

27-
[*.{html,dtml,pt,zpt,xml,zcml,js,json,ts,less,scss,css,sass,yml,yaml}]
33+
[*.{yml,zpt,pt,dtml,zcml,html,xml}]
34+
# 2 space indentation
35+
indent_size = 2
36+
37+
[*.{json,jsonl,js,jsx,ts,tsx,css,less,scss}]
38+
# Frontend development
2839
# 2 space indentation
2940
indent_size = 2
41+
max_line_length = 80
3042

3143
[{Makefile,.gitmodules}]
3244
# Tab indentation (no size specified, but view as 4 spaces)
3345
indent_style = tab
3446
indent_size = unset
3547
tab_width = unset
48+
49+
50+
##
51+
# Add extra configuration options in .meta.toml:
52+
# [editorconfig]
53+
# extra_lines = """
54+
# _your own configuration lines_
55+
# """
56+
##

.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/master/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: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
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: Meta
5+
on:
6+
push:
7+
branches:
8+
- master
9+
- main
10+
pull_request:
11+
branches:
12+
- master
13+
- main
14+
workflow_dispatch:
15+
16+
##
17+
# To set environment variables for all jobs, add in .meta.toml:
18+
# [github]
19+
# env = """
20+
# debug: 1
21+
# image-name: 'org/image'
22+
# image-tag: 'latest'
23+
# """
24+
##
25+
26+
jobs:
27+
qa:
28+
uses: plone/meta/.github/workflows/qa.yml@2.x
29+
coverage:
30+
uses: plone/meta/.github/workflows/coverage.yml@2.x
31+
dependencies:
32+
uses: plone/meta/.github/workflows/dependencies.yml@2.x
33+
release_ready:
34+
uses: plone/meta/.github/workflows/release_ready.yml@2.x
35+
circular:
36+
uses: plone/meta/.github/workflows/circular.yml@2.x
37+
38+
##
39+
# To modify the list of default jobs being created add in .meta.toml:
40+
# [github]
41+
# jobs = [
42+
# "qa",
43+
# "coverage",
44+
# "dependencies",
45+
# "release_ready",
46+
# "circular",
47+
# ]
48+
##
49+
50+
##
51+
# To request that some OS level dependencies get installed
52+
# when running tests/coverage jobs, add in .meta.toml:
53+
# [github]
54+
# os_dependencies = "git libxml2 libxslt"
55+
##
56+
57+
58+
##
59+
# Specify additional jobs in .meta.toml:
60+
# [github]
61+
# extra_lines = """
62+
# another:
63+
# uses: org/repo/.github/workflows/file.yml@main
64+
# """
65+
##

.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.13", "6.2 on py3.13", "py313-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: 27 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,58 @@
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
14
# python related
25
*.egg-info
36
*.pyc
47
*.pyo
58

9+
# translation related
10+
*.mo
11+
612
# tools related
7-
__pycache__/
13+
build/
814
.coverage
9-
.mypy_cache
10-
.pytest_cache
11-
.ruff_cache
12-
/build/
15+
.*project
1316
coverage.xml
1417
dist/
1518
docs/_build
19+
__pycache__/
20+
.tox
21+
.vscode/
1622
node_modules/
23+
forest.dot
24+
forest.json
1725

1826
# venv / buildout related
19-
.eggs/
20-
.installed.cfg
21-
.mr.developer.cfg
22-
.venv/
2327
bin/
2428
develop-eggs/
2529
eggs/
30+
.eggs/
2631
etc/
32+
.installed.cfg
2733
include/
2834
lib/
2935
lib64
36+
.mr.developer.cfg
3037
parts/
3138
pyvenv.cfg
3239
var/
40+
local.cfg
3341

3442
# mxdev
35-
.installed.txt
36-
.lock
43+
/instance/
3744
/.make-sentinels/
3845
/*-mxdev.txt
39-
/instance/
4046
/reports/
4147
/sources/
4248
/venv/
43-
constraints*.txt
44-
requirements*.txt
45-
.mxdev_cache
49+
.installed.txt
50+
4651

52+
##
53+
# Add extra configuration options in .meta.toml:
54+
# [gitignore]
55+
# extra_lines = """
56+
# _your own configuration lines_
57+
# """
58+
##

.meta.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
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+
[meta]
5+
template = "default"
6+
commit-id = "2.3.2"

.pre-commit-config.yaml

Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
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+
ci:
5+
autofix_prs: false
6+
autoupdate_schedule: monthly
7+
8+
repos:
9+
- repo: https://github.com/asottile/pyupgrade
10+
rev: v3.21.2
11+
hooks:
12+
- id: pyupgrade
13+
args: [--py38-plus]
14+
- repo: https://github.com/pycqa/isort
15+
rev: 7.0.0
16+
hooks:
17+
- id: isort
18+
- repo: https://github.com/psf/black-pre-commit-mirror
19+
rev: 25.12.0
20+
hooks:
21+
- id: black
22+
- repo: https://github.com/collective/zpretty
23+
rev: 3.1.1
24+
hooks:
25+
- id: zpretty
26+
27+
##
28+
# Add extra configuration options in .meta.toml:
29+
# [pre_commit]
30+
# zpretty_extra_lines = """
31+
# _your own configuration lines_
32+
# """
33+
##
34+
- repo: https://github.com/PyCQA/flake8
35+
rev: 7.3.0
36+
hooks:
37+
- id: flake8
38+
39+
##
40+
# Add extra configuration options in .meta.toml:
41+
# [pre_commit]
42+
# flake8_extra_lines = """
43+
# _your own configuration lines_
44+
# """
45+
##
46+
- repo: https://github.com/codespell-project/codespell
47+
rev: v2.4.1
48+
hooks:
49+
- id: codespell
50+
additional_dependencies:
51+
- tomli
52+
53+
##
54+
# Add extra configuration options in .meta.toml:
55+
# [pre_commit]
56+
# codespell_extra_lines = """
57+
# _your own configuration lines_
58+
# """
59+
##
60+
- repo: https://github.com/mgedmin/check-manifest
61+
rev: "0.51"
62+
hooks:
63+
- id: check-manifest
64+
- repo: https://github.com/regebro/pyroma
65+
rev: "5.0.1"
66+
hooks:
67+
- id: pyroma
68+
- repo: https://github.com/mgedmin/check-python-versions
69+
rev: "0.24.0"
70+
hooks:
71+
- id: check-python-versions
72+
args: ['--only', 'setup.py,pyproject.toml']
73+
- repo: https://github.com/collective/i18ndude
74+
rev: "6.3.0"
75+
hooks:
76+
- id: i18ndude
77+
78+
79+
##
80+
# Add extra configuration options in .meta.toml:
81+
# [pre_commit]
82+
# i18ndude_extra_lines = """
83+
# _your own configuration lines_
84+
# """
85+
##
86+
87+
88+
##
89+
# Add extra configuration options in .meta.toml:
90+
# [pre_commit]
91+
# extra_lines = """
92+
# _your own configuration lines_
93+
# """
94+
##

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]

0 commit comments

Comments
 (0)