Tags: free software

Filing to become a licensed CA

Originally published at The Pædantic Programmer. Please leave any comments there.

Hey there gentle readers,

I am completing paperwork on behalf of Collier Technologies LLC which is required (as described in chapter 19.34 RCW [pdf]) to file with the state of Washington to become a licensed Certification Authority.

CPS (signed)

Look! I’m also running a(n unrecognized) repository!

Neat, huh?

C.J.

GSoC 2010

Originally published at The Pædantic Programmer. Please leave any comments there.

Earlier this month, I applied to the Mono Project (and the University of Washington, and Ubuntu, and Debian, and The Perl Foundation) requesting a mentor to get Perl6 hosted on the DLR.

Last Tuesday, Miguel contacted me and asked that I chat with Michael Hutchinson about possibly taking up a different project. It seems that the group did not have any mentors who felt comfortable mentoring the Perl6 project. After a bit of consideration, I agreed to modify my application and take up a project to revive the regular expression compiler from 2.2.

Today, the project was officially accepted, and I met with my mentor for the first time (hi Rodrigo!).

I will also be working with Matthew Wilson (aka @diakopter), since he has purportedly implemented a number of regex-to-IL compilers ;) He also offered to mentor me if The Perl Foundation had accepted my application, and since he has already implemented a perl6 compiler in javascript, I have been looking forward to poking some code with him.

Although the GSoC doesn’t officially get started until 5/24, I’m making a git-svn checkout now. I’ve always committed the code directly to svn, but I’ve enjoyed working with git, and it seems about time to start contributing via git-svn. It will be easier to have local branches this way, too.

Anyway, I’m looking forward to it ;)

Getting started with gtk♯

Originally published at The Pædantic Programmer. Please leave any comments there.

This is a quick tutorial for getting a first gtk-sharp app up and going.

Install MonoDevelop

$ sudo apt-get install monodevelop libgtk2.0-cil-dev

Start MonoDevelop

It’ll be in your GNOME application menu under Applications->Programming->MonoDevelop

Create a new Gtk# Project

Create New Project

Create New Project

Select Gtk# 2.0 Project

Select Gtk# 2.0 Project

Select Project Features

Select Project Features

Hello World

Hello World

Run project

You can run this boilerplate by pressing Ctrl-F5

Using the Designer

Double-click on the file named MainWindow.cs in the Solution section. When the file opens, click the Designer button below the code view.

The Designer

The Designer

The Toolbox

To add the Toolbox, press Alt-Shift-B or click View->Toolbox.

Drag a VBox widget from the Toolbox to the main window.

Add VBox

Add VBox

Drop a Menu Bar widget into the top cell of the VBox, and a Statusbar into the bottom.

Insert Menu and Status Bar

Insert Menu and Status Bar

Properties grid

Drop a Button widget into the middle cell of the VBox.
Add the Properties grid from the View menu (Alt+Shift+P or View->Properties).
Select the new button by clicking on it.
In the Properties grid, expand the Button Properties section and click the value of the Label field. Delete the default content and replace it with a different string.

Button with new Label

Button with new Label

Adding a Click handler

Select the button in the Designer view
In the Property grid, select the Signals tab
Click twice on the text in the column to the right of the Clicked and replace Click here to add a new handler with MyButtonClickHandler

Add a click handler

Add a click handler

Click on the Source Code button below the viewer window to switch to the C♯ code. You can use the find tool to search for the new handler you created, called MyButtonClickHandler. Ctrl-F will bring up the find dialogue.

Browse to click handler

Browse to click handler

Add some code to update the status bar.

	protected virtual void MyButtonClickHandler (object sender, System.EventArgs e)
	{
		var contextId = this.statusbar1.GetContextId("clicked");
		this.statusbar1.Push(contextId, "Clicky-Clicky" );
	}
Click handler code

Click handler code

Modify button layout

The size of the running window is a little weird. I fixed mine by un-setting the Auto Size boolean and setting the Expand and Fill in the Box Child Layout section of the Properties grid.

Button layout changes

