-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (32 loc) · 1.03 KB
/
bootstrap.yml
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
name: bootstrap
run-name: first time setup of repo
on:
# run when branch created (repo generated from template)
create:
# only keep latest run of this workflow
concurrency:
group: bootstrap
cancel-in-progress: true
permissions:
actions: write
checks: write
contents: write
jobs:
bootstrap:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/master'
steps:
- name: Checkout code
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
# remove files not needed for user instance of template
- name: Remove unneeded files
run: rm -f LICENSE SECURITY.md .github/workflows/bootstrap.yml
# save changed files
- name: Commit changed files
uses: stefanzweifel/git-auto-commit-action@3ea6ae190baf489ba007f7c92608f33ce20ef04a # v4.16.0
with:
commit_message: "Setup repo"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}