diff --git a/README.md b/README.md index b2ebd82..4627557 100644 --- a/README.md +++ b/README.md @@ -16,7 +16,7 @@ This theme is subject to a CI driven build and release process common for softwa Due to the fact that `webpack` and `npm scripts` are used as pre-processors, the theme cannot be used from the main branch by default. If you want to use the theme from a cloned branch instead of a release tarball you'll need to install `webpack` locally and run the build script once to create all required assets. -```Shell +```shell # install required packages from package.json npm install diff --git a/exampleSite/content/posts/advanced/includes.md b/exampleSite/content/posts/advanced/includes.md index f2d19df..fd05ea2 100644 --- a/exampleSite/content/posts/advanced/includes.md +++ b/exampleSite/content/posts/advanced/includes.md @@ -91,7 +91,7 @@ In some situations, it can be helpful to include Markdown files that also contai Resulting structure should look like this: -```Shell +```shell _includes/ ├── include-page.md └── _index.md diff --git a/exampleSite/content/posts/features/authors.md b/exampleSite/content/posts/features/authors.md index bcc1cae..be42a8c 100644 --- a/exampleSite/content/posts/features/authors.md +++ b/exampleSite/content/posts/features/authors.md @@ -12,7 +12,7 @@ The theme supports multiple authors. The required information for each author ne -```Shell +```shell data/ └── authors ├── john-doe.yml @@ -22,14 +22,14 @@ data/ The name of the file will be used as the reference later, so if you prefer some kind of naming convention this need to covered by the file names. Example authors file: -```YAML +```yaml name: John Doe email: john@example.com ``` With the defined files, you can add as many authors as you want to the front matter of your posts: -```Markdown +```markdown --- title: Demo Posts authors: diff --git a/exampleSite/content/posts/features/code-blocks.md b/exampleSite/content/posts/features/code-blocks.md index 2abc555..c64f80c 100644 --- a/exampleSite/content/posts/features/code-blocks.md +++ b/exampleSite/content/posts/features/code-blocks.md @@ -16,7 +16,7 @@ There are several ways to add code blocks. Most of them work out of the box, onl To display an inline shortcode use single quotes: -```Plain +```plain `some code` ``` @@ -26,22 +26,22 @@ To display an inline shortcode use single quotes: Code blocks can be uses without language specification: -````Markdown -```Plain +````markdown +```plain some code ``` ```` **Example:** -```Plain +```plain some code ``` ... or if you need language specific syntax highlighting: -````Markdown -```Shell +````markdown +```shell # some code echo "Hello world" ``` @@ -49,7 +49,7 @@ echo "Hello world" **Example:** -```Shell +```shell # some code echo "Hello World" ``` @@ -61,7 +61,7 @@ Hugo has a build-in shortcode for syntax highlighting. To work properly with thi {{< tabs "uniqueid" >}} {{< tab "TOML" >}} -```TOML +```toml pygmentsUseClasses=true pygmentsCodeFences=true ``` @@ -69,7 +69,7 @@ pygmentsCodeFences=true {{< /tab >}} {{< tab "YAML" >}} -```YAML +```yaml pygmentsUseClasses: true pygmentsCodeFences: true ``` @@ -80,7 +80,7 @@ pygmentsCodeFences: true You can use it like every other shortcode: -```Markdown +```markdown {{}} # some code echo "Hello World" diff --git a/exampleSite/content/posts/features/icon-sets.md b/exampleSite/content/posts/features/icon-sets.md index c61c3cb..e245a5c 100644 --- a/exampleSite/content/posts/features/icon-sets.md +++ b/exampleSite/content/posts/features/icon-sets.md @@ -26,7 +26,7 @@ Regardless of which tool (or existing sprite) you choose, there are a few requir The result of a valid minimal SVG sprite file could look like this: -```XML +```xml @@ -38,7 +38,7 @@ The result of a valid minimal SVG sprite file could look like this: FontAwesome provides three pre-build sprites included in the regular Web download pack, `sprites/brands.svg`, `sprites/regular.svg` and `sprites/solid.svg`. Choose your sprite to use and copy it to your projects root directory into `assets/sprites`, right beside your `content` folder. The result should look like this: -```Bash +```bash my_projcet/ ├── assets │ └── sprites diff --git a/exampleSite/content/posts/features/sticky.md b/exampleSite/content/posts/features/sticky.md index f55fb1b..03877c3 100644 --- a/exampleSite/content/posts/features/sticky.md +++ b/exampleSite/content/posts/features/sticky.md @@ -15,7 +15,7 @@ Sticky (or pinned) posts can be used to permanently pin important posts to the t **Example:** -```YAML +```yaml --- title: Simple sticky posts weight: 1 diff --git a/exampleSite/content/posts/usage/configuration.md b/exampleSite/content/posts/usage/configuration.md index e83f895..6a50c95 100644 --- a/exampleSite/content/posts/usage/configuration.md +++ b/exampleSite/content/posts/usage/configuration.md @@ -21,7 +21,7 @@ Overview of all available site and page configuration options provided by the th {{< tabs "site-config" >}} {{< tab "TOML" >}} -```Toml +```toml baseURL = "http://localhost" title = "Geekblog" theme = "hugo-geekblog" @@ -151,7 +151,7 @@ enableRobotsTXT = true {{< /tab >}} {{< tab "YAML" >}} -```Yaml +```yaml --- baseURL: "http://localhost" title: "Geekblog" @@ -266,9 +266,10 @@ params: geekblogDarkModeDim: false # (Optional, default false) Enforce code blocks to always use the dark color theme. - geekblogDarkModeCode: false + geekblogDarkModeCode: + false - # (Optional, default true) Display a "Back to top" link in the site footer. + # (Optional, default true) Display a "Back to top" link in the site footer. geekblogBackToTop: true # (Optional, default ["taxonomy", "section", "term", "404"]) @@ -298,7 +299,7 @@ params: {{< tabs "page-config" >}} {{< tab "TOML" >}} -```Toml +```toml # Title of your post. If not set, filename will be used. title = My first post @@ -321,7 +322,7 @@ geekblogAnchor = true {{< /tab >}} {{< tab "YAML" >}} -```Yaml +```yaml # Title of your post. If not set, filename will be used. title: My first post diff --git a/exampleSite/content/posts/usage/getting-started.md b/exampleSite/content/posts/usage/getting-started.md index 4c96b65..b7d54c2 100644 --- a/exampleSite/content/posts/usage/getting-started.md +++ b/exampleSite/content/posts/usage/getting-started.md @@ -40,7 +40,7 @@ You need a recent version of Hugo for local builds and previews of sites that us If you want to use the theme from a cloned branch instead of a release tarball you'll need to install `webpack` locally and run the build script once to create all required assets. -```Shell +```shell # install required packages from package.json npm install @@ -57,13 +57,13 @@ To prepare your new site environment just a few steps are required: 1. Create a new empty Hugo site. - ```Shell + ```shell hugo new site demosite ``` 2. Switch to the root of the new site. - ```Shell + ```shell cd demosite ``` @@ -71,7 +71,7 @@ To prepare your new site environment just a few steps are required: 4. Create the minimal required Hugo configuration `config.toml`. For all configuration options take a look at the [configuration](/posts/usage/configuration/) page. - ```Toml + ```toml baseURL = "http://localhost" title = "Geekblog" theme = "hugo-geekblog" @@ -120,13 +120,13 @@ To prepare your new site environment just a few steps are required: 5. Test your site. - ```Shell + ```shell hugo server -D ``` If you want to add some demo data you could use the content from the [Hugo basic example](https://github.com/gohugoio/hugoBasicExample): - ```Shell + ```shell curl -L https://github.com/gohugoio/hugoBasicExample/archive/master.tar.gz | tar -xz --exclude "config*" --exclude "LICENSE" --exclude "README*" --strip-components=1 ``` @@ -134,7 +134,7 @@ To prepare your new site environment just a few steps are required: Download and extract the latest release bundle into the theme directory. -```Shell +```shell mkdir -p themes/hugo-geekblog/ curl -L https://github.com/thegeeklab/hugo-geekblog/releases/latest/download/hugo-geekblog.tar.gz | tar -xz -C themes/hugo-geekblog/ --strip-components=1 ``` @@ -150,13 +150,13 @@ run the described steps as well. Clone the Geekblog git repository. -```Shell +```shell git clone https://github.com/thegeeklab/hugo-geekblog.git themes/hugo-geekblog ``` Build required theme assets e.g. CSS files and SVG sprites. -```Shell +```shell npm install npm run build ``` @@ -173,7 +173,7 @@ Here are some possible solutions: Add a Makefile to your repository to bundle the required steps. -```Makefile +```makefile THEME_VERSION := v0.8.2 THEME := hugo-geekblog BASEDIR := docs diff --git a/exampleSite/content/posts/usage/menus.md b/exampleSite/content/posts/usage/menus.md index cd1b32d..040abcf 100644 --- a/exampleSite/content/posts/usage/menus.md +++ b/exampleSite/content/posts/usage/menus.md @@ -18,7 +18,7 @@ If you want to customize the menus (header and footer), this can be achieved by **Example:** -```Yaml +```yaml --- header: - name: Github Profile diff --git a/layouts/_default/_markup/render-heading.html b/layouts/_default/_markup/render-heading.html index d82d7ea..a5d0cbe 100644 --- a/layouts/_default/_markup/render-heading.html +++ b/layouts/_default/_markup/render-heading.html @@ -1,4 +1,4 @@ -{{- $showAnchor := (and (default true .Page.Params.GeekblogAnchor) (default true .Page.Site.Params.GeekblogAnchor)) -}} +{{- $showAnchor := (and (default true .Page.Params.geekblogAnchor) (default true .Page.Site.Params.geekblogAnchor)) -}} diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 6ddc4d4..444a115 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -4,7 +4,7 @@ itemtype="http://schema.org/WebPage" lang="{{ .Site.Language.Lang }}" class="color-toggle-hidden" - {{ if default false .Site.Params.GeekblogDarkModeCode }}code-theme="dark"{{ end }} + {{ if default false .Site.Params.geekblogDarkModeCode }}code-theme="dark"{{ end }} > {{ partial "head/meta" . }} @@ -28,7 +28,7 @@
{{ partial "site-header" . }} diff --git a/layouts/_default/list.atom.xml b/layouts/_default/list.atom.xml index af2847d..06161b9 100644 --- a/layouts/_default/list.atom.xml +++ b/layouts/_default/list.atom.xml @@ -17,7 +17,7 @@ {{- end }} {{- end }} {{ now.Format "2006-01-02T15:04:05-07:00" | safeHTML }} - {{- with .Site.Params.GeekblogAuthor -}} + {{- with .Site.Params.geekblogAuthor -}} {{- with index $.Site.Data.authors . }} {{ .name }} diff --git a/layouts/_default/list.json.json b/layouts/_default/list.json.json index d73cbc4..94e803c 100644 --- a/layouts/_default/list.json.json +++ b/layouts/_default/list.json.json @@ -12,7 +12,7 @@ {{- with .OutputFormats.Get "json" }} "feed_url" : "{{ .Permalink }}", {{- end }} - {{- with .Site.Params.GeekblogAuthor -}} + {{- with .Site.Params.geekblogAuthor -}} {{ with index $.Site.Data.authors . }} "authors" : [ { diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 84d0be3..0ff2ec1 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -21,7 +21,7 @@

{{ partial "utils/title" . }}

- {{ if or (eq .Type (default "posts" .Site.Params.GeekblogContentSection)) (eq .Type "post") }} + {{ if or (eq .Type (default "posts" .Site.Params.geekblogContentSection)) (eq .Type "post") }} diff --git a/layouts/_default/sitemap.xml b/layouts/_default/sitemap.xml index 51463bb..c750d3a 100644 --- a/layouts/_default/sitemap.xml +++ b/layouts/_default/sitemap.xml @@ -1,7 +1,7 @@ {{ printf "" | safeHTML }} - {{- $seoIgnore := default (slice "taxonomy" "section" "term" "404") .Site.Params.GeekblogSeoIgnore -}} + {{- $seoIgnore := default (slice "taxonomy" "section" "term" "404") .Site.Params.geekblogSeoIgnore -}} {{- range .Data.Pages }} {{- if and .Permalink (not (in $seoIgnore .Kind)) }} diff --git a/layouts/partials/head/meta.html b/layouts/partials/head/meta.html index 803b7dd..47da999 100644 --- a/layouts/partials/head/meta.html +++ b/layouts/partials/head/meta.html @@ -4,8 +4,8 @@ {{ hugo.Generator }} {{- $keywords := default .Site.Params.Keywords .Keywords -}} -{{- $authors := default (slice .Site.Params.GeekblogAuthor) .Params.authors -}} -{{- $seoIgnore := default (slice "taxonomy" "section" "term" "404") .Site.Params.GeekblogSeoIgnore -}} +{{- $authors := default (slice .Site.Params.geekblogAuthor) .Params.authors -}} +{{- $seoIgnore := default (slice "taxonomy" "section" "term" "404") .Site.Params.geekblogSeoIgnore -}} {{- if not (in $seoIgnore .Kind) }} diff --git a/layouts/partials/head/others.html b/layouts/partials/head/others.html index 825f72f..c4f0636 100644 --- a/layouts/partials/head/others.html +++ b/layouts/partials/head/others.html @@ -1,4 +1,4 @@ -{{- if default true .Site.Params.GeekblogDarkModeToggle }} +{{- if default true .Site.Params.geekblogDarkModeToggle }} {{- end }} @@ -78,7 +78,7 @@ {{- end }} {{- end }} -{{- if (default false $.Site.Params.GeekblogOverwriteHTMLBase) }} +{{- if (default false $.Site.Params.geekblogOverwriteHTMLBase) }} {{- end }} diff --git a/layouts/partials/microformats/schema.html b/layouts/partials/microformats/schema.html index e290bbb..2ab18e5 100644 --- a/layouts/partials/microformats/schema.html +++ b/layouts/partials/microformats/schema.html @@ -3,7 +3,7 @@ { "@context": "http://schema.org", "@type": "WebSite", - {{ with .Site.Params.GeekblogAuthor -}} + {{ with .Site.Params.geekblogAuthor -}} {{ with index $.Site.Data.authors . }}"author": "{{ .name }}",{{ end }} {{- end }} "name": {{ .Site.Title }}, @@ -14,14 +14,14 @@ {{- with partial "utils/featured" . }} "thumbnailUrl": {{ . }}, {{- end }} - {{- with .Site.Params.GeekblogContentLicense }} + {{- with .Site.Params.geekblogContentLicense }} "license": "{{ .name }}", {{- end }} "inLanguage": {{ .Lang }} } {{- else if .IsPage }} - {{- $authors := default (slice .Site.Params.GeekblogAuthor) .Params.authors -}} + {{- $authors := default (slice .Site.Params.geekblogAuthor) .Params.authors -}} {{- $ac := 0 -}} {{- $ac_max := default 0 (len $authors) -}} @@ -43,7 +43,7 @@ "thumbnailUrl": {{ . }}, {{- end }} "wordCount" : "{{ .WordCount }}", - {{- with .Site.Params.GeekblogContentLicense }} + {{- with .Site.Params.geekblogContentLicense }} "license": "{{ .name }}", {{- end }} "inLanguage": {{ .Lang }}, diff --git a/layouts/partials/site-footer.html b/layouts/partials/site-footer.html index 28b1511..8dba5d3 100644 --- a/layouts/partials/site-footer.html +++ b/layouts/partials/site-footer.html @@ -11,12 +11,12 @@ {{ if .Site.Data.menu.extra.footer }} {{ partial "menu-extra" (dict "current" . "source" .Site.Data.menu.extra.footer "target" "footer") }} {{ end }} - {{ with .Site.Params.GeekblogLegalNotice }} + {{ with .Site.Params.geekblogLegalNotice }} Legal Notice {{ end }} - {{ with .Site.Params.GeekblogPrivacyPolicy }} + {{ with .Site.Params.geekblogPrivacyPolicy }} Privacy Policy @@ -28,14 +28,14 @@ - {{ with .Site.Params.GeekblogHostedOn }} + {{ with .Site.Params.geekblogHostedOn }}
Hosted on {{ .name }}
{{ end }} - {{ with .Site.Params.GeekblogContentLicense }} + {{ with .Site.Params.geekblogContentLicense }}
Content licensed under @@ -44,7 +44,7 @@
{{ end }}
- {{ if (default true .Site.Params.GeekblogBackToTop) }} + {{ if (default true .Site.Params.geekblogBackToTop) }}
diff --git a/layouts/partials/site-header.html b/layouts/partials/site-header.html index 3bbcc82..3efd881 100644 --- a/layouts/partials/site-header.html +++ b/layouts/partials/site-header.html @@ -45,7 +45,7 @@