Sync git repositories

Sometimes I need/have to sync a private repository with a public one, so this is what I usually  do.

Add a new remote

git remote add github

Pull the new commits from master

git pull github master

Push new commits to origin

git push origin master

Push new tags

git push --tags origin

How to fix open_stackdumpfile: Dumping stack trace to less.exe.stackdump (git+cygwin)

At work I’m using git [git version] + cgywin , some git commands like diff or log throw an exception and I got this message on the console [main] cygwin_exception::open_stackdumpfile: Dumping stack trace to less.exe.stackdump

To fix this error you have to change the value of $TERM to xterm, previously was screen (collateral damage? I don’t know yet xD)

export TERM=xterm