mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-20 04:14:21 +08:00
chore(ci): updating dgeni processors and templates for new ionic-site structure
This commit is contained in:
@ -77,7 +77,7 @@ module.exports = function(currentVersion, initialVersionBuild) {
|
|||||||
//Instead set latest version in docs root if not initial build
|
//Instead set latest version in docs root if not initial build
|
||||||
var folder = (version == latestVersion) && !initialVersionBuild ? '' : version;
|
var folder = (version == latestVersion) && !initialVersionBuild ? '' : version;
|
||||||
return {
|
return {
|
||||||
href: path.join('/' + config.v2DocsDir, folder),
|
href: path.join('/' + config.v2DocsDir, folder).replace('/content',''),
|
||||||
folder: folder,
|
folder: folder,
|
||||||
name: version
|
name: version
|
||||||
};
|
};
|
||||||
|
@ -19,7 +19,7 @@ module.exports = function indexPage(renderDocsProcessor) {
|
|||||||
id: 'index-page',
|
id: 'index-page',
|
||||||
currentVersion: currentVersion,
|
currentVersion: currentVersion,
|
||||||
template: 'api_index.template.html',
|
template: 'api_index.template.html',
|
||||||
outputPath: 'docs/v2/' + versionPath + '/api/index.md'
|
outputPath: 'content/docs/v2/' + versionPath + '/api/index.md'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -20,31 +20,35 @@ module.exports = function jekyll(renderDocsProcessor) {
|
|||||||
docs[i].URL = doc.outputPath.replace('docs/v2//', 'docs/v2/')
|
docs[i].URL = doc.outputPath.replace('docs/v2//', 'docs/v2/')
|
||||||
.replace('/index.md', '')
|
.replace('/index.md', '')
|
||||||
.replace('//home/ubuntu/ionic/src', '')
|
.replace('//home/ubuntu/ionic/src', '')
|
||||||
.replace('//', '/');
|
.replace('//', '/')
|
||||||
|
.replace('content/', '');
|
||||||
if (docs[i].relativePath) {
|
if (docs[i].relativePath) {
|
||||||
docs[i].relativePath = doc.relativePath
|
docs[i].relativePath = doc.relativePath
|
||||||
.replace('/home/ubuntu/ionic', '');
|
.replace('/home/ubuntu/ionic', '');
|
||||||
}
|
}
|
||||||
|
if (docs[i].href) {
|
||||||
|
docs[i].href = doc.href.replace('content/', '');
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
docs.push({
|
docs.push({
|
||||||
docType: 'api-menu',
|
docType: 'api-menu',
|
||||||
id: 'api-menu',
|
id: 'api-menu',
|
||||||
template: 'api_menu.template.html',
|
template: 'api_menu.template.html',
|
||||||
outputPath: '_includes/v2_fluid/api_menu.html'
|
outputPath: 'content/_includes/v2_fluid/api_menu.html'
|
||||||
});
|
});
|
||||||
docs.push({
|
docs.push({
|
||||||
docType: 'api-menu-flat-version',
|
docType: 'api-menu-flat-version',
|
||||||
id: 'api-menu-flat-version',
|
id: 'api-menu-flat-version',
|
||||||
template: 'api_menu_flat_version.template.html',
|
template: 'api_menu_flat_version.template.html',
|
||||||
outputPath: '_includes/v2_fluid/api_menu_flat_' + currentVersion +
|
outputPath: 'content/_includes/v2_fluid/api_menu_flat_' + currentVersion +
|
||||||
'.html'
|
'.html'
|
||||||
});
|
});
|
||||||
docs.push({
|
docs.push({
|
||||||
docType: 'api-version-select',
|
docType: 'api-version-select',
|
||||||
id: 'api-version-select',
|
id: 'api-version-select',
|
||||||
template: 'api_version_select.template.html',
|
template: 'api_version_select.template.html',
|
||||||
outputPath: '_includes/v2_fluid/api_version_select.html'
|
outputPath: 'content/_includes/v2_fluid/api_version_select.html'
|
||||||
});
|
});
|
||||||
|
|
||||||
// returning docs will replace docs object in the next process
|
// returning docs will replace docs object in the next process
|
||||||
|
Reference in New Issue
Block a user