summaryrefslogtreecommitdiff
path: root/scripts/mkHelpSkeleton
Side-by-side diff
Diffstat (limited to 'scripts/mkHelpSkeleton') (more/less context) (ignore whitespace changes)
-rwxr-xr-xscripts/mkHelpSkeleton10
1 files changed, 4 insertions, 6 deletions
diff --git a/scripts/mkHelpSkeleton b/scripts/mkHelpSkeleton
index ffb21c2..d7914fe 100755
--- a/scripts/mkHelpSkeleton
+++ b/scripts/mkHelpSkeleton
@@ -1,16 +1,16 @@
#!/usr/bin/env python
"""
This skript creates a help skeleton for a certain application
-(C) Michael 'Mickey' Lauer who did this even if he had a lot of other stuff to do...
+(C) Michael 'Mickey' Lauer who did this even if he had a lot of other stuff to do... THANKS
"""
import os
import sys
COUNTRYCODES = "da de en fr nl pl hu no pt it pt_BR ja sl zh_CN es ko zh_TW".split()
OPIEDIR = os.environ["OPIEDIR"]
#Package: opie-appskey-help-en
#Files: help/en/html/opie-appskey.html
#Priority: optional
#Section: opie/onlinedoc
@@ -40,46 +40,44 @@ def doit( name, cc ):
print "Generating help skeleton for application '%s'..." % application
helpdirname = "%s/help/%s/html" % ( OPIEDIR, cc )
helpappdirname = "%s/%s" % ( helpdirname, application )
makecontrol( helpdirname, application, cc, desktop )
makedir( helpappdirname )
makehtml( helpdirname, application, cc, desktop )
#------------------------------------------------------#
def makehtml( directory, application, cc, desktop ):
"""Creates the help template file."""
- helpfilename = "%s/opie-%s.html" % ( directory, application )
+ helpfilename = "%s/%s.html" % ( directory, application )
print "Creating help file '%s'" % helpfilename
h = file( helpfilename, "w" )
- print >> h, """
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html> <head> <title>%s</title> </head>
+ print >> h, """<html> <head> <title>%s</title> </head>
<body>
<center><h1>%s</h1></center>
<hr>
</body>
</html>
""" % ( application, application )
#------------------------------------------------------#
def makecontrol( directory, application, cc, desktop ):
"""Creates the .control file."""
controlfilename = "%s/opie-%s-help-%s.control" % ( directory, application, cc )
print "Creating control file '%s'" % controlfilename
c = file( controlfilename, "w" )
print >> c, "Package: opie-%s-help-%s" % ( application, cc )
- print >> c, "Files: help/%s/html/opie-%s.html help/%s/html/%s" % ( cc, application, cc, application )
+ print >> c, "Files: help/%s/html/%s.html help/%s/html/%s" % ( cc, application, cc, application )
print >> c, "Priority: optional"
print >> c, "Section: opie/onlinedoc"
print >> c, "Maintainer: %s" % desktop.get( "Maintainer", "Team Opie <opie@handhelds.org>" )
print >> c, "Version: $QPE_VERSION-$SUB_VERSION"
print >> c, "Depends: opie-%s" % application
print >> c, "License: GPL"
print >> c, "Description: %s help files (%s)" % ( application, cc )
#------------------------------------------------------#
def makedir( name ):
"""Creates a directory."""