X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=git-instaweb.sh;h=d96eddbe56783d61304941a134361797c82480e7;hb=e4d1afbcf2e39a997ae90befd629ee53e444c4c9;hp=32f6496b0d36cff061f00a4ad70b6fa4d34c2646;hpb=441b40d833fdfa93eb2908e52742248faf0ee993;p=git.git diff --git a/git-instaweb.sh b/git-instaweb.sh index 32f6496b0..d96eddbe5 100755 --- a/git-instaweb.sh +++ b/git-instaweb.sh @@ -77,11 +77,30 @@ start_httpd () { resolve_full_httpd # don't quote $full_httpd, there can be arguments to it (-f) - $full_httpd "$fqgitdir/gitweb/httpd.conf" - if test $? != 0; then - echo "Could not execute http daemon $httpd." - exit 1 - fi + case "$httpd" in + *mongoose*) + #The mongoose server doesn't have a daemon mode so we'll have to fork it + $full_httpd "$fqgitdir/gitweb/httpd.conf" & + #Save the pid before doing anything else (we'll print it later) + pid=$! + + if test $? != 0; then + echo "Could not execute http daemon $httpd." + exit 1 + fi + + cat > "$fqgitdir/pid" <) has been applied - if test -f "$module_path/mod_perl.so" && grep '^our $gitbin' \ + if test -f "$module_path/mod_perl.so" && grep 'MOD_PERL' \ "$GIT_DIR/gitweb/gitweb.cgi" >/dev/null then # favor mod_perl if available @@ -308,6 +327,31 @@ EOF fi } +mongoose_conf() { + cat > "$conf" <