Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/codeql/codeql-config.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# yamllint disable rule:document-start rule:document-end

name: CodeQL configuration
paths:
- src/package
2 changes: 2 additions & 0 deletions .github/dependabot.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# This configuration file enables Dependabot version updates.
# https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/about-dependabot-version-updates
# https://github.com/dependabot/feedback/issues/551
#
# yamllint disable rule:document-start rule:document-end

version: 2
updates:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/_build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,11 @@
# https://docs.github.com/en/actions/security-guides/security-hardening-for-github-actions
#
# for the security recommendations.
#
# yamllint disable rule:document-start rule:document-end

name: Build the package
on:
on: # yamllint disable-line rule:truthy
workflow_call:
inputs:
disable_pip_audit:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/_generate-rebase.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# Automatically rebase one branch on top of another; usually staging on top
# of main after a new package version was published.
#
# yamllint disable rule:document-start rule:document-end

name: Rebase branch
on:
on: # yamllint disable-line rule:truthy
workflow_call:
inputs:
to_head:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/_release-notifications.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# Send a Slack release notification. Instructions to set up Slack to receive
# messages can be found here: https://github.com/slackapi/slack-github-action#setup-2
#
# yamllint disable rule:document-start rule:document-end

name: Release Notifications
on:
on: # yamllint disable-line rule:truthy
workflow_call:
inputs:
repo_name:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/_wiki-documentation.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
# This reusable workflow publishes Markdown docs to Github Wiki. Some manual
# setup is required before using it: enable Wiki in repository and create at
# least one page.
#
# yamllint disable rule:document-start rule:document-end

name: Publish Github Wiki documentation
on:
on: # yamllint disable-line rule:truthy
workflow_call:
inputs:
release_tag:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/codeql-analysis.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# Run CodeQL over the package. For more configuration options see codeql/codeql-config.yaml
# and: https://github.com/github/codeql-action
#
# yamllint disable rule:document-start rule:document-end

name: CodeQL
on:
on: # yamllint disable-line rule:truthy
push:
branches:
- main
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/dependabot-automerge.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# Automatically merge Dependabot PRs upon approval by leaving
# a comment on Dependabot's pull-request.
#
# yamllint disable rule:document-start rule:document-end

name: Automerge Dependabot PR
on:
on: # yamllint disable-line rule:truthy
pull_request_review:
types: [submitted]

Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/pr-change-set.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# This workflow checks and tests the package code, and it builds all package
# artifacts whenever there were changes to a pull request.
#
# yamllint disable rule:document-start rule:document-end

name: Check change set
on:
on: # yamllint disable-line rule:truthy
pull_request:
branches:
- '*'
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/pr-conventional-commits.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@
# package (https://github.com/commitizen-tools/commitizen) and its `cz`
# tool to check the title of the PR and all commit messages of the branch
# which triggers this Action.
#
# yamllint disable rule:document-start rule:document-end

name: Check conventional commits
on:
on: # yamllint disable-line rule:truthy
pull_request:
branches:
- '*'
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# We run checks on pushing to the specified branches.
# Pushing to main also triggers a release.
#
# yamllint disable rule:document-start rule:document-end

name: Check and Release
on:
on: # yamllint disable-line rule:truthy
push:
branches:
- main
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/scorecards-analysis.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
# Run Scorecard for this repository to further check and harden software and process.
#
# yamllint disable rule:document-start rule:document-end

name: Scorecards supply-chain security
on:
on: # yamllint disable-line rule:truthy
# Only the default branch is supported.
branch_protection_rule:
schedule:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/sync-with-upstream.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# Create a PR to sync with the upstream template repo.
# The template repo is https://github.com/jenstroeger/python-package-template.
#
# yamllint disable rule:document-start rule:document-end

name: Sync with template repository
on:
on: # yamllint disable-line rule:truthy
schedule:
- cron: 11 11 * * *

Expand Down
17 changes: 13 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# yamllint disable rule:document-start rule:document-end

# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
default_install_hook_types: [pre-commit, commit-msg, pre-push]
Expand Down Expand Up @@ -117,7 +119,6 @@ repos:
- id: detect-private-key
- id: detect-aws-credentials
args: [--allow-missing-credentials]
- id: check-yaml
- id: check-toml
- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.10.0
Expand Down Expand Up @@ -147,16 +148,24 @@ repos:
args: [--autofix]
- id: pretty-format-yaml
args: [--autofix]
# Commenting this out because https://github.com/pappasam/toml-sort/issues/11
# - id: pretty-format-toml
# args: [--autofix]
# Commenting this out because https://github.com/pappasam/toml-sort/issues/11
# - id: pretty-format-toml
# args: [--autofix]

# Check GitHub Actions workflow files.
- repo: https://github.com/Mateusz-Grzelinski/actionlint-py
rev: v1.6.26.11
hooks:
- id: actionlint

# Check and lint all YAML files.
# https://yamllint.readthedocs.io/en/stable/rules.html
- repo: https://github.com/adrienverge/yamllint
rev: v1.33.0
hooks:
- id: yamllint
args: [--strict]

# On push to the remote, run the unit tests.
- repo: local
hooks:
Expand Down
15 changes: 15 additions & 0 deletions .yamllint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Modify yamllint's defaults so that they work well and strictly with
# ruamel's pretty-formatting of the YAML files.
#
# For more details: https://yamllint.readthedocs.io/en/stable/rules.html
#
# yamllint disable rule:document-start rule:document-end

extends: default
rules:
line-length:
max: 512
indentation:
indent-sequences: consistent
comments:
min-spaces-from-content: 1