Posts

Showing posts from December, 2011

Coalescing multiple edits into a single bazaar commit

Occasionally, after committing some changes on a bzr branch, I'll come back to it and want to make further changes. So, I'll have done something like this: $ bzr commit $ # Oops! Forgot to update foo.c. Let's do that now... $ vim src/foo.c $ bzr status modified: src/foo.c But rather than creating a second commit for the newest changes, I'll want to combine those new changes and the changes in the latest commit into a single new commit. How do we do this? With bzr its easy: $ bzr log -l1 > /tmp/commit.log # save the latest commit log entry $ bzr shelve --all -m "latest changes" # save the latest uncommitted changes $ bzr uncommit --dry-run # check its going to work $ bzr uncommit # undo the last commit $ bzr unshelve --dry-run # check if its going to work $ bzr unshelve # apply the latest changes to the working directory $ bzr commit

Adding an icon in Ubuntu's Unity for applications which don't provide one

Occasionally, when you're exploring the truly vast range of offerings in the Ubuntu Software Archives via the wonderful Ubuntu Software Centre (or maybe via " apt-cache search "), you might find a graphical application that doesn't have an icon. If this happens, there are 2 things to do: Raise a bug on that application to have an icon added. Add an icon temporarily. Raising a bug is easy, just type: $ ubuntu-bug <thing> Where " <thing> " is either the name of the program you are running, or the package that program lives in. However, you can also quickly add an icon yourself using this simple technique... There are 2 steps: Select your icon Create a "desktop" file Icons are installed in the "/usr/share/icons/" directory by default, so have a browse around to see what you like. If you're still struggling to find an appropriate icon, you could add the package wm-icons which adds over 1500 new ones (!):