Skip to content

Instantly share code, notes, and snippets.

Avatar
🚀
Focusing

Dimitri DO BAIRRO rimiti

🚀
Focusing
View GitHub Profile
@rimiti
rimiti / delay.md
Last active Oct 18, 2017
Add delay (ms) between promises
View delay.md

If you wants to add a delay between two promise:

/**
 * @description Add delay (ms) between promises
 * @param delay
 * @return {Promise}
 */
wait(delay) {
  wait(delay) {
@rimiti
rimiti / mysql-dump-with-positions.sql
Last active Oct 18, 2017
Memo - Dumping your MySQL database with your points
View mysql-dump-with-positions.sql
-- To dump your database with your positions
mysqldump --hex-blob --routines --triggers -uroot database -r dump-with-data.sql
@rimiti
rimiti / change-commit-date.md
Last active Jul 16, 2018
How to change lastest commit date
View change-commit-date.md

To change last commit date

GIT_COMMITTER_DATE="`date -R -v-3d`" git commit --amend --no-edit --date "`date -R -v-3d`" && git push
@rimiti
rimiti / git-change-author.sh
Last active Oct 18, 2017
How to change the author (name / email) of all commits in repository ?
View git-change-author.sh
#!/bin/sh
git filter-branch --env-filter '
OLD_EMAIL="old-email@example.com"
CORRECT_NAME="Your Correct Name"
CORRECT_EMAIL="new-email@example.com"
if [ "$GIT_COMMITTER_EMAIL" = "$OLD_EMAIL" ]
then
export GIT_COMMITTER_NAME="$CORRECT_NAME"
export GIT_COMMITTER_EMAIL="$CORRECT_EMAIL"
You can’t perform that action at this time.