This repo makes up the layouts portion of the Presidium System Level Theme, and contains the officially support theme features.
For more info on Hugo Themes see the official Hugo documentation here
Update the config.yml:
module:
imports:
- path: github.com/spandigital/presidium-styling-base
- path: github.com/spandigital/presidium-layouts-base
- Clone the theme
- Clone the presidium-test-validation repo. We use the
presidium-test-validationrepo as the styling and functionality test bed, where we throw all the officially supported features in with the kitchen sink, so that we can validate every theme change has no unintended effects. - Open the
go.modfile in yourpresidium-test-validationclone. - Add the following to the bottom of your
go.modfile, and update the path after the arrow to the correct path where you cloned the theme layout:
replace github.com/spandigital/presidium-layouts-base => /{path-on-your-machine}/presidium-layouts-base
- Run a refresh and then build the docset with Hugo:
make refresh
If you don't have the Makefile in your docset, then you can copy it from here Then run
make serve
Your served site should be available on localhost:1313.
At SPAN we use Conventional Commits 1.0.0 to make our commit messages more useful.
This repository uses Semantic Release tool to automate version management and package publishing.
Upon merging into to the main or develop branch, Semantic Release tool will:
- Calculate the new release version based on the commits
- Create a git commit and a git tag for the release
- Create a Release with release notes from the commit messages
- Create and publish the container images
This repo uses trunk-based development (TBD). If you are not familiar with TBD, then please read this article.
Other TBD articles:
In summary:
main⇾ release versions created from main.develop⇾ the develop branch should NOT exist in this repo.branch⇾ branch directly off main.
Branch prefixes : prefix your branch with the type of work done in the branch, eg.:feat/: feature.fix/: fixing a bug.chore/: mundane update chore.refactor/: restructuring or cleaning-up code but no functional additions.
Make sure to include:
- Any necessary feature flags, and set the default behaviour as DISABLED until the team agrees to change that.
- Code unit tests as far as possible.
The Embed output format generates an embeddable version of a section or article that's appropriate for embedding content in an iframe.
Usage
# config.yml
...
outputs:
page:
- html # -> output: index.html
- embed # -> output: embed.html
section:
- html # -> output: index.html
- embed # -> output: embed.html