Dear all,
I recently released blib [1], a bash library which also aims to be
useful for Qubes OS bash developers.
The documentation can be found at [2], the Qubes specific part at [3].
A short example of what it can do:
-------------------------------
#!/bin/bash
source blib
b_import "os/qubes4/dom0"
function getTheAnswer {
echo "There's none?!"
return 42
}
vm="d-testing"
b_dom0_ensureRunning "$vm" || { B_ERR="Failed to start the VM ${vm}.
Maybe it doesn't exist?" ; B_E }
b_silence b_dom0_execFuncIn "$vm" "" "getTheAnswer"
echo "The answer to everything, computed by the VM ${vm}: $?"
-------------------------------
Please let me know if there's any issues with it.
Best Regards
David
[1]
https://github.com/3hhh/blib
[2]
https://3hhh.github.io/blib-doc/blib.html
[3]
https://3hhh.github.io/blib-doc/blib.html#osqubes4dom0