A 6-char limit is like night.

git-svn-id: file:///srv/svn/repo/mima/trunk@8 d2428f92-30f9-164c-8098-19ee57ce342c
This commit is contained in:
admin 2022-09-06 21:18:31 +00:00
parent eb474416d3
commit b36998e141
2 changed files with 5 additions and 7 deletions

View File

@ -2,7 +2,7 @@ PREFIX=/usr/local
OUTPUT=antifetch
build:
go build -v -o ${OUTPUT}
go build -v ./cmd/${OUTPUT}
clean:
rm -f ${OUTPUT}
install:

View File

@ -15,14 +15,12 @@ import (
)
func main() {
getHost, errhost := os.Hostname()
host, err := os.Hostname()
if errhost != nil {
log.Fatal(errhost)
if err != nil {
log.Fatal(err)
}
// Pretty-print output
fmt.Printf("%s (%d) @ %s", os.Getenv("USER"), os.Getuid(), getHost)
fmt.Printf("%s (%d) @ %s", os.Getenv("USER"), os.Getuid(), host)
fmt.Printf("\n")
fmt.Printf("Editor: %s\n", os.Getenv("EDITOR"))
fmt.Printf("Operating System: %s\n", runtime.GOOS)