Skip to content

Instantly share code, notes, and snippets.

@scharlton2
Created September 8, 2020 23:52
Show Gist options
  • Save scharlton2/182a66b52f5c07616c2fadfa767bd10f to your computer and use it in GitHub Desktop.
Save scharlton2/182a66b52f5c07616c2fadfa767bd10f to your computer and use it in GitHub Desktop.
example that uses PIPESTATUS
name: Check UTF-8
# This workflow is triggered on pushes to the repository.
on: push
# see https://tldp.org/LDP/abs/html/internalvariables.html#PIPESTATUSREF
jobs:
check_files:
runs-on: self-hosted
steps:
- uses: actions/checkout@v2
name: Check out repository
- run: |
./check_utf8.sh 2>&1| tee failed_files.txt
exit ${PIPESTATUS[0]}
name: Run check_utf8.sh
- uses: actions/upload-artifact@v2
name: Upload artifact
with:
name: failed_files.txt
path: failed_files.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment