Simplify prompt, move to chromium
j3s j3s@c3f.net
Sun, 27 Jun 2021 16:53:33 -0500
3 files changed,
3 insertions(+),
8 deletions(-)
M
bin/prompt.go
→
bin/prompt.go
@@ -4,7 +4,6 @@ import (
"fmt" "os" "strings" - "syscall" "time" )@@ -16,12 +15,8 @@ var parts []string
if strings.HasPrefix(cwd, home) { cwd = "~" + cwd[len(home):] } - var sysinfo syscall.Sysinfo_t - syscall.Sysinfo(&sysinfo) - uptime := time.Duration(sysinfo.Uptime) * time.Second - fmt.Printf("[%d:%02d:%02d] %s ", int64(uptime.Hours()), - int64(uptime.Minutes()) % 60, int64(uptime.Seconds()) % 60, - host) + now := time.Now().Format("15:04:05") + fmt.Printf("[%s] %s ", now, host) parts = strings.Split(cwd, "/") for i, part := range parts {
M
bin/xdg-open
→
bin/xdg-open
@@ -1,7 +1,7 @@
#!/bin/sh case "${1%%:*}" in http|https) - exec firefox "$1" + exec chromium "$1" ;; *.pdf) exec zathura "$1"