mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-17 21:01:26 +02:00
all: Remove unused code
Using x/tools/cmd/deadcode
This commit is contained in:
@@ -32,7 +32,6 @@ import (
|
||||
"github.com/jdkato/prose/transform"
|
||||
|
||||
bp "github.com/gohugoio/hugo/bufferpool"
|
||||
"github.com/spf13/pflag"
|
||||
)
|
||||
|
||||
// FilePathSeparator as defined by os.Separator.
|
||||
@@ -317,18 +316,6 @@ func IsWhitespace(r rune) bool {
|
||||
return r == ' ' || r == '\t' || r == '\n' || r == '\r'
|
||||
}
|
||||
|
||||
// NormalizeHugoFlags facilitates transitions of Hugo command-line flags,
|
||||
// e.g. --baseUrl to --baseURL, --uglyUrls to --uglyURLs
|
||||
func NormalizeHugoFlags(f *pflag.FlagSet, name string) pflag.NormalizedName {
|
||||
switch name {
|
||||
case "baseUrl":
|
||||
name = "baseURL"
|
||||
case "uglyUrls":
|
||||
name = "uglyURLs"
|
||||
}
|
||||
return pflag.NormalizedName(name)
|
||||
}
|
||||
|
||||
// PrintFs prints the given filesystem to the given writer starting from the given path.
|
||||
// This is useful for debugging.
|
||||
func PrintFs(fs afero.Fs, path string, w io.Writer) {
|
||||
|
Reference in New Issue
Block a user