-
-
Save delineas/94bec29a7769475b5ca2c42ad21296b0 to your computer and use it in GitHub Desktop.
GitHub Actions - Genelate Nuxt.js deploy for GitHub Pages
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: github pages | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build-deploy: | |
runs-on: ubuntu-18.04 | |
steps: | |
- uses: actions/checkout@master | |
- name: Setup Node | |
uses: actions/setup-node@v1 | |
with: | |
node-version: '10.x' | |
- name: Cache dependencies | |
uses: actions/cache@v1 | |
with: | |
path: ~/.npm | |
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-node- | |
- run: npm ci | |
- run: npm run generate | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v2.5.0 | |
env: | |
ACTIONS_DEPLOY_KEY: ${{ secrets.ACTIONS_DEPLOY_KEY }} | |
PUBLISH_BRANCH: gh-pages | |
PUBLISH_DIR: ./dist |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment