()
| 222 | } |
| 223 | |
| 224 | func (e *Extension) loadManifest() (binManifest, error) { |
| 225 | var bm binManifest |
| 226 | dir, _ := filepath.Split(e.Path()) |
| 227 | manifestPath := filepath.Join(dir, manifestName) |
| 228 | manifest, err := os.ReadFile(manifestPath) |
| 229 | if err != nil { |
| 230 | return bm, fmt.Errorf("could not open %s for reading: %w", manifestPath, err) |
| 231 | } |
| 232 | err = yaml.Unmarshal(manifest, &bm) |
| 233 | if err != nil { |
| 234 | return bm, fmt.Errorf("could not parse %s: %w", manifestPath, err) |
| 235 | } |
| 236 | return bm, nil |
| 237 | } |