Crates.io | pals |
lib.rs | pals |
version | 0.1.2 |
source | src |
created_at | 2021-02-01 06:29:23.86026 |
updated_at | 2021-02-20 07:03:43.850425 |
description | Processes' Arguments LiSt |
homepage | |
repository | https://github.com/oooutlk/pals |
max_upload_size | |
id | 349148 |
size | 69,182 |
The pals project aims at providing a binary utility and a Rust library to generate a running Processes' Arguments LiSt the portable way.
See API doc for more.
The pals command will dump running processes' name, pid, arguments and the sub processes to form a JSON array of elements which are process trees.
A process is a JSON object composed of:
cmd: Process name.
pid: Process id.
args: JSON array of splitted arguments, aka argv. It's optional.
subs: JSON array of sub processes. It's optional.
[{cmd: "alpha", pid:105, args:[ "alpha" ], subs:[
{cmd: "beta", pid:107, args:[ "beta", "--help" ]},
{cmd: "gamma", pid:106 }]},
{cmd: "lorum", pid:102, subs:[
{cmd: "ipsumipsum", pid:104, args:[ "ipsumipsumipsum", "--name-too-long" ]}]}]
Thanks to identing, the JSON output is even human readable.
Supporting on Windows, Linux and FreeBSD are tested. Furthermore, pals works on
any platform that supports ps
command, for example, macOS. However, ps
is
NOT required on all supported platforms.
On some platforms, process names may be truncted to fit in the maximum length.
Under Apache License 2.0 or MIT License, at your will.