LoginSignup
1
0

More than 3 years have passed since last update.

systemd管理サービス一覧のjson形式出力コマンド

Last updated at Posted at 2020-10-17
systemctl --type=service | grep .service | sed -E 's/ +/ /g' | sed -E 's/([^ ]+) +([^ ]+) +([^ ]+) +([^ ]+) +(.*)/{"name":"\1","status":"\4","desc":"\5"},/g' | tr -d '\n' | sed -E 's/(.*),/[\1]/g'
1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0