Skip to content

Commit cb142e6

Browse files
committed
Update to Copier template 0.9.0
Needed to overwrite the project since updating from 0.3.7 is not possible anymore.
1 parent f726344 commit cb142e6

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+2655
-314
lines changed

.codecov.yml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
---
2+
coverage:
3+
status:
4+
project:
5+
default: false
6+
app:
7+
informational: true
8+
paths:
9+
- src/
10+
tests:
11+
informational: true
12+
paths:
13+
- tests/
14+
patch:
15+
default: false
16+
app:
17+
informational: true
18+
paths:
19+
- src/
20+
tests:
21+
informational: true
22+
paths:
23+
- tests/
24+
github_checks:
25+
annotations: false

.copier-answers.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Autogenerated. Do not edit this by hand, use `copier update`.
22
---
3-
_commit: 0.3.7
3+
_commit: 0.9.0
44
_src_path: https://github.com/salt-extensions/salt-extension-copier
55
author: Max Arnold
66
author_email: arnold.maxim@gmail.com
@@ -12,16 +12,20 @@ integration_name: ''
1212
license: apache
1313
loaders:
1414
- engine
15-
max_salt_version: 3007
15+
max_salt_version: '3007'
1616
no_saltext_namespace: false
17+
os_support:
18+
- Linux
19+
- macOS
20+
- Windows
1721
package_name: stalekey
1822
project_name: stalekey
19-
python_requires: '3.8'
23+
python_requires: '3.10'
24+
relax_pylint: false
2025
salt_version: '3006'
2126
source_url: https://github.com/salt-extensions/saltext-stalekey
2227
ssh_fixtures: false
2328
summary: Salt engine that detects inactive minions and removes their keys
2429
test_containers: false
2530
tracker_url: https://github.com/salt-extensions/saltext-stalekey/issues
2631
url: https://github.com/salt-extensions/saltext-stalekey
27-
workflows: org

.coveragerc

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,7 @@ omit =
1111

1212
[report]
1313
# Regexes for lines to exclude from consideration
14-
exclude_lines =
15-
# Have to re-enable the standard pragma
16-
pragma: no cover
17-
14+
exclude_also =
1815
# Don't complain about missing debug-only code:
1916
def __repr__
2017

@@ -26,12 +23,17 @@ exclude_lines =
2623
if 0:
2724
if False:
2825
if __name__ == .__main__.:
26+
if TYPE_CHECKING:
27+
@(abc\.)?abstractmethod
28+
29+
# Add markers which exclude statements in between.
30+
# Requires coverage>=7.6.0.
31+
no cover: start(?s:.)*?no cover: stop
2932

