Git
2022-05-04 (水) 09:09:10
Git とは †
- 分散型のバージョン管理ツール
- DVCS (Distributed Version Control System)
Gitの特徴 †
- ローカルリポジトリ
Gitの機能 †
関連サービス †
Gitクライアント †
- Sourcetree -Atlassian
- TortoiseGit
- Git Bash
Gitを使った開発モデル †
- Git Flow
- GitHub Flow
- フォークを使わないフロー
- masterブランチはデプロイできる状態を保つ
- masterブランチからタスクの内容がわかる名前のブランチを作り、そこで開発を行う
- コミットの単位をレビュアーが分かりやすい単位で行ってPullRequestする。
- タスクの目的の修正と既存のコードの改善や整形はコミットを分ける。
Gitコマンド †
- 「Gitコマンド」参照
Gitの使い方(ポイント) †
コミットメッセージ †
- 一般的に以下のルールで書くこと
- 1行目:表題(変更の要約)
- 2行目:空行
- 3行目以降:変更内容・変更の理由
Gitの用語 †
- issue
- fork
- upstream
- HEAD
- 現在のブランチの先頭(最新状態)
- ワークツリー
- 編集するファイルを格納するディレクトリ
- Index
- リポジトリに格納(コミット)する準備としてワークツリーで変更のあったファイルを登録する一時領域。(addコマンドで登録する)
- 当領域に登録したファイルがコミットの対象になる。(当領域に格納しないとコミット対象にすることができない)
- リポジトリ
- ローカルリポジトリ
- リモートリポジトリ
gitignore †
- gitignore - git-scm.com
https://git-scm.com/docs/gitignore
- git/git/Documentation/gitignore.txt
https://github.com/git/git/blob/master/Documentation/gitignore.txt
- github/gitignore
https://github.com/github/gitignore
関連サイト †
- Git - Book
https://git-scm.com/book/ja/v2
- Git for Windows
https://git-scm.com/
- WindowsにGitをインストールする方法
http://proengineer.internous.co.jp/content/columnfeature/6893
- いまさらGit for Windowsのインストール、GitHubに接続してみた
https://qiita.com/manabu-watanabe/items/ecf1b434baf305adaa00
- Git-flow
- A successful Git branching model
https://nvie.com/posts/a-successful-git-branching-model/
- A successful Git branching model
- git-flow cheatsheet
https://danielkummer.github.io/git-flow-cheatsheet/index.ja_JP.html