diff options
author | Andreas Deininger <andreas@deininger.net> | 2022-05-04 22:58:42 +0300 |
---|---|---|
committer | Andreas Deininger <andreas@deininger.net> | 2022-05-04 22:58:42 +0300 |
commit | a8666e938291192a5cf9d3fb92df46d02305ed1b (patch) | |
tree | 307e8ccf0e43d85cadce9d35e51f5c47de020a61 | |
parent | e55e50b273860a7e18345b3f24a665bec484db4b (diff) |
Turn zen theme into a hugo module
README.md: fixing typos
-rw-r--r-- | README.md | 38 | ||||
-rw-r--r-- | exampleSite/.gitignore | 3 | ||||
-rw-r--r-- | exampleSite/config.yaml | 2 | ||||
-rw-r--r-- | exampleSite/go.mod | 5 | ||||
-rw-r--r-- | exampleSite/go.sum | 2 | ||||
-rw-r--r-- | go.mod | 3 |
6 files changed, 48 insertions, 5 deletions
@@ -81,6 +81,26 @@ Hugo Extended version 0.88.1 or higher is required. ## Installation +### Hugo module + +First of all, you need to turn your new or existing site into a hugo module. + +From the root of your site: + +``` +$ hugo mod init github.com/me/my-site +``` + +Afterwards, declare the `zen` theme module as a dependency of your site: + +From the root of your site: + +``` +$ hugo mod get github.com/frjo/hugo-theme-zen +``` + +### Git submodule + You can download and unpack the theme manually from Github but it's easier to use git to clone the repo. From the root of your site: @@ -100,6 +120,16 @@ git submodule add https://github.com/frjo/hugo-theme-zen.git themes/zen ## Updating +### Hugo module + +From the root of your site: + +``` +hugo mod get -u github.com/frjo/hugo-theme-zen +``` + +### Git submodule + From the root of your site: ``` @@ -211,7 +241,7 @@ params: category: name: # * Feed category (iTunes). subcategories: [] # Feed sub category (iTunes). - explicit: false/true # Feed explicit settting, default to false (iTunes). + explicit: false/true # Feed explicit setting, default to false (iTunes). author: # Feed author (iTunes). owner: name: # Feed owner name (iTunes). @@ -290,7 +320,7 @@ To customise a js or sass file, copy it to the root assets directory and edit it There is an `assets/sass/_custom.scss` file meant for your custom styles. Copy it to the root `assets/sass/_custom.scss` to use it. -The default styles in `assets/sass/_zen.scss` are boring but functional. You can easily overide them completely by placing an empty file named "_zen.scss" in root assets/sass directory. +The default styles in `assets/sass/_zen.scss` are boring but functional. You can easily override them completely by placing an empty file named "_zen.scss" in root assets/sass directory. The sass files are by default built for production, compressed with fingerprint. @@ -308,7 +338,7 @@ Needed styles are in the `_zen.scss` file. ## Multilingual -Arabic, Danish, Finnish, English, Hebrew, French, German, Norwegian, Portugis and Swedish translations are included and you can easily add more to the `i18n` site directory. All but English and Swedish are contributed by users, thanks! +Arabic, Danish, Finnish, English, Hebrew, French, German, Norwegian, Portuguese and Swedish translations are included and you can easily add more to the `i18n` site directory. All but English and Swedish are contributed by users, thanks! A language selector will be included on sites with more than one language. Add `languageName` to your language configuration, this is what will be displayed in the selector. @@ -386,7 +416,7 @@ If your server support php with the mail() command (very common) you can use the If you have a SPF record for your domain, make sure the web server is listed or other mail server may mark the mail as spam. -Two types of spam protection is implemented. The form can only be posted after the user have moved the mouse or pressed the tab or enter key. The form have a "honypot" field that is invisible to humans but not to most spam boots. If that field is filled in the mail will not be sent. +Two types of spam protection are implemented. The form can only be posted after the user moved the mouse or pressed the tab or enter key. The form has a "honypot" field that is invisible to humans but not to most spam boots. If that field is filled in the mail will not be sent. Form validation is handled by HTML5 and there is some CSS to make it look nice. diff --git a/exampleSite/.gitignore b/exampleSite/.gitignore new file mode 100644 index 0000000..3ef3b99 --- /dev/null +++ b/exampleSite/.gitignore @@ -0,0 +1,3 @@ +.hugo_build.lock
+public/
+resources/
\ No newline at end of file diff --git a/exampleSite/config.yaml b/exampleSite/config.yaml index 25dd0a6..e329299 100644 --- a/exampleSite/config.yaml +++ b/exampleSite/config.yaml @@ -1,7 +1,7 @@ --- title: "Hugo Zen theme" baseURL: "https://example.org/" -theme: "zen" +theme: "github.com/frjo/hugo-theme-zen" languageCode: "en-GB" defaultContentLanguage: "en" pluralizelisttitles: false diff --git a/exampleSite/go.mod b/exampleSite/go.mod new file mode 100644 index 0000000..df62840 --- /dev/null +++ b/exampleSite/go.mod @@ -0,0 +1,5 @@ +module github.com/frjo/hugo-theme-zen/exampleSite + +go 1.12 + +require github.com/frjo/hugo-theme-zen v2.1.0+incompatible // indirect diff --git a/exampleSite/go.sum b/exampleSite/go.sum new file mode 100644 index 0000000..fc67ed0 --- /dev/null +++ b/exampleSite/go.sum @@ -0,0 +1,2 @@ +github.com/frjo/hugo-theme-zen v2.1.0+incompatible h1:aDpNcrjQ+w+82oZXEG9ADZadk5nllXpHyN3wzJctD3M= +github.com/frjo/hugo-theme-zen v2.1.0+incompatible/go.mod h1:rnj+r21QUs67tvO9VRsMEggl1cB637lMtSTIZBQk/iA= @@ -0,0 +1,3 @@ +module github.com/frjo/hugo-theme-zen + +go 1.12 |