Skip to content

Instantly share code, notes, and snippets.

@carlynorama
Created November 4, 2022 00:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save carlynorama/fe1db372c59693c6281bad753a16971a to your computer and use it in GitHub Desktop.
Save carlynorama/fe1db372c59693c6281bad753a16971a to your computer and use it in GitHub Desktop.
name: Deploy Project
on: [push, workflow_dispatch]
jobs:
mytests:
runs-on: ubuntu-latest
steps:
- name: Get code
uses: actions/checkout@v3
- name: Install NodeJS
uses: actions/setup-node@v3
with:
node-version: 18
- name: Install dependencies
run: npm ci
- name: Run tests
run: npm test
mydeploy:
needs: mytests
runs-on: ubuntu-latest
steps:
- name: Get code
uses: actions/checkout@v3
- name: Install NodeJS
uses: actions/setup-node@v3
with:
node-version: 18
- name: Install dependencies
run: npm ci
- name: Build project
run: npm run build
- name: Deploy
run: echo "Deploying"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment