MCPcopy Index your code
hub / github.com/jetify-com/devbox / buildEscapedPath

Function buildEscapedPath

nix/flake/flakeref.go:544–550  ·  view source on GitHub ↗

buildEscapedPath escapes and joins path elements for a URL flake ref. The resulting path is cleaned according to url.JoinPath.

(elem ...string)

Source from the content-addressed store, hash-verified

542// buildEscapedPath escapes and joins path elements for a URL flake ref. The
543// resulting path is cleaned according to url.JoinPath.
544func buildEscapedPath(elem ...string) string {
545 for i := range elem {
546 elem[i] = url.PathEscape(elem[i])
547 }
548 u := &url.URL{}
549 return u.JoinPath(elem...).String()
550}
551
552// appendQueryString builds a URL query string from a list of key-value string
553// pairs, omitting any keys with empty values.

Callers 1

StringMethod · 0.85

Calls 1

StringMethod · 0.45

Tested by

no test coverage detected