Showing posts with label rails. Show all posts
Showing posts with label rails. Show all posts

Tuesday, November 30, 2010

this month in the machine...

Had three events this months.

First was the regard ActionHack. I great hacking afternoon at the iLab incubator's boardroom in Toowong.

Second was a big weekend at #railscamp in Perth.

Andrew Grimm (A sysadmin at UNSW) gave in interesting presentation of using an evolutionary like randomly generated programs (mutations) to test Rubinius. He used other ruby implementations (as a group) to validate Rubinius' returns. The other implementations effectively becoming the environment appling natural selection on Rubinius, to determine its fitness.

Andrew's slides

Thirdly, Last week I went to a Linux Users Group meeting. HUMBUG's fortnightly meeting at UQ. Was just a chat & hack session. I had one problem, but solved it that morning.

I had a mial server issue on my first attempt to set up a mail server. I found that courier (I think?), when reading the authpgsqlrc file, is failing to recognize comments and thus getting the auth requests against the database wrong. The fix was to move the comments to the next line, instead on the end of the line they apply to.

Next weekend is a new month, off to ActionHack.

Thursday, December 31, 2009

Been playing with Googlemaps

Been playing with googlemaps and rails. The first step is geo-coding the address to Lat long coordinates.

Here is my first play code

require 'net/http'
require 'uri'
require 'rubygems'
require 'builder'

addrs = [ "1600+Amphitheatre+Parkway,+Mountain+View,+CA",
"1159 Gympie Rd Aspley QLD 4034 ",
"14 Morayfield Rd Caboolture QLD 4510 ",
"521 Ipswich Rd Annerley QLD 4103 "
]

placemarkbase = 'List'
placemarks = Hash.new

xml = Builder::XmlMarkup.new(:target => $stdout, :indent => 4)

geocoder = "http://maps.google.com/maps/geo?q="
output = "&output=csv"
apikey = "&key=### insert your googlemaps token here ###"

counter = 0
addrs.each do |addr|
request = geocoder + addr + output + apikey
sleep 2.0
url = URI.escape(request)
resp = Net::HTTP.get_response(URI.parse(url))
fields = resp.body.split(',')
placemarks[placemarkbase + counter.to_s] = [addr,fields[3],fields[2]]
counter += 1
end

kml = { 'xmlns' => 'http://earth.google.com/kml/2.2'}
xml.instruct! :xml, :version => "1.1", :encoding => "US-ASCII"
kml.each do |key,value|
xml.kml(:xmlns => value) do
xml.Document do
placemarks.each do |key, array|
xml.Placemark do
xml.name(array[0])
xml.address(array[0])
xml.description(placemarkbase)
xml.Point do
str = array[1].to_s + "," + array[2].to_s + "," + 0.to_s
xml.coordinates(str)
end
end
end
end
end
end

Saturday, October 31, 2009

Action Hack: features research on github

During Action Hack I did a quick scan of GitHub.

Was looking for ideas for laying out and grouping features. I looked at 20 projects that had features folders.

Almost all of them just had a flat structure. Simply features files named for groups of features.

The one exception had sub directories that grouped the feature files by release.

Would be interested in hearing how people layout their features.

Gnoll110

Tuesday, June 30, 2009

Git & Capistrano

Last month I got my first Vertial Private Server (VPS) at slicehost.

Got it setup. Used Git & Capistrano for the first time, Happy with Both.

Found a good into tutorial for them, that I can't find atm Doh!

Will post links when I do.

Cheers,

Gnoll110

Update: Found it, it's called 'the building of jetrecord episode 3 git capistrano and a test release'.

Whole Series:
the tabula rasa of doom
tell me a story
git capistrano and a test release
cucumbers and webrats

Sunday, May 31, 2009

CSS background images & Rails

Setting a CSS background image in Rails have one quirk, when using a relative url, the base directory is not the base directory of the project. It's the directory where the stylesheet CSS file lives. So the correct relative url is this;

#wrapper1 {
background: url(../images/background.gif) repeat left top;
}

when the image & stylesheet live in the usual places.

Gnoll110

Sunday, November 30, 2008

RailsCamp4: BackgrounDRb

