package main
import (
"regexp"
"fmt"
)
func main() {
var re = regexp.MustCompile(`(?m)https\:\/\/www\.bugaboo\.com\/(nl|de|us|gb|es)-.{2}\/(campingbedje|reisebett|travel\-cot|play\-yard|cuna\-de\-viaje)\/`)
var str = `NL
https://www.bugaboo.com/nl-nl/campingbedje/
https://www.bugaboo.com/nl-en/travel-cot/
DE
https://www.bugaboo.com/de-de/reisebett/
https://www.bugaboo.com/de-en/travel-cot/
US
https://www.bugaboo.com/us-en/play-yard/
https://www.bugaboo.com/us-es/play-yard/
GB
https://www.bugaboo.com/gb-en/travel-cot/
ES
https://www.bugaboo.com/es-es/cuna-de-viaje/
https://www.bugaboo.com/es-en/travel-cot/
`
var substitution = ""
fmt.Println(re.ReplaceAllString(str, substitution))
}
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for Golang, please visit: https://golang.org/pkg/regexp/