The Hugo files for the BC Libraries site.
- Clone the site into a new directory.
git clone https://github.com/BCLibraries/bc-libraries-site-hugo.git
- Install the testing framework.
cd bc-libraries-site-hugo npm install
- Setup git hooks (optional).
npx husky install
The site is built using Hugo. Be sure to use the extended version with Sass/SCSS support.
Use the hugo new
command to add content, e.g.:
- Upload the image thumbnail to the appropriate subdirectory of /var/www/html/images/news on library.bc.edu.
- Create an AVIF and webp files of the image on library:
npx avif image-filename.jpg mogrify -format webp image-filename.jpg
- Create the news item:
hugo new news/2024-10/headline-in-slug-form.md
- Fill in the news metadata, using a previous story as the model.
hugo new facpub/2022-05-10-facpub-name.md
hugo new exhibit/bapst/2022-05-title.md
We use WebDriverIO for end-to-end tests. Spec files are in the /test/specs directory. To run:
npx wdio run ./wdio.conf.js
Use the deploy-bento
command to deploy new versions of the bento application:
./bin/deploy-bento /path/to/bcbento-client