##// END OF EJS Templates
commit: abort if a subrepo is modified and ui.commitsubrepos=no...
commit: abort if a subrepo is modified and ui.commitsubrepos=no The default behaviour is to commit subrepositories with uncommitted changes. In my experience this is usually undesirable: - Changes to dependencies are often debugging leftovers - Real changes should generally be applied on the source project directly, tested then committed. This is not always possible, subversion subrepos may include only a small part of the source project, without the tests. Setting ui.commitsubrepos=no will now abort commits containing such modified subrepositories like: $ hg --config ui.commitsubrepos=no ci -m msg abort: uncommitted changes in subrepo sub I ruled out the hook solution because it does not easily take --include/exclude options in account. Also, my main concern is whether this flag could cause problems with extensions. If there are legitimate reasons for callers to override this behaviour (I could not find any), they might either override at ui level, or we could add an argument to localrepo.commit() later. v2: - Renamed ui.commitsubs to ui.commitsubrepos - Mention the configuration entry in hg help subrepos

File last commit:

r9999:f91e5630 default
r13411:d4de90a6 default
Show More
revisions.txt
29 lines | 1.2 KiB | text/plain | TextLexer
Mercurial supports several ways to specify individual revisions.
A plain integer is treated as a revision number. Negative integers are
treated as sequential offsets from the tip, with -1 denoting the tip,
-2 denoting the revision prior to the tip, and so forth.
A 40-digit hexadecimal string is treated as a unique revision
identifier.
A hexadecimal string less than 40 characters long is treated as a
unique revision identifier and is referred to as a short-form
identifier. A short-form identifier is only valid if it is the prefix
of exactly one full-length identifier.
Any other string is treated as a tag or branch name. A tag name is a
symbolic name associated with a revision identifier. A branch name
denotes the tipmost revision of that branch. Tag and branch names must
not contain the ":" character.
The reserved name "tip" is a special tag that always identifies the
most recent revision.
The reserved name "null" indicates the null revision. This is the
revision of an empty repository, and the parent of revision 0.
The reserved name "." indicates the working directory parent. If no
working directory is checked out, it is equivalent to null. If an
uncommitted merge is in progress, "." is the revision of the first
parent.