Get returns a versioned file using `git show` at the specified CL.
(ctx context.Context, path string, at SHA)
| 18 | |
| 19 | // Get returns a versioned file using `git show` at the specified CL. |
| 20 | func (g Git) Get(ctx context.Context, path string, at SHA) ([]byte, error) { |
| 21 | str, _, err := g.run(ctx, "show", at.String()+":"+path) |
| 22 | if err != nil { |
| 23 | return nil, err |
| 24 | } |
| 25 | return []byte(str), nil |
| 26 | } |