Scripts to help workflow now on google code.

Posted by stu at January 25th, 2010

I’ve uploaded my scripts to help workflow to google code, naming the project batch flow.

Heres a summary of some of the things you can do.

Clipboard integration

Go to a directory in the clipboard.

If you have the address bar enabled in explorer:

Copy the location, go to the prompt and enter ‘pcd’ to go to that folder

Go to the location of a setting in netbeans or eclipse:

Copy the location , go to the prompt and enter ‘pcd’ to go to the folder (or folder containing the file).

Get the current directory without dragging:

Enter ‘ccd’

Directory bookmarks

dirsave and dirload let you save named bookmarks.

Using hotkeys

If you use the alternate shell 4nt (or the free TCC/LE) you can use the supplied configuration and aliases to access the bookmark functionality from the keyboard:

In the 4nt or tcc/le prompt enter “option”, under the “TCStart/TCExit” path, change the location to the location where batch-flow is installed + “\conf”, for instance on my computer batch-flow is installed to c:\usr\batch-flow, so I set it to

c:\usr\batch-flow\conf

Now in new TCC/LE prompts F5-F10 are reserved for directories: Ctrl+Fkey to save, and Alt+Fkey to load.  Alt-F12 lists these shortcuts.

Note:  Alt-F12 only lists shortcuts on FKeys, to list these and other shortcuts enter dirload /l

batch-flow comes with other handy hotkeys, use ‘alias’ in TCC/LE to see what they are.

Path manipulation

addpath

It’s annoying after installing a program to have to add it to the path, so there is an ‘addpath’ command to do this.

regpath

This is a more general utility for viewing the registry path, you can list it, validate it, check for the location of files within it.

Also useful is ‘regpath /L’ which sets the local prompts path to the one in the registry.

Further help

Most of the commands have help builtin, which you can access by using the /? option.

Posted in Uncategorized| No Comments | 

Access files in a Linux virtual machine from Windows

Posted by stu at January 21st, 2010

I recently found a neat way of accessing files in a linux VMWare image.   This is really useful, as theres never really a good time to break your VMWare image, this is also handy if you don’t want to run the whole machine, but just access the files inside.

There is one caveat:

  • It only works if the filesystem is ext2 (ext3 works, and ext4 probably works).

Install VMWare DiskMount Utility

Accept the EULA, download and install the VMWare DiskMount utility.

For convenience add the utilities folder to the path:

C:\Program Files\VMware\VMware DiskMount Utility

Do this through the Windows Gui, or even use my addpath utility.

At this point you can mount Windows VMWare images.

The usage is:  vmware-mount drive-letter vmdk-image.

Heres how I mount my Ubuntu image to the j: drive

[C:\vmware\Ubuntu]vmware-mount j: ubuntu.vmdk
[C:\vmware\Ubuntu]

No output here indicates success.

At this point everything seems fine, but a crucial piece of the puzzle is still missing; try and view the files and you still can’t:

Failing to see files in an ext2 VMWare image

The next step is to make Windows understand the ext2 filesystem, using a special driver.

Install ext2ifs

Grab ext2ifs from www.fs-driver.org and install.

If the following steps don’t work then you may need to reboot.

Thats it!

You should be now able to access files inside your VMWare image (assuming it’s ext2 and not reiserfs), remount the image and have a go:

In my case I did:

[C:\vmware\Ubuntu]vmware-mount j: ubuntu.vmdk
[C:\vmware\Ubuntu] dir j:

Heres the output – hooray, I can copy my work out of the image !

Viewing files inside a VMWare image with ext2fs

This is very useful, especially if you do dist-upgrade in ubuntu and can’t access the network.

Bonus tip:

Newer versions of VMWare player let you install VMWare tools from inside the GUI, this is another way to fix the kind of catestrophic problems you can cause yourself by accidentally upgrading the kernel in an image.

Posted in Uncategorized| No Comments | 

Using Java2Python to port a JavaCairo tutorial

