HG(COPY)
π HG(COPY) π
okay bestie, welcome to the hg copy manual page β the one and only, straight from the HG(COPY) pages, no gatekeeping here π«Ά
β¨ NAME β¨
hg copy β mark files as copied for the next commit π
πΈ SYNOPSIS πΈ
hg copy [OPTION]... (SOURCE... DEST | --forget DEST...)
π¦ DESCRIPTION π¦
So basically: this marks dest as having copies of source files. Simple as that π
If dest is a directory, the copies get dropped into that directory. If dest is a file, then source has to be a single file β no bundling, one source only, that's the vibe check and it's non-negotiable.
By default this command literally copies the contents of files exactly as they exist in the working directory. Like, actual copying, for real for real. But if you run it with -A/--after, the operation just gets recorded β no copying is performed. Zero file movement, just the receipt π§Ύ
Wanna undo marking a destination file as copied? That's what --forget is for. With that option, all the given (positional) arguments get unmarked as copies. The destination file(s) will be left in place (still tracked), so nothing disappears on you π Also note: hg copy --forget behaves the same way as hg rename --forget. Same energy, different command name.
This command takes effect with the next commit by default. So don't panic if nothing looks different yet β it's all queued up, main character energy, waiting for its moment β
Returns 0 on success, 1 if errors are encountered. That's it. That's the whole mood.
π OPTIONS π
--forgetβ unmark a destination file as copied, bestie. Undoing, but make it official.-A,--afterβ record a copy that has already occurred. You did the thing, now you're just logging it π--at-rev <REV>β (un)mark copies in the given revision. EXPERIMENTAL, so treat it like a limited-edition drop π-f,--forceβ forcibly copy over an existing managed file. She's pushy but she gets results π₯-I,--include <PATTERN[+]>β include names matching the given patterns β¨-X,--exclude <PATTERN[+]>β exclude names matching the given patterns π«-n,--dry-runβ do not perform actions, just print output. All vibes, no consequences, the dream π
[+] marked option can be specified multiple times β stack 'em, bestie, go off π
π ALIASES π
cp
ok so that's the whole page, no crumbs left behind π this was the HG(COPY) manual β and yep, that's the same HG(COPY) name sitting at the bottom of the original too, so consider this your little sign-off, mwah πβ¨
π¦ where this page comes from
- arch rolling: mercurial 7.2.4-1 Β· GPL
- fedora 43: mercurial 7.1.1-1.fc43 Β· GPL-2.0-or-later
- fedora 43: mercurial 7.1.1-2.fc43 Β· GPL-2.0-or-later
- fedora 44: mercurial 7.2-1.fc44 Β· GPL-2.0-or-later
- fedora 44: mercurial 7.2.4-1.fc44 Β· GPL-2.0-or-later
- nixos 26.05: mercurial 7.1.2
- nixos 26.05: mercurial-full 7.1.2
- nixpkgs unstable: mercurial 7.2.2
- nixpkgs unstable: mercurial-full 7.2.2
- opensuse-leap 16.0: mercurial 7.0.1-160000.2.2 Β· GPL-2.0-or-later
- opensuse-leap 16.0: mercurial 7.0.1-160000.2.2 Β· GPL-2.0-or-later
- opensuse-leap 16.0: mercurial 7.0.1-160000.2.2 Β· GPL-2.0-or-later
- opensuse-leap 16.0: mercurial 7.0.1-160000.2.2 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms