Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dev: Use centralized sync-rtd-redirects workflow #1034

Merged
merged 2 commits into from
Apr 9, 2024
Merged
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
27 changes: 12 additions & 15 deletions .github/workflows/sync-redirects.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,25 +8,22 @@ on:
- docs/redirects.yaml
- .github/workflows/sync-redirects.yaml

pull_request:
paths:
- docs/redirects.yaml
- .github/workflows/sync-redirects.yaml

# Manually triggered using GitHub's UI
workflow_dispatch:

jobs:
sync:
# Prevent this job from running on forks.
if: github.repository_owner == 'nextstrain'
victorlin marked this conversation as resolved.
Show resolved Hide resolved
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5

- name: Upgrade Python toolchain
run: python3 -m pip install --upgrade pip setuptools wheel

- name: Install readthedocs-cli
run: python3 -m pip install readthedocs-cli

- name: Sync redirects
run: rtd projects nextstrain-ncov redirects sync -f docs/redirects.yaml --wet-run
env:
RTD_TOKEN: ${{ secrets.RTD_TOKEN }}
name: rtd redirects
uses: nextstrain/.github/.github/workflows/sync-rtd-redirects.yaml@master
with:
project: nextstrain-ncov
file: docs/redirects.yaml
secrets:
RTD_TOKEN: ${{ secrets.RTD_TOKEN }}
Loading