This repository contains the code of the spine.io site. It is based on Hugo and is hosted on GitHub Pages.
This project is two-headed:
- It is a Hugo project.
- It is a Gradle project to for checking the source code embedded to the site.
The code samples used on the site and in the framework documentation are added using
the embed-code tool (Go version).
The code resides under the _code directory. For instructions on embedding the code
into the pages, please see the _code/EMBEDDING.md file.
- JDK 8 (x86_64).
- Go
1.12or newer. - Node.js
18+. - Hugo Extended in version
v0.150.0or higher. - Access to the
site-commonsrepository — to download the theme.
- Make sure SSH configured correctly and the passphrase is stored in the keychain.
- Install project dependencies from the
sitedirectory by runningnpm install.
To build and launch the site on the local server:
./gradlew :runSite
To build the site without running the server:
./gradlew :buildSite
Another way to run the site locally is to follow these steps:
-
Navigate to the
sitefolder. -
Start the local server with this command:
hugo server
If you receive a permission denied message, but you are sure that you have
all the rights to the required repositories, try clearing
the cache:
hugo mod clean --allThen run the hugo serve again.
The documentation is located in a separate repository. It is added to this site as a Hugo Module.
Any changes to the documentation must be made in its own repository.
The documentation repository is made to be self-sustainable in terms of editing. A fully-fledged
Hugo site has been set up for it. All the contents and links in it are working as intended.
It allows making changes to it more convenient for authors.
In terms of building the “main” site, the Hugo Modules are used to embed the content.
-
Navigate to the
sitedirectory. -
Clean the module cache:
hugo mod clean
-
Get the documentation Hugo Module:
hugo mod get -u github.com/SpineEventEngine/documentation/docs
-
Commit and push changes from
go.modandgo.sumfiles. In thego.sumfile, keep only the two required entries for each theme to avoid file clutter.
This project uses the site-commons Hugo theme for general components such
as anchor icons, snackbars, etc.
-
Navigate to the
sitedirectory. -
To get theme updates, run:
hugo mod get -u github.com/TeamDev-Ltd/site-commons
-
Commit and push changes from
go.modandgo.sumfiles. In thego.sumfile, keep only the two required entries for each theme to avoid file clutter.
For instructions on adding the content to the site, please see
the AUTHORING.md file.