Fix build when using go modules (#6)
This commit is contained in:
parent
738c22b5f9
commit
321c0f2404
495 changed files with 140271 additions and 370 deletions
17
vendor/github.com/client9/misspell/url.go
generated
vendored
Normal file
17
vendor/github.com/client9/misspell/url.go
generated
vendored
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
package misspell
|
||||
|
||||
import (
|
||||
"regexp"
|
||||
)
|
||||
|
||||
// Regexp for URL https://mathiasbynens.be/demo/url-regex
|
||||
//
|
||||
// original @imme_emosol (54 chars) has trouble with dashes in hostname
|
||||
// @(https?|ftp)://(-\.)?([^\s/?\.#-]+\.?)+(/[^\s]*)?$@iS
|
||||
var reURL = regexp.MustCompile(`(?i)(https?|ftp)://(-\.)?([^\s/?\.#]+\.?)+(/[^\s]*)?`)
|
||||
|
||||
// StripURL attemps to replace URLs with blank spaces, e.g.
|
||||
// "xxx http://foo.com/ yyy -> "xxx yyyy"
|
||||
func StripURL(s string) string {
|
||||
return reURL.ReplaceAllStringFunc(s, replaceWithBlanks)
|
||||
}
|
||||
Reference in a new issue