Skip to main content
first and foremost

first and foremost

·238 words·2 mins

Powered by Hugo/Blowfish on Gitlab
#

Plenty of documentation exist to setup hugo&blowfish, I just followed the main blowfish documentation which is really well organised.

For Gitlab deployment I followed the instruction from Mariano González’s blog

I just faced 1 issue and made 1 modification:

  • Blowfish hugo module
  • Favicon

Blowfish installation
#

When I tried to use the Gitlab CI to download blowfish hugo theme, I got this issue.

Error: failed to get ["-u" "github.com/nunocoracao/blowfish"]: failed to execute 'go [get -u github.com/nunocoracao/blowfish]': failed to execute binary "go" with args [get -u github.com/nunocoracao/blowfish]: go: github.com/nunocoracao/blowfish: no matching versions for query "upgrade"

But I reviewed the documentation and it seems I just forgot to add v2 at the end of the url :( RTFM…

[[imports]]
disable = false
path = "github.com/nunocoracao/blowfish/v2"

Anyway what I did it’s just used git sub module:

cd mywebsite
git init
git submodule add -b main https://github.com/nunocoracao/blowfish.git themes/blowfish

And then modifing .gitlab-ci.yml:

variables:
    GIT_SUBMODULE_STRATEGY: recursive
    HUGO_ENV: production
    #THEME_URL: "github.com/nunocoracao/blowfish"
default:
  before_script:
    - hugo version
    #  - hugo mod get -u $THEME_URL

Favicons
#

For the favicons, I followed instructions on blowfish documentation

  1. The easiest way to obtain new favicon assets is to generate them using a third-party provider like favicon.io.
  2. Place them directly in the static/.
  3. Simply provide a layouts/partials/favicons.html file:
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
<link rel="android-chrome" sizes="192x192" href="/android-chrome-192x192.png">
<link rel="android-chrome" sizes="512x512" href="/android-chrome-512x512.png">
<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png">
<link rel="manifest" href="/site.webmanifest">