3033
omit =
3134
.nox/*
3235
setup.py
3336

34-
3537
ignore_errors = True
3638

3739
[paths]

.envrc.example

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
layout_saltext() {
2+
VIRTUAL_ENV="$(python3 tools/initialize.py --print-venv)"
3+
PATH_add "$VIRTUAL_ENV/bin"
4+
export VIRTUAL_ENV
5+
}
6+
7+
layout_saltext

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ Remove this section if not relevant
1010
Remove this section if not relevant
1111

1212
### Merge requirements satisfied?
13-
**[NOTICE] Bug fixes or features added to Salt require tests.**
14-
<!-- Please review the [test documentation](https://docs.saltproject.io/en/master/topics/tutorials/writing_tests.html) for details on how to implement tests into Salt's test suite. -->
13+
**[NOTICE] Bug fixes or new features require tests.**
14+
<!-- Please review the [salt-extensions](https://salt-extensions.github.io/salt-extension-copier/topics/testing/writing.html) and [Salt test documentation](https://docs.saltproject.io/en/master/topics/tutorials/writing_tests.html) for details on how to implement tests for your changes. -->
1515
- [ ] Docs
16-
- [ ] Changelog - https://docs.saltproject.io/en/master/topics/development/changelog.html
16+
- [ ] Changelog - https://salt-extensions.github.io/salt-extension-copier/topics/documenting/changelog.html#procedure
1717
- [ ] Tests written/updated
1818

1919
### Commits signed with GPG?
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
---
2+
name: upload-exitstatus
3+
description: Upload a job's status as an artifact
4+
inputs:
5+
artifact_prefix:
6+
required: false
7+
default: exitstatus-
8+
name:
9+
required: false
10+
default: ''
11+
12+
runs:
13+
using: composite
14+
15+
steps:
16+
17+
- name: Set Exit Status
18+
if: always()
19+
env:
20+
OUTFILE: exitstatus/${{ inputs.name == '' && github.job || inputs.name }}
21+
shell: bash
22+
run: |
23+
mkdir exitstatus
24+
echo "${{ job.status }}" > "$OUTFILE"
25+
26+
- name: Upload Exit Status
27+
if: always()
28+
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
29+
with:
30+
name: ${{ inputs.artifact_prefix }}${{ inputs.name == '' && github.job || inputs.name }}
31+
path: exitstatus
32+
if-no-files-found: error

.github/workflows/ci.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
---
2+
name: CI
3+
4+
on:
5+
workflow_call:
6+
7+
jobs:
8+
get-changed-files:
9+
name: Get Changed Files
10+
uses: ./.github/workflows/get-changed-files.yml
11+
permissions:
12+
contents: read
13+
pull-requests: read # for dorny/paths-filter to read pull requests
14+
15+
pre-commit:
16+
name: Pre-Commit
17+
needs:
18+
- get-changed-files
19+
uses: ./.github/workflows/pre-commit-action.yml
20+
with:
21+
changed-files: ${{ needs.get-changed-files.outputs.changed-files }}
22+
permissions:
23+
contents: read
24+
25+
test:
26+
name: Test
27+
needs:
28+
- pre-commit
29+
uses: ./.github/workflows/test-action.yml
30+
31+
docs:
32+
name: Docs
33+
needs:
34+
- pre-commit
35+
uses: ./.github/workflows/docs-action.yml
36+
permissions:
37+
contents: read
38+
39+
build-python-package:
40+
name: Python Package
41+
needs:
42+
- pre-commit
43+
uses: ./.github/workflows/package-action.yml
44+
permissions:
45+
contents: read
Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
---
2+
name: Publish Documentation
3+
4+
on:
5+
workflow_call:
6+
inputs:
7+
# This is the name of the regular artifact that should
8+
# be transformed into a GitHub Pages deployment.
9+
artifact-name:
10+
type: string
11+
required: false
12+
default: html-docs
13+
14+
15+
permissions:
16+
actions: read # For downloading artifacts of other runs when called via workflow_run trigger
17+
pages: write
18+
id-token: write
19+
20+
jobs:
21+
22+
# The released docs are not versioned currently, only the latest ones are deployed.
23+
#
24+
# Versioning support would require either (better):
25+
# * Rebuilding docs for all versions when a new release is made
26+
# * Version selector support in `furo`: https://github.com/pradyunsg/furo/pull/500
27+
#
28+
# or (more basic):
29+
# * using the `gh-pages` branch and peaceiris/actions-gh-pages
30+
# to be able to deploy to subdirectories. The implementation via
31+
# actions/deploy-pages always replaces the directory root.
32+
33+
Deploy-Docs-GH-Pages:
34+
name: Publish Docs to GitHub Pages
35+
36+
environment:
37+
name: github-pages
38+
url: ${{ steps.deployment.outputs.page_url }}
39+
40+
runs-on: ubuntu-24.04
41+
42+
steps:
43+
44+
- name: Download built docs
45+
uses: actions/download-artifact@70fc10c6e5e1ce46ad2ea6f2b72d43f7d47b13c3 # v8.0.0
46+
with:
47+
name: ${{ inputs.artifact-name }}
48+
path: html-docs
49+
github-token: ${{ github.token }}
50+
run-id: ${{ github.event_name == 'workflow_run' && github.event.workflow_run.id || github.run_id }}
51+
52+
- name: Upload GitHub Pages artifact
53+
uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4.0.0
54+
with:
55+
name: html-docs-pages
56+
path: html-docs
57+
58+
- name: Deploy to GitHub Pages
59+
id: deployment
60+
uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4.0.5
61+
with:
62+
artifact_name: html-docs-pages
63+
64+
- name: Delete GitHub Pages artifact
65+
if: always()
66+
uses: geekyeggo/delete-artifact@7ee91e82b4a7f3339cd8b14beace3d826a2aac39 # v5.1.0
67+
with:
68+
name: html-docs-pages
69+
failOnError: false
70+
71+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
72+
73+
- name: Upload Exit Status
74+
if: always()
75+
uses: ./.github/actions/upload-exitstatus

0 commit comments

Comments
 (0)