Button layout changes

Exercise button click handler

Run your application with Ctrl-F5 and click on the button. You should see the new string show up in the status bar at the bottom left of the window.

Not yet clicked

Not yet clicked

Clicked + Status update

Clicked + Status update

Add Menu items

Create File Menu Entry

Create File Menu Entry

Create File->Quit Menu Item

Create File->Quit Menu Item

Add Quit event handler

Add Quit event handler

Add Clear Statusbar Activate Handler

Add Clear Statusbar Activate Handler

dlr-languages 20090805+git.e6b28d27+dfsg-1 in squeeze, -2 uploaded, nearly in lucid

Originally published at The Pædantic Programmer. Please leave any comments there.

Yay! The dlr-languages package has been migrated to testing, which means that it will be included in squeeze, the next release of Debian. Jo has uploaded the -2 version and it is now in sid. This version addresses the issues brought up in the Ubuntu Feature Freeze exception (FFe) bug, so I expect that it will be accepted shortly. Still lots of “ifs”, but this is pretty exciting for me, since this is my first debian package, and I’ve been intending to get it in for over two years.

I’m not just sitting on my hands while this happens. I’ve been working with Ivan, Ankit, Dino and Michael to get the next version of the package put together. I’m currently merging Ivan’s latest branch into the changes I’ve made for DFSG compliance. Dino recommended that the next release include IronRuby 1.0 and IronPython 2.6.1, which should be released by upstream around the middle of April.

IronRuby continuous integration back online

Originally published at The Pædantic Programmer. Please leave any comments there.

We haven’t done much work on keeping the continuous integration (CI) machines online, and there haven’t been any new builds since November of ‘09. I should set Nagios to remind us when things get off track or something. The recent acceptance of the DLR into Debian and our intention to get the next release produced has inspired me (and maybe others) to get things back up.

Ivan and I put a couple of Hudson instances up recently that you can reach via hudson-windows.colliertech.org and hudson-linux.colliertech.org. The linux instance is dropping new builds of IronRuby to http://dlrci.colliertech.org/ironruby/. I expect we can tweak the build script a bit and have it also produce IronPython builds. This would hypothetically drop the builds to http://dlrci.colliertech.org/ironpython/.

Ivan mentioned that we may get CNAME records which would activate the windows-builds.ironruby.net and linux-builds.ironruby.net hosts as well.

Note that these builds are being produced from the linux branch of git://github.com/casualjim/ironruby.git

Thanks for your work on this, Ivan!

More DLR work

Originally published at The Pædantic Programmer. Please leave any comments there.

Ivan put up a hudson server on our winders box. Ankit helped me figure out the IronRuby xbuild build problems. I should probably try it on IronPython, too. I sent the ironruby-core list a patch to fix some case sensitivity issues. Some time in the near future, I’m going to get together a bug report for the compiler and send it off to Marek. But I’m tired and Scarlet’s got a friend doing the sleep-over thing tonight.

So. Later ;)

P.S., can you believe that nobody registered a11y.com before now? Crazy talk.

P.P.S., does anyone out there in gnome land have a ruby app they want to test for compatibility with IronRuby?

IronRuby on OS X

Originally published at The Pædantic Programmer. Please leave any comments there.

We had a visitor on #ironruby today asking for help getting IR running on his mac. I gave him the following directions, and they seemed to work aside from one glitch. I tested them on my wife’s mac, and it worked for me, too.

Install Mono

You can grab the Mono .dmg from go-mono.com. This will install the framework and put the required programs (mono, xbuild) in your PATH.

Fetch the IronRuby source

Since Jim Deville likes macs, I’m sure more recent versions will work, but this is the one we’ve recently packaged up for Debian and tested on Ubuntu. If you want to be certain that the IronRuby code you write on Debian works on OS X, then you should probably build from the same version of the source. You should probably also install version 2.4.3 of Mono, but that may be more effort than it’s worth ;)

http://github.com/mletterle/ironruby/tarball/20090805+git.e6b28d27

Unpack the tarball

