Core

/doc/scripts.md (1.8 KB)

 1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# Scripts

There's a variety of shell scripts available in `./bin`. Here's a few of them:

- `bootstrap.sh`: Downloads and installs the Go libraries and tools needed in other scripts{{{ if .HasModule "android" }}}
- `build/android.sh`: Builds the Android library and application{{{ end }}}
- `build/build.sh`: Builds the app (or just use make build)
- `build/client.sh`: Uses `esbuild` to compile the scripts in `client`
- `build/client-watch.sh`: Builds the TypeScript resources, then watches for changes via `watchexec`{{{ if .BuildDesktop }}}
- `build/desktop.sh`: Uses `tools/desktop` to build a desktop application
- `build/desktop-release.sh`: Meant to be run as part of the release process, builds desktop apps{{{ end }}}{{{ if .HasModule "ios" }}}
- `build/ios.sh`: Builds the iOS framework and application{{{ end }}}
- `build/release.sh`: Runs `goreleaser`
- `build/release-test.sh`: Runs `goreleaser` in test mode
- `check.sh`: Runs code statistics, checks for outdated dependencies, then runs linters
- `dev.sh`: Starts the app, reloading on changes
- `format.sh`: Formatting code from all projects
- `tag.sh`: Tags the git repo using the first argument or the incremented minor version
- `templates.sh`: Builds all the templates using quicktemplate, skipping if unchanged
- `test.sh`: Runs all the tests
- `util/view-binary-size.sh`: Visualizes space usage for the release binary
- `util/view-cpu-profile.sh`: Starts a `pprof` server using the (previously-recorded) CPU profile at `./tmp/cpu.pprof`
- `util/view-go-deps.sh`: Uses `gomod` to visualize the module graph
- `util/view-mem-profile.sh`: Starts a `pprof` server using the (previously-recorded) heap dump at `./tmp/mem.pprof`
- `workspace.sh`: Loads `dev.sh` and `client-watch.sh` in a split window. Requires iTerm