2012
03.15

Sometimes you’ll have an error in your commit message or no message at all. If your repository is configured to accept changes to this log message after the commit is finished, you can “fix” your message remotely using svn propset. However, because of the potential to loose information, Subversion repositories are not, by default, configured to allow changes to unversioned properties—except by an administrator.

This is how your do it:

echo "Your corrected commit message" > message;
svnadmin setlog /home/projman/svn/site/ -r 4658 --bypass-hooks message;
rm message;

If your’re also using Trac your changes won’t show up in your “timeline“. To fix that make sure to resync your TracEnvironment:

trac-admin /home/projman/trac/site/;
resync 4658
exit

Everything should by fine now!

References:

2012
03.15

Here’s a little snippet that I use to remove all the unused kernels on my Ubuntu servers/desktops. Unused means all the kernel that are currently not in use. For servers that don’t reboot so often that could mean removing kernels that are newer than uname -r. So make sure to pay attention…

dpkg -l | egrep '^ii  linux-(image|headers)-2' | awk '{print $2}' \
  | grep -v $(uname -r | sed 's/-generic//' | sed 's/-server//') \
  | xargs apt-get remove --purge -y \
;