1
0
mirror of https://github.com/getsops/sops.git synced 2026-02-05 12:45:21 +01:00

1 Commits

Author SHA1 Message Date
Hidde Beydals
e26844deff version: rewrite command to use GitHub endpoints
This changes the logic of parsing the `version.go` file from a certain
branch to instead make use of the GitHub latest release redirect or
API[1] endpoints for checking if `sops` is on the latest version.

Detaching any future release of SOPS from specific file structures
and/or branches, and (theoretically) freeing it from the requirement of
having to bump the version in-code during release (as this is also done
using `-ldflags` during build). Were it not for the fact that we have
to maintain it for backwards compatibility.

[1]: https://docs.github.com/en/free-pro-team@latest/rest/releases/releases?apiVersion=2022-11-28#get-the-latest-release

Signed-off-by: Hidde Beydals <hidde@hhh.computer>
2023-08-23 07:37:42 +02:00