差分
このページの2つのバージョン間の差分を表示します。
両方とも前のリビジョン 前のリビジョン 次のリビジョン | 前のリビジョン 次のリビジョン両方とも次のリビジョン | ||
linux:git [2019/08/19 07:25] – ともやん | linux:git [2020/01/29 03:10] – ともやん | ||
---|---|---|---|
行 5: | 行 5: | ||
$ git pull | $ git pull | ||
Already up to date. | Already up to date. | ||
+ | </ | ||
+ | |||
+ | ==== ローカルのファイルやディレクトリへの変更を破棄する ==== | ||
+ | < | ||
+ | $ git checkout --force | ||
</ | </ | ||
行 18: | 行 23: | ||
$ git reset --hard origin/ | $ git reset --hard origin/ | ||
</ | </ | ||
+ | ローカルの状態を確認する。\\ | ||
+ | < | ||
+ | $ git status | ||
+ | On branch master | ||
+ | Your branch is up to date with ' | ||
+ | nothing to commit, working tree clean | ||
+ | </ | ||
===== トラブルシューティング ===== | ===== トラブルシューティング ===== | ||