Add Makefile / .drone.yml, use go module with vendor (#20)

* add Makefile / .drone.yml, use go module with vendor

* Update .drone.yml

Co-Authored-By: lunny <xiaolunwen@gmail.com>
This commit is contained in:
Lunny Xiao
2019-04-26 01:06:53 +08:00
committed by Lauris BH
parent b924cd5296
commit d4f107b710
130 changed files with 23280 additions and 17 deletions

View File

@ -10,9 +10,11 @@ var (
protocolRe = regexp.MustCompile("^[a-zA-Z_+-]+://")
)
// URLParser represents a git URL parser
type URLParser struct {
}
// Parse parses the git URL
func (p *URLParser) Parse(rawURL string) (u *url.URL, err error) {
if !protocolRe.MatchString(rawURL) &&
strings.Contains(rawURL, ":") &&
@ -37,6 +39,7 @@ func (p *URLParser) Parse(rawURL string) (u *url.URL, err error) {
return
}
// ParseURL parses URL string and return URL struct
func ParseURL(rawURL string) (u *url.URL, err error) {
p := &URLParser{}
return p.Parse(rawURL)

View File

@ -4,6 +4,7 @@
package setting
// App related variables
var (
AppVer string
AppBuiltWith string