detached 452b6b4

feat(bar): read the pprof address from NEFERBAR_PPROF

commit
452b6b470328c856f6a3409a2b8c77d58b09aea1
author
brice · · 2026-10-08 05:37 UTC
parent
cfe73b7
signature
GPG VerifiedCD88F9E564E0102646FB6077A1A07C7C7C3E349D · arch-gpg Verified for the committer email
2 files · +2 -2
M README.md +1 -1
@@ -231,7 +231,7 @@ neferbar [-config file] [-display socket] [-pprof addr] [-memstats interval]
231231 |---|---|
232232 | `-config` | Config file. Default: `$XDG_CONFIG_HOME/neferbar/config.toml`. |
233233 | `-display` | Wayland socket name or path. Default: `$NEFERBAR_DISPLAY`, then `$WAYLAND_DISPLAY`. |
234-| `-pprof` | Serve Go profiling on a loopback address, such as `localhost:6060`. |
234+| `-pprof` | Serve Go profiling on a loopback address, such as `localhost:6060`. Default: `$NEFERBAR_PPROF`, so a bar started by the compositor can be profiled. |
235235 | `-memstats` | Log allocation counters at this interval. |
236236
237237 ## Reading the focused window
@@ -231,7 +231,7 @@ neferbar [-config file] [-display socket] [-pprof addr] [-memstats interval]
231 |---|---|231 |---|---|
232 | `-config` | Config file. Default: `$XDG_CONFIG_HOME/neferbar/config.toml`. |232 | `-config` | Config file. Default: `$XDG_CONFIG_HOME/neferbar/config.toml`. |
233 | `-display` | Wayland socket name or path. Default: `$NEFERBAR_DISPLAY`, then `$WAYLAND_DISPLAY`. |233 | `-display` | Wayland socket name or path. Default: `$NEFERBAR_DISPLAY`, then `$WAYLAND_DISPLAY`. |
234-| `-pprof` | Serve Go profiling on a loopback address, such as `localhost:6060`. |234+| `-pprof` | Serve Go profiling on a loopback address, such as `localhost:6060`. Default: `$NEFERBAR_PPROF`, so a bar started by the compositor can be profiled. |
235 | `-memstats` | Log allocation counters at this interval. |235 | `-memstats` | Log allocation counters at this interval. |
236 236
237 ## Reading the focused window237 ## Reading the focused window
M cmd/neferbar/main.go +1 -1
@@ -33,7 +33,7 @@ func main() {
3333 }
3434 cfgPath := flag.String("config", "", "config file (default: $XDG_CONFIG_HOME/neferbar/config.toml)")
3535 display := flag.String("display", os.Getenv("NEFERBAR_DISPLAY"), "Wayland socket name or absolute path (default: $NEFERBAR_DISPLAY, then $WAYLAND_DISPLAY)")
36- pprofAddr := flag.String("pprof", "", "serve pprof on this loopback address, e.g. localhost:6060")
36+ pprofAddr := flag.String("pprof", os.Getenv("NEFERBAR_PPROF"), "serve pprof on this loopback address, e.g. localhost:6060 (default: $NEFERBAR_PPROF)")
3737 memStats := flag.Duration("memstats", 0, "log allocation counters at this interval (0: off)")
3838 flag.Parse()
3939
@@ -33,7 +33,7 @@ func main() {
33 }33 }
34 cfgPath := flag.String("config", "", "config file (default: $XDG_CONFIG_HOME/neferbar/config.toml)")34 cfgPath := flag.String("config", "", "config file (default: $XDG_CONFIG_HOME/neferbar/config.toml)")
35 display := flag.String("display", os.Getenv("NEFERBAR_DISPLAY"), "Wayland socket name or absolute path (default: $NEFERBAR_DISPLAY, then $WAYLAND_DISPLAY)")35 display := flag.String("display", os.Getenv("NEFERBAR_DISPLAY"), "Wayland socket name or absolute path (default: $NEFERBAR_DISPLAY, then $WAYLAND_DISPLAY)")
36- pprofAddr := flag.String("pprof", "", "serve pprof on this loopback address, e.g. localhost:6060")36+ pprofAddr := flag.String("pprof", os.Getenv("NEFERBAR_PPROF"), "serve pprof on this loopback address, e.g. localhost:6060 (default: $NEFERBAR_PPROF)")
37 memStats := flag.Duration("memstats", 0, "log allocation counters at this interval (0: off)")37 memStats := flag.Duration("memstats", 0, "log allocation counters at this interval (0: off)")
38 flag.Parse()38 flag.Parse()
39 39

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 5

Tags 4

↑↓ moveenter openesc close