2023-10-30 04:02:57 +01:00
|
|
|
# WaveTerm Commands
|
2022-06-08 02:25:35 +02:00
|
|
|
|
|
|
|
```bash
|
|
|
|
# @scripthaus command webpack-watch
|
2022-07-09 10:37:19 +02:00
|
|
|
# @scripthaus cd :playbook
|
2023-10-25 22:32:15 +02:00
|
|
|
node_modules/.bin/webpack --env dev --watch
|
2022-06-08 02:25:35 +02:00
|
|
|
```
|
|
|
|
|
2022-11-01 08:07:25 +01:00
|
|
|
```bash
|
|
|
|
# @scripthaus command webpack-build
|
|
|
|
# @scripthaus cd :playbook
|
2023-10-25 22:32:15 +02:00
|
|
|
node_modules/.bin/webpack --env dev
|
2022-11-01 08:07:25 +01:00
|
|
|
```
|
|
|
|
|
2022-07-09 10:37:19 +02:00
|
|
|
```bash
|
2023-10-25 22:32:15 +02:00
|
|
|
# @scripthaus command webpack-build-prod
|
2022-07-09 10:37:19 +02:00
|
|
|
# @scripthaus cd :playbook
|
2023-10-25 22:32:15 +02:00
|
|
|
node_modules/.bin/webpack --env prod
|
2022-11-01 08:07:25 +01:00
|
|
|
```
|
|
|
|
|
2022-07-09 10:37:19 +02:00
|
|
|
```bash
|
|
|
|
# @scripthaus command electron-rebuild
|
|
|
|
# @scripthaus cd :playbook
|
|
|
|
node_modules/.bin/electron-rebuild
|
|
|
|
```
|
|
|
|
|
|
|
|
```bash
|
|
|
|
# @scripthaus command electron
|
|
|
|
# @scripthaus cd :playbook
|
2023-11-01 09:26:19 +01:00
|
|
|
WAVETERM_DEV=1 PCLOUD_ENDPOINT="https://ot2e112zx5.execute-api.us-west-2.amazonaws.com/dev" node_modules/.bin/electron dist-dev/emain.js
|
2022-07-09 10:37:19 +02:00
|
|
|
```
|
|
|
|
|
2022-07-05 07:37:45 +02:00
|
|
|
```bash
|
|
|
|
# @scripthaus command typecheck
|
2022-07-09 10:37:19 +02:00
|
|
|
# @scripthaus cd :playbook
|
2023-10-30 17:53:17 +01:00
|
|
|
node_modules/.bin/tsc --jsx preserve --noEmit --esModuleInterop --target ES5 --experimentalDecorators --downlevelIteration src/index.ts src/types/custom.d.ts
|
2022-07-05 07:37:45 +02:00
|
|
|
```
|
2022-10-31 22:59:31 +01:00
|
|
|
|
|
|
|
```bash
|
2022-11-01 08:07:25 +01:00
|
|
|
# @scripthaus command build-package
|
2022-10-31 22:59:31 +01:00
|
|
|
# @scripthaus cd :playbook
|
2022-11-02 05:18:40 +01:00
|
|
|
rm -rf dist/
|
|
|
|
rm -rf bin/
|
2022-12-28 22:29:18 +01:00
|
|
|
rm -rf build/
|
2023-10-25 22:32:15 +02:00
|
|
|
node_modules/.bin/webpack --env prod
|
2023-02-24 00:19:01 +01:00
|
|
|
GO_LDFLAGS="-s -w -X main.BuildTime=$(date +'%Y%m%d%H%M')"
|
2023-10-18 22:32:23 +02:00
|
|
|
(cd waveshell; GOOS=darwin GOARCH=amd64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-darwin.amd64 main-waveshell.go)
|
|
|
|
(cd waveshell; GOOS=darwin GOARCH=arm64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-darwin.arm64 main-waveshell.go)
|
|
|
|
(cd waveshell; GOOS=linux GOARCH=amd64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-linux.amd64 main-waveshell.go)
|
|
|
|
(cd waveshell; GOOS=linux GOARCH=arm64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-linux.arm64 main-waveshell.go)
|
2023-11-05 08:00:47 +01:00
|
|
|
(cd wavesrv; CGO_ENABLED=1 go build -ldflags="$GO_LDFLAGS" -o ../bin/wavesrv ./cmd)
|
2022-11-01 08:07:25 +01:00
|
|
|
node_modules/.bin/electron-forge make
|
2022-10-31 22:59:31 +01:00
|
|
|
```
|
2022-11-02 05:18:40 +01:00
|
|
|
|
2023-10-18 07:54:07 +02:00
|
|
|
```bash
|
|
|
|
# @scripthaus command build-package-linux
|
|
|
|
# @scripthaus cd :playbook
|
|
|
|
rm -rf dist/
|
|
|
|
rm -rf bin/
|
|
|
|
rm -rf build/
|
2023-11-01 09:26:19 +01:00
|
|
|
node_modules/.bin/webpack --env prod
|
2023-10-18 07:54:07 +02:00
|
|
|
GO_LDFLAGS="-s -w -X main.BuildTime=$(date +'%Y%m%d%H%M')"
|
|
|
|
(cd waveshell; GOOS=darwin GOARCH=amd64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-darwin.amd64 main-waveshell.go)
|
|
|
|
(cd waveshell; GOOS=darwin GOARCH=arm64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-darwin.arm64 main-waveshell.go)
|
|
|
|
(cd waveshell; GOOS=linux GOARCH=amd64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-linux.amd64 main-waveshell.go)
|
|
|
|
(cd waveshell; GOOS=linux GOARCH=arm64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-linux.arm64 main-waveshell.go)
|
2023-11-05 08:00:47 +01:00
|
|
|
(cd wavesrv; CGO_ENABLED=1 go build -ldflags="$GO_LDFLAGS" -o ../bin/wavesrv ./cmd)
|
2023-10-18 07:54:07 +02:00
|
|
|
node_modules/.bin/electron-forge make
|
|
|
|
```
|
|
|
|
|
2022-11-02 05:18:40 +01:00
|
|
|
```bash
|
|
|
|
# @scripthaus command open-electron-package
|
|
|
|
# @scripthaus cd :playbook
|
2023-10-30 04:02:57 +01:00
|
|
|
open out/Wave-darwin-x64/Wave.app
|
2022-11-02 05:18:40 +01:00
|
|
|
```
|
2022-12-28 22:29:18 +01:00
|
|
|
|
2023-10-16 22:35:03 +02:00
|
|
|
```bash
|
|
|
|
# @scripthaus command build-wavesrv
|
|
|
|
cd wavesrv
|
2023-11-10 01:08:32 +01:00
|
|
|
CGO_ENABLED=1 go build -ldflags "-X main.BuildTime=$(date +'%Y%m%d%H%M')" -o ../bin/wavesrv ./cmd
|
2023-10-16 22:35:03 +02:00
|
|
|
```
|
|
|
|
|
|
|
|
```bash
|
|
|
|
# @scripthaus command build-waveshell
|
|
|
|
cd waveshell
|
|
|
|
GO_LDFLAGS="-s -w -X main.BuildTime=$(date +'%Y%m%d%H%M')"
|
2023-11-10 03:29:11 +01:00
|
|
|
go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-darwin.amd64 main-waveshell.go
|
2023-10-16 22:35:03 +02:00
|
|
|
```
|
|
|
|
|
|
|
|
```bash
|
|
|
|
# @scripthaus command fullbuild-waveshell
|
2023-10-26 00:20:25 +02:00
|
|
|
set -e
|
2023-10-16 22:35:03 +02:00
|
|
|
cd waveshell
|
|
|
|
GO_LDFLAGS="-s -w -X main.BuildTime=$(date +'%Y%m%d%H%M')"
|
|
|
|
go build -ldflags="$GO_LDFLAGS" -o ~/.mshell/mshell-v0.2 main-waveshell.go
|
2023-11-10 01:08:32 +01:00
|
|
|
GOOS=linux GOARCH=amd64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-linux.amd64 main-waveshell.go
|
|
|
|
GOOS=linux GOARCH=arm64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-linux.arm64 main-waveshell.go
|
|
|
|
GOOS=darwin GOARCH=amd64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-darwin.amd64 main-waveshell.go
|
|
|
|
GOOS=darwin GOARCH=arm64 go build -ldflags="$GO_LDFLAGS" -o ../bin/mshell/mshell-v0.3-darwin.arm64 main-waveshell.go
|
2023-10-16 22:35:03 +02:00
|
|
|
```
|
2023-10-17 00:11:22 +02:00
|
|
|
|
|
|
|
```bash
|
|
|
|
# @scripthaus command build-backend
|
|
|
|
# @scripthaus cd :playbook
|
|
|
|
echo building waveshell
|
|
|
|
scripthaus run fullbuild-waveshell
|
|
|
|
echo building wavesrv
|
|
|
|
scripthaus run build-wavesrv
|
|
|
|
```
|