2

コンピューターと github に "FilmReview" という名前のディレクトリがあり、FilmReview.git空です。このフォルダーを にプッシュしたいと考えていますhttps://github.com/siddhartha-ramesh/FilmReview.git

私は次のことを試しました:

siddhartha@siddhartha-Inspiron-545s ~/Desktop/Untitled Folder $ git init
Initialized empty Git repository in /home/siddhartha/Desktop/Untitled Folder/.git/
siddhartha@siddhartha-Inspiron-545s ~/Desktop/Untitled Folder $ git add .
siddhartha@siddhartha-Inspiron-545s ~/Desktop/Untitled Folder $ git commit -m "The whole Project"
[master (root-commit) 02a49f5] The whole Project
 203 files changed, 39049 insertions(+)
 create mode 100644 film_review/.project
 create mode 100644 film_review/404.html
#Rest of the files in this folder
 create mode 100644 film_review/trailers.html
 create mode 100644 film_review/trailers.html~

siddhartha@siddhartha-Inspiron-545s ~/.ssh $ ls -a
.  ..  key  key.pub  known_hosts
siddhartha@siddhartha-Inspiron-545s ~/.ssh $ cat key.pub
ssh-rsa 
# KEY HERE 

siddhartha@siddhartha-Inspiron-545s ~/Desktop/Untitled Folder $ git remote add origin git@github.com:siddhartha-ramesh/FilmReview.git
fatal: remote origin already exists.
siddhartha@siddhartha-Inspiron-545s ~/Desktop/Untitled Folder $ git push origin master
To git@github.com:siddhartha-ramesh/FilmReview.git
 ! [rejected]        master -> master (non-fast-forward)
error: failed to push some refs to 'git@github.com:siddhartha-ramesh/FilmReview.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Merge the remote changes (e.g. 'git pull')
hint: before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.

誰か私を助けてください

また、これを行いましたが、gitハブにファイルがアップロードされていません

siddhartha@siddhartha-Inspiron-545s ~/Desktop/Untitled Folder $ git push origin master
Username for 'https://github.com': siddhartha-ramesh
Password for 'https://siddhartha-ramesh@github.com': 
To https://github.com/siddhartha-ramesh/FilmReview.git
 ! [rejected]        master -> master (non-fast-forward)
error: failed to push some refs to 'https://github.com/siddhartha-ramesh/FilmReview.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Merge the remote changes (e.g. 'git pull')
hint: before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
siddhartha@siddhartha-Inspiron-545s ~/Desktop/Untitled Folder $ git pill origin master
git: 'pill' is not a git command. See 'git --help'.

Did you mean this?
    pull
siddhartha@siddhartha-Inspiron-545s ~/Desktop/Untitled Folder $ git pull origin master
warning: no common commits
remote: Counting objects: 3, done.
remote: Compressing objects: 100% (2/2), done.
remote: Total 3 (delta 0), reused 0 (delta 0)
Unpacking objects: 100% (3/3), done.
From https://github.com/siddhartha-ramesh/FilmReview
 * branch            master     -> FETCH_HEAD
Merge made by the 'recursive' strategy.
 README.md | 4 ++++
 1 file changed, 4 insertions(+)
 create mode 100644 README.md
4

2 に答える 2