Open up a terminal and unpack the thing you just downloaded:

$ mkdir ~/src/
$ cd ~/src/
$ tar xfz ~/Desktop/mletterle-ironruby-e6b28d2.tar.gz
$ cd mletterle-ironruby-e6b28d2/

Build IronRuby

At this point, you should be able to build the IronRuby assemblies using xbuild. I don’t recommend using rake, as it has some dependencies, and I’m not a fan of dependencies.

$ xbuild /p:TreatWarningsAsErrors=false Merlin/Main/Languages/Ruby/Ruby.sln
<snip/>
Build succeeded.
	 2817 Warning(s)
	 0 Error(s)

Time Elapsed 00:00:28.8378230

Run the IronRuby interactive interpreter

Our guest mentioned that he was using a terminal with a white background. Do note that the font color of the interactive interpreter (aka Read-Eval-Print Loop or REPL) is white, so if you’re using a white background, you might want to change it. IIRC, there is a way to change the font color using a configuration setting. Figuring it out is left as an exercise for the reader.

$ mono Merlin/Main/Bin/Debug/ir.exe
IronRuby 0.9.0.0 on 2.6.3 (tarball Wed Mar 10 18:18:12 MST 2010)
Copyright (c) Microsoft Corporation. All rights reserved.

>>> 1+2
=> 3
>>> exit()

Extra credit: IronPython

The tarball you downloaded also included the source to IronPython. The procedure to build/run IronPython is pretty similar to IronRuby.

Build IronPython

Unlike IronRuby’s .sln, this version of IronPython’s .sln does not have a default configuration parameter, so we need to specify it with the /p:Configuration=Debug argument.

$ xbuild /p:TreatWarningsAsErrors=false /p:Configuration=Debug Merlin/Main/Languages/IronPython/IronPython.sln
<snip/>
	 69 Warning(s)
	 0 Error(s)

Time Elapsed 00:00:38.8057450

Run the IronPython interactive interpreter

IronPython has a REPL interface like IronRuby’s. Or is it the other way around? Anyway, here’s an example.

$ mono .//Merlin/Main/Bin/Debug/ipy.exe
IronPython 2.6 Beta 2 DEBUG (2.6.0.20) on .NET 2.0.50727.1433
Type "help", "copyright", "credits" or "license" for more information.
>>> 1+2
3
>>> ^D

dlr-languages_20090805+git.e6b28d27+dfsg-1_amd64.changes ACCEPTED

Originally published at The Pædantic Programmer. Please leave any comments there.

I’m happy to announce that after the filing of an Intent to Package and nearly 2 years of work, IronRuby 0.9, IronPython 2.6b2, and the DLR are now in Debian. To my knowledge, this is the first package in Debian with direct and active upstream support from Microsoft.

Kudos for this release go to Jo Sheilds (package sponsorship & mentoring), Mirco Bauer (package sponsorship & mentoring), Matthias Klose (IronPython package review), Ivan Porto Carrero (IronRuby build/test support), Michael Letterle (IronRuby build/test support), Jim Deville (IronRuby build/test support), Jimmy Schementi (upstream point of contact @ Microsoft), Dino Viehland (IronPython build/test support), Michael Foord (IronPython build/test support), Marek Safar (mono c# compiler support), Ankit Jain (xbuild support), the folks on OFTC’s #debian-cli, Freenode’s #ironruby and GimpNet’s #mono, and the folks on the IronRuby and IronPython mailing lists.

This is my first package in Debian, too. I’m pretty ecstatic ;)

PPA installation on karmic

Originally published at The Pædantic Programmer. Please leave any comments there.

I don’t know how long add-apt-repository has been around, but I’ve found it very useful for installing some of the bleeding edge stuff I want to test:

$ for ppa in do-core team-xbmc nvidia-vdpau chromium-daily directhex/monoxide
do
  sudo add-apt-repository ppa:$ppa
done
$ apt-get update
$ apt-get install chromium-browser nvidia-glx-195 gnome-do xbmc monodevelop

Is there anything like this for debian proper, I wonder?