Lechlak / staticAid

A Jekyll-based static site generator for archival description in JSON.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Project Name

A Jekyll static site generator for archival description serialized in JSON, generated via the ArchivesSpace REST API.

You can see a live version of this site with sample data here.

Requirements

Installation

Setup

  1. Clone this repository git clone git@github.com:helrond/staticAid.git or download the ZIP file.
  2. Install dependencies. See "Requirements" above for a list of things you'll need to have installed.
  3. In this project's root directory, run npm install to install dependencies for Grunt
  4. Run utilities/setup.py to create a configuration file which will allow you to fetch and update data from ArchivesSpace.

Usage

Building the HTML Site

You have three options for building the HTML site using Jekyll. In all cases, Jekyll will place the generate site in a directory called _site.

Build without updating data

Running grunt build will build the site based on the data currently in the _data directory.

Update data then build site

Running grunt update will fetch JSON for resource records, resource record trees and archival objects from ArchivesSpace using utilities/getJson.py and save it in your _data directory, then will build the site based on that data.

WARNING: Depending on the size of your ArchivesSpace installation, it could take quite a while for this script to loop through all resource records and components. Be patient!

Clean Build

By default, grunt update will only fetch JSON updated since the last time utilities/getJson.py completed successfully. At any point, you can run grunt rebuild to wipe out the existing data and build the site from scratch.

WARNING: Depending on the size of your ArchivesSpace installation, it could take quite a while for this script to loop through all resource records and components. Be patient!

Starting the Local Server

To start a local server (useful for previewing the site), run grunt serve. You can then access the site by opening a browser and pointing it to http://localhost:4000. To stop the server, use ctrl + c.

This server will use the HTML generated by the last build, so if you've made changes to any of your templates or data you'll need to build the site in order to see those changes (see above).

Github Pages

Github Pages support Jekyll sites, so a quick way to make your description publicly accessible is to push to a gh-pages branch in a Github repository. See the Github Pages documentation for more information.

Contributing

Pull requests accepted! Feel free to file issues on this repository as well.

Authors

Hillel Arnold

License

staticAid is released under the MIT License. See LICENSE.md for more information.

About

A Jekyll-based static site generator for archival description in JSON.

License:MIT License


Languages

Language:CSS 84.9%Language:HTML 7.7%Language:Python 6.7%Language:JavaScript 0.7%