Skip to content

[Avatar Addition] Batty Bat (#119) #725

[Avatar Addition] Batty Bat (#119)

[Avatar Addition] Batty Bat (#119) #725

Workflow file for this run

name: Update Website
env:
listPublishDirectory: Website
pathToCi: ci
on:
workflow_dispatch:
workflow_run:
workflows: [Build Release]
types:
- completed
release:
types: [published, edited, created, unpublished, deleted, released]
push:
branches: ["main"]
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
build-web:
name: build-web
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3 # check out this repo
with:
fetch-depth: 0 # fetch all history
- uses: actions/checkout@v3 # check out automation repo
with:
#repository: vrchat-community/package-list-action
repository: Happyrobot33/package-list-action #TODO: Change this to the main repo once it's merged
path: ${{env.pathToCi}}
clean: false # otherwise the local repo will no longer be checked out
- name: Restore Timestamps
uses: chetan/git-restore-mtime-action@v1
- name: Restore Cache
uses: actions/cache@v3
with:
path: |
${{env.pathToCi}}/.nuke/temp
~/.nuget/packages
key: ${{ runner.os }}-${{ hashFiles('**/global.json', '**/*.csproj') }}
- name: Build Package Version Listing
run: ${{env.pathToCi}}/build.cmd BuildMultiPackageListing --root ${{env.pathToCi}} --list-publish-directory $GITHUB_WORKSPACE/${{env.listPublishDirectory}}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
#This ensures that the scripts can always refer to the top level copy, allowing us to move it around in the project without issue
- name: Copy Data
uses: canastro/copy-action@0.0.2
with:
source: "./Packages/com.mattshark.openflight/Runtime/data.json"
target: "./${{env.listPublishDirectory}}/data-original.json"
# Makes the file smaller for everyone to download
- name: Minify and copy data.json
run: jq -r tostring ./${{env.listPublishDirectory}}/data-original.json > ./${{env.listPublishDirectory}}/data.json
#Generate the doxygen documentation
- name: Generate C# Documentation
uses: mattnotmitt/doxygen-action@v1.9.5
with:
working-directory: "./docs/Doxygen/"
doxyfile-path: "./DoxygenConfig"
enable-latex: true
#Copy docs into the website
- name: Copy Docs
uses: canastro/copy-action@master
with:
source: "./docs/."
target: "./${{env.listPublishDirectory}}/docs/"
flags: "-rp" #recursive and preserve timestamps
- name: Setup Pages
uses: actions/configure-pages@v3
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
path: ${{env.listPublishDirectory}}
#path: '.'
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2