Version 1.0.0, release build script
- version.go/version.txt, --version flag, version in the help title - build.sh builds static binaries for macOS and Linux into ./bin - make build/install inject version.txt, make dist runs build.sh - README: binary downloads; development docs: release process Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
156bb18c91
commit
e5750ef24b
9 files changed
+162
-9
No files matched your search
@@ -13,6 +13,7 @@ make install # go install
|
||||
make test # go test ./...
|
||||
make schema # regenerate the option schema for the installed Ghostty
|
||||
make screenshots # regenerate docs/images (needs tmux and Ghostty)
|
||||
make dist # = ./build.sh: release binaries for all platforms into ./bin
|
||||
```
|
||||
|
||||
The code builds on macOS, Linux and the BSDs. Automatic reload is implemented
|
||||
@@ -23,6 +24,8 @@ for macOS and Linux. Other platforms only save.
|
||||
| Path | Content |
|
||||
| --- | --- |
|
||||
| `main.go` | flags, startup, wiring |
|
||||
| `version.go`, `version.txt` | the version: `version.txt` is the released one, `build.sh` injects it |
|
||||
| `build.sh` | builds the release binaries into `./bin` |
|
||||
| `internal/schema` | the option schema: kinds, categories, platform detection, value validation; `schema.json` is embedded |
|
||||
| `internal/config` | the comment- and layout-preserving config file model, atomic saving |
|
||||
| `internal/ghostty` | finding and running the `ghostty` binary (docs, themes, fonts, actions, validation), config paths, reload |
|
||||
@@ -33,6 +36,34 @@ for macOS and Linux. Other platforms only save.
|
||||
| `tools/termsvg` | renders captured terminal screens as SVG (for the screenshots) |
|
||||
| `tools/screenshots.sh` | drives ghosttyconf in tmux and writes `docs/images/*.svg` |
|
||||
|
||||
## Versions and releases
|
||||
|
||||
The version follows `MAJOR.MINOR.PATCH`. `version.txt` holds the version of
|
||||
the last release build. `build.sh` builds `bin/ghosttyconf-<os>-<arch>` for
|
||||
macOS and Linux on arm64 and amd64. The binaries are static (`CGO_ENABLED=0`)
|
||||
and stripped, and they carry the version via `-ldflags "-X main.Version=…"`.
|
||||
`make build` and `make install` use `version.txt` too. Only a plain
|
||||
`go build` reports the literal in `version.go`.
|
||||
|
||||
```sh
|
||||
./build.sh # bump the patch number: 1.0.0 -> 1.0.1
|
||||
VERSION=1.1.0 ./build.sh # or set the version explicitly
|
||||
```
|
||||
|
||||
A release is made with [mgsh](https://git.micw.org/mike/mgsh):
|
||||
|
||||
```sh
|
||||
VERSION=1.1.0 ./build.sh
|
||||
mgsh push "version 1.1.0" # commit and push to the git server
|
||||
mgsh pushremote @micw # update the public mirror
|
||||
mgsh release @micw 1.1.0 "notes" # tag, publish, attach ./bin
|
||||
```
|
||||
|
||||
`mgsh release` creates the annotated tag, pushes it and publishes the release
|
||||
on git.micw.org. Every regular file in `./bin` is attached to it. If the tag
|
||||
already exists with a longer annotation, that annotation becomes the release
|
||||
notes. `./bin` is not part of the repository.
|
||||
|
||||
## The schema
|
||||
|
||||
Ghostty's own documentation (`ghostty +show-config --default --docs`) contains
|
||||
|
||||
Reference in new issue
Block a user