Permalink
Browse files

refactored list_pages()

  • Loading branch information...
1 parent 02f34c5 commit bfa6129d29fcb36afe1dba48b8c7c22acfedfb0c @tj committed May 14, 2012
Showing with 7 additions and 1 deletion.
  1. +7 −1 bin/mad
View
@@ -18,7 +18,13 @@ list_pages() {
printf " \033[1mmad pages:\033[0m\n"
echo
for path in $paths; do
- test ! -z $path && test -d $path && find $path -type f -print0 | xargs -0 basename | grep -iv 'readme*' | grep '.md$' | perl -pe 's|^(.*)\.md$| \1|;'
+ test ! -z $path \
+ && test -d $path \
+ && find $path -type f -print0 \
+ | xargs -0 basename \
+ | grep -iv 'readme*' \
+ | grep '.md$' \
+ | perl -pe 's|^(.*)\.md$| \1|;'
done
echo
}

0 comments on commit bfa6129

Please sign in to comment.