Make Pretty Slug.
go get -u github.com/mozillazg/go-slugify
Install CLI tool:
go get -u github.com/mozillazg/go-slugify/slugify
$ slugify "北京kožušček,abc"
bei-jing-kozuscek-abc
API documentation can be found here: https://godoc.org/github.com/mozillazg/go-slugify
package main
import (
"fmt"
"github.com/mozillazg/go-slugify"
)
func main() {
s := "北京kožušček,abc"
fmt.Println(slugify.Slugify(s))
// Output: bei-jing-kozuscek-abc
}