diff --git a/ci/build-electron b/ci/build-electron new file mode 100755 index 000000000..645dba92a --- /dev/null +++ b/ci/build-electron @@ -0,0 +1,17 @@ +#!/usr/bin/env bash +set -e +set -o pipefail + +sbt webApp/fullOptJS::webpack + +# clear old electron integration +rm -rf webApp/target/scala-2.12/scalajs-bundler/main/electron + +# switch to the webpack root folder: +cd webApp/target/scala-2.12/scalajs-bundler/main + +# https://capacitor.ionicframework.com/docs/electron +npx cap add electron +npx cap copy + +electron electron/ diff --git a/production.nix b/production.nix index 0537f70ba..bc55894d6 100644 --- a/production.nix +++ b/production.nix @@ -14,6 +14,7 @@ in nodejs-11_x yarn # phantomjs # gnumake gcc # required for some weird npm things + electron ]; installPhase= '' diff --git a/project/Deps.scala b/project/Deps.scala index 4ed064ab0..84745e7d8 100644 --- a/project/Deps.scala +++ b/project/Deps.scala @@ -169,6 +169,8 @@ object Deps { "workbox-webpack-plugin" -> "4.3.1" :: "optimize-css-assets-webpack-plugin" -> "5.0.1" :: "cssnano" -> "4.1.10" :: + "@capacitor/core" -> "1.0.0" :: + "@capacitor/cli" -> "1.0.0" :: Nil } diff --git a/webApp/src/html/index.template.html b/webApp/src/html/index.template.html index 9e2e99d44..eeacf2dd5 100644 --- a/webApp/src/html/index.template.html +++ b/webApp/src/html/index.template.html @@ -37,6 +37,9 @@ }; + + + Welcome to Woost! @@ -65,4 +68,6 @@ <% } %>
Welcome to Woost!