Update gatsby-publish.yaml #30
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: Gatsby Publish | |
on: | |
push: | |
branches: | |
main | |
workflow_dispatch: | |
env: | |
ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout the current code | |
uses: actions/checkout@v3 | |
- name: Setup the git user as the Actions user | |
uses: fregante/setup-git-user@v2 | |
- name: install homebrew. | |
run: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" | |
- name: but brew command in Path | |
run: echo "export PATH=/opt/homebrew/bin:$PATH" >> ~/.zshrc | |
- name: Install the most recent Node.js version. | |
run: brew install node@10 | |
- name: link node. | |
run: brew link node@10 | |
- name: Do a clean install of the required packages. | |
run: npm install | |
- name: Install Gatsby CLI | |
run: npm install -g [email protected] | |
- name: Install the gh-pages CLI | |
run: npm install gh-pages -g | |
- name: Build | |
env: | |
TOKEN: ${{ secrets.token_secret_deploy }} | |
run: | | |
gatsby build --prefix-paths && gh-pages -d public -r https://git:[email protected]/LinkedEarth/LeapFROGS.git |