Merge pull request #15 from iamkentleom/feature/monospace-folder-name #14
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: Deployment | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Set up Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 18 | |
- name: Install dependencies | |
run: npm ci | |
- name: Create .env file | |
run: echo "${{ secrets.ENV }}" > .env | |
- name: Build for production | |
run: npm run build | |
- name: Archive Production Artifact | |
uses: actions/upload-artifact@master | |
with: | |
name: dist | |
path: dist | |
deploy: | |
name: Deploy | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@v3 | |
- name: Download Artifact | |
uses: actions/download-artifact@master | |
with: | |
name: dist | |
path: dist | |
- name: Deploy to firebase hosting | |
uses: w9jds/firebase-action@master | |
with: | |
args: deploy --only hosting | |
env: | |
FIREBASE_TOKEN: ${{ secrets.FIREBASE_TOKEN }} |