# HG changeset patch # User Augie Fackler # Date 1538589285 14400 # Node ID 60eb35b0c11cfa37172adb0e871455ca115e9d73 # Parent 3a333a582d7b4344c5dbe17ef5c9057771fc8142 remotefilelog: remove function that was described as deprecated Differential Revision: https://phab.mercurial-scm.org/D4937 diff -r 3a333a582d7b -r 60eb35b0c11c hgext/remotefilelog/extutil.py --- a/hgext/remotefilelog/extutil.py Thu Sep 27 13:03:19 2018 -0400 +++ b/hgext/remotefilelog/extutil.py Wed Oct 03 13:54:45 2018 -0400 @@ -92,18 +92,6 @@ # continue the hg process here. os._exit(returncode) -def runshellcommand(script, env): - ''' - Run a shell command in the background. - This spawns the command and returns before it completes. - - Prefer using runbgcommand() instead of this function. This function should - be discouraged in new code. Running commands through a subshell requires - you to be very careful about correctly escaping arguments, and you need to - make sure your command works with both Windows and Unix shells. - ''' - runbgcommand(script, env=env, shell=True) - @contextlib.contextmanager def flock(lockpath, description, timeout=-1): """A flock based lock object. Currently it is always non-blocking. diff -r 3a333a582d7b -r 60eb35b0c11c hgext/remotefilelog/repack.py --- a/hgext/remotefilelog/repack.py Thu Sep 27 13:03:19 2018 -0400 +++ b/hgext/remotefilelog/repack.py Wed Oct 03 13:54:45 2018 -0400 @@ -49,10 +49,8 @@ msg = _("(running background incremental repack)\n") if packsonly: cmd.append('--packsonly') - cmd = ' '.join(map(procutil.shellquote, cmd)) - repo.ui.warn(msg) - extutil.runshellcommand(cmd, encoding.environ) + extutil.runbgcommand(cmd, encoding.environ) def fullrepack(repo, options=None): """If ``packsonly`` is True, stores creating only loose objects are skipped. diff -r 3a333a582d7b -r 60eb35b0c11c hgext/remotefilelog/shallowrepo.py --- a/hgext/remotefilelog/shallowrepo.py Thu Sep 27 13:03:19 2018 -0400 +++ b/hgext/remotefilelog/shallowrepo.py Wed Oct 03 13:54:45 2018 -0400 @@ -199,9 +199,7 @@ cmd.append('--repack') if revs: cmd += ['-r', revs] - cmd = ' '.join(map(procutil.shellquote, cmd)) - - extutil.runshellcommand(cmd, encoding.environ) + extutil.runbgcommand(cmd, encoding.environ) def prefetch(self, revs, base=None, pats=None, opts=None): """Prefetches all the necessary file revisions for the given revs