mercurial/cmdutil.py
changeset 15231 cd6f10dccf16
parent 15214 231aac5280ba
child 15410 9e99d2bbb1b1
child 15600 195dbd1cef0c
equal deleted inserted replaced
15230:697289c5d415 15231:cd6f10dccf16
    73     if repo.dirstate.p2() != nullid:
    73     if repo.dirstate.p2() != nullid:
    74         raise util.Abort(_('outstanding uncommitted merge'))
    74         raise util.Abort(_('outstanding uncommitted merge'))
    75     modified, added, removed, deleted = repo.status()[:4]
    75     modified, added, removed, deleted = repo.status()[:4]
    76     if modified or added or removed or deleted:
    76     if modified or added or removed or deleted:
    77         raise util.Abort(_("outstanding uncommitted changes"))
    77         raise util.Abort(_("outstanding uncommitted changes"))
       
    78     ctx = repo[None]
       
    79     for s in ctx.substate:
       
    80         if ctx.sub(s).dirty():
       
    81             raise util.Abort(_("uncommitted changes in subrepo %s") % s)
    78 
    82 
    79 def logmessage(ui, opts):
    83 def logmessage(ui, opts):
    80     """ get the log message according to -m and -l option """
    84     """ get the log message according to -m and -l option """
    81     message = opts.get('message')
    85     message = opts.get('message')
    82     logfile = opts.get('logfile')
    86     logfile = opts.get('logfile')