gpt4 book ai didi

mercurial - 在 mercurial 中使用文件指定的提交消息标记修订?

转载 作者:行者123 更新时间:2023-12-04 06:30:32 26 4
gpt4 key购买 nike

是否可以使用消息文件而不只是 -m 来标记 Mercurial 中的修订版?指定消息的参数?

最佳答案

在 *nix 或 Cygwin 上,您可以使用反引号技巧:

bash-4.1$ hg init test
bash-4.1$ cd test
bash-4.1$ echo something > a
bash-4.1$ hg ci -A -m "First commit."
adding a
bash-4.1$ echo "Custom tag message" > msg.txt
bash-4.1$ hg tag mytag -m "`cat msg.txt`" # tag message from file
bash-4.1$ hg tags
tip 1:1b6138117d00
mytag 0:679f354e7ec1
bash-4.1$ hg log
changeset: 1:1b6138117d00
tag: tip
user: gavin
date: Tue Mar 29 21:43:55 2011 -0500
summary: Custom tag message

changeset: 0:679f354e7ec1
tag: mytag
user: gavin
date: Tue Mar 29 21:43:22 2011 -0500
summary: First commit.

关于mercurial - 在 mercurial 中使用文件指定的提交消息标记修订?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5478123/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com