[GRASS-SVN] r64313 - grass-addons/tools/addons

svn_grass at osgeo.org svn_grass at osgeo.org
Sun Jan 25 05:05:15 PST 2015


Author: neteler
Date: 2015-01-25 05:05:15 -0800 (Sun, 25 Jan 2015)
New Revision: 64313

Modified:
   grass-addons/tools/addons/grass-addons-index.sh
Log:
Addons manuals overview: fix one line description

Modified: grass-addons/tools/addons/grass-addons-index.sh
===================================================================
--- grass-addons/tools/addons/grass-addons-index.sh	2015-01-25 12:12:07 UTC (rev 64312)
+++ grass-addons/tools/addons/grass-addons-index.sh	2015-01-25 13:05:15 UTC (rev 64313)
@@ -51,23 +51,19 @@
 <p>
 <hr> <ul>" > index.html
 
-    ls -1 *.html | sed 's+^+<li style="margin-left: 20px"><a href=+g' | sed 's+$+>+g' > /tmp/a.$TMP
+    ls -1 *.html | grep -v index.html | sed 's+^+<li style="margin-left: 20px"><a href=+g' | sed 's+$+>+g' > /tmp/a.$TMP
 
-    ls -1 *.html | sed 's+\.html$+</a>: +g' > /tmp/b.$TMP
+    ls -1 *.html | grep -v index.html | sed 's+\.html$+</a>: +g' > /tmp/b.$TMP
 
-# get one-line perhaps like this:
-## ls -1 *.html | awk '/NAME/,/KEYWORDS/' | grep ' - ' | cut -d'-' -f2-
-
 # size
 # ls -sh *.html | sed 's/^\ //g' | grep -v total | cut -d' ' -f1 | sed 's/$/\<br\>/g'> /tmp/c.$TMP
 # paste -d' ' /tmp/a.$TMP /tmp/b.$TMP /tmp/c.$TMP >> index.html
     
-    awk '/NAME/,/KEYWORDS/'  *.html | grep ' - ' | cut -d'-' -f2- | cut -d'<' -f1  > /tmp/c.$TMP
+    # get one-line description:
+    awk '/NAME/,/KEYWORDS/'  *.html | grep ' - ' | cut -d'-' -f2- | cut -d'.' -f1 | cut -d'<' -f1 | sed 's+>$+></li>+g'  > /tmp/c.$TMP
 
-    ls -1 *.html | sed 's+>$+></li>+g' > /tmp/d.$TMP
+    paste -d' ' /tmp/a.$TMP /tmp/b.$TMP /tmp/c.$TMP >> index.html
 
-    paste -d' ' /tmp/a.$TMP /tmp/b.$TMP /tmp/c.$TMP /tmp/d.$TMP >> index.html
-
     echo "</ul>" >> index.html
 
     echo "<hr>



More information about the grass-commit mailing list