Site Archives windows

Ruby, Windows and RMagick


Been doing a lot of rails work on windows recently and ran into some issues that needed solved.  Just like on Unix, to get the RMagick gem working on a windows platform you need to install ImageMagick.  Go to http://www.imagemagick.org/script/binary-releases.php?ImageMagick=uteqfietdab37ghqrvfuvoul55#windows and download http://www.imagemagick.org/download/binaries/ImageMagick-6.7.3-7-Q16-windows-dll.exe
Double click and go through the installer, selecting to install C and C++ […]

Cross platform fun


While debugging some test problems with the T2 code I discovered some issues between OSX and Windows regards file paths and line breaks.  Seems that instead of just
inputs.put(”fileUrl”, LocalworkerTranslator.class.getResource( “/AAC4_HUMAN.sp”).getFile());
you have to ensure that the absolute path is correct by doing
URI uri = LocalworkerTranslator.class.getResource(”/AAC4_HUMAN.sp”) .toURI();
File newFile = new File(uri);
inputs.put(”fileUrl”, newFile.getAbsolutePath());
Also, you can’t expect checks for […]