Git completion in tcsh


So I’ve been a bit envious at the lovely git completion bash users have – but obviously I can’t just switch to bash. Anyone who is in the same kind of situation might like the fact that I’ve started a project to provide this functionality for tcsh.

The first thing you need to do is download the source for tcsh 6.15, and apply the patch you can find here: http://bugs.gw.com/bug_view_advanced_page.php?bug_id=60. Without it it won’t work. Compile and install the new tcsh version. The next step is to check out the project from github, at http://github.com/olabini/git_complete_tcsh. Make sure that git_complete is executable and on your path. You need to have Ruby installed for this, btw.

The final step is to modify your .cshrc to add something like this: complete git{,-*} ‘p/*/`git_complete`/’.

Now git completion should work, although most of the commands aren’t implemented yet. I’ll get to them in time. The whole project is a port of the bash completion for git