jesseduffield / jesseduffield/lazygit
Could we make .SelectedLocalCommit.Sha support index?
Open
enhancement
- Dominant language
- Go
- Stars
- 82.4k
- Forks
- 3k
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 19
Description
**Is your feature request related to a problem?**
I'm afraid the .SelectedLocalCommit.Sha doesn't support index.
**Describe the solution you'd like**
I tried to add a custom command **git diff --name-only sha1^..sha2**
However, .SelectedLocalCommit.Sha doesn't support index like {{index .PromptResponses 0}}
I have to use an alter solution
Here is my snippets:
```
customCommands:
- key: ''
description: 'list files changed from parent commit'
command: "git diff --name-only {{.SelectedLocalCommit.Sha}}^"
context: 'commits'
subprocess: true
```
Contributor guide
Assessment
This issue has not been assessed yet.