Skip to content

Commit 8e1366a

Browse files
authored
chore(copier): update from template
1 parent 571fa30 commit 8e1366a

File tree

7 files changed

+151
-31
lines changed

7 files changed

+151
-31
lines changed

.config/copier/.copier-answers.python.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# This file is @generated by <https://github.com/liblaf/copier-python>.
22
# DO NOT EDIT!
33
# prettier-ignore
4-
_commit: c22d7f1
4+
_commit: f7444d2
55
_src_path: gh:liblaf/copier-python
66
answers_file_shared: .config/copier/.copier-answers.shared.yaml
77
namespace: ''
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# This file is @generated by <https://github.com/liblaf/copier-release>.
22
# DO NOT EDIT!
33
# prettier-ignore
4-
_commit: 55dfc73
4+
_commit: '3146846'
55
_src_path: gh:liblaf/copier-release
66
release_type: python

.config/copier/.copier-answers.shared.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# This file is @generated by <https://github.com/liblaf/copier-shared>.
22
# DO NOT EDIT!
33
# prettier-ignore
4-
_commit: 610df18
4+
_commit: 1aa0c04
55
_src_path: gh:liblaf/copier-shared
66
author_email: [email protected]
77
author_name: liblaf

.config/release-please/config.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@
5050
"section": "⏪️ Reverts"
5151
}
5252
],
53-
"extra-label": "automerge",
5453
"include-component-in-tag": false,
5554
"always-update": true,
5655
"initial-version": "0.1.0",

.github/workflows/mega-linter.yaml

Lines changed: 12 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -8,45 +8,34 @@ name: MegaLinter
88

99
on:
1010
push:
11-
pull_request:
1211
workflow_dispatch:
1312

