Delete demo/public/FinalCountDown-2.glb #34
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node | |
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs | |
name: Build & Deploy to Pages | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
# 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: | |
name: Build | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [20.x] | |
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/ | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' | |
- run: npm ci | |
# build demo | |
- run: cd demo && npm ci | |
- run: cd demo && npm run build -- --base=/dt-bim-xr/demo | |
# build web-ifc-babylon example | |
- run: cd web-ifc-babylon/example && npm ci | |
- run: cd web-ifc-babylon/example && npm run build -- --base=/dt-bim-xr | |
# build village | |
- run: cd village && npm ci | |
- run: cd village && npm run build -- --base=/dt-bim-xr/village | |
- name: Upload a Build Artifact for demo | |
uses: actions/upload-artifact@v3 | |
with: | |
name: demo | |
path: ./demo/dist | |
- name: Upload a Build Artifact for web-ifc-babylon | |
uses: actions/upload-artifact@v3 | |
with: | |
name: web-ifc-babylon | |
path: ./web-ifc-babylon/example/dist | |
- name: Upload a Build Artifact for village | |
uses: actions/upload-artifact@v3 | |
with: | |
name: village | |
path: ./village/dist | |
deploy: | |
name: Deploy | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- name: Download artifact of demo | |
uses: actions/download-artifact@v3 | |
with: | |
name: demo | |
path: './demo' | |
- name: Download artifact of village | |
uses: actions/download-artifact@v3 | |
with: | |
name: village | |
path: './village' | |
- name: Download artifact of web-ifc-babylon | |
uses: actions/download-artifact@v3 | |
with: | |
name: web-ifc-babylon | |
path: '.' | |
- name: Setup Pages | |
uses: actions/configure-pages@v3 | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v1 | |
with: | |
# Upload entire repository | |
path: '.' | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v2 |