Don't eat yellow snow.
git-svn-id: file:///srv/svn/repo/mima/trunk@6 d2428f92-30f9-164c-8098-19ee57ce342c
This commit is contained in:
parent
e82c2b2914
commit
db8b3589ca
5
main.go
5
main.go
@ -15,10 +15,12 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
// "Uh"
|
||||||
getOS, erros := exec.Command("uname", "-sr").Output()
|
getOS, erros := exec.Command("uname", "-sr").Output()
|
||||||
getArch, errarch := exec.Command("uname", "-m").Output()
|
getArch, errarch := exec.Command("uname", "-m").Output()
|
||||||
getHost, errhost := exec.Command("uname", "-n").Output()
|
getHost, errhost := os.Hostname()
|
||||||
|
|
||||||
|
// At least it works \_(=^.^=)_/
|
||||||
if erros != nil {
|
if erros != nil {
|
||||||
log.Fatal(erros)
|
log.Fatal(erros)
|
||||||
}
|
}
|
||||||
@ -29,6 +31,7 @@ func main() {
|
|||||||
log.Fatal(errhost)
|
log.Fatal(errhost)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Pretty-print output
|
||||||
fmt.Printf("%s (%d) @ %s", os.Getenv("USER"), os.Getuid(), getHost)
|
fmt.Printf("%s (%d) @ %s", os.Getenv("USER"), os.Getuid(), getHost)
|
||||||
fmt.Printf("\n")
|
fmt.Printf("\n")
|
||||||
fmt.Printf("Editor: %s \n", os.Getenv("EDITOR"))
|
fmt.Printf("Editor: %s \n", os.Getenv("EDITOR"))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user