comparison mercurial/commands.py @ 27390:8bc6ece9a2e1

import: reorder help text Try to place key concepts early+together.
author timeless <timeless@mozdev.org>
date Tue, 15 Dec 2015 07:57:04 +0000
parents 7edd78690c57
children 32bea9daa877
comparison
equal deleted inserted replaced
27389:7edd78690c57 27390:8bc6ece9a2e1
4572 """import an ordered set of patches 4572 """import an ordered set of patches
4573 4573
4574 Import a list of patches and commit them individually (unless 4574 Import a list of patches and commit them individually (unless
4575 --no-commit is specified). 4575 --no-commit is specified).
4576 4576
4577 Because import first applies changes to the working directory, 4577 To read a patch from standard input, use "-" as the patch name. If
4578 import will abort if there are outstanding changes. 4578 a URL is specified, the patch will be downloaded from there.
4579
4580 Import first applies changes to the working directory (unless
4581 --bypass is specified), import will abort if there are outstanding
4582 changes.
4583
4584 Use --bypass to apply and commit patches directly to the
4585 repository, without affecting the working directory. Without
4586 --exact, patches will be applied on top of the working directory
4587 parent revision.
4579 4588
4580 You can import a patch straight from a mail message. Even patches 4589 You can import a patch straight from a mail message. Even patches
4581 as attachments work (to use the body part, it must have type 4590 as attachments work (to use the body part, it must have type
4582 text/plain or text/x-patch). From and Subject headers of email 4591 text/plain or text/x-patch). From and Subject headers of email
4583 message are used as default committer and commit message. All 4592 message are used as default committer and commit message. All
4592 If --exact is specified, import will set the working directory to 4601 If --exact is specified, import will set the working directory to
4593 the parent of each patch before applying it, and will abort if the 4602 the parent of each patch before applying it, and will abort if the
4594 resulting changeset has a different ID than the one recorded in 4603 resulting changeset has a different ID than the one recorded in
4595 the patch. This may happen due to character set problems or other 4604 the patch. This may happen due to character set problems or other
4596 deficiencies in the text patch format. 4605 deficiencies in the text patch format.
4597
4598 Use --bypass to apply and commit patches directly to the
4599 repository, not touching the working directory. Without --exact,
4600 patches will be applied on top of the working directory parent
4601 revision.
4602
4603 With -s/--similarity, hg will attempt to discover renames and
4604 copies in the patch in the same way as :hg:`addremove`.
4605 4606
4606 Use --partial to ensure a changeset will be created from the patch 4607 Use --partial to ensure a changeset will be created from the patch
4607 even if some hunks fail to apply. Hunks that fail to apply will be 4608 even if some hunks fail to apply. Hunks that fail to apply will be
4608 written to a <target-file>.rej file. Conflicts can then be resolved 4609 written to a <target-file>.rej file. Conflicts can then be resolved
4609 by hand before :hg:`commit --amend` is run to update the created 4610 by hand before :hg:`commit --amend` is run to update the created
4611 partially apply without losing the associated metadata (author, 4612 partially apply without losing the associated metadata (author,
4612 date, description, ...). Note that when none of the hunk applies 4613 date, description, ...). Note that when none of the hunk applies
4613 cleanly, :hg:`import --partial` will create an empty changeset, 4614 cleanly, :hg:`import --partial` will create an empty changeset,
4614 importing only the patch metadata. 4615 importing only the patch metadata.
4615 4616
4617 With -s/--similarity, hg will attempt to discover renames and
4618 copies in the patch in the same way as :hg:`addremove`.
4619
4616 It is possible to use external patch programs to perform the patch 4620 It is possible to use external patch programs to perform the patch
4617 by setting the ``ui.patch`` configuration option. For the default 4621 by setting the ``ui.patch`` configuration option. For the default
4618 internal tool, the fuzz can also be configured via ``patch.fuzz``. 4622 internal tool, the fuzz can also be configured via ``patch.fuzz``.
4619 See :hg:`help config` for more information about configuration 4623 See :hg:`help config` for more information about configuration
4620 files and how to use these options. 4624 files and how to use these options.
4621 4625
4622 To read a patch from standard input, use "-" as the patch name. If
4623 a URL is specified, the patch will be downloaded from it.
4624 See :hg:`help dates` for a list of formats valid for -d/--date. 4626 See :hg:`help dates` for a list of formats valid for -d/--date.
4625 4627
4626 .. container:: verbose 4628 .. container:: verbose
4627 4629
4628 Examples: 4630 Examples: