commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] r11087 - in gnuradio/trunk/grc: . src/platforms/python


From: jblum
Subject: [Commit-gnuradio] r11087 - in gnuradio/trunk/grc: . src/platforms/python/utils
Date: Fri, 22 May 2009 15:16:38 -0600 (MDT)

Author: jblum
Date: 2009-05-22 15:16:37 -0600 (Fri, 22 May 2009)
New Revision: 11087

Modified:
   gnuradio/trunk/grc/src/platforms/python/utils/extract_docs.py
   gnuradio/trunk/grc/todo.txt
Log:
Quick fix for ubuntu docs dir.



Modified: gnuradio/trunk/grc/src/platforms/python/utils/extract_docs.py
===================================================================
--- gnuradio/trunk/grc/src/platforms/python/utils/extract_docs.py       
2009-05-22 21:02:16 UTC (rev 11086)
+++ gnuradio/trunk/grc/src/platforms/python/utils/extract_docs.py       
2009-05-22 21:16:37 UTC (rev 11087)
@@ -77,15 +77,17 @@
        @param key the block key
        @return a string with documentation
        """
-       #get potential xml file matches for the key
-       if os.path.exists(DOCS_DIR) and os.path.isdir(DOCS_DIR):
-               matches = filter(lambda f: is_match(key, f), 
os.listdir(DOCS_DIR))
-       else: matches = list()
+       UBUNTU_DOCS_DIR = '/usr/share/doc/gnuradio-doc/xml'
+       if os.path.exists(DOCS_DIR): docs_dir = DOCS_DIR
+       elif os.path.exists(UBUNTU_DOCS_DIR): docs_dir = UBUNTU_DOCS_DIR
+       else: return ''
+       #extract matches
+       matches = filter(lambda f: is_match(key, f), os.listdir(docs_dir))
        #combine all matches
        doc_strs = list()
        for match in matches:
                try:
-                       xml_file = DOCS_DIR + '/' + match
+                       xml_file = os.path.join(docs_dir, match)
                        xml = etree.parse(xml_file)
                        #extract descriptions
                        comp_name = 
extract_txt(xml.xpath(DOXYGEN_NAME_XPATH)[0]).strip('\n')

Modified: gnuradio/trunk/grc/todo.txt
===================================================================
--- gnuradio/trunk/grc/todo.txt 2009-05-22 21:02:16 UTC (rev 11086)
+++ gnuradio/trunk/grc/todo.txt 2009-05-22 21:16:37 UTC (rev 11087)
@@ -25,3 +25,4 @@
 -save/restore cwd
 -threads dont die on exit in probe and variable sink
 -overloaded gui classes for each platform, move param input objects into 
overloaded
+-update extract_docs.py for current doxygen setup





reply via email to

[Prev in Thread] Current Thread [Next in Thread]