Skip to content

feat(spyral): improved code suggest for corpus tools #118

feat(spyral): improved code suggest for corpus tools

feat(spyral): improved code suggest for corpus tools #118

Workflow file for this run

name: Build JS
on:
push:
branches:
- master
paths:
- src/main/webapp/app/**
- src/main/webapp/resources/bubblelines/**
- src/main/webapp/resources/knots/**
- src/main/webapp/resources/cirrus/**
- src/main/webapp/resources/doubletree/**
- src/main/webapp/resources/termsradio/**
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v2
with:
java-version: '11'
distribution: 'adopt'
cache: 'maven'
- name: Create maven settings.xml
uses: whelk-io/maven-settings-xml-action@v20
with:
servers: |
[{
"id": "trombone-mvn-repo",
"username": "voyanttools",
"password": "${{secrets.GITHUB_TOKEN}}"
}]
- name: Build with Maven
run: mvn -B package --file pom.xml
- name: unzip WAR
run: jar -xvf target/Voyant*.war
- name: Run JSCacher
run: sudo java -classpath "lib/*:classes/." org.voyanttools.voyant.JSCacher --webappPath=${{github.workspace}}/
working-directory: "WEB-INF"
- name: Commit JS files
run: |
cp resources/voyant/current/voyant.js ${{github.workspace}}/src/main/webapp/resources/voyant/current/voyant.js
cp resources/voyant/current/voyant.min.js ${{github.workspace}}/src/main/webapp/resources/voyant/current/voyant.min.js
git config --global user.name 'Voyant Tools'
git config --global user.email 'voyanttools@users.noreply.github.com'
git add src/main/webapp/resources/voyant/current/voyant.js src/main/webapp/resources/voyant/current/voyant.min.js
git commit -m "chore: add JS build files"
git push
# - name: Archive JS artifacts
# uses: actions/upload-artifact@v2
# with:
# name: js-files
# path: |
# resources/voyant/current/voyant.js
# resources/voyant/current/voyant.min.js