MCPcopy Create free account
hub / github.com/52funny/pikpakcli / expandDeletePatternToken

Function expandDeletePatternToken

internal/shell/shell.go:863–871  ·  view source on GitHub ↗
(token string, pathValue string, currentPath string, source fileStatProvider)

Source from the content-addressed store, hash-verified

861}
862
863func expandDeletePatternToken(token string, pathValue string, currentPath string, source fileStatProvider) ([]string, error) {
864 if !hasWildcard(token) {
865 return []string{token}, nil
866 }
867 if pathValue != "" && !path.IsAbs(token) && strings.Contains(token, "/") {
868 return nil, fmt.Errorf("shell: wildcard expansion with -p does not support nested remote paths: %s", token)
869 }
870 return expandRemotePatternToken(token, pathValue, currentPath, source, pathValue != "")
871}
872
873func expandRemotePatternToken(token string, pathValue string, currentPath string, source fileStatProvider, preferRelative bool) ([]string, error) {
874 if !hasWildcard(token) {

Callers 1

expandDeleteGlobsFunction · 0.85

Calls 2

expandRemotePatternTokenFunction · 0.85
hasWildcardFunction · 0.70

Tested by

no test coverage detected