Static site generator for university research lab website.
Access control is by GitHub account permissions. See allowed collaborators here.
Navigate to /admin and log in with your GitHub account.
Select the Pages Collection on the left-hand side, and select the page or the "New Page" button.
Make your changes and click the "Publish" button. This will upload the page to GitHub.
It should take 30-60 seconds to deploy from GitHub to the content delivery network. Click the status badge at the top of this README for deployment details.
-
Clone this project.
-
Install Node.js and run
npm install
from the project directory.
-
Run
npm run watch
and navigate to http://localhost:4000/
Changes you make to
.pug
templates inthemes/
and.md
files insource/
will update the preview automatically.
-
Hexo site configuration is in
_config.yml
. -
Hexo theme configuration is in
themes/magiclab/_config.yml
. -
Netlify-CMS editor configuration is in
source/admin/config.yml
.
-
Define the schema for the page editor in
source/admin/config.yml
See the documentation on Collections and Widgets configuration. -
For collections that do not support creating new pages in the CMS, create the page file somewhere in
source/
, typically as a.md
file. -
Specify which template to use in the
layout
field. The default ispage.pug
. You can create additional layout files inthemes/magiclab/layout/
. -
If desired, you can write preview templates for the CMS in
source/admin/index.html
. (TODO: automatically load the.pug
files on the admin page.)