aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/github.com/shurcooL/sanitized_anchor_name
diff options
context:
space:
mode:
authorLauris BH <lauris@nix.lv>2019-10-31 03:06:25 +0200
committerzeripath <art27@cantab.net>2019-10-31 01:06:25 +0000
commit086a46994a9f59ba06bfacdf2041817ef2f6671c (patch)
tree1a54a4b9f74d2a1c8a3827f24dec2fb77b8a3554 /vendor/github.com/shurcooL/sanitized_anchor_name
parent690a8ec502ff2e162b6db9cfe1f0555cf6b37323 (diff)
downloadgitea-086a46994a9f59ba06bfacdf2041817ef2f6671c.tar.gz
gitea-086a46994a9f59ba06bfacdf2041817ef2f6671c.zip
Rewrite markdown rendering to blackfriday v2 and rewrite orgmode rendering to go-org (#8560)
* Rewrite markdown rendering to blackfriday v2.0 * Fix style * Fix go mod with golang 1.13 * Fix blackfriday v2 import * Inital orgmode renderer migration to go-org * Vendor go-org dependency * Ignore errors :/ * Update go-org to latest version * Update test * Fix go-org test * Remove unneeded code * Fix comments * Fix markdown test * Fix blackfriday regression rendering HTML block
Diffstat (limited to 'vendor/github.com/shurcooL/sanitized_anchor_name')
-rw-r--r--vendor/github.com/shurcooL/sanitized_anchor_name/.travis.yml6
-rw-r--r--vendor/github.com/shurcooL/sanitized_anchor_name/LICENSE10
-rw-r--r--vendor/github.com/shurcooL/sanitized_anchor_name/README.md6
-rw-r--r--vendor/github.com/shurcooL/sanitized_anchor_name/go.mod1
-rw-r--r--vendor/github.com/shurcooL/sanitized_anchor_name/main.go2
5 files changed, 15 insertions, 10 deletions
diff --git a/vendor/github.com/shurcooL/sanitized_anchor_name/.travis.yml b/vendor/github.com/shurcooL/sanitized_anchor_name/.travis.yml
index f51cf6aea4..93b1fcdb31 100644
--- a/vendor/github.com/shurcooL/sanitized_anchor_name/.travis.yml
+++ b/vendor/github.com/shurcooL/sanitized_anchor_name/.travis.yml
@@ -1,11 +1,11 @@
sudo: false
language: go
go:
- - 1.7
- - tip
+ - 1.x
+ - master
matrix:
allow_failures:
- - go: tip
+ - go: master
fast_finish: true
install:
- # Do nothing. This is needed to prevent default install action "go get -t -v ./..." from happening here (we want it to happen inside script step).
diff --git a/vendor/github.com/shurcooL/sanitized_anchor_name/LICENSE b/vendor/github.com/shurcooL/sanitized_anchor_name/LICENSE
index 5f4e3ed57a..c35c17af98 100644
--- a/vendor/github.com/shurcooL/sanitized_anchor_name/LICENSE
+++ b/vendor/github.com/shurcooL/sanitized_anchor_name/LICENSE
@@ -1,3 +1,5 @@
+MIT License
+
Copyright (c) 2015 Dmitri Shuralyov
Permission is hereby granted, free of charge, to any person obtaining a copy
@@ -7,13 +9,13 @@ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/vendor/github.com/shurcooL/sanitized_anchor_name/README.md b/vendor/github.com/shurcooL/sanitized_anchor_name/README.md
index 8c714bcfa9..670bf0fe6c 100644
--- a/vendor/github.com/shurcooL/sanitized_anchor_name/README.md
+++ b/vendor/github.com/shurcooL/sanitized_anchor_name/README.md
@@ -5,9 +5,11 @@ sanitized_anchor_name
Package sanitized_anchor_name provides a func to create sanitized anchor names.
-Its logic can be reused by multiple packages to create interoperable anchor names and links to those anchors.
+Its logic can be reused by multiple packages to create interoperable anchor names
+and links to those anchors.
-At this time, it does not try to ensure that generated anchor names are unique, that responsibility falls on the caller.
+At this time, it does not try to ensure that generated anchor names
+are unique, that responsibility falls on the caller.
Installation
------------
diff --git a/vendor/github.com/shurcooL/sanitized_anchor_name/go.mod b/vendor/github.com/shurcooL/sanitized_anchor_name/go.mod
new file mode 100644
index 0000000000..1e25534759
--- /dev/null
+++ b/vendor/github.com/shurcooL/sanitized_anchor_name/go.mod
@@ -0,0 +1 @@
+module github.com/shurcooL/sanitized_anchor_name
diff --git a/vendor/github.com/shurcooL/sanitized_anchor_name/main.go b/vendor/github.com/shurcooL/sanitized_anchor_name/main.go
index 72a8753509..6a77d12431 100644
--- a/vendor/github.com/shurcooL/sanitized_anchor_name/main.go
+++ b/vendor/github.com/shurcooL/sanitized_anchor_name/main.go
@@ -13,7 +13,7 @@ import "unicode"
func Create(text string) string {
var anchorName []rune
var futureDash = false
- for _, r := range []rune(text) {
+ for _, r := range text {
switch {
case unicode.IsLetter(r) || unicode.IsNumber(r):
if futureDash && len(anchorName) > 0 {