✨ Update career details and SEO keywords to reflect the transition from Developer Enablement to Company-wide AI Enablement
$ npm install -g gatsby-cli $ gatsby new portfolio-gatsby https://github.com/kentaro-m/portfolio-gatsby
$ npm install $ npm run develop
Open at http://localhost:8000 in the browser.
http://localhost:8000
Add the pathPrefix to gatsby-config.js.
pathPrefix
gatsby-config.js
module.exports = { pathPrefix: `/repo-name`, }
Update the build script to package.json.
package.json
-"build": "gatsby build", +"build": "gatsby build --prefix-paths",
Add secrets to repository settings.
public_repo
read_qiita
repo
Create the workflow file like deploy.yml and add it to .github/workflows.
deploy.yml
.github/workflows
name: Deploy on: push: branches: - master jobs: build: runs-on: ubuntu-latest steps: - uses: actions/checkout@v1 - name: setup node 10.x uses: actions/setup-node@v1 with: node-version: '10.x' - name: install run: npm install - name: build run: npm run build env: GITHUB_API_TOKEN: ${{ secrets.GITHUB_API_TOKEN }} QIITA_API_TOKEN: ${{ secrets.QIITA_API_TOKEN }} RSS2JSON_API_TOKEN: ${{ secrets.RSS2JSON_API_TOKEN }} - name: deploy uses: peaceiris/actions-gh-pages@v2.3.2 env: PERSONAL_TOKEN: ${{ secrets.GH_TOKEN }} PUBLISH_BRANCH: gh-pages PUBLISH_DIR: ./public
Push your changes to the master branch and start the build for deploy to GitHub Pages.
MIT
portfolio-gatsby
Create a new site
Develop the site locally
Open at
http://localhost:8000in the browser.🚀 Deploy
Deploy to GitHub Pages using GitHub Actions
Add the
pathPrefixtogatsby-config.js.Update the build script to
package.json.Add secrets to repository settings.
public_reporead_qiitarepoCreate the workflow file like
deploy.ymland add it to.github/workflows.Push your changes to the master branch and start the build for deploy to GitHub Pages.
📝 Licence
MIT