Build in js methods article #38
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 and deploy | |
on: | |
push: | |
branches: ["master"] | |
pull_request: | |
branches: ["master"] | |
permissions: | |
contents: write | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | |
- uses: actions/checkout@v3 | |
# Build | |
- uses: actions/setup-node@v4 | |
with: | |
# Version Spec of the version to use in SemVer notation. | |
# It also emits such aliases as lts, latest, nightly and canary builds | |
# Examples: 12.x, 10.15.1, >=10.15.0, lts/Hydrogen, 16-nightly, latest, node | |
node-version: "latest" | |
- name: Install deps | |
run: npm ci | |
# Runs a single command using the runners shell | |
- name: Run build | |
run: npm run build && touch ./out/.nojekyll && echo 'zhenya.dev' > ./out/CNAME | |
- name: Deploy 🚀 | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
folder: out |