微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

Git 预提交问题

如何解决Git 预提交问题

嗯,我在一个使用 react 的项目中,我们有自己的 git 钩子,像这样安装

mkdir -p .git/hooks && git config --local commit.template hooks/commit-msg

此外,我们将 *.po 文件i18n 库一起使用。我的问题,每次我在 po 文件中提交反斜杠时都会更改为斜杠。我正在使用 MacOS 编码。

我知道这是一个愚蠢的问题,但正在发生,我不知道如何解决

[更新]:这是钩子

# Add title above: one-line description of change tagged with JIRA
# Example:
# [POS-123456] Catch Exception thrown by CTM Client
# [NOJIRA] Remove unused Math utility class

Description & Context
=====================

# Explain what the change is (at least 1 sentence,but can be a couple paragraphs for a significant change)
# Explain why this change is necessary


Related Links
-------------

# Add links to JIRA issues,GitHub issues,and/or Confluence page,or any other links providing context.
# Example: GitHub Issue
# Issue #20

Testing Done
------------

# Describe how you have tested this change.
# If this commit is part of a multi-commit PR,you can ignore this,and fill it out in the PR description.

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。