Archive for the ‘windows’ Category

Creating a windows installer from your WxPython application.. a love story.

December 5, 2007

I’ve just finished wrestling with a small wxpython application I wrote a few years back for our bookkeeper. It needed minor updating with a couple of new features. Now that I’ve finished the process here are a few remarks:

  1. Python is a lovely language. After about 14 months of not touching this app (or much of python in any case) it only took a few minutes of review to get back up to speed on it. Granted, I made judicious use of comments and verbose variable naming when I wrote it, but dang is it ever nice clean, clear and simple code.
  2. Once I had the thing running I downloaded and installed the latest version of py2exe (this app is to be installed on an XP machine). This little gem is invaluable in making .exe files from your .py files  and not requiring a Python install on the machine which is going to run the application. Our bookkeeper has no interest in what Python is, never mind running it.
  3. I love the Nullsoft Installer System (NSIS). It’s an open source system for creating professional looking Windows installers. No funky console windows or command line gobble-de-gook for the person installing it – typical modern looking windows install  – wizard style.
  4. Now the Nullsoft installer system is scripted (you have to create a script file to direct the setup) which allows for a lot of power and customization. But if you’re like me and have no interest in building these things by hand, you can use the wonderful HM NIS Edit application which lets you set up the whole thing through a nice friendly wizard.

So in the end, with the combination of my original .py file, py2exe, NSIS, and the HM NIS Edit, I have a very professional looking windows install file after about 5 or 10 minutes work. Brilliant!

Blogged with Flock

My Open Source Oasis

July 4, 2007

I first started dabbling with Linux almost three years ago. In the past year it became my primary OS at home, and now it’s the sole occupant of my home pc. But at work we run AutoCAD on XP Pro, so there’s no escaping the giant from Redmond I guess. However, I have managed to maintain my little ‘open-source oasis’ in this proprietary desert. Here’s how I cope:

First, I run windows versions of my favourite Linux apps. Inkscape, GIMP, and GVim get a full workout here on my XP box at work. More recently I’ve been pleasantly surprised to find that Avidemux (which I use for a bunch of screencasting tasks) has a windows version too. As does Blender, the 3D modelling and animation application that we used to create that 15 second animation for our screencast intros at screencasters.heathenx.org. Oh, and don’t forget Audacity which I use for a bit of audio editing – which has a perfectly serviceable windows version. And let’s not forget OpenOffice which I try to use in lieu of MS-Office whenever I can. Of course Firefox goes without saying.

Next, I run Cygwin, which is a Linux-like environment for Windows. It isn’t an emulator and won’t run native linux apps on windows, but you can recompile linux applications from source to run on Cygwin. However my needs are much simpler. I mostly use it as a terminal for file management and my todo list duties. There is even a port of the X-Window system called Cygwin/X that allows you to run many graphical Linux apps inside of windows. For some reason I can’t seem to get that working – something to do with our proxy server setup here at work. A head-scratcher that is…

Interestingly, I ran Cygwin from a shortcut on my desktop but was frustrated by the fact that it ran inside a DOS window. This limited my font choices to raster fonts or Lucida console 12pt. I could do various things to customize the bash shell (colours etc..) but the font limitation seemed to stick. That is, until I found these instructions for running rxvt on top of Cygwin.

Now I run a shortcut to rxvt and set up the shortcut to launch with whatever font I want. Here’s my current shortcut launch command to get rxvt up and running:
C:\cygwin\bin\run.exe rxvt -sl 1500 -fn “Consolas-14” -bg black -fg grey -sr -e bash –login -i

Now you combine this with the recent excellent blog post (and comments) by Kyle Pott at Lifehacker about turbocharging your terminal, and you’ve got a perfectly serviceable linux terminal inside of XP.

So there you have it. That’s how I get my Linux fix at work. If you’re a lone Linux fish swimming in proprietary waters, how do you cope?

Underwhelmed But Happy About It

January 31, 2007

Earl Moore is underwhelmed by the relatively quiet launch of Vista. Actually I haven’t been paying much attention to Vista simply because I’m almost well and truly Linux-ized (is there actually a term for that? – there should be..)

However I did know about it since I caught 5 minutes of CNN this morning where Miles O’Brien talked a bit about it, showing an interview clip with Bill Gates and discussing it very briefly with their financial guy. I shook my head a little and chuckled when Miles ended the segment by stating that a lot of people were saying that Vista brought the Windows desktop experience up to OS-X standards and perhaps more importantly ended off with the comment that people could upgrade to Vista or “just get a Mac”. I betcha Microsoft PR was just gleeful hearing that comment this morning. 😉

I also had a couple of co-workers discussing Vista with me today. Of course I took the opportunity to nod repeatedly – yes it looks quite flashy… yes it supposedly requires lots more hardware power… yes it supposedly really cracks down on pirated applications and media.. ever heard of Linux?… I actually run it at home…yes it is actually free…

The impression I get is that while Vista will be no outright failure (it’ll be installed on virtually every PC you buy) there are more and more Linux and Mac types who will have more and more conversations with their non-techie co-workers and friends just suggesting (not pushing it down their throats) that there *are* alternatives out there. My feeling is that while MS is not ceding it’s king of the hill status any time soon, the earth is slowly eroding under their feet. It may take a long while, but I think it is happening right now.

Combine all those water cooler conversations with the fact that the OS itself might be of diminishing importance as more and more services reside on the net irrespective of OS. The resurgence of gaming consoles at the expense of PC-based gaming also makes switching from Windows to something else significantly easier.

The fact that the launch didn’t seem to generate much fanfare only bodes well for the future in my mind. It would be nice to see some real market competition in OS’s again.