Skip to content

Translate 07-git-tools interactive-staging v2 #164

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Aug 14, 2015

Conversation

networm
Copy link
Member

@networm networm commented Jul 3, 2015

No description provided.

@networm networm changed the title Translate 07-git-tools interactive-staging Translate 07-git-tools interactive-staging v2 Jul 3, 2015
@networm networm mentioned this pull request Jul 29, 2015
95 tasks
@networm networm modified the milestone: v1.0.0 Jul 29, 2015
These tools are very helpful if you modify a bunch of files and then decide that you want those changes to be in several focused commits rather than one big messy commit.
This way, you can make sure your commits are logically separate changesets and can be easily reviewed by the developers working with you.
If you run `git add` with the `-i` or `--interactive` option, Git goes into an interactive shell mode, displaying something like this:
Git 自带一些可以使命令行工作更容易的脚本。
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Git 自带的一些脚本可以使命令行工作更加容易

@IceNature
Copy link
Contributor

@networm 已完成

@networm
Copy link
Member Author

networm commented Aug 3, 2015

@IceNature 已修正。

@IceNature
Copy link
Contributor

You can see that this command shows you a much different view of your staging area – basically the same information you get with git status but a bit more succinct and informative.

@networm 但是扩折号后面说基本上相同,前面又是much different,不觉得有点冲突了吗?
different 是不是指的是文件的不同,修改前后的差异?

邮件回复为嘛没有显示……手机没办法添加行注释,只能回复到这了

@networm
Copy link
Member Author

networm commented Aug 3, 2015

@IceNature 不冲突,就是说你修改的文件还是那几个,但是会以什么样的方式显示出来有所不同,这个视图左侧加了几个 M + - 符号之类的,git status 里面的没有,就这个意思。

@IceNature
Copy link
Contributor

@networm 明白了

If you run `git add` with the `-i` or `--interactive` option, Git goes into an interactive shell mode, displaying something like this:
Git 自带的一些脚本可以使命令行工作更加容易。
本节的几个互交命令可以帮助你将文件的特定部分组合成提交。
当想要修改一组文件来将不同的改动放到几个提交中,而不是放在一个大的混乱的提交中时,这几个工具会非常有用。
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

当你修改一组文件后希望这些改动能放到若干提交而不是混杂在一起成为一个提交时...

@networm
Copy link
Member Author

networm commented Aug 8, 2015

@byr-gdp 能将此节完整审校吗?

These tools are very helpful if you modify a bunch of files and then decide that you want those changes to be in several focused commits rather than one big messy commit.
This way, you can make sure your commits are logically separate changesets and can be easily reviewed by the developers working with you.
If you run `git add` with the `-i` or `--interactive` option, Git goes into an interactive shell mode, displaying something like this:
Git 自带的一些脚本可以使命令行工作更加容易。
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Git 自带的一些脚本可以使在命令行下工作更容易。

You have a lot of options at this point.
Typing `?` shows a list of what you can do:
这时有很多选项。
输入 `?` 显示所有可以做的列表:
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

输入 ? 显示所有可以使用的命令列表:

@jeffsui
Copy link

jeffsui commented Aug 11, 2015

@networm #164 审校完毕

@networm
Copy link
Member Author

networm commented Aug 11, 2015

@jeffsui 已修正。

@0xinhua
Copy link

0xinhua commented Aug 11, 2015

2+=== 交互式暂存
3
-Git comes with a couple of scripts that make some command-line tasks easier.
-Here, you’ll look at a few interactive commands that can help you easily craft your commits to include only certain combinations and parts of files.
+Git 自带一些可以使命令行工作更容易的脚本。
+这里,你会看到几个交互命令,用来帮助你将文件的特定部分组合成你的提交。

+Git 自带一些让命令行运行更简单的脚本。
+这里,你将会看到几个交互命令,可以巧妙地帮你提交你确定的部分和某些文件。
我的理解:脚本让命令行运行起来更简单,easily craft我加上了翻译,only certain 应该是指你确定的那个部分。仅供参考!谢谢!

Git 也可以暂存文件的特定部分。
例如,如果在 simplegit.rb 文件中做了两处修改,但只想要暂存其中的一个而不是另一个,Git 会帮你轻松地完成。
从交互式提示符中,输入 `5` `p`(补丁)。
Git 询问想要部分暂存哪些文件;然后,对已选择文件的每一个部分,它都会显示文件区别块并询问是否想要暂存它们,一个接一个地:
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+Git 会询问你想要部分暂存哪些文件;然后,对已选择文件的每一个部分,它都会一个个地显示文件区别并询问你是否想要暂存它们:

@0xinhua
Copy link

0xinhua commented Aug 13, 2015

@networm 已审核完#164

@@ -53,8 +53,8 @@ Update>> 1,2
Update>>
----

The `*` next to each file means the file is selected to be staged.
If you press Enter after typing nothing at the `Update>>` prompt, Git takes anything selected and stages it for you:
每个文件前面的 `*` 意味着这个文件将会被暂存。
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+每个文件前面的 * 意味着选中的文件将会被暂存。

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我觉原文翻译的没问题,你这个说法更容易理解一点。

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

同意

@0xinhua
Copy link

0xinhua commented Aug 13, 2015

@networm #164 重新看了一遍 有3个异议,已完成审校!

@networm
Copy link
Member Author

networm commented Aug 14, 2015

@M1sery 已修正。

networm added a commit that referenced this pull request Aug 14, 2015
Translate 07-git-tools interactive-staging
@networm networm merged commit dfe80e4 into progit:master Aug 14, 2015
@networm
Copy link
Member Author

networm commented Aug 14, 2015

@IceNature @jeffsui @M1sery 已合并入主干。

@0xinhua
Copy link

0xinhua commented Aug 14, 2015

@networm 好的!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants