-
Notifications
You must be signed in to change notification settings - Fork 0
60 lines (49 loc) · 1.46 KB
/
mirror.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: Mirror from declaratia
permissions: write-all
on:
schedule:
- cron: "0 0 * * *"
workflow_dispatch:
jobs:
sync:
runs-on: ubuntu-latest
steps:
- run: |
git config --global user.name 'GitHub Action'
git config --global user.email '[email protected]'
- uses: actions/setup-python@v5
with:
python-version: "3.13"
- uses: actions/checkout@v3
with:
repository: newren/git-filter-repo
path: git-filter-repo
- uses: actions/checkout@v3
with:
repository: merrkry/declaratia
fetch-depth: 0
path: declaratia
ref: master
token: ${{ secrets.PAT }}
- uses: actions/checkout@v3
with:
repository: merrkry/decalratia
path: decalratia
ref: master
- run: |
cd declaratia
python ../git-filter-repo/git-filter-repo --path flake.lock --invert-paths --force
- run: |
rm -rf declaratia/.github/workflows
mkdir -p declaratia/.github/workflows
cp -r decalratia/.github/workflows/* declaratia/.github/workflows/
cd declaratia
git add .github/workflows
git commit -m "Override workflows"
- uses: ad-m/github-push-action@master
with:
branch: master
force: true
directory: declaratia
repository: merrkry/decalratia
github_token: ${{ secrets.PAT }}