questions as a diff
timeless
timeless at gmail.com
Sun Mar 1 08:42:14 CST 2009
Unlike most diffs, this diff is not meant to be committed. It's a
series of questions I formulated which djc wasn't able to answer
before he pushed my changes.
could people please comment about the items tagged w/ XXX?
diff --git a/hgext/patchbomb.py b/hgext/patchbomb.py
--- a/hgext/patchbomb.py
+++ b/hgext/patchbomb.py
@@ -195,20 +195,28 @@ def patchbomb(ui, repo, *revs, **opts):
hg email -r 3000 # send patch 3000 only
hg email -r 3000 -r 3001 # send patches 3000 and 3001
hg email -r 3000:3005 # send patches 3000 through 3005
hg email 3000 # send patch 3000 (deprecated)
hg email -o # send all patches not in default
hg email -o DEST # send all patches not in DEST
hg email -o -r 3000 # send all ancestors of 3000 not in default
hg email -o -r 3000 DEST # send all ancestors of 3000 not in DEST
+XXX i'm told this is supposed to match hg help push -r
+-r --rev a specific revision up to which you would like to push
+ If -r is used, the named changeset and all its ancestors will
+ to the remote repository.
+However, the text doesn't, isn't consistent, etc., if it means the same thing,
+please be kind to your localizers and make it say precisely the same thing as
+best as possible, and if you have trouble spell it out "this matches the
+behavior of ...".
hg email -b # send bundle of all patches not in default
hg email -b DEST # send bundle of all patches not in DEST
hg email -b -r 3000 # bundle of all ancestors of 3000 not in default
hg email -b -r 3000 DEST # bundle of all ancestors of 3000 not in DEST
Before using this command, you will need to enable email in your hgrc.
See the [email] section in hgrc(5) for details.
'''
diff --git a/mercurial/help.py b/mercurial/help.py
--- a/mercurial/help.py
+++ b/mercurial/help.py
@@ -49,20 +49,21 @@ helptable = (
(["patterns"], _("File Name Patterns"),
_(r'''
Mercurial accepts several notations for identifying one or more
files at a time.
By default, Mercurial treats filenames as shell-style extended
glob patterns.
Alternate pattern notations must be specified explicitly.
+XXX should be in a paragraph, and probably reworded to sound more
like a sentence.
To use a plain path name without any pattern matching, start it
with "path:". These path names must completely match starting at
the current repository root.
To use an extended glob, start a name with "glob:". Globs are
rooted at the current directory; a glob such as "*.c" will only
match files in the current directory ending with ".c".
The supported glob syntax extensions are "**" to match any string
@@ -101,39 +102,45 @@ HG::
exutable's name if it's frozen, or an executable named 'hg'
(with %PATHEXT% [defaulting to COM/EXE/BAT/CMD] extensions on
Windows) is searched.
HGEDITOR::
This is the name of the editor to run when committing. See EDITOR.
(deprecated, use .hgrc)
HGENCODING::
- This overrides the default locale setting detected by Mercurial.
+ This supercedes the encoding derived from the locale setting
+ detected by Mercurial.
+XXX the original text pretended ENCODING and LOCALE were equivalent.
+I'm assuming that LOCALE includes translation (and as such was a superset)
+If I'm wrong. Fix the message some other way or explain what it actually
+meant and I'll figure out something else.
This setting is used to convert data including usernames,
changeset descriptions, tag names, and branches. This setting can
be overridden with the --encoding command-line option.
HGENCODINGMODE::
This sets Mercurial's behavior for handling unknown characters
while transcoding user input. The default is "strict", which
causes Mercurial to abort if it can't map a character. Other
settings include "replace", which replaces unknown characters, and
"ignore", which drops them. This setting can be overridden with
the --encodingmode command-line option.
HGMERGE::
An executable to use for resolving merge conflicts. The program
will be executed with three arguments: local file, remote file,
ancestor file.
(deprecated, use .hgrc)
+XXX isn't there a command line option for this?
HGRCPATH::
A list of files or directories to search for hgrc files. Item
separator is ":" on Unix, ";" on Windows. If HGRCPATH is not set,
platform default search path is used. If empty, only the .hg/hgrc
from the current repository is read.
For each element in HGRCPATH:
* if it's a directory, all directories ending with .rc are added
* otherwise, the directory itself will be added
@@ -277,32 +284,35 @@ PYTHONPATH::
$ hg log -r1 --template "{node}\n"
b56ce7b07c52de7d5fd79fb89701ea538af65746
Strings in curly braces are called keywords. The availability of
keywords depends on the exact context of the templater. These keywords
are usually available for templating a log-like command:
- author: String. The unmodified author of the changeset.
- branches: String. The name of the branch on which the changeset
was committed. Will be empty if the branch name was default.
+XXX what if there's more than one?
+XXX if not, isn't this horribly misnamed? if so, the help should note that
- date: Date information. The date when the changeset was committed.
- desc: String. The text of the changeset description.
- files: List of strings. All files modified, added, or removed by
this changeset.
- file_adds: List of strings. Files added by this changeset.
- file_mods: List of strings. Files modified by this changeset.
- file_dels: List of strings. Files removed by this changeset.
- node: String. The changeset identification hash, as a 40-character
hexadecimal string.
- parents: List of strings. The parents of the changeset.
- rev: Integer. The repository-local changeset revision number.
- - tags: List of strings. Any tags associated with the changeset.
+ - tags: List of strings. All tags associated with the changeset.
+XXX in general, only some of these explain what happens for
empty/default cases.
The "date" keyword does not produce human-readable output. If you
want to use a date in your output, you can use a filter to process it.
Filters are functions which return a string based on the input variable.
You can also use a chain of filters to get the desired output:
$ hg tip --template "{date|isodate}\n"
2008-08-21 18:22 +0000
List of filters:
@@ -319,71 +329,79 @@ PYTHONPATH::
the timezone: "Mon Sep 04 15:13:13 2006 0700".
- domain: Any text. Finds the first string that looks like an email
address, and extracts just the domain component.
Example: 'User <user at example.com>' becomes 'example.com'.
- email: Any text. Extracts the first string that looks like an email
address. Example: 'User <user at example.com>' becomes
'user at example.com'.
- escape: Any text. Replaces the special XML/XHTML characters "&",
"<" and ">" with XML entities.
- fill68: Any text. Wraps the text to fit in 68 columns.
+XXX what does it do if there are 70 -'s in a row?
+how does it choose where to wrap? surprise me?
- fill76: Any text. Wraps the text to fit in 76 columns.
+XXX 80?
- firstline: Any text. Returns the first line of text.
+XXX is this operating on lists or lines, or lists with entries w/ multilines?
- hgdate: Date. Returns the date as a pair of numbers:
"1157407993 25200" (Unix timestamp, timezone offset).
- isodate: Date. Returns the date in ISO 8601 format.
- obfuscate: Any text. Returns the input text rendered as a sequence
of XML entities.
- person: Any text. Returns the text before an email address.
+XXX example
- rfc822date: Date. Returns a date using the same format used
in email headers.
- short: Changeset hash. Returns the short form of a changeset hash,
i.e. a 12-byte hexadecimal string.
- shortdate: Date. Returns a date like "2006-09-18".
- strip: Any text. Strips all leading and trailing whitespace.
- tabindent: Any text. Returns the text, with every line except the
first starting with a tab character.
- urlescape: Any text. Escapes all "special" characters. For example,
"foo bar" becomes "foo%20bar".
- user: Any text. Returns the user portion of an email address.
''')),
(['urls'], _('Url Paths'),
_(r'''
Valid URLs are of the form:
local/filesystem/path (or file://local/filesystem/path)
+XXX local=localhost? (there's a lot of confusion about how to
properly write file://localhost/path/)
http://[user[:pass]@]host[:port]/[path]
https://[user[:pass]@]host[:port]/[path]
ssh://[user[:pass]@]host[:port]/[path]
Paths in the local filesystem can either point to Mercurial
repositories or to bundle files (as created by 'hg bundle' or
'hg incoming --bundle').
+XXX paths outside the local file system can't point to bundles?
An optional identifier after # indicates a particular branch, tag,
or changeset to use from the remote repository.
Some features, such as pushing to http:// and https:// URLs are
only possible if the feature is explicitly enabled on the
remote Mercurial server.
Some notes about using SSH with Mercurial:
- SSH requires an accessible shell account on the destination machine
and a copy of hg in the remote path or specified with as remotecmd.
- path is relative to the remote user's home directory by default.
Use an extra slash at the start of a path to specify an absolute path:
ssh://example.com//tmp/repository
- Mercurial doesn't use its own compression via SSH; the right thing
to do is to configure it in your ~/.ssh/config, e.g.:
Host *.mylocalnetwork.example.com
Compression no
+XXX why are you turning off local compression here w/o explanation?
Host *
Compression yes
Alternatively specify "ssh -C" as your ssh command in your hgrc or
with the --ssh command line option.
These urls can all be stored in your hgrc with path aliases under the
[paths] section like so:
[paths]
alias1 = URL1
alias2 = URL2
More information about the Mercurial-devel
mailing list