Skip to content

Publish to pages

Publish to pages #2

Workflow file for this run

name: Publish to pages
# Controls when the action will run.
on:
# This workflow requires enabling pages in the repository settings.
# Therefore not running automatically on push and pr
#push: # Uncomment to runs on push events
#pull_request: # Runs on pull requests
workflow_dispatch: # Allows you to run this workflow manually from the Actions tab
env:
MLM_LICENSE_TOKEN: ${{ secrets.MLM_LICENSE_TOKEN }}
PRODUCT_LIST: MATLAB MATLAB_Test MATLAB_Compiler MATLAB_Compiler_SDK
MW_MATLAB_BATCH_URL_OVERRIDE: https://mw-ci-static-dev.s3.amazonaws.com/matlab-batch/v2/ # IGNORE - HOPEFULLY NOT BE IN FLORIDA
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: "pages"
cancel-in-progress: false
jobs:
build-workshop-pages:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
# The type of runner that the job will run on
runs-on: ubuntu-latest
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v4
- name: Setup Pages
uses: actions/configure-pages@v4
- name: Setup MATLAB
uses: matlab-actions/setup-matlab@v2-prerelease
with:
release: latest-including-prerelease
cache: true
products: ${{env.PRODUCT_LIST }}
- name: Start display server on linux (required for building doc)
run: |
Xvfb :99 &
echo "DISPLAY=:99" >> $GITHUB_ENV
# Build the toolbox
- name: Run the build to produce workshop html pages
uses: matlab-actions/run-build@v2
with:
tasks: workshop
- name: Upload pages
uses: actions/upload-pages-artifact@v3
with:
# Upload results
path: results
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4