From: Eric S. Raymond Date: Mon, 10 Nov 2014 23:16:43 +0000 (-0500) Subject: Added src version. X-Git-Tag: 0.5~33 X-Git-Url: http://thyrsus.com/gitweb/?a=commitdiff_plain;h=44f606fe829e624dc7ea6f684a87069741b22581;p=src.git Added src version. --- diff --git a/NEWS b/NEWS index 64190f4..6a0d455 100644 --- a/NEWS +++ b/NEWS @@ -1,6 +1,7 @@ ` src project news Repository head: + Added src version. 'U' (unmodified) becomes '.' in src status listings. 0.4: 2014-11-10 diff --git a/src b/src index 828116b..4f004da 100755 --- a/src +++ b/src @@ -296,6 +296,9 @@ src release ['file'...] have to interoperate with other tools that expect RCS masters to be in their normal (unlocked) stare. +src version + Report the version of src. + The omission of 'src remove' is a deliberate speed bump. """ @@ -859,6 +862,10 @@ def fast_import_method(*args): os.rename(fn, corresponding) shutil.rmtree("RCS") +def version_method(*args): + "Report SRC's version" + sys.stdout.write("%s\n" % version) + dispatch = { "help": help_method, "add": add_method, @@ -883,6 +890,7 @@ dispatch = { "fast-export": fast_export_method, "fast-import": fast_import_method, "release": release_method, + "version": version_method, } class RCS: diff --git a/src.asc b/src.asc index 1fab861..15462ee 100644 --- a/src.asc +++ b/src.asc @@ -121,6 +121,9 @@ src release ['file'...]:: have to interoperate with other tools that expect RCS masters to be in their normal (unlocked) stare. +src version:: + Report the version of src. + The omission of 'src remove' is a deliberate speed bump. If no files are specified, all eligible files are operated on in sequence.