diff --git a/.github/actionlint.yaml b/.github/actionlint.yaml new file mode 100644 index 0000000..8a4ce2e --- /dev/null +++ b/.github/actionlint.yaml @@ -0,0 +1,6 @@ +--- +self-hosted-runner: + labels: + - cc + - iac + - opentofu diff --git a/.github/dependabot.yml b/.github/dependabot.yml index f8827a2..497d0b2 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,24 +1,33 @@ --- version: 2 updates: - - package-ecosystem: pip + - package-ecosystem: uv directory: / schedule: - interval: daily + interval: monthly open-pull-requests-limit: 20 + groups: + uv-dependencies: + applies-to: version-updates + patterns: + - '*' + uv-security-dependencies: + applies-to: security-updates + patterns: + - '*' reviewers: - worgarside - package-ecosystem: github-actions directory: / schedule: - interval: daily + interval: monthly reviewers: - worgarside - package-ecosystem: npm directory: / schedule: - interval: daily + interval: monthly reviewers: - worgarside diff --git a/.github/labeler.yml b/.github/labeler.yml index 074a80e..6f41d25 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -13,7 +13,7 @@ labels: - label: dependencies files: - ^Pipfile\.lock$ - - ^poetry\.lock$ + - ^uv\.lock$ - ^requirements\.txt$ - label: dependencies diff --git a/.github/repo_labels.yml b/.github/repo_labels.yml index 6fa3cb3..e698c62 100644 --- a/.github/repo_labels.yml +++ b/.github/repo_labels.yml @@ -9,19 +9,10 @@ color: 8B4513 description: Regular code maintenance - - name: bot:delete-on-merge - description: Delete this branch after merging (bot command) - color: 8B0000 - - name: bot:do-not-close description: Do not close this PR, even if it's empty (bot command) color: 2C6AAB - - name: bot:keep-updated - from_name: keep-updated - description: Keep this PR updated from its base branch (bot command) - color: 87FAA6 - - name: dependencies description: Pull requests that update a dependency file color: 0366D6 diff --git a/.github/workflows/auto-create-pr.yml b/.github/workflows/auto-create-pr.yml new file mode 100644 index 0000000..c70be0c --- /dev/null +++ b/.github/workflows/auto-create-pr.yml @@ -0,0 +1,22 @@ +--- +name: Auto-Create PR + +on: + push: + branches-ignore: + - main + - dependabot/** + - renovate/** + workflow_dispatch: + +jobs: + create-pr: + name: Create PR + # yamllint disable-line rule:line-length + uses: worganisation/github-config-files/.github/workflows/__create-pull-request.yml@0.10.0 + with: + base-ref-name: ${{ github.event.repository.default_branch }} + head-ref-name: ${{ github.ref_name }} + pr-draft: true + update-pr-body-if-exists: true + secrets: inherit diff --git a/.github/workflows/ci_deployment.yml b/.github/workflows/ci_deployment.yml index bea320a..28aefe9 100644 --- a/.github/workflows/ci_deployment.yml +++ b/.github/workflows/ci_deployment.yml @@ -9,9 +9,9 @@ on: jobs: ci-validation: name: 'CI: Validation' - uses: worgarside/github-config-files/.github/workflows/__ci_validation.yml@main + uses: worganisation/github-config-files/.github/workflows/__ci-validation.yml@0.10.0 with: - build-branch: ${{ github.ref }} + build-branch: '${{ github.ref }}' build-type: '' node-build-directory: '' python-version: '3.12' @@ -29,16 +29,17 @@ jobs: id-token: write contents: read pages: write - uses: worgarside/github-config-files/.github/workflows/__ci_deployment.yml@main + # yamllint disable-line rule:line-length + uses: worganisation/github-config-files/.github/workflows/__ci-deployment.yml@0.10.0 with: - build-branch: ${{ github.ref }} + build-branch: '${{ github.ref }}' build-type: '' deploy-to: '' deploy-documentation: '' node-build-directory: '' path-to-__version__-file: '' python-version: '3.12' - release-tag: ${{ needs.ci-validation.outputs.release-tag }} + release-tag: '${{ needs.ci-validation.outputs.release-tag }}' unit-test: '' update-pyproject-toml: 'true' update-json-file-path: '' diff --git a/.github/workflows/ci_validation.yml b/.github/workflows/ci_validation.yml index 874317d..5d93030 100644 --- a/.github/workflows/ci_validation.yml +++ b/.github/workflows/ci_validation.yml @@ -12,9 +12,9 @@ on: jobs: ci-validation: name: 'CI: Validation' - uses: worgarside/github-config-files/.github/workflows/__ci_validation.yml@main + uses: worganisation/github-config-files/.github/workflows/__ci-validation.yml@0.10.0 with: - build-branch: ${{ github.ref }} + build-branch: '${{ github.ref }}' build-type: '' node-build-directory: '' python-version: '3.12' diff --git a/.github/workflows/manage-pr.yml b/.github/workflows/manage-pr.yml new file mode 100644 index 0000000..aadecc9 --- /dev/null +++ b/.github/workflows/manage-pr.yml @@ -0,0 +1,34 @@ +--- +name: Standard PR Checks + +on: + pull_request: + types: + - opened + - reopened + - synchronize + - ready_for_review + - edited + - labeled + - unlabeled + +# Do not cancel code-event work when housekeeping changes a label or title. +concurrency: + group: pr-metadata-${{ github.event.pull_request.number }}-${{ github.event.action }} + cancel-in-progress: true + +jobs: + metadata: + name: Standard PR Checks + # yamllint disable-line rule:line-length + uses: worganisation/github-config-files/.github/workflows/__standard-pr-checks.yml@0.10.0 + permissions: + contents: read + pull-requests: write + with: + validate-title: ${{ vars.CI_DISABLE_PR_TITLE != 'true' }} + manage-labels: ${{ vars.CI_DISABLE_PR_LABELS != 'true' }} + close-empty: ${{ vars.CI_DISABLE_CLOSE_EMPTY_PR != 'true' }} + # Organisation repositories always require a deliberate merge. + auto-merge: ${{ github.repository_owner != 'worganisation' && vars.CI_DISABLE_AUTO_MERGE != 'true' }} + secrets: inherit diff --git a/.github/workflows/manage-repo-labels.yml b/.github/workflows/manage-repo-labels.yml new file mode 100644 index 0000000..3ca45bf --- /dev/null +++ b/.github/workflows/manage-repo-labels.yml @@ -0,0 +1,17 @@ +--- +name: Manage Repo Labels + +on: + push: + branches: + - main + paths: + - .github/repo_labels.yml + workflow_dispatch: + +jobs: + manage-repo-labels: + name: Manage Repo Labels + uses: worganisation/github-config-files/.github/workflows/__manage-repo-labels.yml@0.10.0 + permissions: + issues: write diff --git a/.yamllint b/.yamllint index 25ddba2..4d53e4e 100644 --- a/.yamllint +++ b/.yamllint @@ -1,4 +1,4 @@ --- rules: line-length: - max: 100 + max: 120