(ctx context.Context)
| 733 | } |
| 734 | |
| 735 | func (c *Client) GitDir(ctx context.Context) (string, error) { |
| 736 | out, err := c.revParse(ctx, "--git-dir") |
| 737 | if err != nil { |
| 738 | return "", err |
| 739 | } |
| 740 | return firstLine(out), nil |
| 741 | } |
| 742 | |
| 743 | // Show current directory relative to the top-level directory of repository. |
| 744 | func (c *Client) PathFromRoot(ctx context.Context) string { |