a Pypi package to help fake github history
Report Bug
·
Request Feature
Table of Contents
A Pypi pakcage to fake github commit history
To get a local repo with faked history up and running follow these simple example steps.
Ensure you have python. Follow the steps on the official documentation https://www.python.org/downloads/
You can check what python version you have with the following command
python --version
Git is also necessary to run the package. Follow the documentation to install Git: https://github.com/git-guides/install-git
- Upgrade pip
pip install --upgrade pip
- Install fgch pip packages
pip install gh-commit-history
The fake github commit history generator has many different functionalities to produce various realistic and versatile commit frequencies
**General Usage**
1. Navigate to the location you wish to fake your history and enter python shell in terminal
Windows: `python`
Mac/Linux:
`python3`
3. Import the module:
>> from fgch.commit_generator import generate_commits
3. Run the module:
>> generate_commits()
A new directory titled github-history
with a file named fake-history.txt
should have appeared after the sequence commences
Including no parameters will run the default settings
4. Create a GitHub Repository with a name of your choice (recommend github-history)
5. Push changes into the GitHub Repository
Navigate to the github-history directory
Windows:
cd .\github-history\
Mac/Linux:
cd /github-history
Connect remote to GitHub Repository
git remote add origin https://github.com/<your-user-name>/<your-repository-name>.git
Ex: git remote add origin https://github.com/Vish-04/github-history.git
Push to Repository
git push -u origin master
Reload your GitHub Profile, and your history should be changed!
Parameters
commits_per_day
: type String "int-int"
, default: "0-3"
range between which the number of commits per day is chosen from
start_date
: type String "MM/DD/YY"
, default: None
start date of fake github history. If None, start date will be a year back from current date
end_date
: type String "MM/DD/YY"
, default: None
end date of fake github history. If None, end date will be the current date
workdays_only
: type Boolean
, default: False
restricts commits to only occur on weekdays
weekend_behavior
: type Boolean
, default: False
lowers commit frequency to 0-1 commits on weekends
working_hours
: type String "int-int"
, default: 9-17
determines between what hours in military time to commit between
gradient
: type String
, default: None
increases commits per day closer to the higher number of commit range over time - choose between 'linear', 'exponential', 'bursts'
- linear: linearly increases commits per day
- exponential: exponentially increases commits per day
- bursts: increases and decreases commits per day in batches of 3 weeks, mimicking sprints
`no_commit_percentage` : type `Float`, default: `0`
_float between 0 and 1 that determines what percentage of history to not fake commits too_
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the MIT License. See LICENSE
for more information.
Vishwa Akkati - LinkedIn - [email protected]
Project Link: https://github.com/Vish-04/fake-github-commit-history