Ignore scratch files
Quest: ignore-scratch-files
Mission
Preserve the starter ignore rules, add *.tmp, then prove the scratch file stays out of Git status.
Why This Matters
Git ignore rules only affect files inside the repository. ~/public_html/ is already outside the ~/src repository, so it does not need a public_html/ ignore rule there. Ignore rules are for disposable files that actually appear inside source.
Commands You Will Use
microtouchgit status
Steps
- Add the line
*.tmpto~/src/.gitignorewithout removing its existing rules. - You can use an editor or run
echo '*.tmp' >> ~/src/.gitignore. - Run
cd ~/src. - Run
touch scratch.tmp. - Run
git status. The optional--shortflag only makes the output compact. - Confirm
scratch.tmpis not listed. - Run
guide check.
Hints
.gitignorelives at the repository root.- The starter rules must remain.
- The new line must be
*.tmp.
If Check Fails
Make sure the file is named .gitignore and contains node_modules/, dist/, and *.tmp on their own lines.

Linux Foundations