提问人:Jenil 提问时间:1/26/2023 最后编辑:Jenil 更新时间:1/26/2023 访问量:49
如何在 vs code 的 git commit 消息模板文件中获取修改后的文件路径
How to fetch modified files path in git commit message template file for vs code
问:
我正在尝试向我的模板文件添加一个别名,该别名会自动将当前存储库中所有修改的文件添加到提交消息中。.gitmessage.txt
我在我的项目文件夹中创建了这个文件。我正在使用 GitLens 扩展进行提交和推送
我在我的文件中写了${relativeFile}
进行获取,自动添加所有修改的文件,并使用git config commit.template .gitmessage.txt
使其成为默认的git提交消息文件.gitmessage.txt
当我提交消息时,它会提交消息${relativeFile}
(原样)
但我想要修改后的文件路径代替{relativeFiles}
我不知道我会怎么做,请帮我弄清楚。
答: 暂无答案
评论