Skip to content

Commit 93265b3

Browse files
authored
Add callable action to repopulate the recipe archives
1 parent 2120e69 commit 93265b3

File tree

1 file changed

+46
-0
lines changed

1 file changed

+46
-0
lines changed
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
name: Update Flex Archives
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
branch:
7+
default: master
8+
required: false
9+
type: string
10+
11+
jobs:
12+
flex-update-archived:
13+
name: Update Flex Archives
14+
runs-on: Ubuntu-20.04
15+
16+
steps:
17+
-
18+
name: Checkout
19+
uses: actions/checkout@v2
20+
id: checkout
21+
with:
22+
fetch-depth: 0
23+
24+
-
25+
name: Install tools
26+
run: |
27+
git config --global user.email ""
28+
git config --global user.name "github-action[bot]"
29+
cd .github
30+
wget -q -O recipes-checker.zip https://codeload.github.com/symfony-tools/recipes-checker/zip/refs/heads/main
31+
unzip recipes-checker.zip
32+
cd recipes-checker-main
33+
composer install --ansi --no-dev
34+
-
35+
name: Update Flex Archives
36+
run: |
37+
git switch ${{ inputs.branch }}
38+
39+
mkdir .github/archived
40+
php .github/recipes-checker-main/run generate:archived-recipes . ${{ inputs.branch }} .github/archived
41+
42+
git switch flex/main
43+
cp -a .github/archived .
44+
git add archived/
45+
git commit -m 'Update Flex archives' || true
46+
git push origin -f flex/main

0 commit comments

Comments
 (0)