Show More
@@ -146,16 +146,6 b' heads::' | |||||
146 | changesets. They are where development generally takes place and |
|
146 | changesets. They are where development generally takes place and | |
147 | are the usual targets for update and merge operations. |
|
147 | are the usual targets for update and merge operations. | |
148 |
|
148 | |||
149 | history:: |
|
|||
150 | Print a log of the revision history of the repository. |
|
|||
151 |
|
||||
152 | By default this command outputs: changeset id and hash, tags, |
|
|||
153 | parents, user, date and time, and a summary for each commit. The |
|
|||
154 | -v switch adds some more detail, such as changed files, manifest |
|
|||
155 | hashes or message signatures. |
|
|||
156 |
|
||||
157 | To display the history of a given file, see the log command. |
|
|||
158 |
|
||||
159 | identify:: |
|
149 | identify:: | |
160 | Print a short summary of the current state of the repo. |
|
150 | Print a short summary of the current state of the repo. | |
161 |
|
151 | |||
@@ -178,11 +168,15 b' import [-p <n> -b <base> -q] <patches>::' | |||||
178 | init:: |
|
168 | init:: | |
179 | Initialize a new repository in the current directory. |
|
169 | Initialize a new repository in the current directory. | |
180 |
|
170 | |||
181 |
log |
|
171 | log [file]:: | |
182 | Print the revision history of the specified file. |
|
172 | Print the revision history of the specified file or the entire project. | |
183 |
|
173 | |||
184 | To display the revision history for the whole repository, use the history |
|
174 | By default this command outputs: changeset id and hash, tags, | |
185 | command. |
|
175 | parents, user, date and time, and a summary for each commit. The | |
|
176 | -v switch adds some more detail, such as changed files, manifest | |||
|
177 | hashes or message signatures. | |||
|
178 | ||||
|
179 | aliases: history | |||
186 |
|
180 | |||
187 | manifest [revision]:: |
|
181 | manifest [revision]:: | |
188 | Print a list of version controlled files for the given revision. |
|
182 | Print a list of version controlled files for the given revision. |
@@ -434,11 +434,6 b' def heads(ui, repo):' | |||||
434 | for n in repo.changelog.heads(): |
|
434 | for n in repo.changelog.heads(): | |
435 | show_changeset(ui, repo, changenode=n) |
|
435 | show_changeset(ui, repo, changenode=n) | |
436 |
|
436 | |||
437 | def history(ui, repo): |
|
|||
438 | """show the changelog history""" |
|
|||
439 | for i in range(repo.changelog.count() - 1, -1, -1): |
|
|||
440 | show_changeset(ui, repo, rev=i) |
|
|||
441 |
|
||||
442 | def identify(ui, repo): |
|
437 | def identify(ui, repo): | |
443 | """print information about the working copy""" |
|
438 | """print information about the working copy""" | |
444 | parents = [p for p in repo.dirstate.parents() if p != hg.nullid] |
|
439 | parents = [p for p in repo.dirstate.parents() if p != hg.nullid] | |
@@ -511,13 +506,16 b' def init(ui, source=None):' | |||||
511 | sys.exit(1) |
|
506 | sys.exit(1) | |
512 | repo = hg.repository(ui, ".", create=1) |
|
507 | repo = hg.repository(ui, ".", create=1) | |
513 |
|
508 | |||
514 | def log(ui, repo, f): |
|
509 | def log(ui, repo, f = None): | |
515 | """show the revision history of a single file""" |
|
510 | """show the revision history of the repository or a single file""" | |
|
511 | if f: | |||
516 | f = relpath(repo, [f])[0] |
|
512 | f = relpath(repo, [f])[0] | |
517 |
|
||||
518 | r = repo.file(f) |
|
513 | r = repo.file(f) | |
519 | for i in range(r.count() - 1, -1, -1): |
|
514 | for i in range(r.count() - 1, -1, -1): | |
520 | show_changeset(ui, repo, filelog=r, rev=i) |
|
515 | show_changeset(ui, repo, filelog=r, rev=i) | |
|
516 | else: | |||
|
517 | for i in range(repo.changelog.count() - 1, -1, -1): | |||
|
518 | show_changeset(ui, repo, rev=i) | |||
521 |
|
519 | |||
522 | def manifest(ui, repo, rev = []): |
|
520 | def manifest(ui, repo, rev = []): | |
523 | """output the latest or given revision of the project manifest""" |
|
521 | """output the latest or given revision of the project manifest""" | |
@@ -745,7 +743,6 b' table = {' | |||||
745 | "export": (export, [], "hg export <changeset>"), |
|
743 | "export": (export, [], "hg export <changeset>"), | |
746 | "forget": (forget, [], "hg forget [files]"), |
|
744 | "forget": (forget, [], "hg forget [files]"), | |
747 | "heads": (heads, [], 'hg heads'), |
|
745 | "heads": (heads, [], 'hg heads'), | |
748 | "history": (history, [], 'hg history'), |
|
|||
749 | "help": (help, [], 'hg help [command]'), |
|
746 | "help": (help, [], 'hg help [command]'), | |
750 | "identify|id": (identify, [], 'hg identify'), |
|
747 | "identify|id": (identify, [], 'hg identify'), | |
751 | "import|patch": (import_, |
|
748 | "import|patch": (import_, | |
@@ -753,7 +750,7 b' table = {' | |||||
753 | ('b', 'base', "", 'base path')], |
|
750 | ('b', 'base', "", 'base path')], | |
754 | "hg import [options] <patches>"), |
|
751 | "hg import [options] <patches>"), | |
755 | "init": (init, [], 'hg init'), |
|
752 | "init": (init, [], 'hg init'), | |
756 |
"log": (log, [], 'hg log |
|
753 | "log|history": (log, [], 'hg log [file]'), | |
757 | "manifest": (manifest, [], 'hg manifest [rev]'), |
|
754 | "manifest": (manifest, [], 'hg manifest [rev]'), | |
758 | "parents": (parents, [], 'hg parents [node]'), |
|
755 | "parents": (parents, [], 'hg parents [node]'), | |
759 | "pull": (pull, |
|
756 | "pull": (pull, |
@@ -13,11 +13,10 b' hg commands:' | |||||
13 | forget don't add the specified files on the next commit |
|
13 | forget don't add the specified files on the next commit | |
14 | heads show current repository heads |
|
14 | heads show current repository heads | |
15 | help show help for a given command or all commands |
|
15 | help show help for a given command or all commands | |
16 | history show the changelog history |
|
|||
17 | identify print information about the working copy |
|
16 | identify print information about the working copy | |
18 | import import an ordered set of patches |
|
17 | import import an ordered set of patches | |
19 | init create a new repository in the current directory |
|
18 | init create a new repository in the current directory | |
20 | log show the revision history of a single file |
|
19 | log show the revision history of the repository or a single file | |
21 | manifest output the latest or given revision of the project manifest |
|
20 | manifest output the latest or given revision of the project manifest | |
22 | parents show the parents of the current working dir |
|
21 | parents show the parents of the current working dir | |
23 | pull pull changes from the specified source |
|
22 | pull pull changes from the specified source | |
@@ -65,11 +64,10 b' hg commands:' | |||||
65 | forget don't add the specified files on the next commit |
|
64 | forget don't add the specified files on the next commit | |
66 | heads show current repository heads |
|
65 | heads show current repository heads | |
67 | help show help for a given command or all commands |
|
66 | help show help for a given command or all commands | |
68 | history show the changelog history |
|
|||
69 | identify print information about the working copy |
|
67 | identify print information about the working copy | |
70 | import import an ordered set of patches |
|
68 | import import an ordered set of patches | |
71 | init create a new repository in the current directory |
|
69 | init create a new repository in the current directory | |
72 | log show the revision history of a single file |
|
70 | log show the revision history of the repository or a single file | |
73 | manifest output the latest or given revision of the project manifest |
|
71 | manifest output the latest or given revision of the project manifest | |
74 | parents show the parents of the current working dir |
|
72 | parents show the parents of the current working dir | |
75 | pull pull changes from the specified source |
|
73 | pull pull changes from the specified source |
General Comments 0
You need to be logged in to leave comments.
Login now