I think GitHub should fix this bug to prevent attacks on profiles
This is neither a bug, nor is it easy to "fix". The solution is to use the right tool for the job and sign your commits.
Oh and by the way: git commit --author 'Your Name <your.name@domain.com>' does the same thing but is much easier to remember. And it's far from the only thing you can mess with, take for example this neat little script I use to make commits "in the future":
Just put that script in your path as git-timeshift and you can call it as git timeshift "+3 hours" commit to commit something with a timestamp 3 hours in the future. Why you might want to do this, I'll leave to your imagination.
This is neither a bug, nor is it easy to "fix". The solution is to use the right tool for the job and sign your commits.
Oh and by the way:
git commit --author 'Your Name <your.name@domain.com>'
does the same thing but is much easier to remember. And it's far from the only thing you can mess with, take for example this neat little script I use to make commits "in the future":Just put that script in your path as
git-timeshift
and you can call it asgit timeshift "+3 hours" commit
to commit something with a timestamp 3 hours in the future. Why you might want to do this, I'll leave to your imagination.Thank you for your comment!
You can also make commit in the past. There is Anthony Fu's script to make commit in 1990 github.com/antfu/1990-script