Hands-on task
Keep the junk out with .gitignore
After the bot was run, the /root/bot repository got files that don't belong in git: .env with a token, and logs — files with the .log extension, in the root and in the logs/ directory.
- Make git ignore
.envand any.logfiles — both the existing ones and future ones, in whatever directory they show up. - Commit
.gitignore. Neither.envnor the logs may end up in the commit.
The new file config.py is needed by the project — git must still see it.
- .gitignore
- ignore patterns
- git check-ignore