title: How to proceed with git push when getting "rejected" and "<filename>: needs merge"?
body: <p>Within project, someone pushed new files, I didn't pull them, then I've added new files, commited and then tried to push it to main.</p>
  <pre><code>git push -u origin main
  </code></pre>
  <p>Returns</p>
  <pre><code>! [rejected]        main -&gt; main (non-fast-forward)
  </code></pre>
  <p>Then <code>git checkout main</code></p>
  <p>Gives me</p>
  <pre><code>README.md: needs merge
  error: you need to resolve your current index first
  </code></pre>
  <p>How to solve conflict and proceed with my push?</p>