2009-02-26 8:34am +1100, by Paul Colby
If you've used Subversion for any significant length of time, then you've probably run into the following message (or one just like it), near the end of a "svn diff
" command.
\ No newline at end of file
Of course, you would have realised that this is because your editor has added a newline character to the end of the file in question, where the original had no such newline character.
Read more
2009-02-13 8:14am +1100, by Paul Colby
Sometimes you just want to extract a single BLOB from a DB2 database... you don't want to write any software... you don't want to pull out some scripting language with a true DB2 database driver binding... you just want to get a BLOB from the database, and write it to a file - using nothing but the command line.
Well, there are two ways, that I know of, to do so. The first one, is the officially "correct" method, and should always work. The second method is even easier, but only works for very small BLOBs (which is all you need sometimes).
Read more
2009-02-10 6:00pm +1100, by Paul Colby
I've been using the excellent PyODConverter (aka Python OpenDocument Converter) for quite sometime now. It's a very small Python script that uses OpenOffice's Python-UNO bridge to convert documents between formats. For example, to convert test.doc
to a PDF file, you could execute:
python DocumentConverter.py test.doc test.pdf
As a small side note, for the Python-UNO bridge (and thus PyODConverter) to work, you do need to use the python
binary that installs with OpenOffice, so you will most likely need to full-qualify the python
command like:
/opt/openoffice.org3/program/python DocumentConverter.py test.doc test.pdf
Anyway, PyODConverter always tries to talk to OpenOffice via (the somewhat arbitrary) port 8100. But today I found myself needing to able to tell PyODConverter which port to use via the command line. So, I went about modifying the PyODConverter code - which was very easy, thanks to it being already very well written.
Read more
2009-02-10 5:54pm +1100, by Paul Colby
There are many ways to determine local IP addresses on Linux platforms. They almost always involve piping ifconfig
into a number of grep
, awk
, cat
, and/or tr
commands.
Well, my new favorite approach is to pipe ifconfig
into a single sed
command :)
ifconfig | sed -n -e 's/:127\.0\.0\.1 //g' -e 's/ *inet addr:\([0-9.]\+\).*/\1/gp'
Neat, huh?! :)
Read more
2009-02-05 9:22pm +1100, by Paul Colby
As a mentioned back in this post, I am building a completely solid-state, dual-core, 64-bit media PC. I won't go into any of th "planning" details here (refer back to the original post for that). However, this post will show some of the progress so far (using lots of pics), and give some idea of the project's feasibility:)
Read more
2009-02-02 7:03pm +1100, by Paul Colby
During the past three years, I've often been amazed at just how difficult it can be to get IBM's DB2 to successfully restore from its own backups. Even in the most simple case (offline backups, with circular logging) you can run into difficulty, but in can be incredibly difficult if the database has been configured to use log shipping, and especially if the backups were taken "online" - that, it seems, can be most difficult DB2 backup / restore scenario. And, of course, DB2's error messages usually offer very little (to the untrained eye) to explain what's going wrong.
Read more
2009-02-02 5:50pm +1100, by Paul Colby
For a little while now, we've been seeing ads on TV for a new soon-to-be-upon-us service called Freeview. Well okay, my interest was raised... mainly because of the promised "15 new free to air channels". Note, the "new" part was my misunderstanding - ie it was implied, but not declared, as we shall soon see.
Read more
2009-01-29 8:54am +1100, by Paul Colby
This is a simple test post - used for testing things such as trackbacks. This post is not intended for visitors to view.
This test is using the Drupal Trackback module first announced here.
Read more
2009-01-28 12:55pm +1100, by Paul Colby
As mentioned back in this post, I helped to build Job Bounty Hunter. So, I was quite pleased to see one of my own architecture diagrams appear on this Amazon Web Services blog post.
So, since that particular diagram is now publicly available, I might as well present it here - I did create it, after all ;)
Read more