Well, that took way too long but I’ve finally updated my SublimePrint plugin to work in Sublime Text 3. It was just a few Python 3 tweaks that were needed. The update can be fetched from Package Control, and this is what has changed in case you care.
Submodules, you either love them or hate them. The support is getting better for each new Git version, but for some reason there is still no command to remove a submodule from a project. Here is a script to fix that problem.
Sometimes you have a project with lots of submodules that you never change yourself, but want to update occasionally. One example would be if you use Pathogen for your VIM plugins. You’d think you could use git submodule update here, and sometimes you can. But note that one of the main features of submodules is that they are locked to a particular commit. In case you want to pull in the latest changes from the remote, you need something else.
I put this alias in my .gitconfig file to solve the problem (note that this needs to be all on one line):
subup = submodule foreach 'git pull -s recursive -X theirs origin master'
The command will cd into each submodule, and do a forced pull overwriting any local changes you may have. Nice, right?
If you are like me, you have a whole bunch of projects on your hard disk that you want to update occasionally, but don’t really work actively with. Previously I usually put an update-all.sh file in the root folder of those projects. But in most cases it is possible to use a general approach. I now do it like this:
If you pass a path to the script, it updates all subdirectories under that path, else it uses the current directory. And to make it even more convenient, you can add an alias to your .gitconfig file, like so:
pullall = !~/bin/git-pullall.sh
Now you can just use git pullall to update everything in one go. Convenient!