Add version line after banner with release date
Added mfer/constants.go with Version and ReleaseDate constants for deterministic builds. Banner now shows "mfer by @sneak: v0.1.0 released 2025-12-17"
This commit is contained in:
parent
818358a8a1
commit
6edc798de0
@ -9,6 +9,7 @@ import (
|
|||||||
"github.com/spf13/afero"
|
"github.com/spf13/afero"
|
||||||
"github.com/urfave/cli/v2"
|
"github.com/urfave/cli/v2"
|
||||||
"sneak.berlin/go/mfer/internal/log"
|
"sneak.berlin/go/mfer/internal/log"
|
||||||
|
"sneak.berlin/go/mfer/mfer"
|
||||||
)
|
)
|
||||||
|
|
||||||
// CLIApp is the main CLI application container. It holds configuration,
|
// CLIApp is the main CLI application container. It holds configuration,
|
||||||
@ -43,6 +44,7 @@ const banner = `
|
|||||||
func (mfa *CLIApp) printBanner() {
|
func (mfa *CLIApp) printBanner() {
|
||||||
if log.GetLevel() <= log.InfoLevel {
|
if log.GetLevel() <= log.InfoLevel {
|
||||||
_, _ = fmt.Fprintln(mfa.Stdout, banner)
|
_, _ = fmt.Fprintln(mfa.Stdout, banner)
|
||||||
|
_, _ = fmt.Fprintf(mfa.Stdout, " mfer by @sneak: v%s released %s\n", mfer.Version, mfer.ReleaseDate)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
6
mfer/constants.go
Normal file
6
mfer/constants.go
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
package mfer
|
||||||
|
|
||||||
|
const (
|
||||||
|
Version = "0.1.0"
|
||||||
|
ReleaseDate = "2025-12-17"
|
||||||
|
)
|
||||||
Loading…
Reference in New Issue
Block a user