User Tools

Site Tools


git:correcting-git-commits

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
git:correcting-git-commits [2026/02/11 15:39] – [How to Do It (Command Line)] odeftagit:correcting-git-commits [2026/02/11 15:40] (current) – [How to Do It (Command Line)] odefta
Line 31: Line 31:
     Because you have changed a commit that already exists on the remote server, you must force the update. **Always** use the safer `--force-with-lease` option.     Because you have changed a commit that already exists on the remote server, you must force the update. **Always** use the safer `--force-with-lease` option.
 <code bash> <code bash>
-Varianta scurtă (când branch-ul are deja upstream configurat)+Short version (when the branch already has upstream configured)
 git push --force-with-lease git push --force-with-lease
  
-Varianta completă (specifică explicit remote-ul și branch-ul)+Full version (explicitly specify remote and branch)
 git push --force-with-lease origin <your-branch-name> git push --force-with-lease origin <your-branch-name>
 </code> </code>
 <note tip> <note tip>
-💡 **Tip:** În majoritatea cazurilor poți folosi varianta scurtă. Git va folosi automat upstream-ul configurat pentru branch-ul curent.+💡 **Tip:** In most cases you can use the short version. Git will automatically use the configured upstream for the current branch.
 </note> </note>
 <note> <note>
git/correcting-git-commits.txt · Last modified: by odefta