-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdoc.go
More file actions
32 lines (25 loc) · 733 Bytes
/
Copy pathdoc.go
File metadata and controls
32 lines (25 loc) · 733 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
/*
Package status is a go implementation of a debian-like statusline.
The idea of the package is that no prior configuration needs to be applied before
using it so that functions can be called "off-the-shelf"
Example:
package main
import (
"os"
"time"
"github.com/els0r/status"
)
func main() {
// print a status line
status.Linef("Waiting %d seconds", 5)
time.Sleep(5*time.Second)
status.Ok("")
// now write to stderr
status.SetOutput(os.Stderr)
// print another status line
status.Linef("Alerting you in %d seconds", 5)
time.Sleep(5*time.Second)
status.Warn("this went to stderr")
}
*/
package status