git-instaweb: pass through invoking user's path to gitweb CGI scripts

When used with lighttpd or mongoose, git-instaweb previously passed a
hard-coded, default value of PATH to the gitweb CGI script. Use the invoking
user's value for PATH for this instead. (This is already implicitly the
behaviour for other web servers supported by git-instaweb.)

Signed-off-by: Chris Webb <chris@arachsys.com>
Acked-by: Eric Wong <normalperson@yhbt.net>
This commit is contained in:
Chris Webb 2010-04-15 14:29:45 +01:00 коммит произвёл Junio C Hamano
Родитель 8de096b671
Коммит 39407304f1
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -212,7 +212,7 @@ server.errorlog = "$fqgitdir/gitweb/error.log"
# variable above and uncomment this
#accesslog.filename = "$fqgitdir/gitweb/access.log"
setenv.add-environment = ( "PATH" => "/usr/local/bin:/usr/bin:/bin" )
setenv.add-environment = ( "PATH" => env.PATH )
cgi.assign = ( ".cgi" => "" )
@ -361,7 +361,7 @@ error_log $fqgitdir/gitweb/error.log
access_log $fqgitdir/gitweb/access.log
#cgi setup
cgi_env PATH=/usr/local/bin:/usr/bin:/bin,GIT_DIR=$GIT_DIR,GIT_EXEC_PATH=$GIT_EXEC_PATH
cgi_env PATH=$PATH,GIT_DIR=$GIT_DIR,GIT_EXEC_PATH=$GIT_EXEC_PATH
cgi_interp $PERL
cgi_ext cgi,pl