Skip to content
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

Fix 113 #117

Open
wants to merge 16 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 7 additions & 1 deletion A-git-in-other-environments.asc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[#A-git-in-other-environments]
[[A-git-in-other-environments]]
[appendix]
//////////////////////////
== Git in Other Environments
Expand All @@ -20,8 +20,14 @@ include::book/A-git-in-other-environments/sections/guis.asc[]

include::book/A-git-in-other-environments/sections/visualstudio.asc[]

include::book/A-git-in-other-environments/sections/visualstudiocode.asc[]

include::book/A-git-in-other-environments/sections/eclipse.asc[]

include::book/A-git-in-other-environments/sections/jetbrainsides.asc[]

include::book/A-git-in-other-environments/sections/sublimetext.asc[]

include::book/A-git-in-other-environments/sections/bash.asc[]

include::book/A-git-in-other-environments/sections/zsh.asc[]
Expand Down
2 changes: 1 addition & 1 deletion book/06-github/sections/2-contributing.asc
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ After a few seconds, you'll be taken to your new project page, with your own wri
//////////////////////////
数秒後、新しいプロジェクトのページに自動的に移動します。これは、あなた自身が書き込み可能なコピーです。

[[r_github_flow]]
[[ch06-github_flow]]
//////////////////////////
==== The GitHub Flow
//////////////////////////
Expand Down
4 changes: 2 additions & 2 deletions book/06-github/sections/3-maintaining.asc
Original file line number Diff line number Diff line change
Expand Up @@ -218,10 +218,10 @@ $ curl http://github.com/tonychacon/fade/pull/1.patch | git am
===== プルリクエスト上での共同作業

//////////////////////////
As we covered in <<r_github_flow>>, you can now have a conversation with the person who opened the Pull Request.
As we covered in <<ch06-github_flow>>, you can now have a conversation with the person who opened the Pull Request.
You can comment on specific lines of code, comment on whole commits or comment on the entire Pull Request itself, using GitHub Flavored Markdown everywhere.
//////////////////////////
<<r_github_flow>> で説明したとおり、プルリクエストの作者とのやりとりができるようになりました。
<<ch06-github_flow>> で説明したとおり、プルリクエストの作者とのやりとりができるようになりました。
コードの特定の行にコメントをしたり、コミット全体やプルリクエストそのものに対してコメントしたりすることができ、
その際には GitHub Flavored Markdown が使えます。

Expand Down
12 changes: 6 additions & 6 deletions book/A-git-in-other-environments/sections/bash.asc
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ Copy it somewhere handy, like your home directory, and add this to your `.bashrc
取得したファイルをどこか適当な場所(例えばホームディレクトリ)へコピーした上で、 `.bashrc` に次の内容を追加します。

[source,console]
-----
----
. ~/git-completion.bash
-----
----

//////////////////////////
Once that's done, change your directory to a git repository, and type:
Once that's done, change your directory to a Git repository, and type:
//////////////////////////
設定が完了したら、カレントディレクトリをgitリポジトリに変更し、次のようにタイプしてみてください。
設定が完了したら、カレントディレクトリをGitリポジトリに変更し、次のようにタイプしてみてください。

[source,console]
----
Expand All @@ -50,11 +50,11 @@ To add these to your prompt, just copy the `contrib/completion/git-prompt.sh` fi
プロンプトにこれらを追加するには、Gitのソースリポジトリから `contrib/completion/git-prompt.sh` ファイルをあなたのホームディレクトリにコピーし、次のような内容を `.bashrc` に追加します。

[source,console]
-----
----
. ~/git-prompt.sh
export GIT_PS1_SHOWDIRTYSTATE=1
export PS1='\w$(__git_ps1 " (%s)")\$ '
-----
----

//////////////////////////
The `\w` means print the current working directory, the `\$` prints the `$` part of the prompt, and `__git_ps1 " (%s)"` calls the function provided by `git-prompt.sh` with a formatting argument.
Expand Down
54 changes: 28 additions & 26 deletions book/A-git-in-other-environments/sections/guis.asc
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ Gitkのインターフェイスは次のようになっています。
.The `gitk` history viewer.
image::images/gitk.png[The `gitk` history viewer.]
//////////////////////////
.`gitk`の歴史ビューアー
image::images/gitk.png[`gitk`の歴史ビューアー]
.`gitk` の歴史ビューアー
image::images/gitk.png[`gitk` の歴史ビューアー]

//////////////////////////
On the top is something that looks a bit like the output of `git log --graph`; each dot represents a commit, the lines represent parent relationships, and refs are shown as colored boxes.
Expand All @@ -96,9 +96,9 @@ It, too, is easiest to invoke from the command line:
これも、コマンドラインから起動するのが最も簡単です。

[source,console]
-----
----
$ git gui
-----
----

//////////////////////////
And it looks something like this:
Expand Down Expand Up @@ -145,17 +145,17 @@ Each of them is tailored for a specific purpose (viewing history and creating co


//////////////////////////
==== GitHub for Mac and Windows
==== GitHub for macOS and Windows
//////////////////////////
==== MacとWindows用のGitHubクライアント
==== macOSとWindows用のGitHubクライアント

(((GitHub for Mac)))(((GitHub for Windows)))
(((GitHub for macOS)))(((GitHub for Windows)))
//////////////////////////
GitHub has created two workflow-oriented Git clients: one for Windows, and one for Mac.
GitHub has created two workflow-oriented Git clients: one for Windows, and one for macOS.
These clients are a good example of workflow-oriented tools – rather than expose _all_ of Git's functionality, they instead focus on a curated set of commonly-used features that work well together.
They look like this:
//////////////////////////
GitHubは、ワークフロー指向のGitクライアントを公開しています。Windows用クライアントと、Mac用クライアントがあります
GitHubは、ワークフロー指向のGitクライアントを公開しています。Windows用クライアントと、macOS用クライアントがあります
これらのクライアントは、ワークフロー指向のツールの良い例です。Gitの機能の _すべて_ を公開するのではなく、よく使われる機能の中から一緒に使うと便利な機能を選択し、それにフォーカスしています。
表示内容は次のようになっています。

Expand All @@ -167,13 +167,15 @@ image::images/github_mac.png[GitHub for Mac.]
image::images/github_mac.png[GitHubのMac用クライアント]

//////////////////////////
.GitHub for Windows.
image::images/github_win.png[GitHub for Windows.]
.GitHub for macOS.
image::images/github_mac.png[GitHub for macOS.]
//////////////////////////
.GitHubのWindows用クライアント
image::images/github_win.png[GitHubのWindows用クライアント]

//////////////////////////
.GitHub for Windows.
image::images/github_win.png[GitHub for Windows.]
They are designed to look and work very much alike, so we'll treat them like a single product in this chapter.
We won't be doing a detailed rundown of these tools (they have their own documentation), but a quick tour of the ``changes'' view (which is where you'll spend most of your time) is in order.
//////////////////////////
Expand All @@ -183,13 +185,13 @@ We won't be doing a detailed rundown of these tools (they have their own documen
//////////////////////////
* On the left is the list of repositories the client is tracking; you can add a repository (either by cloning or attaching locally) by clicking the ``+'' icon at the top of this area.
* In the center is a commit-input area, which lets you input a commit message, and select which files should be included.
(On Windows, the commit history is displayed directly below this; on Mac, it's on a separate tab.)
(On Windows, the commit history is displayed directly below this; on macOS, it's on a separate tab.)
* On the right is a diff view, which shows what's changed in your working directory, or which changes were included in the selected commit.
* The last thing to notice is the ``Sync'' button at the top-right, which is the primary way you interact over the network.
//////////////////////////
* 左側には、クライアントが追跡しているリポジトリのリストが表示されます。この領域の一番上の ``+ '' アイコンをクリックすると、(ローカルでクローンするかアタッチするかして)リポジトリを追加できます。
* 真ん中はコミット入力領域です。コミットメッセージを入力したり、コミットに含めるファイルを選択したりできます。
(Windowsでは、コミットの歴史は、この下に直接表示されます。Macの場合は、別のタブに表示されます。)
(Windowsでは、コミットの歴史は、この下に直接表示されます。macOSの場合は、別のタブに表示されます。)
* 右側はdiffビューです。作業ディレクトリの変更内容、または、選択しているコミットに含まれている内容が表示されます。
* 最後に、右上の ``Sync'' ボタンは、ネットワーク経由で対話を行う主要な手段です。

Expand All @@ -212,16 +214,16 @@ While they're designed to highlight GitHub's service and recommended workflow, t
===== インストール

//////////////////////////
GitHub for Windows can be downloaded from https://windows.github.com[], and GitHub for Mac from https://mac.github.com[].
GitHub for Windows can be downloaded from https://windows.github.com[], and GitHub for macOS from https://mac.github.com[].
When the applications are first run, they walk you through all the first-time Git setup, such as configuring your name and email address, and both set up sane defaults for many common configuration options, such as credential caches and CRLF behavior.
//////////////////////////
Windows用のGitHubクライアントは https://windows.github.com[] から、Mac用のGitHubクライアントは https://mac.github.com[] からダウンロードできます。
Windows用のGitHubクライアントは https://windows.github.com[] から、macOS用のGitHubクライアントは https://mac.github.com[] からダウンロードできます。
クライアントを初めて実行する際には、名前やメールアドレスの設定といったGitの初期設定がひと通り行われます。また、認証情報のキャッシュやCRLFの挙動といった、一般的なオプション設定に対して、デフォルト値が設定されます。

//////////////////////////
Both are ``evergreen'' – updates are downloaded and installed in the background while the applications are open.
This helpfully includes a bundled version of Git, which means you probably won't have to worry about manually updating it again.
On Windows, the client includes a shortcut to launch Powershell with Posh-git, which we'll talk more about later in this chapter.
On Windows, the client includes a shortcut to launch PowerShell with Posh-git, which we'll talk more about later in this chapter.
//////////////////////////
これらのツールはいずれも ``新鮮'' な状態に保たれます。つまり、アプリケーションのアップデートは、アプリケーションの実行中にバックグラウンドで自動的にダウンロードされ、インストールされます。
このアップデートには、ツールに同梱されているGitも含まれています。そのため、Gitを手動で更新する心配をする必要はおそらくないと思います。
Expand All @@ -244,25 +246,25 @@ If you already have a local repository, just drag its directory from the Finder
//////////////////////////
Once it's installed and configured, you can use the GitHub client for many common Git tasks.
The intended workflow for this tool is sometimes called the ``GitHub Flow.''
We cover this in more detail in <<ch06-github#r_github_flow>>, but the general gist is that (a) you'll be committing to a branch, and (b) you'll be syncing up with a remote repository fairly regularly.
We cover this in more detail in <<ch06-github#ch06-github_flow>>, but the general gist is that (a) you'll be committing to a branch, and (b) you'll be syncing up with a remote repository fairly regularly.
//////////////////////////
インストールと設定が完了したら、GitHubクライアントを使って一般的なGitのタスクの多くが行えます。
このツールで想定されているワークフローは ``GitHub Flow'' とも呼ばれています。
この詳細は <<ch06-github#r_github_flow>> で取り上げます。要点としては、(a)コミットはブランチに対して行う、(b)定期的にリモートリポジトリと同期する、といった点があります。
この詳細は <<ch06-github#ch06-github_flow>> で取り上げます。要点としては、(a)コミットはブランチに対して行う、(b)定期的にリモートリポジトリと同期する、といった点があります。

//////////////////////////
Branch management is one of the areas where the two tools diverge.
On Mac, there's a button at the top of the window for creating a new branch:
On macOS, there's a button at the top of the window for creating a new branch:
//////////////////////////
ブランチ管理は、2つのツールで操作が異なる点の一つです。
Mac用クライアントでは、新しいブランチを作成するためのボタンがウィンドウ上部にあります。
macOS用クライアントでは、新しいブランチを作成するためのボタンがウィンドウ上部にあります。

//////////////////////////
.``Create Branch'' button on Mac.
image::images/branch_widget_mac.png[``Create Branch'' button on Mac.]
.``Create Branch'' button on macOS.
image::images/branch_widget_mac.png[``Create Branch'' button on macOS.]
//////////////////////////
.Mac用クライアントの ``Create Branch'' ボタン
image::images/branch_widget_mac.png[Mac用クライアントの ``Create Branch'' ボタン]
.macOS用クライアントの ``Create Branch'' ボタン
image::images/branch_widget_mac.png[macOS用クライアントの ``Create Branch'' ボタン]

//////////////////////////
On Windows, this is done by typing the new branch's name in the branch-switching widget:
Expand Down Expand Up @@ -330,9 +332,9 @@ However, if your workflow is different, or you want more control over how and wh

//////////////////////////
There are a number of other graphical Git clients, and they run the gamut from specialized, single-purpose tools all the way to apps that try to expose everything Git can do.
The official Git website has a curated list of the most popular clients at http://git-scm.com/downloads/guis[].
The official Git website has a curated list of the most popular clients at https://git-scm.com/downloads/guis[].
A more comprehensive list is available on the Git wiki site, at https://git.wiki.kernel.org/index.php/Interfaces,_frontends,_and_tools#Graphical_Interfaces[].
//////////////////////////
グラフィカルなGitクライアントは他にもあり、一つの目的に特化したツールから、Gitのできることは全て操作可能にしようとしているアプリケーションまで多岐に渡ります。
Gitのオフィシャルウェブサイトには、よく使われているクライアントのリストがあります。詳しくは http://git-scm.com/downloads/guis[] を参照してください。
Gitのオフィシャルウェブサイトには、よく使われているクライアントのリストがあります。詳しくは https://git-scm.com/downloads/guis[] を参照してください。
また、より包括的なリストは Git wiki のサイトに掲載されています。詳しくは https://git.wiki.kernel.org/index.php/Interfaces,_frontends,_and_tools#Graphical_Interfaces[] を参照してください。
25 changes: 25 additions & 0 deletions book/A-git-in-other-environments/sections/jetbrainsides.asc
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
//////////////////////////
=== Git in IntelliJ / PyCharm / WebStorm / PhpStorm / RubyMine
//////////////////////////
=== IntelliJ / PyCharm / WebStorm / PhpStorm / RubyMine で Gitを使う

//////////////////////////
JetBrains IDEs (such as IntelliJ IDEA, PyCharm, WebStorm, PhpStorm, RubyMine, and others) ship with a Git Integration plugin.
It provides a dedicated view in the IDE to work with Git and GitHub Pull Requests.
//////////////////////////
JetBrainsのIDE(IntelliJ IDEA、PyCharm、WebStorm、PhpStorm、RubyMine、その他のような)はGitを統合したプラグインを同梱しています。
これはGitおよびGitHubプルリクエストと連携する専用インタフェースをIDEに提供します。

//////////////////////////
.Version Control ToolWindow in JetBrains IDEs.
image::images/jb.png[Version Control ToolWindow in JetBrains IDEs.]
//////////////////////////
.JetBrains IDEのバージョン管理ウィンドウ.
image::images/jb.png[JetBrains IDEのバージョン管理ウィンドウ.]

//////////////////////////
The integration relies on the command-line git client, and requires one to be installed.
The official documentation is available at https://www.jetbrains.com/help/idea/using-git-integration.html[].
//////////////////////////
この統合プラグインはコマンドラインのgitクライアントに依存しており、gitクライアントがインストールされている必要があります。
公式ドキュメントは https://www.jetbrains.com/help/idea/using-git-integration.html[] で参照できます。