[pycopia] r531 committed - Minor documentation update.

0 views
Skip to first unread message

pyc...@googlecode.com

unread,
Feb 8, 2012, 9:29:09 PM2/8/12
to pyc...@googlegroups.com
Revision: 531
Author: keith.dart
Date: Wed Feb 8 18:28:42 2012
Log: Minor documentation update.

http://code.google.com/p/pycopia/source/detail?r=531

Modified:
/trunk/CLI/pycopia/CLI.py

=======================================
--- /trunk/CLI/pycopia/CLI.py Mon Jan 30 23:10:04 2012
+++ /trunk/CLI/pycopia/CLI.py Wed Feb 8 18:28:42 2012
@@ -568,11 +568,15 @@

def cycle(self, argv):
"""cycle <range> <command> [<arg>...]
- Cycle the % variable through range, and re-evaluate the command for
- each value.
+ Cycle the variable symbol % through the range, and re-evaluate the
command
+ for each value.
Range is of the form [start':']end[':' step]
- Where start defaults to zero and step defaults to one.
- Or, range is a list of values separated by ','."""
+ Where start defaults to zero and step defaults to one.
+ Or, range may be a list of values separated by ','.
+
+ Example:
+ > cycle 5 printf "This is {}" %
+ """
argv.pop(0) # eat name
rangetoken = argv.pop(0)
argv = self._expand_aliases(argv)
@@ -706,7 +710,7 @@
return ui

def _rst_out(name, docstr):
- return "\n{0}\n {1}\n\n".format(name, docstr)
+ return "\n{0}\n {1}\n".format(name, docstr)

# This is needed to reset PagedIO so background events don't cause the
pager to activate.
class _RepeatWrapper(object):

Reply all
Reply to author
Forward
0 new messages