$$$$$$$$$=<<>>==<<>>==<<=<<=<<>>=>>==<<>>==<<>>==<<>>==<<=<<=<<=<<=<<>>=>>=>>==<<=<<=<<>>==<<>>==<<=<<$
=<<
Build dependencies for Ubuntu:
libwebkit2gtk-4.0-dev gobject-introspection libgirepository1.0-dev fonts-takao gir1.2-webkit2-4.0
GHCUp recommended.
linux only
cp stack.linux.warp.yaml stack.yaml
stack build
Install nix first.
./build-nix-ghcjs-bare.bash
See https://www.haskell.org/ghcup/guide/#ghc-js-cross-bindists-experimental to setup experimental GHCJS. We need javascript-unknown-ghcjs-ghc-9.10.0.20240413
.
./build-cabal-910.bash
cp stack.linux.warp.yaml stack.yaml
stack build
linux only
Hot reload using custom websocket server.
SERVER_MODE=WARP node ./watch.js
Or without hot reloading: ./run-warp.bash
Access to http://localhost:11923
via Google Chrome. (Firefox not supported)
You can also change the hostname by specifying SERVER_HOST
Hot reload using browser-sync.
yarn install
SERVER_MODE=GHCJS node ./watch.js
./run-webkit.bash
hot reloading is WIP.
docker build -f build-tools/docker-nix/Dockerfile -t myimage .
docker run -itd --name mycontainer myimage
./build-nix-ghcjs-docker.bash
mkdir .stack-cache
mkdir .cabal-cache
mkdir -p .stack-cache/hooks/
curl https://raw.githubusercontent.com/haskell/ghcup-hs/master/scripts/hooks/stack/ghc-install.sh > .stack-cache/hooks/ghc-install.sh
chmod +x .stack-cache/hooks/ghc-install.sh
echo "system-ghc: false" >> .stack-cache/config.yaml
docker-compose up
docker exec -it rdwp-myservice-1 /root/uid-remap.bash bash
orssh haskell@localhost -p2222
(password: haskell)cd /workspace/frontend; nvim .
- Happy editing!
- Access to
ssh haskell@localhost -p2222
(password: haskell) - Run
code /workspace/frontend
- Happy editing!