From db716b2349ed952a341818abe7c5ca1ac726a7db Mon Sep 17 00:00:00 2001 From: George Cushen Date: Sat, 11 Jan 2020 23:44:47 +0000 Subject: [PATCH] feat: add Markdown render hook to parse links Adds support for opening external links in new tabs in Hugo v0.62+. BREAKING CHANGE: Requires Hugo v0.62 See #1514 --- layouts/_default/_markup/render-link.html | 2 ++ netlify.toml | 2 +- theme.toml | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) create mode 100644 layouts/_default/_markup/render-link.html diff --git a/layouts/_default/_markup/render-link.html b/layouts/_default/_markup/render-link.html new file mode 100644 index 00000000..74871eba --- /dev/null +++ b/layouts/_default/_markup/render-link.html @@ -0,0 +1,2 @@ +{{/* A Hugo Markdown render hook to parse links, opening external links in new tabs. */}} +{{ .Text | safeHTML }} diff --git a/netlify.toml b/netlify.toml index fe07a84c..577497af 100644 --- a/netlify.toml +++ b/netlify.toml @@ -5,7 +5,7 @@ [build.environment] HUGO_THEME = "repo" - HUGO_VERSION = "0.60.1" + HUGO_VERSION = "0.62.2" HUGO_ENABLEGITINFO = "true" [context.production.environment] diff --git a/theme.toml b/theme.toml index ea008039..a0df2a5b 100644 --- a/theme.toml +++ b/theme.toml @@ -3,7 +3,7 @@ license = "MIT" licenselink = "https://github.com/gcushen/hugo-academic/blob/master/LICENSE.md" description = "The website builder for Hugo. Build *anything* with widgets and deploy with one click! Fully personalize your site with themes, plugins, and language packs." homepage = "https://sourcethemes.com/academic/" -min_version = "0.60" +min_version = "0.62" tags = ["widgets", "resume", "portfolio",