To undo last commit in git you can use the following command below:
$ git reset HEAD~
web development and system administration of Linux
To undo last commit in git you can use the following command below:
$ git reset HEAD~
To display changes in the particular commit you can use the following command:
# git show COMMIT_HASH
You can find commit hash using one of the following commands:
# git log
… or by commit message text:
# git log --all --grep="commit comment message"
You can also find more information in git show documentation.
If you need to change current value of auto_increment for table you could use the following SQL query:
ALTER TABLE `table_name` AUTO_INCREMENT=1001;
If you need to find some commits by commit message text you could use the command below:
git log --all --grep='message text to search for'
I’ve completed Pimcore CMS Senior Developer Certification.
To downgrade composer to version 1 the following command should be used:
$ composer self-update --1
To make tar archive without .git folder or any other version control systems –exclude-vcs option can be used for tar.
Example tar command could be:
$ tar --exclude-vcs -cpjf ~/backup__no_vcs__$(date +'%Y-%m-%d_%H-%M').tar.bz2 ./
To list all the files in a commit use command:
# git show commitId
To get a commitId use command:
# git log
Today, I have finally completed my first Pimcore Academy Certification.
I really like Pimcore CMS. It is really cool tool to build amazing websites and web applications.
To change the author or message of the last commit consider using the following commands:
# git commit --amend --author="Taras Shkodenko <taras@shkodenko.com>"
or
# git commit --amend -m "New Fixed Commit Message"