FI-3771: Deprecate legacy validator (#635) #3
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
name: UI Build | |
on: | |
push: | |
branches: [ main ] | |
workflow_dispatch: | |
jobs: | |
generate: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: ['20.x'] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Cache Node.js modules | |
uses: actions/cache@v4 | |
with: | |
# npm cache files are stored in `~/.npm` on Linux/macOS | |
path: ~/.npm | |
key: ${{ runner.OS }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.OS }}-node- | |
${{ runner.OS }}- | |
- run: npm ci | |
- run: npm run build | |
- name: Remove js build files from .gitignore | |
run: | | |
sed -i '/\/lib\/inferno\/public\/assets\*/d' .gitignore | |
sed -i '/\/lib\/inferno\/public\/\*\.js/d' .gitignore | |
sed -i '/\/lib\/inferno\/public\/\*\.png/d' .gitignore | |
- name: Set github author | |
run: | | |
git config --global user.email "inferno-developers@groups.mitre.org" | |
git config --global user.name "Inferno CI" | |
- name: Commit docs | |
run: | | |
git add lib/inferno/public/*.js | |
git add lib/inferno/public/*.png | |
git add lib/inferno/public/assets* | |
git commit -m 'build ui' | |
- name: Push to ci-main-ui branch | |
uses: ad-m/github-push-action@master | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
branch: ci-main-ui | |
force: true |