diff --git a/lib/generate/json/index.js b/lib/generate/json/index.js
index 745933bf3..6a68f686f 100644
--- a/lib/generate/json/index.js
+++ b/lib/generate/json/index.js
@@ -26,7 +26,6 @@ Generator.prototype.convertFile = function(content, input) {
return Q()
.then(function() {
return parse.page(content, {
- repo: that.options.githubId,
dir: path.dirname(input) || '/'
});
})
diff --git a/lib/generate/page/index.js b/lib/generate/page/index.js
index a01321914..9e48a5eaf 100644
--- a/lib/generate/page/index.js
+++ b/lib/generate/page/index.js
@@ -37,33 +37,9 @@ Generator.prototype.convertFile = function(content, input) {
progress: parse.progress(this.options.navigation, input)
};
- var _callHook = function(name) {
- return that.callHook(name, json)
- .then(function(_page) {
- json = _page;
- return json;
- });
- };
-
- return Q()
- .then(function() {
- return parse.page(content, {
- repo: that.options.githubId,
- dir: path.dirname(input) || '/',
- outdir: './',
- singleFile: true
- });
- })
- .then(function(sections) {
- json.content = sections;
- })
- .then(function(sections) {
-
- // Use plugin hook
- return _callHook("ebook:page");
- })
- .then(function() {
- that.pages[input] = json;
+ return this.prepareFile(content, input)
+ .then(function(page) {
+ that.pages[input] = page;
});
};
diff --git a/lib/generate/site/index.js b/lib/generate/site/index.js
index 5d3a57b5f..dc9a4d4e8 100644
--- a/lib/generate/site/index.js
+++ b/lib/generate/site/index.js
@@ -62,10 +62,6 @@ Generator.prototype._writeTemplate = function(tpl, options, output, interpolate)
title: that.options.title,
description: that.options.description,
- githubAuthor: that.options.github ? that.options.github.split("/")[0] : "",
- githubId: that.options.github,
- githubHost: that.options.githubHost,
-
glossary: that.options.glossary,
summary: that.options.summary,
@@ -133,7 +129,6 @@ Generator.prototype.prepareFile = function(content, _input) {
// Get HTML generated sections
return parse.page(lexed, {
- repo: that.options.githubId,
dir: path.dirname(_input) || '/',
outdir: path.dirname(_input) || '/',
});
diff --git a/theme/javascript/core/state.js b/theme/javascript/core/state.js
index 2f7c633ed..de5c65cac 100755
--- a/theme/javascript/core/state.js
+++ b/theme/javascript/core/state.js
@@ -7,7 +7,6 @@ define([
var $book = $(dom.find(".book"));
state.$book = $book;
- state.githubId = $book.data("github");
state.level = $book.data("level");
state.basePath = $book.data("basepath");
state.revision = $book.data("revision");
diff --git a/theme/javascript/gitbook.js b/theme/javascript/gitbook.js
index 0682b2fde..77c7ae05d 100755
--- a/theme/javascript/gitbook.js
+++ b/theme/javascript/gitbook.js
@@ -18,11 +18,6 @@ define([
var $book;
$book = state.$book;
- if (state.githubId) {
- // Initialize storage
- storage.setBaseKey(state.githubId);
- }
-
// Init sidebar
sidebar.init();
diff --git a/theme/templates/page.html b/theme/templates/page.html
index 9c58ab141..89ffc24e6 100644
--- a/theme/templates/page.html
+++ b/theme/templates/page.html
@@ -41,7 +41,7 @@
{{ item.title }}
{% if pages[item.path] %}
- {{ articleContent(pages[item.path].content) }}
+ {{ articleContent(pages[item.path].sections) }}
{% endif %}