Skip to content

Commit 673ab23

Browse files
committed
chore(workflow): check for uncommited changes
1 parent ce0881d commit 673ab23

1 file changed

Lines changed: 23 additions & 2 deletions

File tree

.github/workflows/ci.yml

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,29 @@ jobs:
8787
node --version
8888
npm --version
8989
90-
- name: npm install and test
91-
run: npm cit
90+
- name: npm install
91+
run: npm ci
92+
env:
93+
CI: true
94+
NODE_OPTIONS: ${{ matrix.node.options }}
95+
96+
- name: Build parser
97+
run: npm run build
98+
env:
99+
CI: true
100+
NODE_OPTIONS: ${{ matrix.node.options }}
101+
102+
- name: Check for uncommitted changes
103+
run: |
104+
if ! git diff --exit-code; then
105+
echo ""
106+
echo "::error::Detected changes that appear to not be committed."
107+
echo "::error::Please run 'npm run build' and commit the built parser."
108+
exit 1
109+
fi
110+
111+
- name: npm test
112+
run: npm t
92113
env:
93114
CI: true
94115
NODE_OPTIONS: ${{ matrix.node.options }}

0 commit comments

Comments
 (0)