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