Skip to content

Commit

Permalink
Polish build & styles
Browse files Browse the repository at this point in the history
  • Loading branch information
blokhin committed Sep 22, 2023
1 parent 3ba946b commit 859d8be
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 11 deletions.
15 changes: 8 additions & 7 deletions .github/workflows/deploy-to-gh.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
name: Build on GitHub

on:
workflow_dispatch:
push:
branches:
- master

jobs:
build-then-deploy:
Expand All @@ -23,14 +25,13 @@ jobs:

- name: Save files
run: |
mkdir build
cp ermac.min.js jquery.min.js build
cp -r webassets build
cp example_prod.html build/index.html
ls -al build
mkdir dist
cp ermac.min.js jquery.min.js dist
cp -r webassets oauth crystvis dist
cp example_prod.html dist/index.html
- name: Deploy
uses: JamesIves/[email protected]
with:
branch: gh-pages
folder: build
folder: dist
4 changes: 2 additions & 2 deletions deploy/build_js.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ ROOT=$(dirname $0)/../
JSCOMP=$ROOT/third_party/jscomp/compiler.jar
JSTARGET=$ROOT/ermac.min.js

echo '/* Author: Evgeny Blokhin, Tilde Materials Informatics */' > $JSTARGET

# Desktop (not mobile) GUI
java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT5_STRICT --js $ROOT/src_js/browser_chk.js >> $JSTARGET

java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT5_STRICT --js $ROOT/src_js/third_party/jquery.tablesorter.js --compilation_level WHITESPACE_ONLY >> $JSTARGET
java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT5_STRICT --js $ROOT/src_js/third_party/wNumb.js >> $JSTARGET
java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT5_STRICT --js $ROOT/src_js/third_party/nouislider.js >> $JSTARGET
java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT5_STRICT --js $ROOT/src_js/third_party/selectize.js >> $JSTARGET
java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT5_STRICT --js $ROOT/src_js/third_party/selectize_preserve_on_blur.js >> $JSTARGET
java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT_NEXT --js $ROOT/src_js/third_party/optimade_mpds_nlp.js >> $JSTARGET

java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT5_STRICT --js $ROOT/src_js/wmsettings.js >> $JSTARGET
java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT_NEXT --js $ROOT/src_js/wmcore.js >> $JSTARGET
java -jar $JSCOMP --jscomp_off checkTypes --language_in ECMASCRIPT5_STRICT --js $ROOT/src_js/sliders.js >> $JSTARGET
Expand Down
2 changes: 1 addition & 1 deletion example_prod.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta charset="utf-8" />
<link rel="stylesheet" type="text/css" href="webassets/ermac.css?140722" />
<link rel="stylesheet" type="text/css" href="webassets/ermac.css" />
<script type="text/javascript" src="jquery.min.js"></script>
</head>
<body class="noscroll">
Expand Down
2 changes: 1 addition & 1 deletion webassets/ermac.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 859d8be

Please sign in to comment.