Archive for October, 2007

29OctMozREPL: REPL for mozilla

Adam Burmister, a collegue @Xero put me onto MozREPL

Connect to Firefox and other Mozilla apps, explore and modify them from the inside, while they’re running.

Execute Javascript, play with browser GUI, sneak into HTML pages, examine functions and variables, redefine them on the fly, hot-fix bugs, … MozRepl itself is programmable from within MozRepl.

 

del.icio.us tags: , ,

29OctA little browser with ironruby and wpf

Whilst preparing for my talk on saturday I got to play a little with Iron ruby and wpf.

One of my experiments was to create a little browser which i dubbed biffy :)

You can download it here: biffy.zip

 

del.icio.us tags: , ,

29OctSVNBridge is finally working

So this weekend I discovered that SVNBridge is working fine now.

I haven’t tried it against our production TFS server but against codeplex it works great.

http://www.codeplex.com/SvnBridge

SvnBridge – Use TortoiseSVN with Team Foundation Server

Project Description
SvnBridge allows you to use TortoiseSVN and other Subversion clients with Team Foundation Server. It converts the calls made by your Subversion client to the API supported by TFS.
SvnBridge works by running an executable on your local machine that acts as the bridge to TFS. You point SvnBridge at the TFS server, and point TortoiseSVN at the bridge running on your local machine. This allows you to use TortoiseSVN with any TFS server without needing to change the TFS server in any way (no need to convince your system administrator of anything!).

If you haven’t checked it out already, it’s definitely worth a look.

 

26OctI like what I’m seeing from Microsoft lately

Microsoft has just hired Rob Connery from SubSonic, and his job is going to be to work on his own open source project.
I am very pleasantly surprised by that news, and this is the change of direction so many people have been waiting for I think.

I for one like this whole new direction of embracing open source. It seems like lately the party can’t stop, they also hired: Scott Hanselman, Phil Haack and Alex James. I should maybe start thinking about getting one aggregated feed from msdn :)

It’s good to see that open source projects are now being endorsed. I can’t wait to see what’s next. 

24OctGenerics overwhelming

Ayende put this post up which looks freakishly a lot like some code I wrote a couple of months ago.


public abstract class AccountServiceBase<T, K, Q> : IAccountService<K>

        where T : BankImportSetup, IAccountData, new()

        where K : class, IAccountData, new()

        where Q : class, IEntityQueries<T, K>, new()

        .....

The reason for building it this way is that I have to implement something for heaps of banks each one has a subtle difference in the way they are processed. But 95% of the code would be the same for every BankImportSetup entity.

This way I could save a lot of time by going a bit overboard on the generics side of it.

To cut a long story short. Generics are fun but they can be pretty overwhelming at first.

 

PS. My colours look very different on my pc. It's copy source as html that doesn't pick up all the colors resharper adds.

22OctRejoining the pack

The last year I’ve dabbled a lot with linux, ruby etc. Investigating alternative means of developing web applications.  I have switched back to vista ultimate x64 now because I spend about 95% of my time developing on windows so it didn’t make sense to run linux as a base system.  Both ubuntu with Beryl or vista are just as slow/fast on my computer the admin time for my windows system is a lot shorter than the one for my ubuntu system.

I’m not taking a hard line against webforms any more, I still think I won’t be using them in complex projects but for quick prototyping the dynamic datacontrols are pretty cool. Which won’t stop me from building my own mvc style architecture because the current defacto standard is suffering from code bloat and a too tight integration of javascript frameworks etc.

This weekend I’ve finally started playing around with c# 3.0 and silverlight and I liked what I saw a lot. 

I’m getting my head around the new technolgies by building a little texas holdem multiplayer game.  So the technologies this project will use are: .net 3.5 with c# 3.0, silverlight 1.1 (with xaml), WCF.

I started building that texas holdem poker game because I couldn’t find a nice one that I could install on my LAN or one that wouldn’t require me to get a mortgage if I would lose a game online.

The microsoft one that comes with vista ultimate is nice and i aim to beat it by making it multiplayer.

The most challenging bit of this poker game is definitely the AI for the computer players because I don’t want them to be idiots but also not the best players in the world seen as i’m not the world’s greatest poker player (I’m still working for a living :) ). If somebody that reads this blog has done some similar work or knows of some resources for me to work through some of that stuff please share them.

So far I’ve got the following logic going:

Evaluating wheter it’s a good hand or a bad hand: simulate about 1000 games with the same hand,same cards on the table and the same number of players.

That gives me an idea of how good the hand is and if it should fold.  Next I want to figure out whether the player should bet, check or raise this is done by looking at the odds and the maximum score I could reach as well as how far along we are in the game.. I have more in my head but not enoughtime to write it all down. I’ll write more on this subject in the course of the next few weeks.

I’m planning on making the multiplayer version open sourced for demo purposes but not the one that contains the AI for the computer players.

 

del.icio.us tags: , , ,

18OctGet all the css classes in use on your page

By using javascript that can be done pretty easily. The script below requires prototype

var classes = [];
function collectClasses(ele){
  var children = ele.childElements();
  if(children.length > 0){
    children.each(function(el){collectClasses(el);});
  }
  else{
   ele.classNames()
     .each(function(className){classes.push(className)});
   return classes;
  }
}
var body = document.getElementsByTagName(‘body’)[0];
collectClasses(body);
var myUniqueClasses = classes.uniq();

 

The myUniqueClasses variable holds all the classnames that are in use on your page.

 

 

del.icio.us tags: ,

Recent Flickrs

    Blogroll

    Recent Listening

    Scrobbler
    • Loading...