linux:mercurial_git

差分

このページの2つのバージョン間の差分を表示します。

この比較画面へのリンク

両方とも前のリビジョン 前のリビジョン
次のリビジョン
前のリビジョン
linux:mercurial_git [2019/05/18 02:23] – 外部編集 非ログインユーザーlinux:mercurial_git [2021/03/31 05:18] (現在) ともやん
行 48: 行 48:
 | <code>hg status</code>  | <code>git status</code>  | ローカルのリポジトリで更新があったファイルの一覧を表示  |   | | <code>hg status</code>  | <code>git status</code>  | ローカルのリポジトリで更新があったファイルの一覧を表示  |   |
 | <code>hg update [-C]</code>  | <code>git merge origin/master</code>  | 作業ディレクトリをリポジトリの最新内容に更新  |   | | <code>hg update [-C]</code>  | <code>git merge origin/master</code>  | 作業ディレクトリをリポジトリの最新内容に更新  |   |
 +| <code>hg tags</code>  | <code>git tag</code>  | タグの一覧を表示  |   |
 | <code>hg branch <branch name></code>  | <code>git checkout -b <branch name></code>  | ブランチの作成  |   | | <code>hg branch <branch name></code>  | <code>git checkout -b <branch name></code>  | ブランチの作成  |   |
 | <code>hg update <branch name></code>  | <code>git checkout <branch name></code>  | ブランチの切替  |   | | <code>hg update <branch name></code>  | <code>git checkout <branch name></code>  | ブランチの切替  |   |
行 59: 行 60:
 | <code>hg pull –update</code>  | <code>git pull</code><code>git fetch | <code>hg pull –update</code>  | <code>git pull</code><code>git fetch
 git merge /origin/<branch name></code>  | 変更差分の取り込み  | Mercurial はブランチのローカル取り込みと作業ディレクトリのリポジトリ最新内容に更新を同時に行う  | git merge /origin/<branch name></code>  | 変更差分の取り込み  | Mercurial はブランチのローカル取り込みと作業ディレクトリのリポジトリ最新内容に更新を同時に行う  |
 +|   | <code>git pull --tags</code>  | リモートのタグを取得  |   |
 | <code>hg merge</code>  | <code>git stash save -u | <code>hg merge</code>  | <code>git stash save -u
 git merge origin/<branch_name> git merge origin/<branch_name>
行 65: 行 67:
 | <code>hg commit</code>  | <code>git commit -a</code>  | ローカルリポジトリにコミット  |   | | <code>hg commit</code>  | <code>git commit -a</code>  | ローカルリポジトリにコミット  |   |
 | <code>hg push</code>  | <code>git push</code>  | コミットした変更をリポジトリサーバに反映  |   | | <code>hg push</code>  | <code>git push</code>  | コミットした変更をリポジトリサーバに反映  |   |
 +|   | <code>git push --tags</code>  | ローカルのタグをリモートに push  |   |
 | <code>hg annotate/blame <file></code>  | <code>git blame <file></code>  | チェンジセットを行ごとに表示  |   | | <code>hg annotate/blame <file></code>  | <code>git blame <file></code>  | チェンジセットを行ごとに表示  |   |
 | <code>hg cat <file></code><code>hg cat -r <revision> -o <out file> <file></code>  | <code>git cat-file -p <revision>:<file></code>  | ファイルを出力  |   | | <code>hg cat <file></code><code>hg cat -r <revision> -o <out file> <file></code>  | <code>git cat-file -p <revision>:<file></code>  | ファイルを出力  |   |
行 74: 行 77:
 cd <directory> cd <directory>
 git submodule update --init --recursive</code>  | submodule をクローンし忘れた場合  |  | git submodule update --init --recursive</code>  | submodule をクローンし忘れた場合  |  |
 +
 +===== 参考文献 =====
 +[[https://stackoverflow.com/questions/35837/what-is-the-difference-between-mercurial-and-git|version control - What is the Difference Between Mercurial and Git? - Stack Overflow]]\\
 +
  • linux/mercurial_git.1558113795.txt.gz
  • 最終更新: 2019/05/18 02:23
  • by 非ログインユーザー