author | Jakub Narebski <jnareb@gmail.com> | |
Sat, 26 Feb 2011 22:32:33 +0000 (23:32 +0100) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 28 Feb 2011 06:02:31 +0000 (22:02 -0800) | ||
commit | 20e7ab8ae26108e1d8675c375be7f06820da5cb0 | |
tree | 795228f3106c6016982254193a75772f70e193ff | tree | snapshot |
parent | 62270f6b0a4e67e5044fb0d70d0e82ac6e553eb2 | commit | diff |
git-instaweb: Change how gitweb.psgi is made runnable as standalone app
According to blog post "FindBin, __FILE__, $0 and PSGI woes"
http://bulknews.typepad.com/blog/2011/02/findbin-__file__-0-and-psgi-woes.html
by Tatsuhiko Miyagawa, using 'if (__FILE__ eq $0)' in .psgi code
(to check if script was run from command line), is not supposed to work
since Plack 0.9971.
Replace it with one of proposed solutions; while at it return $app
explicitely, rather than implicitely by being a last expression.
This affects 'plackup' web server.
While at it cleanup whitespace.
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Acked-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
According to blog post "FindBin, __FILE__, $0 and PSGI woes"
http://bulknews.typepad.com/blog/2011/02/findbin-__file__-0-and-psgi-woes.html
by Tatsuhiko Miyagawa, using 'if (__FILE__ eq $0)' in .psgi code
(to check if script was run from command line), is not supposed to work
since Plack 0.9971.
Replace it with one of proposed solutions; while at it return $app
explicitely, rather than implicitely by being a last expression.
This affects 'plackup' web server.
While at it cleanup whitespace.
Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Acked-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-instaweb.sh | diff | blob | history |