01 / 10
Unfinished work and files that should not be committed
Previously, your choices were binary: commit changes or discard them. However, real-world development frequently involves cases in between:
- Unfinished code in progress … not ready to commit, but you cannot afford to discard it
- Files that must never be committed … passwords, API keys, build logs, dependency folders
In this chapter, you learn how to handle both cases using git stash (temporary shelving) and .gitignore (exclusion rules).