git-ctm = git commit Time Machine
Sometimes you need to create a commit with particular timestamp. git-ctm provides a command-line tool ctm for easy committing with desired timestamp:
$ ctm -d 'Thu Feb 8 03:14:15 2018 +0200' -m 'my commit message' # is the same as $ GIT_AUTHOR_DATE='Thu Feb 8 03:14:15 2018 +0200' \ GIT_COMMITTER_DATE='Thu Feb 8 03:14:15 2018 +0200' \ git commit -m 'my commit message'All commits in this project are done with ctm itself.
From PyPI using pip package manager:
pip install --upgrade git-ctmOr install the latest sources from GitHub:
pip install https://github.com/pavdmyt/git-ctm/archive/master.zipOr just put ctm PEX (Python EXecutable) file somewhere in the $PATH:
$ git clone https://github.com/pavdmyt/git-ctm.git $ cd git-ctm $ sudo cp ctm /usr/local/bin/Now ctm command-line tool should be available to use, try:
ctm --version$ ctm --help Usage: ctm -d <date> -m <msg> ctm -p -d <date> Commit date and time -m <msg> Commit message -p Print date template --help Print usage --version Print versionClone the repository:
git clone https://github.com/pavdmyt/git-ctm.gitInstall dependencies:
make install-devLint code:
make lint- Fork it!
- Create your feature branch:
git checkout -b my-new-feature - Commit your changes:
git commit -m 'Add some feature' - Push to the branch:
git push origin my-new-feature - Submit a pull request
- Make sure tests are passing
MIT - Pavlo Dmytrenko