-#!/bin/sh -efux
+#!/bin/sh -eux
exec 2>&1
+sv=${PWD#/etc/sv/}
+eval "home=~$sv"
+
exec /usr/bin/chpst \
- -u git-daemon:git-daemon \
- /usr/bin/git daemon \
- --base-path=/home/git/pub/git \
- --interpolated-path=/home/git/srv/git/%H%D \
+ -u "$sv":"$sv":git-data \
+ /usr/lib/git-core/git-daemon \
+ --interpolated-path="$home"/%H%D \
--reuseaddr \
- --syslog \
--user-path=pub/git \
- --verbose \
- -- \
- /home/git/pub/git
+ --verbose