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

Function IsFlake

internal/devpkg/pkgtype/flake.go:9–21  ·  view source on GitHub ↗
(s string)

Source from the content-addressed store, hash-verified

7)
8
9func IsFlake(s string) bool {
10 if IsRunX(s) {
11 return false
12 }
13 parsed, err := flake.ParseInstallable(s)
14 if err != nil {
15 return false
16 }
17 if IsAmbiguous(s, parsed) {
18 return false
19 }
20 return true
21}
22
23// IsAmbiguous returns true if a package string could be a Devbox package or
24// a flake installable. For example, "nixpkgs" is both a Devbox package and a

Callers 4

ResolveMethod · 0.92
FetchResolvedPackageMethod · 0.92
updatePendingPackagesMethod · 0.92

Calls 3

ParseInstallableFunction · 0.92
IsAmbiguousFunction · 0.85
IsRunXFunction · 0.70

Tested by

no test coverage detected