Update gatsby filesystem setup

This commit is contained in:
Daniel Lautzenheiser 2022-09-30 11:19:06 -04:00
parent 375355705a
commit 2faa036efe
3 changed files with 32 additions and 16 deletions

26
.github/workflows/website-backup.yml vendored Normal file
View File

@ -0,0 +1,26 @@
name: Website Publish
on:
push:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Install
uses: borales/actions-yarn@v3.0.0
with:
cmd: --cwd website install # will run `yarn install` command
- name: Build
uses: borales/actions-yarn@v3.0.0
with:
cmd: --cwd website build # will run `yarn build` command
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.ACCESS_TOKEN }}
publish_dir: ./website/dist

View File

@ -9,18 +9,8 @@ jobs:
build: build:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout - uses: actions/checkout@v3
uses: actions/checkout@v3 - uses: enriikke/gatsby-gh-pages-action@v2
- name: Install
uses: borales/actions-yarn@v3.0.0
with: with:
cmd: --cwd website install # will run `yarn install` command access-token: ${{ secrets.ACCESS_TOKEN }}
- name: Build working-dir: website
uses: borales/actions-yarn@v3.0.0
with:
cmd: --cwd website build # will run `yarn build` command
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.ACCESS_TOKEN }}
publish_dir: ./website/dist

View File

@ -28,14 +28,14 @@ module.exports = {
{ {
resolve: 'gatsby-source-filesystem', resolve: 'gatsby-source-filesystem',
options: { options: {
path: `${__dirname}/content`, path: `${__dirname}/website/content`,
name: 'content', name: 'content',
}, },
}, },
{ {
resolve: 'gatsby-source-filesystem', resolve: 'gatsby-source-filesystem',
options: { options: {
path: `${__dirname}/data`, path: `${__dirname}/website/data`,
name: 'data', name: 'data',
}, },
}, },