Skip to main content

edit_msg_path

Function edit_msg_path 

Source
pub fn edit_msg_path(cwd: &str) -> PathBuf
Expand description

Get the path to the COMMIT_EDITMSG file.

Note that we use git rev-parse --git-path COMMIT_EDITMSG to resolve the path correctly. This is necessary because in a git worktree, .git is a file rather than a directory, and the actual git directory is stored elsewhere.