From: Eric S. Raymond Date: Sun, 16 Nov 2014 18:36:01 +0000 (-0500) Subject: Documentation improvements. Regression test passes. X-Git-Tag: 0.9~2 X-Git-Url: http://thyrsus.com/gitweb/?a=commitdiff_plain;h=f6a7d781c67faaee631ecb733f9acd37e4cbd991;p=src.git Documentation improvements. Regression test passes. --- diff --git a/NEWS b/NEWS index 0038b2f..75bcb8d 100644 --- a/NEWS +++ b/NEWS @@ -16,7 +16,7 @@ Repository head: Bugfix release: fix initial file commit. There was a bug in my tests... 0.6: 2014-11-12 - Useful boilerplare in commit and amend message buffers. + Useful boilerplate in commit and amend message buffers. Tag names for revisions work; so does tag renaming. Branch-sensitive traversal with .. is working. Fixed yet another fast-export bug. diff --git a/src b/src index 9bccee5..4f95e96 100755 --- a/src +++ b/src @@ -373,12 +373,12 @@ src status [-a] ['file'...] Find more details under 'help status'. 'st' is a synonym fot status. src tag [list|-l|delete|del|-d] ['name'] ['revision'] ['file'...] - Create or delete a tag. With no or only file arguments, list tags. + List tags, create tags, or delete tags. Takes a singleton + revision, defaulting to the current branch tip. -src branch [list|-l|delete|del|-d] ['name'] ['revision'] ['file'...] - Create, switch to, or delete a branch. With no arguments, - list branches; the active branch is first in the list. The default - branch is 'trunk'. +src branch [list|-l|delete|del|-d] ['name'] ['file'...] + List, create, or delete branches. the active branch is first in + the list. The default branch is 'trunk'. src rename ['tag'|'branch'] ['oldname'] ['newname'] ['file'...] Rename a tag or branch. Refuses to step on an existing symbol or @@ -549,6 +549,28 @@ Takes a single revision number, tag, or branch name. The default if you give none is the tip revision of the current branch. This command is mainly intended for use in scripts. +""", + "tag" : """ +src tag [list|-l|delete|del|-d] ['name'] ['revision'] ['file'...] + +List tags (with -l), create tags, or delete tags (with -d). + +Takes at most a singleton revision; the default is the current branch tip. + +Tag creation and deletion require a following name argument. Tag +creation will not step on an existing tag name, and a noneitent branch +cannot be deleted. +""", + "branch" : """ +src branch [list|-l|delete|del|-d] ['name'] ['file'...] + +List branches (with -l), create branches, or delete branches (with -d). + +In the list produced by '-', the active branch is first in the list. + +Branch creation and deletion require a following name argument. Branch +creation will not step on an existing branch name, and a noneitent branch +cannot be deleted. """, "log" : """ src log ['revision-range'] ['file'...] @@ -1136,7 +1158,7 @@ def tag_helper(args, legend, validation_hook, delete_method, set_method): if not quiet and len(args) > 1: announce("in %s, %s %s removed" % (arg, legend, name)) return - if args[0] in ("-l", "list"): + elif args[0] in ("-l", "list"): args.pop(0) ctx = CommandContext(legend + " listing", args, require_empty=True) width = screenwidth() diff --git a/src.asc b/src.asc index bb1e864..20cb1ec 100644 --- a/src.asc +++ b/src.asc @@ -80,12 +80,12 @@ src status [-a] ['file'...]:: synonym for status. src tag [list|-l|delete|del|-d] ['name'] ['revision'] ['file'...]:: - Create or delete a tag. With no or only file arguments, list tags. + List tags, create tags, or delete tags. Takes a singleton + revision, defaulting to the current branch tip. -src branch [list|-l|delete|del|-d] ['name'] ['revision'] ['file'...]:: - Create, switch to, or delete a branch. With no arguments, - list branches; the active branch is first in the list. The default - branch is 'trunk'. +src branch [list|-l|delete|del|-d] ['name'] ['file'...]:: + List, create, or delete branches. the active branch is first in + the list. The default branch is 'trunk'. src rename ['tag'|'branch'] ['oldname'] ['newname'] ['file'...]:: Rename a tag or branch. Refuses to step on an existing symbol or