Added book-product.json

This commit is contained in:
Stian Thorgersen 2016-06-09 14:09:54 +02:00
parent 8e3fc3616b
commit 9b1a2da589
5 changed files with 39 additions and 18 deletions

View file

@ -1,10 +1,9 @@
{{book.title}}
===========================================
= Securing Applications and Services Guide
image:images/keycloak_logo.png[alt="Keycloak"]
*Keycloak* _Documentation_ for {{book.project.version}}
{{book.project.name}} {{book.project.version}}
http://www.keycloak.org

25
book-product.json Executable file
View file

@ -0,0 +1,25 @@
{
"gitbook": "2.x.x",
"structure": {
"readme": "README.adoc"
},
"plugins": [
"toggle-chapters",
"ungrey",
"splitter"
],
"variables": {
"title": "Securing Applications and Services Guide",
"project": {
"name": "Red Hat Single Sign-On",
"version": "7.0.0"
},
"community": false,
"product": true,
"images": "rhsso-images",
"adminguide": {
"name": "Server Administration Guide",
"link": "https://access.redhat.com/documentation/en/red-hat-single-sign-on/7.0.0/server-administration-guide/"
}
}
}

View file

@ -10,20 +10,16 @@
],
"variables": {
"title": "Securing Applications and Services Guide",
"community": true,
"product": false,
"images": "keycloak-images",
"appserver": {
"name": "Wildfly",
"version": "10"
},
"adminguide": {
"name": "Keycloak Administration Guide",
"link": "https://keycloak.gitbooks.io/server-adminstration-guide/content/"
},
"project": {
"name": "Keycloak",
"version": "1.9.7.Final"
},
"community": true,
"product": false,
"images": "keycloak-images",
"adminguide": {
"name": "Server Administration Guide",
"link": "https://keycloak.gitbooks.io/server-adminstration-guide/content/"
}
}
}

View file

@ -5,5 +5,3 @@ cd $(readlink -f `dirname $0`)
python gitlab-conversion.py
cd target
asciidoctor master.adoc
xdg-open master.html

View file

@ -42,6 +42,9 @@ if os.path.isdir('keycloak-images'):
if os.path.isdir('rhsso-images'):
shutil.copytree('rhsso-images',os.path.join(targetdir, 'rhsso-images'))
shutil.copyfile('metadata.ini', os.path.join(targetdir, 'metadata.ini'));
shutil.copyfile('master-docinfo.xml', os.path.join(targetdir, 'master-docinfo.xml'));
tmp = os.path.join(targetdir, 'topics')
if not os.path.exists(tmp):
os.makedirs(tmp)
@ -67,8 +70,8 @@ input = re.sub(r"[ ]*\.+\s*link:(.*)\[(.*)\]", "include::\g<1>[]", input)
input = applyTransformation(input)
output.write(input)
# parse book.json file and create document attributes
with open('book.json') as data_file:
# parse book-product.json file and create document attributes
with open('book-product.json') as data_file:
data = json.load(data_file)
variables = data['variables']