모든 종류의 문제가 있기 때문에 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 내가 커밋 원래에서 이러한 파일을 제거하는 방법을 알아낼 수 없었다. 나는 머리를 원점으로 되돌려 보려고했지만 그것들을 없애지는 못했다. 대신, 나는 신선한 시작하고 싶습니다. 나는 단지 나의 Git 리모트가 나의 지역과 어울리기를 원한다. 그래서 나는 푸쉬 연습과 커밋을 시작할 수있다. 스택 오버플로에서 찾은 모든 것이 제대로 작동하지 않는 것 같습니다.
[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>...]'
감사합니다!
다시 복제 하시겠습니까? –
이전의 HEAD 위치를 보려면 "git reflog"를 시도해보고 그 위치에 reset --hard를 사용할 수 있습니다 –