1413
jobs:
15-
skip-duplicate:
16-
name: Skip Duplicate
17-
permissions:
18-
actions: write
19-
runs-on: ubuntu-latest
20-
outputs:
21-
should-skip: ${{ steps.skip-duplicate.outputs.should-skip }}
22-
steps:
23-
- id: skip-duplicate
24-
name: Skip Duplicate
25-
uses: liblaf/actions/skip-duplicate@dist
26-
with:
27-
cancel-others: true
28-
2914
mega-linter:
3015
name: MegaLinter
3116
permissions:
3217
contents: write
33-
issues: write
3418
pull-requests: write
35-
needs:
36-
- skip-duplicate
37-
if: needs.skip-duplicate.outputs.should-skip != 'true'
19+
environment:
20+
name: MegaLinter
3821
runs-on: ubuntu-latest
3922
steps:
23+
- id: auth
24+
name: Auth
25+
uses: liblaf/actions/auth@dist
26+
with:
27+
app-id: ${{ vars.APP_ID }}
28+
private-key: ${{ secrets.PRIVATE_KEY }}
4029
- name: Checkout
4130
uses: actions/checkout@v5
42-
with:
43-
ref: ${{ github.head_ref || github.ref }}
4431
- id: lint
4532
name: MegaLinter
4633
uses: liblaf/actions/mega-linter@dist
34+
with:
35+
token: ${{ steps.auth.outputs.token }}
4736
- if: success() || failure()
4837
name: Upload Reports
49-
uses: actions/upload-artifact@v4
38+
uses: actions/upload-artifact@v5
5039
with:
5140
name: mega-linter-reports
5241
path: |-
@@ -67,9 +56,7 @@ jobs:
6756
sign-commits: true
6857
title: "chore(mega-linter): apply linters automatic fixes"
6958
body-path: ${{ runner.temp }}/megalinter-report.md
70-
labels: |-
71-
autofix
72-
automerge
59+
labels: auto,automerge
7360
assignees: ${{ github.repository_owner }}
7461
reviewers: ${{ github.repository_owner }}
7562
- if: steps.lint.outputs.has-updated-sources > 0 && github.ref != 'refs/heads/main'
Lines changed: 134 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,134 @@
1+
# This file is @generated by <https://github.com/liblaf/copier-release>.
2+
# DO NOT EDIT!
3+
4+
name: Release Please
5+
6+
on:
7+
push:
8+
branches:
9+
- main
10+
11+
jobs:
12+
release-please:
13+
name: Release Please
14+
permissions:
15+
contents: write
16+
pull-requests: write
17+
runs-on: ubuntu-latest
18+
environment:
19+
name: Release Please
20+
outputs:
21+
pr: ${{ steps.release-please.outputs.pr }}
22+
prs_created: ${{ steps.release-please.outputs.prs_created }}
23+
release_created: ${{ steps.release-please.outputs.release_created }}
24+
tag: ${{ steps.release-please.outputs.tag_name }}
25+
steps:
26+
- id: auth
27+
name: Auth
28+
uses: liblaf/actions/auth@dist
29+
with:
30+
app-id: ${{ vars.APP_ID }}
31+
private-key: ${{ secrets.PRIVATE_KEY }}
32+
- name: Checkout
33+
uses: actions/checkout@v5
34+
with:
35+
token: ${{ steps.auth.outputs.token }}
36+
- id: release-please
37+
name: Release Please
38+
uses: googleapis/release-please-action@v4
39+
with:
40+
token: ${{ steps.auth.outputs.token }}
41+
config-file: .config/release-please/config.json
42+
manifest-file: .config/release-please/.manifest.json
43+
44+
post-pr:
45+
name: Post PR
46+
permissions:
47+
contents: write
48+
pull-requests: write
49+
needs:
50+
- release-please
51+
if: ${{ needs.release-please.outputs.pr }}
52+
runs-on: ubuntu-latest
53+
environment:
54+
name: Release Please
55+
steps:
56+
- id: auth
57+
name: Auth
58+
uses: liblaf/actions/auth@dist
59+
with:
60+
app-id: ${{ vars.APP_ID }}
61+
private-key: ${{ secrets.PRIVATE_KEY }}
62+
- name: Checkout
63+
uses: actions/checkout@v5
64+
with:
65+
ref: ${{ fromJson(needs.release-please.outputs.pr).headBranchName }}
66+
token: ${{ steps.auth.outputs.token }}
67+
fetch-depth: 0
68+
- id: tag
69+
name: Get Tag
70+
run: |-
71+
title='${{ fromJson(needs.release-please.outputs.pr).title }}'
72+
version="$(awk '{ print $NF }' <<< "$title")"
73+
printf 'tag=%s\n' "v$version" >> "$GITHUB_OUTPUT"
74+
- name: Changelog
75+
uses: liblaf/actions/changelog@dist
76+
with:
77+
output: CHANGELOG.md
78+
args: --tag '${{ steps.tag.outputs.tag }}'
79+
- id: message
80+
name: Get Commit Message
81+
run: |-
82+
delimiter="$(uuidgen)"
83+
message="$(git show --format='%B' --no-patch)"
84+
printf 'message<<%s\n%s\n%s\n' "$delimiter" "$message" "$delimiter" >> "$GITHUB_OUTPUT"
85+
- name: Undo Last Commit
86+
run: git reset --soft HEAD~1
87+
- name: Commit
88+
uses: liblaf/actions/commit@dist
89+
with:
90+
add-options: --verbose 'CHANGELOG.md'
91+
force: true
92+
message: ${{ steps.message.outputs.message }}
93+
ref: ${{ fromJson(needs.release-please.outputs.pr).headBranchName }}
94+
token: ${{ steps.auth.outputs.token }}
95+
- name: Add Label
96+
run: |-
97+
gh pr edit '${{ fromJson(needs.release-please.outputs.pr).number }}' --add-label 'automerge'
98+
env:
99+
GH_TOKEN: ${{ steps.auth.outputs.token }}
100+
101+
post-release:
102+
name: Post Release
103+
permissions:
104+
contents: write
105+
needs:
106+
- release-please
107+
if: ${{ needs.release-please.outputs.release_created }}
108+
runs-on: ubuntu-latest
109+
environment:
110+
name: Release Please
111+
steps:
112+
- id: auth
113+
name: Auth
114+
uses: liblaf/actions/auth@dist
115+
with:
116+
app-id: ${{ vars.APP_ID }}
117+
private-key: ${{ secrets.PRIVATE_KEY }}
118+
- name: Checkout
119+
uses: actions/checkout@v5
120+
with:
121+
ref: ${{ needs.release-please.outputs.tag }}
122+
token: ${{ steps.auth.outputs.token }}
123+
fetch-depth: 0
124+
- id: changelog
125+
name: Changelog
126+
uses: liblaf/actions/changelog@dist
127+
with:
128+
args: --current --strip all
129+
- name: Update Release Notes
130+
run: >-
131+
gh release edit '${{ needs.release-please.outputs.tag }}'
132+
--notes-file '${{ steps.changelog.outputs.changelog }}'
133+
env:
134+
GH_TOKEN: ${{ steps.auth.outputs.token }}

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,14 @@ ci:
1919

2020
repos:
2121
- repo: https://github.com/astral-sh/ruff-pre-commit
22-
rev: v0.14.1
22+
rev: v0.14.2
2323
hooks:
2424
- id: ruff-check
2525
args:
2626
- --fix
2727
- id: ruff-format
2828
- repo: https://github.com/biomejs/pre-commit
29-
rev: v2.2.6
29+
rev: v2.3.1
3030
hooks:
3131
- id: biome-check
3232
exclude: \.jsonc?$

0 commit comments

Comments
 (0)