[Documentation] Add a build step

Support generation of non-API docs using
npm run docs. Supports MissionControl/vista#21
This commit is contained in:
Victor Woeltjen 2015-07-30 16:36:17 -07:00
parent ee64ef5fc1
commit 64e2de7aa6
4 changed files with 30 additions and 10 deletions

View File

@ -0,0 +1,12 @@
# Introduction
This is a placeholder for an architectural description of Open MCT Web.
```nomnoml
[<start> Start]->[<state> Load bundles.json]
[Load bundles.json]->[<state> Load bundle.json files]
[Load bundle.json files]->[<state> Resolve implementations]
[Resolve implementations]->[<state> Register with Angular]
[Register with Angular]->[<state> Bootstrap application]
[Bootstrap application]->[<end> End]
```

View File

@ -108,4 +108,19 @@ GLOBAL.window = GLOBAL.window || GLOBAL; // nomnoml expects window to be define
});
});
// Also copy over all HTML files
glob(options['in'] + "/**/*.html", {}, function (err, files) {
files.forEach(function (file) {
var destination = file.replace(options['in'], options.out),
destPath = path.dirname(destination);
mkdirp(destPath, function (err) {
fs.createReadStream(file, { encoding: 'utf8' })
.pipe(fs.createWriteStream(destination, {
encoding: 'utf8'
}));
});
});
});
}());

View File

@ -1,12 +1,3 @@
# Hello, world!
This is a placeholder for the developer guide.
```nomnoml
[<start> Start]->[<state> Load bundles.json]
[Load bundles.json]->[<state> Load bundle.json files]
[Load bundle.json files]->[<state> Resolve implementations]
[Resolve implementations]->[<state> Register with Angular]
[Register with Angular]->[<state> Bootstrap application]
[Bootstrap application]->[<end> End]
```

View File

@ -28,7 +28,9 @@
"start": "node app.js",
"test": "karma start --single-run",
"jshint": "jshint platform example || exit 0",
"jsdoc": "jsdoc -c jsdoc.json -r -d docs/api"
"jsdoc": "jsdoc -c jsdoc.json -r -d docs/api",
"otherdoc": "node docsrc/gendocs.js --in docsrc --out docs",
"docs": "npm run jsdoc ; npm run otherdoc"
},
"repository": {
"type": "git",