Skip to content

Commit

Permalink
Only run workflows if the correct files are changed
Browse files Browse the repository at this point in the history
  • Loading branch information
TheLovinator1 committed Jun 4, 2024
1 parent e3cd23b commit ed4d615
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
13 changes: 10 additions & 3 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ on:
schedule:
- cron: "27 6 * * *"
push:
paths:
- "**.py"
- "Dockerfile"
- ".github/workflows/docker-publish.yml"
- "requirements.txt"
- "requirements-dev.txt"
pull_request:
workflow_dispatch:
env:
Expand All @@ -16,9 +22,10 @@ jobs:
- uses: actions/setup-python@v5
with:
python-version: "3.12"
- run: pipx install poetry
- run: poetry install
- run: poetry run pytest
cache: "pip"
- run: python -m pip install -r requirements.txt
- run: python -m pip install -r requirements-dev.txt
- run: python -m pytest
build:
runs-on: ubuntu-latest
permissions:
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/ruff.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Ruff
on:
push:
paths:
- '**.py'
- '.github/workflows/ruff.yml'
pull_request:
schedule:
- cron: '0 0 * * *' # Run every day
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/static.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ name: Deploy to GitHub Pages
on:
push:
branches: ["master"]
paths:
- "pages/**"
- ".github/workflows/static.yml"
workflow_dispatch:
permissions:
contents: read
Expand Down

0 comments on commit ed4d615

Please sign in to comment.