{"id":19374916,"url":"https://github.com/dappcoderr/git-tutorial","last_synced_at":"2026-03-03T10:31:40.954Z","repository":{"id":212505947,"uuid":"731587268","full_name":"DappCoderr/Git-Tutorial","owner":"DappCoderr","description":null,"archived":false,"fork":false,"pushed_at":"2023-12-14T19:04:27.000Z","size":13,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-11-18T10:04:11.207Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DappCoderr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-12-14T12:16:39.000Z","updated_at":"2023-12-14T14:15:21.000Z","dependencies_parsed_at":"2024-11-10T08:36:45.310Z","dependency_job_id":"8ae8b95d-d168-4775-93f3-e129efb4f1f1","html_url":"https://github.com/DappCoderr/Git-Tutorial","commit_stats":null,"previous_names":["dappcoderr/git-tutorial"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/DappCoderr/Git-Tutorial","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DappCoderr%2FGit-Tutorial","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DappCoderr%2FGit-Tutorial/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DappCoderr%2FGit-Tutorial/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DappCoderr%2FGit-Tutorial/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DappCoderr","download_url":"https://codeload.github.com/DappCoderr/Git-Tutorial/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DappCoderr%2FGit-Tutorial/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30041271,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-03T10:28:37.494Z","status":"ssl_error","status_checked_at":"2026-03-03T10:28:28.686Z","response_time":61,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-10T08:36:31.108Z","updated_at":"2026-03-03T10:31:40.909Z","avatar_url":"https://github.com/DappCoderr.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"1. `git init` -\u003e Powers your folder to be managed by git. And initializes new empty folder.\n\n2. `touch` -\u003e command is used to create a new folder inside you repository.\n3. `cat` -\u003e command is used open your folder that you have created.\n4. `ls -a` -\u003e command is used to view your .git folder.\n5. `rm -rf .git` -\u003e command is used to remove your existing .git folder.\n\n### running`git init` will reinitialize the git into the repository.\n\n6. `git status` \n    -\u003e Working Area : \n        -\u003e Are not in staging area.\n        -\u003e Not managed by git.\n        -\u003e Any changes is also not managed by git.\n        -\u003e Always files you will see in the \"Untracked Files\" means all the files in the working area.\n    -\u003e Staging Area\n        -\u003e Area in which files will be going to be part of the next version.\n    -\u003e Repository Area\n        -\u003e Git manages all the files and know the version history.\n        -\u003e knows the previous registered version.\n\n6. `git add README.txt` -\u003e Moving file from working area to staging area.\n7. `git rm --cached README.txt` -\u003e Moving file from staging area to working area.\n\n### In git version are managed by commits.\n### One git commit is one version.\n### Commit -\u003e A commit is a snapshot of the project in the staged changes and create a version out of it.\n\n8. `git commit` -\u003e register staging changes to a commit.\n\n-------------------------------------------------------\nAdding some new lines. \nDelete it after the work is done.\n-------------------------------------------------------\n\n9. `git restore README.txt` -\u003e File in the staging area and remove all the modified content in the file.\n                            -\u003e Instead of deleting all the changed in the file line by line, restore the last \n                            clean version of the file.\n\n10. `git restore --staged README.txt` -\u003e help you to move back your file changes from staging area to working area.\n                                      -\u003e Then you can restore the file and get the clean a last version of it.\n\n-------------------------------------------------------\nAgain doing this to lean the staging and unstaging of the git.\n\nAdding some new lines. \nDelete it after the work is done.\n-------------------------------------------------------\n\n\n11. `git diff commitID2 commitID1` -\u003e This provide a difference between both the commited files.\n\n12. `git commit -m \"this is my final\"` -\u003e To avoid vim/nano editor and directly commit the message with the git command only.\n\n13. `git remote` -\u003e To list down all the remote connection name.\n\n14. Remote Connection -\u003e It help you to link 2 git repos for uploading and downloading changes from each other.\n\n15. `git remote add \u003cremote name\u003e \u003cremote link\u003e`\n\n16. `git push \u003cremote name\u003e \u003cbranch name\u003e`\n\n17. `git remote rm \u003cname of the remote\u003e`\n\n18. `git remote rename \u003coldName\u003e \u003cnewName\u003e` -\u003e To rename the file name.\n\n19. `git add .` -\u003e To add multiple files from working to the staging area.\n\nChanges made by some other user.\n\n20. `git pull origin master` -\u003e Help you to pull all the changes made by your team mate to the same repo.\n\n### Best practice to use-\nMake changes\nAdd file to staging area\nCommit those changes\nFirst pull to avoid conflict.\nThen push the changes to the repo.\n\n### stuck with the merge conflict!!\n\nmerge conflict occured. Please resolve!\n\nNew merge conflict by user 1.\n\nNew merge Conflict by user 2\n\n21. `git fetch origin master` -\u003e To fetch the latest changes\n\n22. `git merge origin/master` -\u003e To merge the changes from the remote 'master' branch.\n\n23.  `git remote -v` -\u003e To verify the remote\n\n24. `git branch` -\u003e To check all the branch repo has.\n\n25. `git branch -M main` -\u003e To change the branch name or we can say to rename the branch.\n\n26. `git checkout \u003cbranch name\u003e` -\u003e To navigate from one branch to another branch.\n\n27. `git checkout -b \u003cnew Branch Name\u003e` (git checkout -b starter) -\u003e This command is used to create \n                                                                     a new branch.\n\n28. `git branch -d \u003cbranch name\u003e` -\u003e To delete the branch.\n\n\n---------------------------UnDoing Commit Changes-------------------------------\n\n29. `git reset HEAD~1` -\u003e Undoing for one commit\n\n30. `git reset \u003ccommit hash\u003e` -\u003e For many commit\n\n31. `git reset --hard \u003ccommit hast\u003e` -\u003e For many commit\n\n\n-------------------Concluded--------------------------------\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdappcoderr%2Fgit-tutorial","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdappcoderr%2Fgit-tutorial","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdappcoderr%2Fgit-tutorial/lists"}