4

I am trying to deploy a hugo website on Gitlab but it returns the following error:

WARN: 2016/11/04 14:57:24 hugo.go:547: Unable to find static directory for theme strange-case in /builds/joaoeira/hugo/themes/strange-case/static

The theme "strange-case" is inside the themes folder, and it has a static folder there which is why I am finding this problem baffling. Here I include the steps I took to deploy the website (it says github because that was my first try):

git submodule add https://github.com/ExchangeRate-API/strange-case.git
git remote add origin https://github.com/joaoeira/joaoeira.github.io.git
hugo -t strange-case
git add .
git commit -m "first commit"
git push origin master

The final message hugo gives me:

=============================================================
Your rendered home page is blank: /index.html is zero-length
* Did you specify a theme on the command-line or in your
"config.toml" file? (Current theme: "strange-case")
* For more debugging information, run "hugo -v"
=============================================================

Any guesses?

My config.toml file:

baseurl = "https://joaoeira.gitlab.io"
title = "Lettuce be Cereal"
author = "João Eira"
copyright = "Your Copyright"
canonifyurls = true
paginate = 5
PygmentsCodeFences = false

googleAnalytics = ""

contentdir = "content/post"
layoutdir = "layouts"
publishdir = "public"
theme = "strange-case"

[params]
    colorScheme = "scheme-darkbrown"
    DateFormat = "2 Jan 2006"
    description ="João Eira is a Master's student in Economics at Universidade de Coimbra."
    sidebarDescription = "João Eira's personal blog"
    sidebarFreeText =  "\"Shared fictions are the necessary condition of social coordination.\""
    piwikSiteID = ""
    piwikURL = ""


[[menu.main]]
    name = "About"
    url = "http://joaoeira.com"

[[menu.main]]
    name = "Twitter"
    url = "http://twitter.com/joaoeira"

My .gitlab.ci.yml file. Note the "hugo -t strange-case -v" specifying the theme and all:

image: alpine:3.4

before_script:
  - apk update && apk add openssl
  - wget https://github.com/spf13/hugo/releases/download/v0.16/hugo_0.16_linux-64bit.tgz
  - echo "37ee91ab3469afbf7602a091d466dfa5  hugo_0.16_linux-64bit.tgz" | md5sum -c
  - tar xf hugo_0.16_linux-64bit.tgz && cp ./hugo /usr/bin
  - hugo version

test:
  script:
  - hugo
  except:
  - master

pages:
  script:
  - hugo -t strange-case -v
  artifacts:
    paths:
    - public
  only:
  - master
4

2 に答える 2