Documentation ¶
Index ¶
- func ArgsToCmdResults(cmd *goNixArgParser.Command, args []string) (results []*goNixArgParser.ParseResult, printVersion, printHelp bool, ...)
- func EntriesToKVs(entries []string) [][2]string
- func NewCliCmd() *goNixArgParser.Command
- func NormalizeFsPaths(inputs []string) []string
- func NormalizeRedirectCode(code int) int
- func NormalizeUrlPaths(inputs []string) []string
- func PrintHelp()
- func SplitAllKeyValue(inputs []string) (results [][2]string)
- func SplitAllKeyValues(inputs []string) (results [][]string)
- func SplitKeyValue(input string) (k, v string, ok bool)
- func SplitKeyValues(input string) (key string, values []string, ok bool)
- type Param
- type Params
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ArgsToCmdResults ¶ added in v1.15.2
func ArgsToCmdResults(cmd *goNixArgParser.Command, args []string) (results []*goNixArgParser.ParseResult, printVersion, printHelp bool, errs []error)
func EntriesToKVs ¶ added in v1.15.3
EntriesToKVs input element: "key:value" output element: [2]string{"key, "value"}
func NewCliCmd ¶ added in v1.15.2
func NewCliCmd() *goNixArgParser.Command
func NormalizeFsPaths ¶ added in v1.15.3
func NormalizeRedirectCode ¶ added in v1.15.3
func NormalizeUrlPaths ¶ added in v1.15.3
func SplitAllKeyValue ¶ added in v1.15.3
func SplitAllKeyValues ¶ added in v1.15.3
func SplitKeyValue ¶ added in v1.15.3
SplitKeyValue input format: <sep><key><sep><value>
Types ¶
type Param ¶
type Param struct { Root string EmptyRoot bool PrefixUrls []string ForceDirSlash int DefaultSort string DirIndexes []string // value: [url-path, fs-path] Aliases [][2]string GlobalRestrictAccess []string // value: [restrict-path, allow-hosts...] RestrictAccessUrls [][]string RestrictAccessDirs [][]string // value: [name, value] GlobalHeaders [][2]string // value: [path, (name, value)...] HeadersUrls [][]string HeadersDirs [][]string GlobalUpload bool UploadUrls []string UploadDirs []string GlobalMkdir bool MkdirUrls []string MkdirDirs []string GlobalDelete bool DeleteUrls []string DeleteDirs []string GlobalArchive bool ArchiveUrls []string ArchiveDirs []string GlobalCors bool CorsUrls []string CorsDirs []string GlobalAuth bool AuthUrls []string AuthDirs []string // value: [username, password] UsersPlain [][2]string UsersBase64 [][2]string UsersMd5 [][2]string UsersSha1 [][2]string UsersSha256 [][2]string UsersSha512 [][2]string UserMatchCase bool Certificates []tls.Certificate Listens []string ListensPlain []string ListensTLS []string HostNames []string Theme string ThemeDir string GlobalHsts bool GlobalHttps bool HttpsPort string Shows []string ShowDirs []string ShowFiles []string Hides []string HideDirs []string HideFiles []string AccessLog string ErrorLog string PreMiddlewares []middleware.Middleware PostMiddlewares []middleware.Middleware }
type Params ¶ added in v1.15.2
type Params []*Param
func CmdResultsToParams ¶ added in v1.15.2
func CmdResultsToParams(results []*goNixArgParser.ParseResult) (params Params, errs []error)
func ParseFromCli ¶ added in v1.15.1
Click to show internal directories.
Click to hide internal directories.