File tree Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : Update LKG
2
+
3
+ on :
4
+ workflow_dispatch :
5
+ inputs :
6
+ branch_name :
7
+ description : Release branch name to LKG
8
+ required : true
9
+ type : string
10
+
11
+ permissions :
12
+ contents : read
13
+
14
+ # Ensure scripts are run with pipefail. See:
15
+ # https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#exit-codes-and-error-action-preference
16
+ defaults :
17
+ run :
18
+ shell : bash
19
+
20
+ jobs :
21
+ build :
22
+ runs-on : ubuntu-latest
23
+ steps :
24
+ - run : |
25
+ if [[ ! "${{ inputs.branch_name }}" =~ ^release- ]]; then
26
+ echo "Branch name must start with 'release-'"
27
+ exit 1
28
+ fi
29
+
30
+ - uses : actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
31
+ with :
32
+ ref : ${{ inputs.branch_name }}
33
+ token : ${{ secrets.TS_BOT_GITHUB_TOKEN }}
34
+ - uses : actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2
35
+ - run : |
36
+ npm --version
37
+ # corepack enable npm
38
+ npm install -g $(jq -r '.packageManager' < package.json)
39
+ npm --version
40
+ - run : |
41
+ npm ci
42
+ npx hereby LKG
43
+ git add --force ./lib
44
+ git config user.email "[email protected] "
45
+ git config user.name "TypeScript Bot"
46
+ git commit -m 'Update LKG'
47
+ git push
You can’t perform that action at this time.
0 commit comments