mirror of https://github.com/aminya/setup-cpp
ci: commit the dist after the build
This commit is contained in:
parent
48bca6ce1e
commit
efdf36d38c
|
@ -56,13 +56,17 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
pnpm run test.lint
|
pnpm run test.lint
|
||||||
|
|
||||||
- name: Validate Dist
|
- name: Update Dist
|
||||||
run: |
|
run: |
|
||||||
if [ "$(git diff --ignore-space-at-eol --text dist/ | wc -l)" -gt "0" ]; then
|
if [ "$(git diff --ignore-space-at-eol --text dist/ | wc -l)" -gt "0" ]; then
|
||||||
echo "Detected uncommitted changes after build. See status below:"
|
git config user.name "github-actions[bot]"
|
||||||
git diff --ignore-space-at-eol --text dist/ ':(exclude)*.js.map'
|
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
||||||
exit 1
|
git add dist/
|
||||||
|
git commit -m "chore(build): update dist"
|
||||||
|
git push
|
||||||
fi
|
fi
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Upload Dist
|
- name: Upload Dist
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
|
|
|
@ -78,6 +78,7 @@ words:
|
||||||
- nodistro
|
- nodistro
|
||||||
- NOPASSWD
|
- NOPASSWD
|
||||||
- noprogressbar
|
- noprogressbar
|
||||||
|
- noreply
|
||||||
- nothrow
|
- nothrow
|
||||||
- npmrc
|
- npmrc
|
||||||
- Opencppcoverage
|
- Opencppcoverage
|
||||||
|
|
Loading…
Reference in New Issue