Commit b34f51a1 authored by Семён Марьясин's avatar Семён Марьясин Committed by Jouke Witteveen
Browse files

Speed up 'netctl list'

When you call `netctl list`, it calls `systemctl status` for each of the
profiles. By default, `systemctl status` fetches the last log entries from the
journal, which is often a time-consuming operation. Additionally, the status
output is not meant for machine processing.
parent e8109311
......@@ -144,7 +144,7 @@ sd_call() {
## Retrieves the status string from the unit for a profile
# $1: profile name
sd_status_text() {
sd_call status "$1" | sed -n 's/^ *Status: "\(.*\)"$/\1/p'
sd_call "show --property=StatusText --value" "$1"
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment