2020-02-28 05:44:45 +08:00
Current steps for a release:
### gotop
1. Update Version in main.go
2. Update CHANGELOG.md
3. Tag
4. Push everything
2020-03-02 23:09:17 +08:00
5. When the github workflows complete, finish the draft release and publish.
2020-04-16 21:14:13 +08:00
6. Wait for the [Homebrew ](https://github.com/xxxserxxx/homebrew-gotop ) and [AUR](https://github.com/xxxserxxx/gotop-linux] projects to finish building.
1. check out gotop-linux and run `aurpublish aur` and `aurpublish aur-bin`
2. update the hashes in the Nix package (see below), test build, push a pull request
3. notify Homebrew
2020-03-02 23:09:17 +08:00
Homebrew is automatically updated. The AUR project still needs secret
credentials to aurpublish to the AUR repository, so the final publish step is
still currently manual.
Oh, what a tangled web.
2020-03-03 19:47:52 +08:00
Nix adds new and interesting complexities to the release.
2020-04-16 21:14:13 +08:00
0. Download the gotop src package; run sha256 on it to get the hash
2020-03-03 19:47:52 +08:00
1. cd to the nixpkgs directory
2020-04-16 21:14:13 +08:00
2. Update the sha256 hash in `pkgs/tools/system/gotop/default.nix`
2. `docker run -it --rm --mount type=bind,source="\$(pwd)",target=/mnt nixos/nix sh`
3. `cd /mnt`
8. install & run vgo2nix to update deps.nix
7. `nix-build -A gotop`
8. When it fails, copy the hash and update the
2020-03-03 20:36:42 +08:00
For plugin development:
```
V=$(git show -s --format=%cI HEAD | cut -b -19 | tr -cd '[:digit:]')-$(git rev-parse HEAD | cut -b -12)
go build -ldflags "-X main.Version=$V" -o gotop ./cmd/gotop
```