Skip to content

Commit

Permalink
Merge pull request #52 from s-weigand/update-action-version
Browse files Browse the repository at this point in the history
Update tooling
  • Loading branch information
econchick authored Sep 30, 2020
2 parents 624dc09 + 90ac374 commit 6abba89
Show file tree
Hide file tree
Showing 5 changed files with 59 additions and 7 deletions.
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: 2
updates:
# Maintain dependencies for GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
day: "sunday"
33 changes: 33 additions & 0 deletions .github/workflows/autoupdate-pre-commit-config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: "Update pre-commit config"
# You need to set an access token as a secret ACTION_TRIGGER_TOKEN on this repo
# in order for the PR to trigger the CI.
# For more details see: https://github.com/technote-space/create-pr-action#github_token
# If you don't want the PR to trigger the CI (NOT RECOMMENDED), comment out the GITHUB_TOKEN line.

on:
schedule:
- cron: "0 7 * * 1" # At 07:00 on each Monday.
workflow_dispatch:

jobs:
update-pre-commit:
name: Autoupdate pre-commit config
runs-on: ubuntu-latest
steps:
- name: Set up Python
uses: actions/setup-python@v2
- uses: actions/cache@v2
with:
path: ~/.cache/pre-commit
key: pre-commit-autoupdate
- name: Update pre-commit config packages
uses: technote-space/create-pr-action@v2
with:
GITHUB_TOKEN: ${{ secrets.ACTION_TRIGGER_TOKEN }}
EXECUTE_COMMANDS: |
pip install pre-commit
pre-commit autoupdate || (exit 0);
pre-commit run -a || (exit 0);
COMMIT_MESSAGE: "⬆️ UPGRADE: Autoupdate pre-commit config"
PR_BRANCH_NAME: "pre-commit-config-update-${PR_ID}"
PR_TITLE: "⬆️ UPGRADE: Autoupdate pre-commit config"
17 changes: 14 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,17 @@ on:
types: rebuild

jobs:
pre-commit:
name: "Pre-commit"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- name: Locally install interrogate
run: python -m pip install .
- name: Run pre-commit
uses: pre-commit/[email protected]

tests:
name: "Python ${{ matrix.python-version }} on Ubuntu"
runs-on: "ubuntu-latest"
Expand All @@ -23,7 +34,7 @@ jobs:
python-version: ["3.5", "3.6", "3.7", "3.8"]
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v1"
- uses: "actions/setup-python@v2"
with:
python-version: "${{ matrix.python-version }}"
- name: "Install dependencies"
Expand All @@ -47,7 +58,7 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v1"
- uses: "actions/setup-python@v2"
with:
python-version: "3.8"
- name: "Install pep517 and twine"
Expand All @@ -67,7 +78,7 @@ jobs:
runs-on: "${{ matrix.os }}"
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v1"
- uses: "actions/setup-python@v2"
with:
python-version: "3.8"
- name: "Install in dev mode"
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/sanity.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
python-version: ["3.5", "3.6", "3.7", "3.8"]
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v1"
- uses: "actions/setup-python@v2"
with:
python-version: "${{ matrix.python-version }}"
- name: "Install dependencies"
Expand All @@ -39,7 +39,7 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v1"
- uses: "actions/setup-python@v2"
with:
python-version: "3.8"
- name: "Install pep517 and twine"
Expand All @@ -56,7 +56,7 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v1"
- uses: "actions/setup-python@v2"
with:
python-version: "3.8"
- name: "Install in dev mode"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
python-version: ["3.5", "3.6", "3.7", "3.8"]
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v1"
- uses: "actions/setup-python@v2"
with:
python-version: "${{ matrix.python-version }}"
- name: "Install dependencies"
Expand Down

0 comments on commit 6abba89

Please sign in to comment.