absorb

Description

The absorb extension provides a command to use annotate information to amend modified chunks into the corresponding non-public changesets.

[absorb]
# only check 50 recent non-public changesets at most
max-stack-size = 50
# whether to add noise to new commits to avoid obsolescence cycle
add-noise = 1
# make `amend --correlated` a shortcut to the main command
amend-flag = correlated

[color]
absorb.description = yellow
absorb.node = blue bold
absorb.path = bold

Commands

absorb

incorporate corrections into the stack of draft changesets:

hg absorb [OPTION] [FILE]...

absorb analyzes each change in your working directory and attempts to amend the changed lines into the changesets in your stack that first introduced those lines.

If absorb cannot find an unambiguous changeset to amend for a change, that change will be left in the working directory, untouched. They can be observed by hg status or hg diff afterwards. In other words, absorb does not write to the working directory.

Changesets outside the revset ::. and not public() and not merge() will not be changed.

Changesets that become empty after applying the changes will be deleted.

By default, absorb will show what it plans to do and prompt for confirmation. If you are confident that the changes will be absorbed to the correct place, run hg absorb -a to apply the changes immediately.

Returns 0 on success, 1 if all chunks were ignored and nothing amended.

Options:

-a, --apply-changes
 apply changes without prompting for confirmation
-p, --print-changes
 always print which changesets are modified by which changes
-i, --interactive
 interactively select which chunks to apply (EXPERIMENTAL)
-e, --edit-lines
 edit what lines belong to which changesets before commit (EXPERIMENTAL)
-n, --dry-run do not perform actions, just print output
--style <STYLE>
 display using template map file (DEPRECATED)
-T, --template <TEMPLATE>
 display with template
-I, --include <PATTERN[+]>
 include names matching the given patterns
-X, --exclude <PATTERN[+]>
 exclude names matching the given patterns

[+] marked option can be specified multiple times