Files
moby/pkg/system/args_windows.go
Sebastiaan van Stijn 63bada41e5 pkg/system: deprecate EscapeArgs and move internal
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
2025-07-12 19:49:22 +02:00

19 lines
432 B
Go

package system
import (
"strings"
"golang.org/x/sys/windows"
)
// EscapeArgs makes a Windows-style escaped command line from a set of arguments
//
// Deprecated: this function is no longer used and will be removed in the next release.
func EscapeArgs(args []string) string {
escapedArgs := make([]string, len(args))
for i, a := range args {
escapedArgs[i] = windows.EscapeArg(a)
}
return strings.Join(escapedArgs, " ")
}