-
Notifications
You must be signed in to change notification settings - Fork 327
46 lines (43 loc) · 1.25 KB
/
env-manifest.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
40
41
42
43
44
45
46
name: Generate Env Manifest
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Use Node.js 16
uses: actions/setup-node@v1
with:
node-version: 16
- name: install npm v8
run: |
npm install -g npm@8
- uses: actions/cache@v2
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: generate manifest
run: |
npm install
npm run ci:generate-manifest
env:
CI: true
NODE_ENV: test
- name: check for changes
id: changes
run: |
git diff --name-only | xargs
echo "::set-output name=files::$(git diff --name-only | xargs)"
- name: commit changes
if: ${{ contains(steps.changes.outputs.files, 'env-variables.manifest.json') }}
run: |
git config user.name twilio-labs-ci
git config user.email [email protected]
git add env-variables.manifest.json
git commit -m "chore(env-manifest): update manifest file"
git push