I'm trying to write a commit-msg script that calls a powershell script with the commit message passed in as a parameter.
So far I am able to execute the powershell script with parameters, but I cannot figure out how to access the commit message inside of commit-msg. Since the commit isn't completed yet, I cannot use the log. What other options are there?
Here is the code I have in commit-msg so far:
exec c:/Windows/System32/WindowsPowerShell/v1.0/powershell.exe -Command "& {C:/Windows/System32/WindowsPowerShell/git-pre-commit.ps1 '{the_git_commit_message}'}"