Installing RMagick on Snow Leopard / Leopard

UPDATE: After using this for a little, i’ve discovered that there’s a small problem with the install script, it does not include the ghostscript fonts (for use with ImageMagick) properly. I’ve forked the repository and applied a fix (http://github.com/dazoakley/ImageMagick-sl) - use this until masterkain accepts the change. :)

This used to be quite a complicated task to install ImageMagick and RMagick from source, but these days (thanks to some great work by others) it’s a piece of cake…

First install ImageMagick using this install script hosted on github (http://github.com/masterkain/ImageMagick-sl):

cd ~/src
git clone git://github.com/masterkain/ImageMagick-sl.git
cd ImageMagick-sl
chmod +x install_im.sh
sh install_im.sh

Now simply sit back and wait. (Oh, you’ll need to enter your password at some points as the libraries are installed into /usr/local).

Then, once that’s done, RMagick is installed by:

gem install rmagick

Simples. :)

Posted in mac, ruby | Tagged , , , , , , | 5 Comments

Installing the Ruby Bindings for Oracle on Mac OS X

This quick crib sheet is for the guys at work (and anyone else who might need help on this one)…

First install the oracle instant client somewhere - I normally install it to /usr/local/oracle/instantclient_10_2. Then…

cd /usr/local/oracle/instantclient_10_2
ln -s libclntsh.dylib.10.1 libclntsh.dylib

Following this, run mkdir -p /usr/local/oracle/network/admin/, and place a copy of the tnsnames.ora file in this directory.

Now you need to add the following to your .profile or .bashrc file:

# Oracle env variables
export ORACLE_HOME="/usr/local/oracle/instantclient_10_2"
export DYLD_LIBRARY_PATH="/usr/local/oracle/instantclient_10_2:$DYLD_LIBRARY_PATH"
export SQLPATH="/usr/local/oracle/instantclient_10_2"
export TNS_ADMIN="/usr/local/oracle/network/admin"
export NLS_LANG="AMERICAN_AMERICA.UTF8"
export PATH="$PATH:$DYLD_LIBRARY_PATH"

That’s all of the set-up done, now you just need to install the gem:

gem install ruby-oci8

Done. :)

Posted in mac, oracle, ruby | Tagged , , , , | Leave a comment

Removing ._ Files From Mounted Drives

Here’s a quick snippet of goodness to remove those annoying ‘._’ files that Macs generate on mounted drives…

cd [wherever you want to clean]
find . -name "._*" -exec rm '{}' \; -print
Posted in mac | Tagged , , | 2 Comments

Creating Users on a Linux System

It’s been a while since I’ve had to do any basic sysadmin stuff on a Linux box… seeing as I had to google the answers to this I thought I’d better write them down!

useradd syntax

useradd [options] {username}

Useful options are:

-d
declare the users home directory
-m
force ‘useradd’ to create the home directory
-D
accept the system defaults for account settings

An alternative for ‘useradd’ though is ‘adduser’:

adduser {username}

This will then prompt you for all the information needed to set up the account.

making the user an administrator (with sudo)

As the root user…

visudo

Then underneath the entry for ‘root’ just add in an entry with the desired user name:

{username} ALL=(ALL) ALL
Posted in linux | Tagged , , , | Leave a comment

Git and Github

Here’s the slides of another presentation I gave at work just before the Christmas break - this time on some of the development tools and resources that i’m using in my work: git and github.

The general gist is a basic introduction to both git and github, for developers who are already using version control (i.e. cvs or svn) but have yet to try distributed version control tools such as git.

Posted in other | Tagged , , | Leave a comment

Homebrew: The First Batch

I’ve always fancied trying my hand at a bit of home brewing but never actually found the guts to get myself a kit. Well, this time I finally went through with it and I’m now the proud owner of a starter home brewing kit!

I got the kit from the folks at The Happy Brewer in Bedford, it was very reasonably priced, and they were very friendly and happy to explain what was needed to be done to a complete novice. If you live near the Bedford area and fancy having a go yourself I’d happily recommend them.

The first batch in progress...

That there is potentially 40 pints of Woodfordes Wherry, a very tasty beer sold at the local near the Sanger Institute - fingers crossed I’ll do a good job of it. This is the first fermentation step, in about 4-6 days I can move it into the barrel, then it’s a 3-4 week wait for the finished product. Will update with news on whether I killed myself (and anyone else brave enough to try it) soon! :)

Posted in other | Tagged , , | 1 Comment

Links for 2009-09-22

Posted in links | Leave a comment

IWPLS 2009: The Sanger Mouse Resources Portal - a Testbed for Collaborative Data Integration

Last week I enjoyed some time up in Edinburgh for the International Workshop on Portals for Life Sciences (IWPLS ‘09), hosted at the e-Science Institute. It was a good workshop - there were good presentations, lively debates, and good social planning for the evenings!

I have to admit that quite a lot of the content of the workshop was completely irrelevant to me and went straight over my head at times, but I did enjoy it, and it’s good to hear what other people are doing.

I was there for two reasons, first was an interest in the content of the workshop, and second was that I was one of the people presenting a lightning talk! The content of my talk was pretty different to most of the other presentations - they were mostly about grid computing and development of portal interfaces for said grids - whereas mine was about the architecture I developed for the new Sanger Mouse Resources Portal.

It seemed to go down pretty well, it got a couple of laughs, no one fell asleep and quite a few asked questions at the end, so I was quite happy at that. Here’s the slides from the talk, just in case anyone would like to take a look. Copies of all the presentations from the workshop can be found here.

Posted in other | Tagged , , , , , , | Leave a comment

This Week on Twitter (2009-09-20)

Posted in twitter | Tagged | Leave a comment

This Week on Twitter (2009-09-13)

  • Just arrived in Edinburgh ready for #IWPLS tomorrow. Time to check out some sights, then prepare the presentation… #
Posted in twitter | Tagged | Leave a comment