1. Иш бошланиши
2. Git асослари
4. Git серверда
7. Git Tools
- 7.1 Revision Selection
- 7.2 Interactive Staging
- 7.3 Stashing and Cleaning
- 7.4 Signing Your Work
- 7.5 Searching
- 7.6 Rewriting History
- 7.7 Reset Demystified
- 7.8 Advanced Merging
- 7.9 Rerere
- 7.10 Debugging with Git
- 7.11 Qism modullar (Submodule)
- 7.12 Bundling
- 7.13 Replace
- 7.14 Credential Storage
- 7.15 Summary
10. Git Internals
A3.11 Appendix C: Git Commands - Administration
If you’re administering a Git repository or need to fix something in a big way, Git provides a number of administrative commands to help you out.
git gc command runs “garbage collection” on your repository, removing unnecessary files in your database and packing up the remaining files into a more efficient format.
This command normally runs in the background for you, though you can manually run it if you wish. We go over some examples of this in Maintenance.
git fsck command is used to check the internal database for problems or inconsistencies.
We only quickly use this once in Data Recovery to search for dangling objects.
git reflog command goes through a log of where all the heads of your branches have been as you work to find commits you may have lost through rewriting histories.
We cover this command mainly in RefLog Shortnames, where we show normal usage to and how to use
git log -g to view the same information with
git log output.
We also go through a practical example of recovering such a lost branch in Data Recovery.
git filter-branch command is used to rewrite loads of commits according to certain patterns, like removing a file everywhere or filtering the entire repository down to a single subdirectory for extracting a project.
In Removing a File from Every Commit we explain the command and explore several different options such as