File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -54,6 +54,10 @@ func init() {
5454 githubRepo = os .Getenv ("GITHUB_REPO" )
5555 githubAPIEndpoint = os .Getenv ("GITHUB_API" )
5656
57+ if githubAPIEndpoint == "" {
58+ githubAPIEndpoint = "https://api.github.com"
59+ }
60+
5761 flag .BoolVar (& verFlag , "version" , false , "-version" )
5862 flag .Parse ()
5963}
@@ -113,7 +117,7 @@ Please refer to https://help.github.com/articles/creating-an-access-token-for-co
113117
114118 githubUser = userRepo [0 ]
115119 githubRepo = userRepo [1 ]
116- githubAPIEndpoint = fmt .Sprintf ("https://api.github.com/ repos/%s/%s" , githubUser , githubRepo )
120+ githubAPIEndpoint = fmt .Sprintf ("%s/ repos/%s/%s" , githubAPIEndpoint , githubUser , githubRepo )
117121
118122 if debug {
119123 log .Println ("Glob pattern received: " )
You can’t perform that action at this time.
0 commit comments