V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
git
Pro Git
Atlassian Git Tutorial
Pro Git 简体中文翻译
GitX
Livid
V2EX  ›  git

每次 git commit 的 message(英文)的末尾是否需要英文的句号呢?

  •  
  •   Livid · 2013-08-27 04:18:57 +08:00 · 5187 次点击
    这是一个创建于 3896 天前的主题,其中的信息可能已经有所发展或是发生改变。
    其实这是我自从开始用版本控制系统就一直纠结的一个问题。
    25 条回复    1970-01-01 08:00:00 +08:00
    yangqi
        1
    yangqi  
       2013-08-27 04:29:12 +08:00
    这个真的不重要,跟着你的感觉走,实在不行就掷硬币
    jjgod
        2
    jjgod  
       2013-08-27 05:09:58 +08:00   ❤️ 1
    message 不加,description 要加。
    lightening
        3
    lightening  
       2013-08-27 05:41:46 +08:00   ❤️ 1
    不需要。我的 commit message 不是完整的句子。(一般缺主语)
    aveline
        4
    aveline  
       2013-08-27 06:03:32 +08:00
    一般不加,看個人習慣吧。

    我一般是這麼寫 Commit Message 的,不知道其他人怎麼寫。。。

    thedevil5032
        5
    thedevil5032  
       2013-08-27 06:23:37 +08:00 via iPad
    果断加,丢不掉的强迫症,哈哈。
    wwqgtxx
        6
    wwqgtxx  
       2013-08-27 06:33:53 +08:00 via Android
    从来不加
    jianghu52
        7
    jianghu52  
       2013-08-27 08:27:18 +08:00
    我自己用的git版本都是写中文的。
    alexrezit
        8
    alexrezit  
       2013-08-27 08:35:56 +08:00
    我都加了.
    hustlzp
        9
    hustlzp  
       2013-08-27 08:40:04 +08:00
    不加
    013231
        10
    013231  
       2013-08-27 08:54:18 +08:00
    如果message是個完整的句子就加句號, 不是就不加.
    wy315700
        11
    wy315700  
       2013-08-27 08:57:13 +08:00
    @jianghu52 中文+1 看得懂最重要
    rrrrutdk
        12
    rrrrutdk  
       2013-08-27 09:06:01 +08:00   ❤️ 1
    把Git Commit Message当成一封邮件看待,首行为标题。
    raptor
        13
    raptor  
       2013-08-27 09:11:54 +08:00
    不加
    Keyes
        14
    Keyes  
       2013-08-27 09:14:03 +08:00
    <改动类型>:<详细说明>

    改动类型:新功能、功能增强、BUG-FIX等
    详细说明:字面意思

    一句话无标点不加句号
    一句话以上加句号
    toctan
        15
    toctan  
       2013-08-27 09:17:43 +08:00   ❤️ 1
    DO

    - Write the summary line and description of what you have done in the imperative mode, that is as if you were commanding someone. Write “fix”, “add”, “change” instead of “fixed”, “added”, “changed”.
    - Always leave the second line blank.
    - Line break the commit message (to make the commit message readable without having to scroll horizontally in gitk).

    DON’T

    - Don’t end the summary line with a period.

    https://github.com/erlang/otp/wiki/Writing-good-commit-messages
    http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html
    dalang
        16
    dalang  
       2013-08-27 09:22:40 +08:00
    @aveline 请问截图的软件叫什么名字?
    NemoAlex
        17
    NemoAlex  
       2013-08-27 09:23:58 +08:00
    @dalang 这个目测是用QQ截的
    dalang
        18
    dalang  
       2013-08-27 09:27:29 +08:00
    @NemoAlex
    @aveline
    抱歉问得有点歧义了,我是问截图里的git客户端软件叫什么名字?
    toctan
        19
    toctan  
       2013-08-27 09:29:47 +08:00
    @Keyes 更加适当的格式:

    Capitalized, short (50 chars or less) summary

    More detailed explanatory text, if necessary. Wrap it to about 72
    characters or so. In some contexts, the first line is treated as the
    subject of an email and the rest of the text as the body. The blank
    line separating the summary from the body is critical (unless you omit
    the body entirely); tools like rebase can get confused if you run the
    two together.

    Write your commit message in the imperative: "Fix bug" and not "Fixed bug"
    or "Fixes bug." This convention matches up with commit messages generated
    by commands like git merge and git revert.

    Further paragraphs come after blank lines.

    - Bullet points are okay, too

    - Typically a hyphen or asterisk is used for the bullet, preceded by a
    single space, with blank lines in between, but conventions vary here

    - Use a hanging indent

    http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html
    NemoAlex
        20
    NemoAlex  
       2013-08-27 09:29:49 +08:00
    @dalang http://www.sourcetreeapp.com/
    OS X 平台最棒的免费 Git/Mercurial GUI 工具
    CoX
        21
    CoX  
       2013-08-27 09:41:30 +08:00
    我个人习惯是写上bug号~~
    aveline
        22
    aveline  
       2013-08-27 09:53:28 +08:00
    @dalang SourceTree,Atlassian 家的,Windows 下也有客戶端,非常好用。
    vibbow
        23
    vibbow  
       2013-08-27 14:06:32 +08:00
    @aveline 擦,SourceTree在Mac下那么好看...
    vibbow
        24
    vibbow  
       2013-08-27 14:08:22 +08:00
    @jianghu52 @wy315700 我的git服务器都在本地。
    所以也果断中文啊...
    ssword
        25
    ssword  
       2013-08-27 21:10:01 +08:00 via Android
    第一句相当于标题
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   2636 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 04:37 · PVG 12:37 · LAX 21:37 · JFK 00:37
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.