Skip to content

Commit

Permalink
git-instaweb: Remove pidfile after stopping web server
Browse files Browse the repository at this point in the history
This way running e.g. "git instaweb" after "git instaweb --stop" would
not try to kill already stopped web server.

This is probably important only for those web servers that are
"daemonized" by git-instaweb itself, i.e. for those where it is
git-instaweb that creates pidfile.  Currently it is includes only
'mongoose' web server, but it would also include 'plackup' web server
(added in later commit).

Signed-off-by: Jakub Narebski <jnareb@gmail.com>
Acked-by: Petr Baudis <pasky@suse.cz>
Acked-by: Eric Wong <normalperson@yhbt.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Jakub Narebski authored and Junio C Hamano committed Jun 2, 2010
1 parent c0cb4ed commit d112762
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions git-instaweb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,7 @@ EOF

stop_httpd () {
test -f "$fqgitdir/pid" && kill $(cat "$fqgitdir/pid")
rm -f "$fqgitdir/pid"
}

while test $# != 0
Expand Down

0 comments on commit d112762

Please sign in to comment.