! [rejected] master -> master (fetch first) error: failed to push some refs to 'git@github.com:abc70/new.git'

0 votes

Hi,

I am getting the below error when trying to push data from local to GitHub.

! [rejected]        master -> master (fetch first)
error: failed to push some refs to 'git@github.com:abc70/new.git'
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.

Thank You

3 days ago in Git & GitHub by akhtar
• 1,440 points
86 views

1 answer to this question.

0 votes

Hi@akhtar,

 Here you tried to push your repo to GitHub. But before that fetch the metadata from GitHub.

$ git fetch

Thank You

answered 3 days ago by MD
• 2,750 points

Related Questions In Git & GitHub

0 votes
1 answer

How to solve the ‘Git commit -a error’?

This happens when no editor is set. ...READ MORE

answered Jul 5, 2018 in Git & GitHub by Tyrion anex
• 8,340 points
100 views
0 votes
1 answer

Error: git pull fails “unable to resolve reference” “unable to update local ref”

This happens when there are unnecessary files ...READ MORE

answered Jul 26, 2018 in Git & GitHub by Sophie may
• 9,940 points
2,660 views
0 votes
1 answer

git error: RPC failed; curl 56 GnuTLS recv error

This is simple, you’re probably missing openssl ...READ MORE

answered Sep 26, 2018 in Git & GitHub by Tyrion anex
• 8,340 points
1,987 views
+13 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 26, 2018 in DevOps & Agile by DragonLord999
• 8,400 points
352 views
0 votes
1 answer
0 votes
1 answer
0 votes
2 answers

How do I install Git on CentOS?

Hi, If you want to install Git 1 ...READ MORE

answered Feb 4 in Git & GitHub by MD
• 2,750 points
52 views