Skip to content

Commit 083e73d

Browse files
authored
fix: add os/arch in version command (#1275)
Pending on #1260 Example of notation version command ``` Notation - a tool to sign and verify artifacts. Version: v2.0.0-alpha.1+unreleased Go version: go1.24.0 OS/Arch: linux/amd64 Git commit: c68425f ``` Resolve part of #1247 --------- Signed-off-by: Junjie Gao <junjiegao@microsoft.com>
1 parent 55900b5 commit 083e73d

2 files changed

Lines changed: 3 additions & 0 deletions

File tree

cmd/notation/version.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ func runVersion() {
3838

3939
fmt.Printf("Version: %s\n", version.GetVersion())
4040
fmt.Printf("Go version: %s\n", runtime.Version())
41+
fmt.Printf("OS/Arch: %s/%s\n", runtime.GOOS, runtime.GOARCH)
4142

4243
if version.GitCommit != "" {
4344
fmt.Printf("Git commit: %s\n", version.GitCommit)

specs/cmd/version.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ Notation - a tool to sign and verify artifacts.
1111
1212
Version: <MAJOR.MINOR.PATCH>
1313
Go version: go<MAJOR.MINOR.PATCH>
14+
OS/Arch: <OS>/<ARCH>
1415
Git commit: <long_hash>
1516
```
1617

@@ -41,5 +42,6 @@ Notation - a tool to sign and verify artifacts.
4142
4243
Version: 1.0.0
4344
Go Version: go1.19.2
45+
OS/Arch: linux/amd64
4446
Git commit: 1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a
4547
```

0 commit comments

Comments
 (0)