Skip to content

Commit ecd2b95

Browse files
authored
Fix for the new GitHub token match (#104)
Github token now starts with `ghp_`
1 parent 6266602 commit ecd2b95

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/github.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ func CheckGithubAPIToken(t string, sess *Session) string {
153153
}
154154

155155
// match only letters and numbers and ensure you match 40
156-
exp1 := regexp.MustCompile(`^[A-Za-z0-9]{40}`)
156+
exp1 := regexp.MustCompile(`[A-Za-z0-9\_]{40}`)
157157
if !exp1.MatchString(t) {
158158
sess.Out.Error("The token is invalid. Please use a valid Github token\n")
159159
os.Exit(2)

0 commit comments

Comments
 (0)