[PATCH 1 of 1] Enable commit to disallow recursive submodule commits

Martin Geisler mg at aragost.com
Fri Apr 23 03:26:50 CDT 2010


Dan Villiom Podlaski Christiansen <danchr at gmail.com> writes:

>> +                        if srepo.wcdirty() and not force:
>> +                            fail(s, _("submodule working copy dirty"
>> +                                      + " (--force to commit anyway)"))

Same problem here.

>> +                        else:
>> +                            self.ui.status(_('subrepository %s changed'
>> +                                             + ' (updating .hgsubstate)\n') % s)
>> +                            state[s] = (state[s][0], srepo.curstate())
>
> AFAICT the ‘+’ here is redundant. I'd suggest you remove it as might
> confuse gettext. (I haven't checked.)

You are right, it gettext will complain about this when it extracts
messages. Gettext knows about how Python will merge several literal
strings into one (the same rule as in C). So it should be like this
instead with the space on the upper line:

>> +                            self.ui.status(_('subrepository %s changed '
>> +                                             '(updating .hgsubstate)\n') % s)

-- 
Martin Geisler

Fast and powerful revision control: http://mercurial.selenic.com/


More information about the Mercurial-devel mailing list