Posted by stu at August 21st, 2009

I recently came across Java2Python.  As I’m interested in Cairo I thought it would be interesting to try porting one of the example tutorials from ZetCode.

I’ll run through the steps involved in porting then try and reach some conclusions at the end :) .

1. Get setup

This is easiest in Linux, I’m running Ubuntu (in vmware), and installed

antlr 2.x
python2.5.x
sun java6
pygtk
java-gnome

You can install them like this:

# sudo apt-get install antlr python2.5 sun-java6-bin libjava-gnome-java

Then install Python2Java with easy_install

# sudo easy_install-2.5 java2python

To test if it’s working run j2py -i.  It should complain there is no file:

# j2py -i
Usage: j2py [options]

j2py: error: -i option requires an argument

If you get any other errors your missing some packages.

2. Get the Java Code from the Simple Example.

Save the ’simple.java’ example as ‘GSimple.java’

If java-gnome is running ok, compiling and running it you should see a window:

# javac GSimple.java
# java GSimple

gsimple

Now we’ll run through the code, it’s important to understand what it does before we port it…

(more…)

Posted in Uncategorized, projects| 9 Comments | 

The Bloggage and slacking

Posted by stu at August 7th, 2009

Just been checking out what Mr Palmer has been up to… quite a lot it seems…   if I could get further than 2 chapters in 6 months with Getting Things Done maybe I could stop procrastination and start GTD too :)

And I’ve been checking out some online comics…

My 6 monthlyish check on SayUncle comics blog always makes me want to do some drawing.

Also Quite enjoying the Beartato in space storyline in nedroid.

Posted in Uncategorized| No Comments | 

Toast

Posted by stu at January 9th, 2009

Lyrics

Posted in Uncategorized| No Comments | 

Router upgrade nixed xbmc

Posted by stu at December 14th, 2008

It turns out my lack of networked media consumption utopia via xbmc was all down to upgrading my router… the xbox was fixed on 10.0.0.x while everything else moved over to 192.168.1.x  …so I learned that SMB doesn’t like that at all.

Oh well, one task down… many more todo… maybe I can actually setup my kurobox in the next few days and then some really nice things might be possible.

Posted in Uncategorized| No Comments | 

Noodleglue – found!

Posted by stu at October 1st, 2008

For the last few days I’ve been looking for a project called NoodleGlue.  I got interested when I wanted to look into generating java wrappings for the Verse library.

If you just want to download Noodleglue skip to the end of the article.

Verse is a network protocol that lets 3d applications talk to each other in realtime, being developed by the Blender foundation.  I was wondering how difficult it would be to link the ease of use of processing with the power of Blender.

(more…)

Posted in Uncategorized| 8 Comments | 

Track all your forum posts in delicious

Posted by stu at September 21st, 2008

I’ve been using delicious for a while, but have started bookmarking all my forum posts in there, it should be a lot easier for me to find out whatever I was talking about in the future :)

Posted in Uncategorized| No Comments | 

Warn: There is another system

Posted by stu at September 15th, 2008

Saw “Colossus, The Forbin Project” last night; The U.S. gives an AI control of all it’s nukes… what could possibly go wrong?

Shortly after they turn it, on a message comes up “Warn:  There is another system”, it turns out the Russians have done the same thing, and the system wants a link.  I won’t give away any more of the film, which has some seriously cool looking 70s tech in it (and obligatory wooden panelling everywhere).  I did like the message in the “computer” writing of the time, so made an version in Inkscape, as it would probably make a cool T-Shirt.

Posted in Uncategorized| 2 Comments | 

ZX Spectrum flightsim

Posted by stu at July 12th, 2008

Just found this while going through my phones photos.  This is from my last contract, the company used to be Psions software division, we found the tape in the bottom of a desk draw, who knows maybe it is the master tape for this game?

Psion flight simulation on cassette

Update:  Link to PsionSoftwareLTD promotional information on worldofspectrum.org

Posted in Uncategorized| No Comments | 

Next Postings »