I'm currently packaging libratbag which provides the cli interface ratbagctl. when launched without arguments, it normally the current devices ###################### ## with wrap-program (correct): b@ui ~/guix [env]$ ratbagctl warbling-mara:       Logitech G102 Prodigy Gaming Mouse b@ui ~/guix [env]$ head `which ratbagctl` #!/gnu/store/29jhbbg1hf557x8j53f9sxd9imlmf02a-bash-minimal-5.0.7/bin/bash export PYTHONPATH="/gnu/store/88v8lvs02sdqgzv7w96g19fvh8hffzzp-libratbag-0.13/lib/python3.7/site-packages/:/gnu/store/h4jkr0qg86zjn1kq6iq8v33pcadj9r13-python-evdev-1.3.0/lib/python3.7/site-packages/:/gnu/store/z5fdc5aa9hs4c3p79ajzgxhazv7702y8-python-pygobject-3.28.3/lib/python3.7/site-packages/" exec -a "$0" "/gnu/store/88v8lvs02sdqgzv7w96g19fvh8hffzzp-libratbag-0.13/bin/.ratbagctl-real" "$@" ###################### ## with wrap-script: b@ui ~/guix [env]$ ratbagctl usage: /gnu/store/754ylqjs68va7rswr3fscwa0kyazsbjq-profile/bin/ratbagctl        {info,name,profile,resolution,dpi,rate,button,led} ... /gnu/store/754ylqjs68va7rswr3fscwa0kyazsbjq-profile/bin/ratbagctl : error: invalid choice: '/gnu/store/754ylqjs68va7rswr3fscwa0kyazsbjq-profile/bin/ratbagctl' (choose from 'info', 'name', 'profile', 'resolution', 'dpi', 'rate', 'button', 'led') b@ui ~/guix [env]$ ratbagctl list /gnu/store/754ylqjs68va7rswr3fscwa0kyazsbjq-profile/bin/ratbagctl : error: invalid choice: '/gnu/store/754ylqjs68va7rswr3fscwa0kyazsbjq-profile/bin/ratbagctl' (choose from 'info', 'name', 'profile', 'resolution', 'dpi', 'rate', 'button', 'led') b@ui ~/guix [env]$ ratbagctl info rastkasnts atkatkaf ftbaontb aesbtabtowf ~5qawylftarsnvbawlpfyq usage: /gnu/store/754ylqjs68va7rswr3fscwa0kyazsbjq-profile/bin/ratbagctl        {info,name,profile,resolution,dpi,rate,button,led} ... /gnu/store/754ylqjs68va7rswr3fscwa0kyazsbjq-profile/bin/ratbagctl : error: invalid choice: '/gnu/store/754ylqjs68va7rswr3fscwa0kyazsbjq-profile/bin/ratbagctl' (choose from 'info', 'name', 'profile', 'resolution', 'dpi', 'rate', 'button', 'led') b@ui ~/guix [env]$ b@ui ~/guix [env]$ head `which ratbagctl` #!/gnu/store/0awhym5h0m890n0wq87y0dxznh14rk88-guile-next-3.0.1/bin/guile --no-auto-compile #!#; Guix wrapper #\-(begin (setenv "PYTHONPATH" "/gnu/store/1hcpppqc6268siki64vs1ygq1qsr8w35-libratbag-0.13/lib/python3.7/site-packages/:/gnu/store/h4jkr0qg86zjn1kq6iq8v33pcadj9r13-python-evdev-1.3.0/lib/python3.7/site-packages/:/gnu/store/z5fdc5aa9hs4c3p79ajzgxhazv7702y8-python-pygobject-3.28.3/lib/python3.7/site-packages/")) #\-(let ((cl (command-line))) (apply execl "/gnu/store/608bvypsh90c58apvd2cgg3m9l2pwjqn-python-3.7.4/bin/python3" (car cl) (cons (car cl) (append (quote ("")) cl)))) #!/gnu/store/608bvypsh90c58apvd2cgg3m9l2pwjqn-python-3.7.4/bin/python3 #################### Here I make a copy of the guix build utils module and modify the wrap-script, removing #\space as suggested, so it defaults to char-set:graphic. This results in the above guile wrapper chaging to: #\-(let ((cl (command-line))) (apply execl "/gnu/store/608bvypsh90c58apvd2cgg3m9l2pwjqn-python-3.7.4/bin/python3" (car cl) (cons (car cl) (append (quote ()) cl)))) The behaviour changes somewhat. Now running ratbagctl prints the commants list, which is what should happen when the wrong arguments are provided, e.g., `ratbagctl qwfqwfqf` b@ui ~/guix [env]$ ratbagctl usage: ratbagctl [OPTIONS] list        ratbagctl [OPTIONS] {COMMAND} ... b@ui ~/guix [env]$ ratbagctl list usage: /gnu/store/fgl1w0lh1pzqg8j4gi8j1yi29aa122ja-profile/bin/ratbagctl        {info,name,profile,resolution,dpi,rate,button,led} ... /gnu/store/fgl1w0lh1pzqg8j4gi8j1yi29aa122ja-profile/bin/ratbagctl : error: invalid choice: 'list' (choose from 'info', 'name', 'profile', 'resolution', 'dpi', 'rate', 'button', 'led')