Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 67 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
name: Build

# This workflow is meant to run on changes pushed to the vnext branch only.
# If it runs on PRs, it will create PRs to the destination repos' vnext branches - we don't want that.
on:
push:
branches:
- vnext
- master
workflow_dispatch:
inputs:
isVerbose:
description: 'Get verbose output from steps - where configurable'
required: false
type: boolean
default: false

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read

steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
clean: true
persist-credentials: true
path: igniteui-angular-examples

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.19.0'

- name: Install npm dependencies
run: npm install
working-directory: ./igniteui-angular-examples/browser

- name: Apply very special configuration
shell: bash
run: |
echo "Current directory: $(pwd)"
sed -i 's/build --configuration production/build --configuration production --base-href=\/angular-demos-dv\//g' package.json
working-directory: ./igniteui-angular-examples/browser

- name: Build project
run: |
if [ "${{ github.event.inputs.isVerbose }}" == "true" ]; then
npm run build --verbose
else
npm run build
fi
working-directory: ./igniteui-angular-examples/browser

- name: Copy web.config to dist
run: |
cp web.config dist/browser/
working-directory: ./igniteui-angular-examples/browser

- name: Upload build artifacts
uses: actions/upload-artifact@v4
with:
name: dist
path: ./igniteui-angular-examples/browser/dist/browser
retention-days: 1