From 0a23baa6a90901f772c234107c4f12c16c76f4aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Pedersen?= Date: Tue, 20 Mar 2018 21:11:45 +0100 Subject: [PATCH] Squashed 'docs/' changes from 211a3c613..3068989b9 3068989b9 Merge commit '7ae9cf2ccb3eecc1ff50f686925249d01cf37c6c' 7ae9cf2cc Squashed 'themes/gohugoioTheme/' changes from d7a475e7..a1768ebb b55157fae Revert "Anchorify headings up to h4" b63dd5566 Anchorify headings up to h4 edfe36a19 Test out trac as highlighter style 98dc8d269 Update multilingual.md a6e4d92c0 Update multilingual.md 86a90edf9 Fix typo 'If will' to 'It will' line 41 6b626fac6 Add a tip for testing custom 404.html on hugo server 6bfc17cfc Update few links to now point to gohugoio organization repos f66bad971 Remove unintended alias 3bc56e9ec Fix shortcode name in example: image -> img 251142388 Fix broken link 27245af6a Fix the minimum required git version for GH Pages flow aefc87b4d Fix link in Forestry showcase 489ec5ea0 Squashed 'themes/gohugoioTheme/' changes from 6f3a8bf5..d7a475e7 308a616fd Merge commit '489ec5ea03799fa092d891838c1655e60b34f337' a80859814 Adjust showcase description git-subtree-dir: docs git-subtree-split: 3068989b9c601146e8e6be8c4e8e2b2c679e5230 --- config.toml | 6 +++--- content/about/benefits.md | 4 ++-- content/content-management/multilingual.md | 6 +++--- content/contribute/themes.md | 2 +- content/functions/countwords.md | 2 +- .../hosting-and-deployment/hosting-on-github.md | 2 +- content/showcase/forestry/index.md | 4 ++-- content/templates/404.md | 8 +++++++- content/templates/lookup-order.md | 2 +- content/templates/shortcode-templates.md | 6 +++--- layouts/shortcodes/gh.html | 6 +++--- .../layouts/partials/site-search.html | 4 ++-- .../src/css/_documentation-styles.css | 2 +- themes/gohugoioTheme/src/js/anchorforid.js | 2 +- themes/gohugoioTheme/src/readme.md | 2 +- themes/gohugoioTheme/static/dist/app.bundle.js | 14 +++++++------- themes/gohugoioTheme/static/dist/main.css | 2 +- 17 files changed, 40 insertions(+), 34 deletions(-) diff --git a/config.toml b/config.toml index 819880e4d..c81890ecf 100644 --- a/config.toml +++ b/config.toml @@ -16,18 +16,18 @@ pluralizeListTitles = false # We do redirects via Netlify's _redirects file, generated by Hugo (see "outputs" below). disableAliases = true - # Highlighting config (Pygments) # It is (currently) not in use, but you can do ```go in a content file if you want to. pygmentsCodeFences = true pygmentsOptions = "" # Use the Chroma stylesheet -pygmentsUseClasses = true +# TODO(bep) build new CSS when we have picked a new style. +pygmentsUseClasses = false pygmentsUseClassic = false # See https://help.farbox.com/pygments.html -pygmentsStyle = "friendly" +pygmentsStyle = "trac" [outputs] home = [ "HTML", "RSS", "REDIR", "HEADERS" ] diff --git a/content/about/benefits.md b/content/about/benefits.md index 74c5dde39..0ba28c5cc 100644 --- a/content/about/benefits.md +++ b/content/about/benefits.md @@ -29,14 +29,14 @@ This has many benefits. The most noticeable is performance. HTTP servers are *ve * ["An Introduction to Static Site Generators", David Walsh][] * ["Hugo vs. Wordpress page load speed comparison: Hugo leaves WordPress in its dust", GettingThingsTech][hugovwordpress] -* ["Static Site Generators", O-Reilly][] +* ["Static Site Generators", O'Reilly][] * [StaticGen: Top Open-Source Static Site Generators (GitHub Stars)][] * ["Top 10 Static Website Generators", Netlify blog][] * ["The Resurgence of Static", dotCMS][dotcms] ["An Introduction to Static Site Generators", David Walsh]: https://davidwalsh.name/introduction-static-site-generators -["Static Site Generators", O-Reilly]: /documents/oreilly-static-site-generators.pdf +["Static Site Generators", O'Reilly]: http://www.oreilly.com/web-platform/free/files/static-site-generators.pdf ["Top 10 Static Website Generators", Netlify blog]: https://www.netlify.com/blog/2016/05/02/top-ten-static-website-generators/ [hugovwordpress]: https://gettingthingstech.com/hugo-vs.-wordpress-page-load-speed-comparison-hugo-leaves-wordpress-in-its-dust/ [StaticGen: Top Open-Source Static Site Generators (GitHub Stars)]: https://www.staticgen.com/ diff --git a/content/content-management/multilingual.md b/content/content-management/multilingual.md index eba196c39..8da599cd2 100644 --- a/content/content-management/multilingual.md +++ b/content/content-management/multilingual.md @@ -34,16 +34,16 @@ help = "Help" [languages.en] title = "My blog" weight = 1 +[languages.en.params] linkedin = "english-link" [languages.fr] copyright = "Tout est à moi" title = "Mon blog" weight = 2 +[languages.fr.params] linkedin = "lien-francais" - -# skip params key for front matter -[languages.fr.navigation] +[languages.fr.params.navigation] help = "Aide" {{< /code >}} diff --git a/content/contribute/themes.md b/content/contribute/themes.md index e6070c383..256f46093 100644 --- a/content/contribute/themes.md +++ b/content/contribute/themes.md @@ -25,7 +25,7 @@ A collection of all themes created by the Hugo community, including screenshots ## tl;dr 1. Create your theme using `hugo new theme `; -2. Test your theme against \* +2. Test your theme against \* 3. Add a `theme.toml` file to the root of the theme with all required metadata 4. Add a descriptive `README.md` to the root of the theme source 5. Add `/images/screenshot.png` and `/images/tn.png` diff --git a/content/functions/countwords.md b/content/functions/countwords.md index cf699b1b4..44f9360c9 100644 --- a/content/functions/countwords.md +++ b/content/functions/countwords.md @@ -15,7 +15,7 @@ workson: [] hugoversion: relatedfuncs: [countrunes] deprecated: false -aliases: [/functions/countrunes/,/functions/countwords/] +aliases: [/functions/countwords/] --- The template function works similar to the [.WordCount page variable][pagevars]. diff --git a/content/hosting-and-deployment/hosting-on-github.md b/content/hosting-and-deployment/hosting-on-github.md index fc874f892..37b82ab2b 100644 --- a/content/hosting-and-deployment/hosting-on-github.md +++ b/content/hosting-and-deployment/hosting-on-github.md @@ -23,7 +23,7 @@ GitHub provides free and fast static hosting over SSL for personal, organization ## Assumptions -1. You have Git 2.5 or greater [installed on your machine][installgit]. +1. You have Git 2.8 or greater [installed on your machine][installgit]. 2. You have a GitHub account. [Signing up][ghsignup] for GitHub is free. 3. You have a ready-to-publish Hugo website or have at least completed the [Quick Start][]. diff --git a/content/showcase/forestry/index.md b/content/showcase/forestry/index.md index ee1ebe07a..1a9c0faaa 100644 --- a/content/showcase/forestry/index.md +++ b/content/showcase/forestry/index.md @@ -1,7 +1,7 @@ --- title: Forestry.io date: 2018-03-16 -description: "A Git-backed CMS (content management system) for websites and web products built using static site generators." +description: "Showcase: \"Seeing Hugo in action is a whole different world of awesome.\"" siteURL: https://forestry.io/ siteSource: https://github.com/forestryio/forestry.io --- @@ -40,7 +40,7 @@ Lastly, we want to take the opportunity to give some love to other amazing tools * [**Hugo**](https://gohugo.io/) -- of course. * Chris can’t think of modern web development without [**Gulp**](https://gulpjs.com/) & [**Webpack**](https://webpack.js.org/). We used them to add additional build steps such as Browsersync, CSS, JS and SVG optimization. * Speaking about adding steps to our build, our lives would be much harder without [**CircleCI**](https://circleci.com/) for continuous deployment and automated testing purposes. -* We can’t stop raving about [**Algolia**](https://www.algolia.com/). Chris loves it and even wrote a tutorial on [how to implement Algolia]([https://forestry.io/blog/search-with-algolia-in-hugo/) into static sites using Hugo’s [Custom Outputs](https://gohugo.io/templates/output-formats/). +* We can’t stop raving about [**Algolia**](https://www.algolia.com/). Chris loves it and even wrote a tutorial on [how to implement Algolia](https://forestry.io/blog/search-with-algolia-in-hugo/) into static sites using Hugo’s [Custom Outputs](https://gohugo.io/templates/output-formats/). * [**Cloudinary**](https://cloudinary.com/) is probably one of the easiest ways to get responsive images into your website. * We might be a little biased on this one - We think [**Forestry.io**](https://forestry.io/) is a great way to add a content management system with a clean UI on top of your site without interrupting your experience as a developer. * For hosting purposes we use the almighty [**AWS**](https://aws.amazon.com/). diff --git a/content/templates/404.md b/content/templates/404.md index 8f6caa3ae..eaa479d29 100644 --- a/content/templates/404.md +++ b/content/templates/404.md @@ -52,4 +52,10 @@ Your 404.html file can be set to load automatically when a visitor enters a mist * Amazon AWS S3. When setting a bucket up for static web serving, you can specify the error file from within the S3 GUI. * Caddy Server. Using `errors { 404 /404.html }`. [Details here](https://caddyserver.com/docs/errors) -[pagevars]: /variables/page/ \ No newline at end of file +{{% note %}} +`hugo server` will not automatically load your custom `404.html` file, but you +can test the appearance of your custom "not found" page by navigating your +browser to `/404.html`. +{{% /note %}} + +[pagevars]: /variables/page/ diff --git a/content/templates/lookup-order.md b/content/templates/lookup-order.md index fd03d5977..d197b6141 100644 --- a/content/templates/lookup-order.md +++ b/content/templates/lookup-order.md @@ -38,7 +38,7 @@ Layout : Can be set in page front matter. Type -: Is value of `type` if set in front matter, else it is the name of the root section (e.g. "blog"). If will always have a value, so if not set, the value is "page". +: Is value of `type` if set in front matter, else it is the name of the root section (e.g. "blog"). It will always have a value, so if not set, the value is "page". Section : Is relevant for `section`, `taxonomy` and `taxonomyTerm` types. diff --git a/content/templates/shortcode-templates.md b/content/templates/shortcode-templates.md index 08f1b4c80..67e54089f 100644 --- a/content/templates/shortcode-templates.md +++ b/content/templates/shortcode-templates.md @@ -301,9 +301,9 @@ The following example is contrived but demonstrates the concept. Assume you have {{< /code >}} -You also have an `image` shortcode with a single named `src` parameter that you want to call inside of `gallery` and other shortcodes so that the parent defines the context of each `image`: +You also have an `img` shortcode with a single named `src` parameter that you want to call inside of `gallery` and other shortcodes, so that the parent defines the context of each `img`: -{{< code file="layouts/shortcodes/image.html" >}} +{{< code file="layouts/shortcodes/img.html" >}} {{- $src := .Get "src" -}} {{- with .Parent -}} @@ -322,7 +322,7 @@ You can then call your shortcode in your content as follows: {{}} ``` -This will output the following HTML. Note how the first two `image` shortcodes inherit the `class` value of `content-gallery` set with the call to the parent `gallery`, whereas the third `image` only uses `src`: +This will output the following HTML. Note how the first two `img` shortcodes inherit the `class` value of `content-gallery` set with the call to the parent `gallery`, whereas the third `img` only uses `src`: ```