Show More
@@ -849,9 +849,14 b' def start(ui, dirstate, root, opts):' | |||||
849 | finally: |
|
849 | finally: | |
850 | self.master.shutdown() |
|
850 | self.master.shutdown() | |
851 |
|
851 | |||
852 | runargs = None |
|
|||
853 | if 'inserve' not in sys.argv: |
|
852 | if 'inserve' not in sys.argv: | |
854 | runargs = [sys.argv[0], 'inserve', '-R', root] |
|
853 | runargs = [sys.argv[0], 'inserve', '-R', root] | |
|
854 | else: | |||
|
855 | runargs = sys.argv[:] | |||
|
856 | ||||
|
857 | pidfile = ui.config('inotify', 'pidfile') | |||
|
858 | if opts['daemon'] and pidfile is not None and 'pid-file' not in runargs: | |||
|
859 | runargs.append("--pid-file=%s" % pidfile) | |||
855 |
|
860 | |||
856 | service = service() |
|
861 | service = service() | |
857 | logfile = ui.config('inotify', 'log') |
|
862 | logfile = ui.config('inotify', 'log') |
@@ -20,7 +20,11 b' echo "inotify=" >> $HGRCPATH' | |||||
20 | cd repo2 |
|
20 | cd repo2 | |
21 | echo b >> a |
|
21 | echo b >> a | |
22 | # check that daemon started automatically works correctly |
|
22 | # check that daemon started automatically works correctly | |
23 | hg status |
|
23 | # and make sure that inotify.pidfile works | |
|
24 | hg --config "inotify.pidfile=../hg2.pid" status | |||
|
25 | ||||
|
26 | # make sure that pidfile worked. Output should be silent. | |||
|
27 | kill `cat ../hg2.pid` | |||
24 |
|
28 | |||
25 | cd ../repo1 |
|
29 | cd ../repo1 | |
26 | echo % inserve |
|
30 | echo % inserve |
@@ -20,10 +20,10 b' hg ci -m foo' | |||||
20 |
|
20 | |||
21 | cd .. |
|
21 | cd .. | |
22 |
|
22 | |||
23 |
hg --config " |
|
23 | hg --config "inotify.pidfile=../hg2.pid" clone test test2 | |
|
24 | cat ../hg2.pid >> "$DAEMON_PIDS" | |||
|
25 | ||||
24 | cd test2 |
|
26 | cd test2 | |
25 | hg inserve -d --pid-file=../hg2.pid |
|
|||
26 | cat ../hg2.pid >> "$DAEMON_PIDS" |
|
|||
27 | echo bar > bar |
|
27 | echo bar > bar | |
28 | hg add |
|
28 | hg add | |
29 | hg ci -m bar |
|
29 | hg ci -m bar |
General Comments 0
You need to be logged in to leave comments.
Login now