(key string)
| 66 | } |
| 67 | |
| 68 | func (c RunLogCache) Open(key string) (*zip.ReadCloser, error) { |
| 69 | r, err := zip.OpenReader(c.filepath(key)) |
| 70 | if err != nil { |
| 71 | return nil, fmt.Errorf("opening cache entry: %v", err) |
| 72 | } |
| 73 | |
| 74 | return r, nil |
| 75 | } |
| 76 | |
| 77 | func (c RunLogCache) filepath(key string) string { |
| 78 | return filepath.Join(c.cacheDir, fmt.Sprintf("run-log-%s.zip", key)) |