Created
August 20, 2020 16:00
-
-
Save tcmorris/a779e0c62f9db194b7a15bdef0ec696e to your computer and use it in GitHub Desktop.
Example GitHub Action for building with node.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build node.js | |
on: [push] | |
env: | |
NODE_VERSION: '10.x' | |
jobs: | |
build-assets: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
# Setup Node | |
- name: Use Node.js ${{ env.NODE_VERSION }} | |
uses: actions/setup-node@v1 | |
with: | |
node-version: ${{ env.NODE_VERSION }} | |
# Run npm build | |
- name: npm install, build | |
run: | | |
npm install | |
npm run build | |
# Do something with assets |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment