私はすべての種類の問題を抱えているので、私のGitをリセットしようとしています。それは私が私のリモコンにいくつかの大きなファイルをプッシュすることはできませんし、コミットからそれらを削除する方法を知らない。私はファイルをコミットすることさえ気にしません。GITをリモートバージョンにリセットする
私のリモコンは次のとおりです。
[email protected] MINGW64 /c/wamp64/www/postmyproject (master)<br>
$ git push pmp_staging master<br>
Enter passphrase for key '/c/Users/kjlin/.ssh/id_rsa':<br>
Counting objects: 7215, done.<br>
Delta compression using up to 4 threads.<br>
Compressing objects: 100% (7006/7006), done.<br>
Writing objects: 100% (7215/7215), 44.69 MiB | 1.01 MiB/s, done.<br>
Total 7215 (delta 1112), reused 0 (delta 0)<br>
remote: Resolving deltas: 100% (1112/1112), done.<br>
remote: git.wpengine.com: validating<br>
remote: - info: detected push to staging application ...<br>
remote: - info: validating files in 9f1931e ...<br>
remote: - info: found application servers ...<br>
remote: failed...<br>
remote: system/large file types detected:<br>
remote: ------------------------------------------------------------------<br>
<br>
remote: wp-content/mu-plugins/wpengine-common/preamble.php<br>
remote: wp-content/mu-plugins/wpengine-common/redis-object-cache.php<br>
remote: wp-content/mu-plugins/wpengine-common/s3-uploads.php<br>
remote: wp-content/mu-plugins/wpengine-common/util.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/admin-footer.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/admin/advanced.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/admin/debug-db.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/admin/notice-sticky.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/admin/notice.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/general/powered-by.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/modal.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/staging-modal.php<br>
remote: wp-content/mu-plugins/wpengine-common/views/wpe-migration-preview-<br>template.php
remote: wp-content/mu-plugins/wpengine-common/wpe_wpdb.php<br>
remote: ------------------------------------------------------------------
remote: please remove these files from your source, re-commit, and push...
To git.wpengine.com:staging/postmyproject2.git
! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to'[email protected]:staging/postmyproject2.git'<br>
pmp_staging私がコミット元からこれらのファイルを削除する方法を見つけ出すことができませんでした。私は起源に頭を戻してみましたが、それらを取り除くように見えることはできません。代わりに、新鮮なものから始めたいと思います。私はちょうど私の地元のリモートに私の地元の人と一致するように私はプッシュとコミットを練習を開始することができますしたい。私がスタックオーバーフローで探すすべてがうまくいかないようです。
[email protected] MINGW64 /c/wamp64/www/postmyproject (master)<br>
$ git fetch pmp_staging<br>
Enter passphrase for key '/c/Users/kjlin/.ssh/id_rsa':<br>
<br>
[email protected] MINGW64 /c/wamp64/www/postmyproject (master)
$ git reset --hard master/master<br>
fatal: ambiguous argument 'master/master': unknown revision or path not in the working tree.<br>
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'<br>
<br>
[email protected] MINGW64 /c/wamp64/www/postmyproject (master)<br>
$ git reset --hard pmp_staging/master<br>
fatal: ambiguous argument 'pmp_staging/master': unknown revision or path not in the working tree.<br>
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
ありがとう!
もう一度クローンしますか? –
"git reflog"を実行して前のHEADの位置を確認し、その位置にreset --hardを使用することができます –