Fix up regex to escape dot in URL
This commit is contained in:
parent
28b3b2c9e7
commit
212993632b
2 changed files with 2 additions and 2 deletions
|
|
@ -431,7 +431,7 @@ func createRun(opts *CreateOptions) error {
|
|||
pushTries := 0
|
||||
maxPushTries := 3
|
||||
for {
|
||||
regexp := regexp.MustCompile("^remote: (|Create a pull request for '.*' on GitHub by visiting:.*|.*https://github.com/.*/pull/new/.*)$")
|
||||
regexp := regexp.MustCompile("^remote: (|Create a pull request for '.*' on GitHub by visiting:.*|.*https://github\\.com/.*/pull/new/.*)$")
|
||||
cmdErr := NewRegexWriter(os.Stderr, regexp, "")
|
||||
cmdOut := os.Stdout
|
||||
if err := git.Push(headRemote.Name, fmt.Sprintf("HEAD:%s", headBranch), cmdOut, cmdErr); err != nil {
|
||||
|
|
|
|||
|
|
@ -114,7 +114,7 @@ func Test_Write(t *testing.T) {
|
|||
remote:
|
||||
output: more information
|
||||
`),
|
||||
regexp: regexp.MustCompile("^remote: (|Create a pull request for '.*' on GitHub by visiting:.*|.*https://github.com/.*/pull/new/.*)$"),
|
||||
regexp: regexp.MustCompile("^remote: (|Create a pull request for '.*' on GitHub by visiting:.*|.*https://github\\.com/.*/pull/new/.*)$"),
|
||||
repl: "",
|
||||
},
|
||||
output: output{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue