Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // RegexForGitHTTP defines a regular expression with capture groups that can be used to parse/validate // HTTP(S) URLs RegexForGitHTTP = fmt.Sprintf( `^(?P<%s>http[s]*)\:\/\/`+ `(?:(?P<%s>[a-zA-Z0-9\_\.\-]+)`+ `(?:\:(?P<%s>.*))?@)*`+ `(?P<%s>[a-zA-Z0-9\.\-\_]+)`+ `(?:\:(?P<%s>\d+?))?\/`+ `(?P<%s>[a-zA-Z0-9\.\-\_]+)\/`+ `(?P<%s>[a-zA-Z0-9\/\.\-\_]+)`+ `\.git$`, keySchema, keyUsername, keyPassword, keyHostname, keyPort, keyUser, keyPath, ) // RegexForGitSSH defines a regular expression with capture groups that can be used to parse/validate // SSH URLs RegexForGitSSH = fmt.Sprintf( `^(?P<%s>[a-zA-Z0-9\-\_\.]+?)@`+ `(?P<%s>[a-zA-Z0-9\-\_\.]+?):`+ `(?:(?P<%s>\d*?)\/)?`+ `(?P<%s>[a-zA-Z0-9\-\_\.]+)\/`+ `(?P<%s>[a-zA-Z0-9\-\_\.\/]+?)`+ `\.git$`, keyUsername, keyHostname, keyPort, keyUser, keyPath, ) )
Functions ¶
func IsGitHTTPUrl ¶
IsGitHTTPUrl is used for testing if a provided :test string is a valid HTTP(S) URL
func IsGitSSHUrl ¶
IsGitSSHUrl is used for testing if a provided :test string is a valid SSH URL
Types ¶
Click to show internal directories.
Click to hide internal directories.