D3649: serve: add option print-url

yuja (Yuya Nishihara) phabricator at mercurial-scm.org
Fri Jun 1 22:47:45 EDT 2018


yuja added a comment.


  >   ('t', 'templates', '', _('web templates to use'), _('TEMPLATE')),
  >   ('', 'style', '', _('template style to use'), _('STYLE')),
  >   ('6', 'ipv6', None, _('use IPv6 in addition to IPv4')),
  > 
  > - ('', 'certificate', '', _('SSL certificate file'), _('FILE'))] +    ('', 'certificate', '', _('SSL certificate file'), _('FILE')), +    ('', 'print-url', None, _('start and print only the URL'))] + subrepoopts, _('[OPTION]...'), optionalrepo=True) @@ -4798,6 +4799,10 @@ opts = pycompat.byteskwargs(opts) if opts["stdio"] and opts["cmdserver"]: raise error.Abort(_("cannot use --stdio with --cmdserver")) +    if opts["print_url"] and ui.verbose: +        raise error.Abort(_("cannot use --print-url with --verbose")) +    if opts["print_url"]: +        opts['daemon'] = True
  
  It's surprising that `hg serve --print-url` spawns a daemon process!

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D3649

To: nspanti-logilab, #hg-reviewers, durin42
Cc: yuja, mercurial-devel


More information about the Mercurial-devel mailing list