common/environment/setup: add vsv command to add runit services.

This commit is contained in:
Enno Boland 2014-10-13 11:03:14 +02:00
parent 379d3d103f
commit 33fd83f6be

View file

@ -13,10 +13,22 @@ _noglob_helper() {
}
# Apply _noglob to v* commands
for cmd in vinstall vcopy vmove vmkdir vbin vman vdoc vconf vsconf vlicense; do
for cmd in vinstall vcopy vmove vmkdir vbin vman vdoc vconf vsconf vlicense vsv; do
alias ${cmd}="set -f; _noglob_helper _${cmd}"
done
_vsv() {
local service="$1"
if [ $# -lt 1 ]; then
msg_red "$pkgver: vsv: 1 argument expected: <service>\n"
return 1
fi
vmkdir etc/sv
vcopy "${FILESDIR}/$service" etc/sv
}
_vbin() {
local file="$1" targetfile="$2"