mirror of
https://github.com/moparisthebest/xeps
synced 2024-11-25 18:52:23 -05:00
Add fast build mode which basically just rebuilds the HTML list of XEPs.
git-svn-id: file:///home/ksmith/gitmigration/svn/xmpp/trunk@3556 4b5297f7-1745-476d-ba37-a9c6900126ab
This commit is contained in:
parent
a0d1a8f6d9
commit
d6aaa478b2
8
gen.py
8
gen.py
@ -46,6 +46,7 @@ XEPPATH = "/var/www/vhosts/xmpp.org/extensions"
|
|||||||
CONFIGPATH = "/var/local/xsf"
|
CONFIGPATH = "/var/local/xsf"
|
||||||
|
|
||||||
verbose = False
|
verbose = False
|
||||||
|
fast = False
|
||||||
last_build = {}
|
last_build = {}
|
||||||
|
|
||||||
def getText(nodelist):
|
def getText(nodelist):
|
||||||
@ -257,6 +258,7 @@ def buildPDF( file ):
|
|||||||
return True
|
return True
|
||||||
|
|
||||||
def buildXEP( filename ):
|
def buildXEP( filename ):
|
||||||
|
if not fast:
|
||||||
print "Building " + filename + ": ",
|
print "Building " + filename + ": ",
|
||||||
if buildXHTML( filename ):
|
if buildXHTML( filename ):
|
||||||
print "XHTML(OK) / ",
|
print "XHTML(OK) / ",
|
||||||
@ -288,14 +290,16 @@ def usage():
|
|||||||
print "Options:"
|
print "Options:"
|
||||||
print "-v Enable verbose output for debugging."
|
print "-v Enable verbose output for debugging."
|
||||||
print "-a Build all available XEPs."
|
print "-a Build all available XEPs."
|
||||||
|
print "-f Fast; means no actual compiling is done"
|
||||||
|
|
||||||
def main(argv):
|
def main(argv):
|
||||||
global verbose
|
global verbose
|
||||||
global CONFIGPATH
|
global CONFIGPATH
|
||||||
|
global fast
|
||||||
buildall = False
|
buildall = False
|
||||||
|
|
||||||
try:
|
try:
|
||||||
options, remainder = getopt.gnu_getopt(argv, "va")
|
options, remainder = getopt.gnu_getopt(argv, "vaf")
|
||||||
except getopt.GetoptError:
|
except getopt.GetoptError:
|
||||||
usage()
|
usage()
|
||||||
sys.exit(2)
|
sys.exit(2)
|
||||||
@ -305,6 +309,8 @@ def main(argv):
|
|||||||
verbose = True
|
verbose = True
|
||||||
elif opt in ('-a'):
|
elif opt in ('-a'):
|
||||||
buildall = True
|
buildall = True
|
||||||
|
elif opt in ('-f'):
|
||||||
|
fast = True
|
||||||
|
|
||||||
if len(remainder) > 0:
|
if len(remainder) > 0:
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in New Issue
Block a user