Hallo is a single-page Hugo theme to introduce yourself. Add a portrait, an introduction, several links, and you’re set.
1. Install the theme
If your site is also under version control using git, the easiest way to install this theme is to add it as a submodule. If you have not created a git repo for your project yet, you need to run git init beforehand. Inside the folder of your Hugo site, run the following command.
If you have installed the theme as a git submodule, you can update the theme by issuing the following command inside your project folder.
git submodule update --remote --rebase
If you have cloned the theme, you can run git pull inside the theme folder.
Put your own portrait in /static/images/portrait.jpg of your own site and Hugo wil automatically use that portraid instead of the standard one. It’s not necessary to alter the theme.
Put your own introduction text in /layouts/partials/introduction.html of your own site and Hugo wil automatically use that introduction instead of the standard one. It’s not necessary to alter the theme.
Hallo will use the name of the author that has been configured in the Author section of your site’s config.toml. Add the lines below to your config.toml to configure the name.
name = "Emiel"
You can put your own links below the introduction text, for example to link to your social media accounts or to include your e-mail address. These links use icons from FontAwesome. The links can be configured in the params section of your site’s config.toml. This is an example configuration for a link to Github:
Hallo by default allows you to choose an icon from the brands set. Put the name of the icon in the icon parameter. This set is the default set because these links will mostly be used for links to social media.
It is possible to use an icon from the solid set. To do this, specify the icon set, like this:
Hallo supports using other languages than English. Language files for the texts Hallo uses are provided in the i18n directory. The default language is English. To switch languages, add the key defaultContentLanguage to your config.toml file. For example:
defaultContentLanguage = "nl"
To translate texts your site uses, add an i18n folder to your site.
Feel free to submit pull requests for other translations of Hallo’s texts.
foreground: Used for text and the border of the portrait.
hover: Used for hover of links.
Warning: When using Hugo Basic, you need to perform additional steps to make custom colors work.
If you get the following error message while building your site, you’re using Hugo Basic:
error: failed to transform resource: TOCSS: failed to transform "style.hallo.scss" (text/x-scss): this feature is not available in your current Hugo version
The SCSS needs to be transpiled for your custom colors, which is something Hugo Basic cannot do. For the standard colors, the transpiled SCSS comes with the theme.
If you’re stuck with Hugo Basic, e.g. because your Hugo site is generated on a server that only has Hugo Basic installed, you can get custom colors to work by performing the following steps.
Install Hugo Extended on your local machine.
Generate your site locally by running hugo on your local machine.
Commit the generated resources folder to the root folder of your site. This folder can be found inside the public folder after running hugo.
Hugo Basic will then use this resources folder to find the transpiled SCSS.
By default, the theme uses the translation of the word ‘Hello’ for the language of your site. You can also choose to alter this text completely. To do so, add the parameter greeting to your config.toml, like so:
greeting = "Greetings!"
The theme supports Google Analytics. To use Google Analytics, specify the parameter googleAnalytics in your config.toml. This will add the code for Google Analytics when you generate your site for production. It will not be included for any environment other than production (e.g. when using hugo serve).