This is not a blog

May 8, 2007

failing the Turing test

Filed under: DeVry, humor — aberant @ 2:37 pm

My girlfriend’s coworker said the best thing ever when he saw some of the comments other students in my DeVry Online class were making.

Apparently, at least as far as these folks go, they have yet to make the great discovery of “cogent thought” or “even remotely insightful notion”.

“Prose that is at best dull and more likely impossible to parse expressing the most trivial of ideas not worthy of a functionally retarded bivalve” however seems to be all the rage. – Chris Gannon

March 19, 2007

ruby modules

Filed under: Ruby — aberant @ 12:24 pm

So found this out the hard way trying to use modules to overload instance methods in classes.

So if you have something like the code listed below, the module will never execute the test method.


module Mixin
def test
puts "i am in the module"
end
end


class Example
include Mixin
def test
puts "i am in the class"
end
end

This is because when you mix in a module, it’s listed as an ancestor. So when ruby looks for the object to answer the message, it first looks in the class, finds the method, and says job done. It never reaches the module.
For example:

>> Example.ancestors
=> [Example, Mixin, Object, Kernel]

This means that to do things like using a module to overload how an object is converted to yaml you have to crack open the meta-class and do your work there.

November 13, 2006

all your database are belong to rails

Filed under: Ruby, RubyOnRails — aberant @ 12:39 pm

just read about DrySQL and thought it was the best thing ever.  It now makes ActiveRecord smart enough to ask the database for associations instead of you.

November 7, 2006

ruby heart ADSI

Filed under: Active Directory, Ruby, Windows — aberant @ 12:11 pm

so i was trying to find an example of how to use win32ole in ruby that does’t involve excel and stumbled across this interesting post about ADSI. so now armed with this and the reference at MSDN, i now have the shoulder mounted missile launcher i need to crack active directory.

require 'win32ole'
domain = WIN32OLE.connect("WinNT://my_domain.com")
user = domain.Create("user", "my_username")
user.FullName = "Foo Bar"
user.Description = "just a lil ol' test of how ruby <3 ADSI"
user.SetPassword = "my_password"
user.SetInfo

now that i’ve been freed of point-n-click-administration hell, i wonder what i’m going to do with all that free time.

October 25, 2006

The Knife – Heartbeats

Filed under: Video, theknife — aberant @ 12:19 pm

September 17, 2006

MySql 5.0 for idiots

Filed under: MySQL Server, Windows — aberant @ 3:41 pm

maybe this will save you an hour or so of your life to learn from my mistake.  When installing MySql 5.0 on windows and you screw up the configuration and want to start over from scratch a couple things will help you out.

  1. Remove the MySql service before you uninstall.  This can be easily done with the configuration manager and i recommend this because it seemed ( atleast on my system) that uninstaling the program didn’t always remove the service.
  2. Delete the MySql directory in program files after you uninstall.  The configuration files are kept here, so if you don’t delete this before you reinstall, you have to battle with the same botched config files again.

August 16, 2006

has it been this long?

Filed under: Firewalls, Gentoo, Ruby — aberant @ 9:45 am

i’ve just been really busy lately with between work and school, but fortunately i’ll be graduating by next summer.

I’ve also been working on a project at work where i’m creating a rails front end to control a gentoo box running firehol so we can rent this out to clients as a cheep firewall.  I’m also working on having it pull down configurations from a central server, so it’s much easier to manage then having to ssh into every box.

I’ve also been working on this MUD DSL using ruby.  Mostly because the guy i work with is really into MUD’s and i thought this would be a good way to practice some tricky meta programming with ruby.

May 12, 2006

link day

Filed under: Ruby, javascript — aberant @ 7:51 am

A terrific breakdown of what this library is capable of

Using prototype.js v1.4.0 – Sergio Pereira

A fast, event driven, easy to use network library in ruby. i now have no excuse not to make that mud…

Ruby/EventMachine

And of course the teaser site for the awesome scrapbooking site that matt and i are creating

scrapease.com

April 25, 2006

foldersize

Filed under: Windows — aberant @ 12:41 pm

you probably have no idea how many times i've beaten my head against a
wall because i didn't have something like this…  why isn't an easy way to view and compare the size of folders built into the operating system?

http://foldersize.sourceforge.net/

April 21, 2006

thought for the day

Filed under: IBM, humor — aberant @ 8:52 am

All parts should go together without forcing. You must remember that he parts you are reassembling were disassembled by you. Therefore, ifyou can't get them together again, there must be a reason. By all means, do not use a hammer.
—IBM maintenance manual (1925)

Older Posts »

Blog at WordPress.com.