Merge pull request #38 from navneetkarnani/master

Add support for custom start file
pull/39/head
Romain 8 years ago committed by GitHub
commit d6432f92b8

@ -13,6 +13,9 @@ var opts = yargs
'output': {
description: 'Output path for the static website',
},
'index': {
description: 'Name of the First page in the flow. Defaults to index.html'
},
'title': {
description: 'Website title',
default: 'My gallery'
@ -61,5 +64,6 @@ index.build({
originalVideos: opts['original-videos'] + '' === 'true',
sortFolders: opts['sort-folders'],
css: opts['css'],
googleAnalytics: opts['google-analytics']
googleAnalytics: opts['google-analytics'],
index: opts['index']
});

@ -24,9 +24,10 @@ exports.build = function(metadata, opts, callback) {
function website(callback) {
var structure = model.create(metadata, opts);
var homepage = pages.homepage(structure);
var index = opts.index || 'index.html';
var items = [
render('index.html', 'homepage', homepage)
render(index, 'homepage', homepage)
];
structure.forEach(function(folder, index) {

Loading…
Cancel
Save