It has been two week since I got back from Railscamp4 in Adelaide. Been off the grid mainly. Took lots of notes and idea point during the weekend.

The first I'd like to note in a background processing utility. It looks interesting but I've not had a chance to use it. Hopefully I will in the next month or so.

Here is the link to BackgrounDRb.

Enjoy


Gnoll110

Monday, June 30, 2008

Discovery: Rubyspaces

At Rail Camp, the weekend before last.

While flicking through the index of the pickaxe, I came across an entry for JavaSpaces. Went to the indicated section and found a little bit of sample code that shows the concept.

Run it, worked great. This discovery alone make the trek up to Brisbane Water all worth it.

Gnoll110

Saturday, May 31, 2008

Rail sand box!

While at the Canberra Ruby Crew night, on the 30th May, I was introduced to the heroku site.

An IDE (Integrated Development Environment) in a browser.

In this case it a build environment for the Ruby On Rails framework.

Looking forward to playing it.

Will keep people posted, in my copious spear time ;)


Gnoll110

Thursday, January 31, 2008

Canberra Ruby Crew

There is a new special interest group in town.

The Canberra Ruby Crew (CRC). The first get together was earlier this month.

The second will be of the night of 15 Feb. I'll be there. Don't know the venue yet, stay tune.


Gnoll110

Friday, December 28, 2007

Picked up ‘Refactoring Databases: Evolutionary Database Design’ by Scott W. Ambler & Pramod J. Sadalage at the start of the month.

Ask one of the DBAs at work if he had read any book or articles by Scott Amber. His awnser was ‘Who’s that?’. Not an inspiring reply.

Think ‘Refactoring Databases’ is worth the effort. Looking forward to using some of the ideas when I start using Merb, next week.

Think I’ll get ‘Refactoring to Patterns’ or one or the enterprise pattern books in January.

In January, I think I’ll also try to start pulling a Canberra Ruby group together. Will start with a Coffee get together with the 2 other Canberra guys I meet at the RailsCamp2 at Bacchus March and go from there.


Gnoll110

Friday, November 30, 2007

RailsCamp2 and Merb

RailsCamp 2 was last weekend at Bacchus Marsh, just west of Melbourne.

Was a great weekend. About 40 camper attended.

Learn some new things, including some of the new stuff in the Rails release, due real soon.

Other package I was introduced to include Merb, another framework, that includes a more flexible and extensible structure. Going to look at that this weekend.

There is Flog too. It's a complexity metrics tool.

Lots to play with.


Gnoll110

Sunday, August 26, 2007

Life in a 24x7 world: Seesaw

Need to be able to roll your servers processes without bringing a site down. Seewas enables you to increment the version of components in your application, without an outage.

Max Muermann and Matt Allen have written the Seesaw rudy package that lets you roll Mongrel processes.

Matt & Max were working on it at the Hax day, in Sydney, last weekend.

Has a chat to them about the next stage. The hard stage, rolling the database structure forward without downtime. I think it is possible, but the features needed to make it possible need to be part of the bone and muscle of the database management system (DBMS). I'm going to write a post able how I think it could be done and its limits.


Gnoll110

Technorati tags:

Monday, August 20, 2007

Ruby: Hax Day

Ruby on Rails Oceania held a Hax Day at lachie’s place last Saturday. All good value. Like to thank Lachie and his sweet darling wife for looking after us. Wireless, food and drink; what else could you ask for?

This ruby newbie learnt a few things and picked up some new gems (HAML, SASS & Staticmatic).

Gnoll110

Technorati tags:

Monday, July 30, 2007

Ruby: One Day on Rails

Better late that never.

Last weekend, 21 & 22, I went down to Melbourne to attend Cogent Consulting’s Ruby on Rails EAT workshop. Steve Hayes lead the workshop. The workshop was on the Saturday and was titled ‘One Day on Rails’.

It was a good intro to Ruby, Rails and Cogent’s tools & practices. It was divided about a third each way.

The InstantRails tool was used to ensure everyone started with the same configuration. I had some problems with mysql, it all came down to the fact that Zip didn’t work the first time. After the second upzip, everything worked great.

I’ve been using InstantRails over the last week, as I continue to work through the Agile Web Development with Rails book.


Gnoll110