Changeset 13984 in genesis for tools


Ignore:
Timestamp:
Sep 22, 2017, 6:05:41 PM (7 years ago)
Author:
www
Message:

Add version number of repository, to detect whether an update is usefull at all.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tools/gformat.py

    r13940 r13984  
    3333
    3434SVN = filter(os.path.isfile, ('/usr/local/bin/svn', '/usr/bin/svn'))[0]
     35SVNVERSION = filter(os.path.isfile, ('/usr/local/bin/svnversion', '/usr/bin/svnversion'))[0]
    3536
    3637import argparse
     
    372373def generate_title(nodelist):
    373374  """ Main overview page """
    374   items = {'root' : "." }
     375  items = { \
     376        'root'      :   ".",
     377        'version'   :   subprocess.Popen([SVNVERSION, "%s/.." % NODE_DIR], stderr=subprocess.STDOUT, stdout=subprocess.PIPE).communicate()[0]
     378        }
    375379  def fl(spaces, line):
    376380    return (' ' * spaces) + line + '\n'
     
    394398    </form>
    395399    <table>
    396       <caption><h3>Wireless Leiden Configurator</h3></caption>
     400      <caption><h3>Wireless Leiden Configurator  - Revision %(version)s</h3></caption>
    397401  """ % items
    398402
Note: See TracChangeset for help on using the changeset viewer.