Skip to content

Commit

Permalink
Filter out the preceeding empty lines of the doc-string when listing …
Browse files Browse the repository at this point in the history
…stuff
  • Loading branch information
chrisvest committed Mar 7, 2008
1 parent 7fa5394 commit b4065a0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion fabfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ def install(**kvargs):
local('sudo python setup.py install')

def layout(**kvargs):
"""Print a layout-overview of fabric.py to the console.
"""
Print a layout-overview of fabric.py to the console.
Optionally append an argument to the underlying grep call.
Expand Down
2 changes: 1 addition & 1 deletion fabric.py
Original file line number Diff line number Diff line change
Expand Up @@ -782,7 +782,7 @@ def _list_objs(objs):
for name, fn in cmds:
print ' ', name.ljust(max_name_len),
if fn.__doc__:
print ':', fn.__doc__.splitlines()[0]
print ':', filter(None, fn.__doc__.splitlines())[0].strip()
else:
print

Expand Down

0 comments on commit b4065a0

Please sign in to comment.