multilingual bool
}
+// NewPathSpecFromConfig creats a new PathSpec from the given ConfigProvider.
func NewPathSpecFromConfig(config ConfigProvider) *PathSpec {
return &PathSpec{
disablePathToLower: config.GetBool("disablePathToLower"),
}
}
+// PaginatePath returns the configured root path used for paginator pages.
func (p *PathSpec) PaginatePath() string {
return p.paginatePath
}
return newPath
}
+// URLizeAndPrep applies misc sanitation to the given URL to get it in line
+// with the Hugo standard.
func (p *PathSpec) URLizeAndPrep(in string) string {
return URLPrep(p.uglyURLs, p.URLize(in))
}
+// URLPrep applies misc sanitation to the given URL.
func URLPrep(ugly bool, in string) string {
if ugly {
x := Uglify(SanitizeURL(in))