Show More
@@ -917,6 +917,9 b' def bookmark(ui, repo, *names, **opts):' | |||||
917 | diverged, a new 'divergent bookmark' of the form 'name@path' will |
|
917 | diverged, a new 'divergent bookmark' of the form 'name@path' will | |
918 | be created. Using :hg:`merge` will resolve the divergence. |
|
918 | be created. Using :hg:`merge` will resolve the divergence. | |
919 |
|
919 | |||
|
920 | Specifying bookmark as '.' to -m or -d options is equivalent to specifying | |||
|
921 | the active bookmark's name. | |||
|
922 | ||||
920 | A bookmark named '@' has the special property that :hg:`clone` will |
|
923 | A bookmark named '@' has the special property that :hg:`clone` will | |
921 | check it out by default if it exists. |
|
924 | check it out by default if it exists. | |
922 |
|
925 | |||
@@ -962,6 +965,7 b' def bookmark(ui, repo, *names, **opts):' | |||||
962 | if delete or rename or names or inactive: |
|
965 | if delete or rename or names or inactive: | |
963 | with repo.wlock(), repo.lock(), repo.transaction('bookmark') as tr: |
|
966 | with repo.wlock(), repo.lock(), repo.transaction('bookmark') as tr: | |
964 | if delete: |
|
967 | if delete: | |
|
968 | names = pycompat.maplist(repo._bookmarks.expandname, names) | |||
965 | bookmarks.delete(repo, tr, names) |
|
969 | bookmarks.delete(repo, tr, names) | |
966 | elif rename: |
|
970 | elif rename: | |
967 | if not names: |
|
971 | if not names: |
@@ -213,6 +213,26 b' rename bookmark using . with no active b' | |||||
213 | $ hg up -q Y |
|
213 | $ hg up -q Y | |
214 | $ hg book -d rename-me |
|
214 | $ hg book -d rename-me | |
215 |
|
215 | |||
|
216 | delete bookmark using . | |||
|
217 | ||||
|
218 | $ hg book delete-me | |||
|
219 | $ hg book -d . | |||
|
220 | $ hg bookmark | |||
|
221 | X2 1:925d80f479bb | |||
|
222 | Y 2:db815d6d32e6 | |||
|
223 | Z 0:f7b1eb17ad24 | |||
|
224 | $ hg up -q Y | |||
|
225 | ||||
|
226 | delete bookmark using . with no active bookmark | |||
|
227 | ||||
|
228 | $ hg book delete-me | |||
|
229 | $ hg book -i delete-me | |||
|
230 | $ hg book -d . | |||
|
231 | abort: no active bookmark | |||
|
232 | [255] | |||
|
233 | $ hg up -q Y | |||
|
234 | $ hg book -d delete-me | |||
|
235 | ||||
216 | list bookmarks |
|
236 | list bookmarks | |
217 |
|
237 | |||
218 | $ hg bookmark |
|
238 | $ hg bookmark |
General Comments 0
You need to be logged in to leave comments.
Login now