Viewing git diffs on the command line is OK for small diffs, but I like viewing larger ones in a […]
Tag: git
Display list of files containing conflicts in Git
Usually I just use the output from the merge command, but sometimes if there’s a lot of changes, it can […]
Small script for updating all git repositories within a directory.
A simple script that jumps into a given directory (or a default one) and updates all git repos in there. […]
Git: Show all unmerged branches
You can list all branches which have not been merged into current branch. unmerged branches git branch -a –no-merged The […]
Release practices for applications
I am assuming here that you are aware of version control, continuous integration and do releases on a UNIX based […]
How to push a different branch to heroku instead of master
To push a different branch to heroku instead of master you just need to: git push heroku <YOUR_BRANCH>:master e.g., If […]
Shortcut to checkout previous branch on git
I always switched between two branches to make some rebase or cherry-pick and I always typed g co branch_name (git […]
Build Event : Publishing application details
When troubleshooting a web application or web services, few things are more annoying than not knowing exactly what code is […]
Why You Should Consider Using Git Rebase?
For a long time, I was telling myself how ugly those fucking merge bulks were on my git history. Then […]
Tagging in Git with Ruby
#!/usr/bin/env ruby puts ‘Tag version?’ tag = gets.chomp tag = “v#{tag}” unless tag[0] == ‘v’ `git commit -m ‘Bump version […]
Commit a new file to git using Rugged
This tip demonstrates how to use Rugged to commit a new file to git and leave behind a clean working […]
Some handy (for me) bash aliases
Bash aliases are super handy for some of those commands you use on a regular basis. Here are a few […]
Exporting a folder to a separate Git repository
Ever wanted to split your codebase in multiple pieces, and keep all the commits? This is easier than you may […]
Better Git log
Use git lg instead ! type this: git config –global alias.lg “log –graph –pretty=format:’%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset’ –abbrev-commit […]
Git: remove old local branches
for k in $(git branch | sed /*/d); do if [ -n “$(git log -1 –before=’1 week ago’ -s $k)” […]
A Simple Shell Function to Update Git Branches
A client of mine was having a hard time remembering the project workflow to keep topic branches updated, so I […]
commiting to a remote github gist
If you own a gist, for example gist number 123456, then you can clone it locally using the scp-like git […]
Change last commit
Oh no ! I just committed, providing a wrong message. No problemo, you can just edit the log of the […]
Faster Git Clones
If you don’t need the Git history when cloning (which is often the case if you are just forking to […]
Read git commit logs with style.
A fun way to read commit logs: Example: http://starlogs.net/#gentlero/bitbucket-api Use it for your own repo like this: http://starlogs.net/#[github username]/[repo name]