Skip to main content

base_command

Function base_command 

Source
pub fn base_command(command: &str) -> String
Expand description

Extract the first real command word, skipping leading KEY=VALUE assignments.

Uses shlex for correct handling of quoted values like FOO="bar baz". Returns the basename of the command (e.g. /usr/bin/lsls).