Replaces underscores with "%5F" (hex code for underscores) in links (only of http, https, ftp and mailto type). - Fixes https://github.com/kaushalmodi/ox-hugo/issues/170. Revert his commit once https://github.com/russross/blackfriday/issues/278 gets fixed.master
parent
b350b8772c
commit
ad98ebf498
10 changed files with 97 additions and 13 deletions
@ -0,0 +1,12 @@ |
||||
#+title: Post with underscore in name |
||||
#+author: |
||||
#+date: 2017-07-20 |
||||
|
||||
#+hugo_base_dir: ../../ |
||||
#+hugo_section: singles |
||||
#+hugo_tags: "cross-link" |
||||
#+description: Test post to test another ox-hugo test. |
||||
|
||||
This test post is created to test [{{< relref |
||||
"italicize-links-with-underscores" >}}]({{< relref |
||||
"italicize-links-with-underscores" >}}). |
||||
@ -0,0 +1,32 @@ |
||||
+++ |
||||
title = "Italicize links with underscores" |
||||
description = "Test that links with underscores can be italicized/emboldened/both." |
||||
tags = ["body", "italic", "links", "underscore"] |
||||
draft = false |
||||
+++ |
||||
|
||||
`ox-hugo` Issue #[170](https://github.com/kaushalmodi/ox-hugo/issues/170) |
||||
|
||||
|
||||
## External links {#external-links} |
||||
|
||||
Italic |
||||
: _What is a [two's complement](https://en.wikipedia.org/wiki/Two%27s%5Fcomplement)?_ |
||||
|
||||
Bold |
||||
: **What is a [two's complement](https://en.wikipedia.org/wiki/Two%27s%5Fcomplement)?** |
||||
|
||||
Bold + Italic |
||||
: _**What is a [two's complement](https://en.wikipedia.org/wiki/Two%27s%5Fcomplement)?**_ |
||||
|
||||
|
||||
## Internal links {#internal-links} |
||||
|
||||
Italic |
||||
: _Link to [another post on this site]({{< relref "post_with_underscore_in_name" >}})?_ |
||||
|
||||
Bold |
||||
: **Link to [another post on this site]({{< relref "post_with_underscore_in_name" >}})?** |
||||
|
||||
Bold + Italic |
||||
: _**Link to [another post on this site]({{< relref "post_with_underscore_in_name" >}})?**_ |
||||
@ -0,0 +1,11 @@ |
||||
+++ |
||||
title = "Post with underscore in name" |
||||
description = "Test post to test another ox-hugo test." |
||||
date = 2017-07-20 |
||||
tags = ["cross-link"] |
||||
draft = false |
||||
+++ |
||||
|
||||
This test post is created to test [{{< relref |
||||
"italicize-links-with-underscores" >}}]({{< relref |
||||
"italicize-links-with-underscores" >}}). |
||||
Loading…
Reference in new issue