Skip to content

Pages

Pages #2

Workflow file for this run

name: Pages
on:
push:
branches: [master]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: false
jobs:
build:
if: github.repository == 'mruby/mruby.github.io'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: .ruby-version
bundler-cache: true
- name: Configure GitHub Pages
uses: actions/configure-pages@v5
- name: Generate and build
run: bundle exec rake build
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
JEKYLL_ENV: production
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
deploy:
if: github.repository == 'mruby/mruby.github.io'
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4