Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Andrew Grimm
You can replace that grep with find . -name "*.rb" so you can have find . -name "*.rb" | xargs cat | grep OMG http://github.com/rails/rails/commit/2ebea1c02d10e0fea26bd98d297a8f4d41dc1aff Andrew On Fri, Feb 12, 2010 at 3:14 PM, Jonathan Clarke wrote: > Insert your swearword of choice below:

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Korny Sietsma
I'm afraid I kill a few trees this way - printouts are still the best way to use my commuting time; until I get something with a kindle-like screen, that also does syntax highlighting (ideally in colour!) :) Mind you, I do print 4-up double-sided, so 316 pages becomes 39 pages of 4-up double-side

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Ryan Bigg
Whilst this app that I'm doing at the moment isn't the biggest I've ever worked on, the total line count of it is 10,128. Given an average number of 32 lines on a single piece of paper, this would mean 316 pieces of paper or 158 if you duplexed. According to this rake stats output the code LOC is o

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Matthew Winter
On 12/02/2010, at 4:09 PM, Clifford Heath wrote: > On 12/02/2010, at 3:45 PM, Matthew Winter wrote: >> On 12/02/2010, at 3:15 PM, Clifford Heath wrote: >> Kill Trees vs Get a big screen >> Eco Papervs Coal fired power station > > Yo

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Clifford Heath
On 12/02/2010, at 3:50 PM, Matthew Winter wrote: On 12/02/2010, at 3:25 PM, Chris Lloyd wrote: In Coders at Work, Peter Norvig recalled working on an interpreter. To refractor it he printed out all the code, took it to a cabin for a week and rewrote it with a pen and paper. My memory is prett

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Clifford Heath
On 12/02/2010, at 3:45 PM, Matthew Winter wrote: On 12/02/2010, at 3:15 PM, Clifford Heath wrote: Kill Trees vs Get a big screen Eco Paper vs Coal fired power station You can turn off a screen. You can't turn a tree on again.

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Matthew Winter
On 12/02/2010, at 3:25 PM, Chris Lloyd wrote: > In Coders at Work, Peter Norvig recalled working on an interpreter. To > refractor it he printed out all the code, took it to a cabin for a week and > rewrote it with a pen and paper. My memory is pretty fuzzy, so it may not > have been Peter Nor

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Matthew Winter
On 12/02/2010, at 3:15 PM, Clifford Heath wrote: > It's never elegant to gratuitously kill trees. > Get a big screen and practise using your tools better, would be my advice. > Kill Trees vs Get a big screen Eco Paper vs Coa

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Matthew Winter
On 12/02/2010, at 3:15 PM, Jonathan Clarke wrote: > Best way to get to know the project is through the tests...read and > understand every one of them and mastery shall be yours... > > There are tests right? > > Jonathan There are tests and plenty of them. Agreed, going through the tests are

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Geoff Tench
On Fri, Feb 12, 2010 at 2:03 PM, Matthew Winter wrote: > Hi, > > I was wondering if anyone knows of a good method of being able to print all > source code within a Rails project, ideally with a single command. > > I have seen many methods of printing Ruby code, but nothing that would > allow me to

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Jared Fraser
As I was just recalling on Twitter, at the end of my first semester teaching, My boss requested that I print out the entire rails app developed by my students (I was teaching a class which just develops a real world project). I objected, but he was insistent. After seeing the sheer size of the thin

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Mark Wotton
Printing out can be helpful for really gnarly code. I used to do it a lot more - even with your own code, you sometimes see it in a different light on paper. mark On Fri, Feb 12, 2010 at 3:34 PM, Ryan Bigg wrote: > I agree with going through the code and reading the tests (again "there are > tes

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Ryan Bigg
I agree with going through the code and reading the tests (again "there are tests, aren't there?", aka TATAT). If the application is a bit light on tests ask them what they spend most of their time as that's probably going to be where you're going to spend most of yours too. See a bug? Write a test

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Chris Lloyd
On 12 February 2010 14:52, Anthony Richardson wrote: > I don't know the answer sorry but the mind boggles as to why anyone > would want to do that? In Coders at Work, Peter Norvig recalled working on an interpreter. To refractor it he printed out all the code, took it to a cabin for a week

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Gavin Sinclair
"head -1" may be better than "cat". It titles each file. On 12/02/2010, at 3:13 PM, Matthew Winter wrote: Hi, When picking up an existing project, I find it so much easier to be able to print the source and work through the paper output. Taking notes etc. Guess this could be someth

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Clifford Heath
On 12/02/2010, at 3:13 PM, Matthew Winter wrote: I guess resorting to unix commands will be the only option. Just figured that someone in the Rails community had probably already wrapped this into some elegant alternative. It's never elegant to gratuitously kill trees. Get a big screen and p

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Jonathan Clarke
Best way to get to know the project is through the tests...read and understand every one of them and mastery shall be yours... There are tests right? Jonathan On 12 February 2010 15:13, Matthew Winter wrote: > Hi, > When picking up an existing project, I find it so much easier to be able to > p

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Jonathan Clarke
Insert your swearword of choice below: find . | grep .rb | xargs cat | grep shit vendor/gems/cucumber-rails-0.2.4/spec/cucumber/web/tableish_spec.rb it "should do complex shit" do My lulz for the day On 12 February 2010 15:03, Grant Bissett wrote: > point the command at a rails project

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Matthew Winter
Hi, When picking up an existing project, I find it so much easier to be able to print the source and work through the paper output. Taking notes etc. Guess this could be something for the iPad to do. I guess resorting to unix commands will be the only option. Just figured that someone in the R

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Grant Bissett
point the command at a rails project and for it to automatically *concatenate* all source code use concatenate! find . | grep .rb | xargs cat yes? -- You received this message because you are subscribed to the Google Groups "Ruby or Rails Oceania" group. To post to this group, send email to

[rails-oceania] Re: Printing Ruby on Rails Source Code

2010-02-11 Thread Nathan
Pretty sure that's a feature of Textmate 2. :) Cheers, Nathan On Feb 12, 2:03 pm, Matthew Winter wrote: > Hi, > > I was wondering if anyone knows of a good method of being able to print all > source code within a Rails project, ideally with a single command. > > I have seen many methods of

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Glen Maddern
It's the 'Filing Cabinet' approach to source control, perhaps? -glen. On Fri, Feb 12, 2010 at 2:52 PM, Anthony Richardson < goo...@anthonyrichardson.com> wrote: > I don't know the answer sorry but the mind boggles as to why anyone > would want to do that? > > Cheers, > > Anthony > > > > On

Re: [rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Anthony Richardson
I don't know the answer sorry but the mind boggles as to why anyone would want to do that? Cheers, Anthony On Fri, Feb 12, 2010 at 1:33 PM, Matthew Winter wrote: > Hi, > > I was wondering if anyone knows of a good method of being able to print all > source code within a Rails project, ide

[rails-oceania] Printing Ruby on Rails Source Code

2010-02-11 Thread Matthew Winter
Hi, I was wondering if anyone knows of a good method of being able to print all source code within a Rails project, ideally with a single command. I have seen many methods of printing Ruby code, but nothing that would allow me to point the command at a rails project and for it to automatically

[rails-oceania] Re: Rubyconf India

2010-02-11 Thread Nicholas Faiz
I just purchased my ticket! Will be trying to spend some time over there seeing things, but also perhaps working from wireless hotspots/ hotel/shared desk space. Cheers, Nicholas On Feb 11, 5:10 pm, James Healy wrote: > Hi Folks, > > Registration for Rubyconf India[1] opened this afternoon, is a

[rails-oceania] 2x Rails developers in Sydney

2010-02-11 Thread Michael Cindric
Hi Guys, Sentia is looking for 2 more devs for min 12month contract or perm role. Prefer 2years plus experience but will look at more junior people if they have the right stuff so still send through ur cv's to j...@sentia.com.au. For full details please check out http://sentia.com.au/2010/02/rai

[rails-oceania] Re: Arel presentation follow up

2010-02-11 Thread sambo99
Re: > > What happens if one of the names contains unescaped SQL? What happens if the > names array is empty? The former compromises your database, the latter causes > an invalid statement exception to be raised. Both issues are averted by using > one of two ActiveRecord query APIs: > >     User

Re: [rails-oceania] Arel presentation follow up

2010-02-11 Thread Nathan de Vries
Hi Sam, Thanks for publishing your ARel experiments. Just a suggestion though, the article could be improved by getting someone who's more familiar with ActiveRecord to check over the examples for you. The reason I say this, is that unless you've been working with Rails for a while, it's quite