ssbc/ssbc-sitegen

Name: ssbc-sitegen

Owner: Secure Scuttlebutt Consortium

Description: Tool to generate the GH pages for ssbc repos

Created: 2016-01-13 16:27:26.0

Updated: 2017-11-10 03:37:14.0

Pushed: 2016-01-19 16:53:46.0

Homepage: null

Size: 62

Language: JavaScript

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

ssbc site generator

A tool to generate the GH pages for ssbc repos. Requires the latest node because it uses es6 features, such as template-strings and generators.

Usage

Example:

/patchwork
checkout gh-pages
bc-sitegen/index.js patchwork
File structure

Each repo has a folder under ./repos, plus an entry in the REPOS constant in ./index.js. The JS files in the repo folder are templates.

The build-tool will iterate all .JS and .TXT files under ./repo/<repo>/* and write the output to cwd. The output-file is the file, minus the .js or .txt extension. Therefore, index.html.js will output index.html.

The build-tool also iterates and outputs all JS files under ./common.

Note, most templates will pull from markdown files in the cwd, such as README.md.

Template files

The JS files are template files. They should export a generator which yields the output. They are passed the object that's exported by ./gen.js, which gives them access to build utilities and partials.

The TXT files are copied without changes.


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.