This project provides a shell script that generates a year's worth of GitHub commits for a specified year. It's designed to fill in your GitHub contribution graph for any given year.
This tool is for educational and demonstration purposes only. Using this script to artificially inflate your GitHub contributions may violate GitHub's terms of service and is not recommended for actual use. It's important to maintain the integrity of your GitHub profile with genuine contributions.
- Generate commits for any specified year
- Random number of commits (0-5) for each day of the year
- Customizable commit messages and file content
- Works on both Linux (GNU) and macOS (BSD) systems
- Git installed on your system
- Bash shell (default on most Unix-based systems)
- Clone this repository or download the
year_of_commits.sh
file. - Make the script executable:
- Run the script:
./year_of_commits.sh
- When prompted, enter the year for which you want to generate commits (e.g., 2023).
- The script will create a directory named
year_of_commits
(if it doesn't exist) and generate the commits within this directory.
After running the script, you'll have the following structure:
βββ year_of_commits/
βββ .git/
βββ file_YYYY-MM-DD_X.txt (multiple files)
To push the generated commits to GitHub:
- Create a new repository on GitHub.
- Navigate to the
year_of_commits
directory:cd year_of_commits
- Add the GitHub repository as a remote:
git push -u origin main
- This script creates a large number of commits in a short time, which may look suspicious on GitHub.
- GitHub may flag unusual activity or large numbers of backdated commits.
- Use this tool responsibly and be aware of GitHub's terms of service.
- The script uses the
date
command, which may behave differently on GNU (Linux) and BSD (macOS) systems. The script attempts to accommodate both, but you may need to adjust it for your specific system.
You can customize the script by modifying:
- The range of random commits per day (currently 0-5)
- The content of the generated files
- The commit messages
Look for these sections in the script and adjust as needed.
Contributions to improve the script or extend its functionality are welcome. Please feel free to submit pull requests or open issues for bugs and feature requests.
This project is open source and available under the MIT License.
This project was created as an educational tool to demonstrate shell scripting and Git manipulation. It should be used responsibly and ethically.