Skip to content

Commit

Permalink
CI: add dry run workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Kobzol committed Mar 27, 2024
1 parent c9a63f6 commit 87a0708
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: CI
on: [push, pull_request]
on: [ push, pull_request ]

jobs:
ci:
Expand All @@ -26,6 +26,11 @@ jobs:
- name: Run tests
run: cargo test

- name: Dry run
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_API_READ_TOKEN }}
run: cargo run -- --only-print-plan github

- name: Build the Docker container
run: docker build -t sync-team .

Expand Down
24 changes: 24 additions & 0 deletions .github/workflows/dry_run.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Smoke test that checks if we can download team data and read from the GitHub API.
name: Dry run

on:
workflow_dispatch:
schedule:
# Try to dry run every 4 hours
- cron: "0 */4 * * *"

jobs:
run:
name: Perform a dry run
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
- uses: Swatinem/rust-cache@v1
- name: Dry run
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_API_READ_TOKEN }}
run: cargo run -- --only-print-plan github

0 comments on commit 87a0708

Please sign in to comment.