(output string)
| 285 | } |
| 286 | |
| 287 | func (p *Package) InstallableForOutput(output string) (string, error) { |
| 288 | inCache, err := p.IsOutputInBinaryCache(output) |
| 289 | if err != nil { |
| 290 | return "", err |
| 291 | } |
| 292 | |
| 293 | if inCache { |
| 294 | installable, err := p.InputAddressedPathForOutput(output) |
| 295 | if err != nil { |
| 296 | return "", err |
| 297 | } |
| 298 | return installable, nil |
| 299 | } |
| 300 | |
| 301 | // TODO savil: does this work for outputs? |
| 302 | installable, err := p.urlForInstall() |
| 303 | if err != nil { |
| 304 | return "", err |
| 305 | } |
| 306 | return installable, nil |
| 307 | } |
| 308 | |
| 309 | // FlakeInstallable returns a flake installable. The raw string must contain |
| 310 | // a valid flake reference parsable by ParseFlakeRef, optionally followed by an |
no test coverage detected