Skip to content

Commit 8ff03b7

Browse files
committed
sync-git-mailing-list-mirror: centralize the repository URLs
... and fix it up after moving the workflow to a different repository. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent eca1e3c commit 8ff03b7

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

.github/workflows/sync-git-mailing-list-mirror.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,9 @@ on:
66
- cron: "2,7,12,17,22,27,32,37,42,47,52,57 * * * *"
77

88
env:
9-
LORE_EPOCH: 1
9+
LORE_EPOCH: 1 # also adjust SOURCE_REPOSITORY
10+
SOURCE_REPOSITORY: https://lore.kernel.org/git/1 # LORE_EPOCH
11+
TARGET_GITHUB_REPOSITORY: gitgitgadget/git-mailing-list-mirror
1012

1113
concurrency:
1214
group: sync-git-mailing-list-mirror
@@ -20,12 +22,12 @@ jobs:
2022
steps:
2123
- name: Partial clone
2224
run: |
23-
git clone --bare --depth=1 -b lore-$LORE_EPOCH --filter=blob:none https://github.com/$GITHUB_REPOSITORY .
25+
git clone --bare --depth=1 -b lore-$LORE_EPOCH --filter=blob:none https://github.com/$TARGET_GITHUB_REPOSITORY .
2426
- name: Update from lore.kernel.org
2527
run: |
26-
git fetch https://lore.kernel.org/git/$LORE_EPOCH refs/heads/master:refs/heads/lore-$LORE_EPOCH
28+
git fetch "$SOURCE_REPOSITORY" refs/heads/master:refs/heads/lore-$LORE_EPOCH
2729
- name: Push to mirror
2830
env:
2931
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3032
run: |
31-
git push https://$GITHUB_ACTOR:[email protected]/$GITHUB_REPOSITORY lore-$LORE_EPOCH
33+
git push https://$GITHUB_ACTOR:[email protected]/$TARGET_GITHUB_REPOSITORY lore-$LORE_EPOCH

0 commit comments

Comments
 (0)