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

Method Resolve

internal/devpkg/package_test.go:125–139  ·  view source on GitHub ↗
(pkg string)

Source from the content-addressed store, hash-verified

123}
124
125func (l *lockfile) Resolve(pkg string) (*lock.Package, error) {
126 switch {
127 case strings.Contains(pkg, "path:"):
128 return &lock.Package{Resolved: pkg}, nil
129 case strings.Contains(pkg, "github:"):
130 return &lock.Package{Resolved: pkg}, nil
131 default:
132 return &lock.Package{
133 Resolved: flake.Installable{
134 Ref: l.Stdenv(),
135 AttrPath: pkg,
136 }.String(),
137 }, nil
138 }
139}
140
141func testInputFromString(s, projectDir string) *testInput {
142 return lo.ToPtr(testInput{Package: PackageFromStringWithDefaults(s, &lockfile{projectDir})})

Callers

nothing calls this directly

Calls 2

StdenvMethod · 0.95
StringMethod · 0.45

Tested by

no test coverage detected