# shellcheck shell=dash
___x_cmd_pwsh_ps(){
    pwsh:arg:null

    local x_output_mode=; local x_output=
    while [ $# -gt 0 ]; do
        case "$1" in
            -h|--help) ___x_cmd help -m pwsh ps; return ;;
        esac
        pwsh:output:mode:all
    done

    [ "$x_output_mode" != app ] || {
        ___x_cmd_pwsh___exec "$x_output_mode" "Get-Process" "$x_output" \
            | ___x_cmd csv tab - 48,23,10,2,3,7,6,5,24 \
            | ___x_cmd csv --app
        return
    }

    ___x_cmd_pwsh___exec "$x_output_mode" "Get-Process" "$x_output"
}
