yasushi has quit [Remote host closed the connection]
<karstensrage>
hmm
<karstensrage>
should something like 'method arg1 { :foo => 'foo', :bar => 'bar' }.merge otherhash' work?
Progster has joined #ruby
<karstensrage>
or is there some way to make the { :foo => 'foo', :bar => 'bar' }.merge otherhash be arg2? without taking it out?
<karstensrage>
scoping with '() ' or something?
<fowl>
karstensrage: () does not open a new scope
fyolnish_ has joined #ruby
<fowl>
karstensrage: when passing a literal hash you have to use () otherwise ruby thinks its a block
deryl has quit [Read error: No route to host]
deryl has joined #ruby
<fowl>
what are you trying to do o_O
deryl is now known as Guest21486
pingfloyd has joined #ruby
mmitchell has joined #ruby
noyb has joined #ruby
CircleDot has quit [Read error: Connection reset by peer]
<karstensrage>
ok, i think () will work
fyolnish_ has quit [Ping timeout: 244 seconds]
<karstensrage>
lemme give it a try
Elico1 has quit [Ping timeout: 264 seconds]
Guest21486 has quit [Client Quit]
fantazo has joined #ruby
sailias has joined #ruby
wpaulson has joined #ruby
sailias has quit [Client Quit]
ThatDudeGuy_ has quit [Quit: ThatDudeGuy_]
dpk has quit [Quit: Asleep at the keyboard.]
Elico1 has joined #ruby
cakehero has quit [Ping timeout: 252 seconds]
gfontenot has quit []
<shevy>
karstensrage you must remember that the ruby parser tries to find out what you wanna use. in ruby, a hash can be screated via {}, but {} can also be used for blocks. ruby needs to "guess" which one is the correct
<shevy>
*created
<davidcelis>
pretty sure ruby doesn't guess, pretty sure if a method takes a block, ruby just assumes it's a block
cakehero has joined #ruby
rednails has joined #ruby
rednails has left #ruby [#ruby]
n_blownapart has joined #ruby
n_blownapart has quit [Remote host closed the connection]
Elico1 has quit [Ping timeout: 244 seconds]
savage- has joined #ruby
<karstensrage>
i gotta say, im liking ruby a lot better than python
<karstensrage>
and you guys are a great help, i really appreciate that
<Spooner>
davidcelis shevy: Ruby will happily pass a block to a method that doesn't have any interest in the block. It can parse the difference between a hash and a block though. E.g. f.meth {} is a block, but f.meth({}) is a hash argument (as is the implicit f.meth(x: 12)
slyv has quit [Quit: Cya]
<ryanf>
it's just a question of whether it decides to use yield
<ryanf>
which can't be determined statically
<ryanf>
well, I guess it could, but it's not
adamjm has joined #ruby
bananagram has quit [Ping timeout: 272 seconds]
<davidcelis>
basically what i meant
<davidcelis>
is that guessing is not involved
bananagram has joined #ruby
CodeFriar has quit [Quit: Leaving...]
pdtpatrick has quit [Quit: pdtpatrick]
rking has quit [Quit: Freeing up memory]
bluenemo has joined #ruby
bluenemo has quit [Changing host]
bluenemo has joined #ruby
<shevy>
{} means a hash, Hash.new {} to pass a block to it, {}{} however does not work
kvirani has quit [Remote host closed the connection]
adamjm has left #ruby [#ruby]
<Spooner>
Yeah, not guessing. It is more that as a newbie has to guess what Ruby will what it is handed ;)
<karstensrage>
it worked putting () around it so 'method arg1 ({ :foo => 'foo', :bar => 'bar' }.merge otherhash)
<flyinprogramer>
you modified the reg and added: .+(.\d+.\d+)/
banisterfiend has quit [Remote host closed the connection]
afex has quit [Quit: afex]
<flyinprogramer>
why do you have to add that, i was under the impression that the single matching group would catch all possible matches, not the first
<flyinprogramer>
**not just the first
<deryl>
yeah because you need to list each match you want. not just the first. it stops matching after the first match
<flyinprogramer>
ah
<flyinprogramer>
that seems silly, but i'll accept it
pdtpatrick has joined #ruby
<deryl>
:shrug: i didn't write it, i just follow its rules
<crocket>
I think ruby or something cached a verion of a program somewhere.
<deryl>
anyways, time for bed now that the kids are down.
<crocket>
How can I remove that cache
<flyinprogramer>
yup, you're correct, if you use scan instead of match, you get all occurrences
cakehero has quit [Quit: Leaving...]
yoklov has joined #ruby
mmitchell has joined #ruby
Elico1 has quit [Ping timeout: 260 seconds]
horofox has joined #ruby
justinmcp has joined #ruby
Karmaon_ is now known as Karmaon
Elico1 has joined #ruby
justinmcp has quit [Remote host closed the connection]
justinmcp has joined #ruby
mmitchell has quit [Ping timeout: 276 seconds]
stabby_lambda is now known as rjsamson
Kilaru has joined #ruby
Kilaru has left #ruby [#ruby]
digitalcakestudi has quit [Ping timeout: 252 seconds]
robbyoconnor has joined #ruby
robbyoconnor has quit [Read error: Connection reset by peer]
robbyoconnor has joined #ruby
mneorr has joined #ruby
Elico1 has quit [Ping timeout: 260 seconds]
Axsuul has quit [Ping timeout: 268 seconds]
fbernier has quit [Ping timeout: 276 seconds]
chimay has quit [Quit: WeeChat 0.3.9-rc1]
Axsuul has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
emmanuelux has quit [Remote host closed the connection]
niklasb_ has quit [Ping timeout: 246 seconds]
raul782 has quit [Remote host closed the connection]
Elico1 has joined #ruby
justinmcp has quit [Remote host closed the connection]
<Azure>
[Sep09 12:43:14AM] <Azure> I have not one idea how to make a 'live' blog feed display via command line (or pushing it some other way, like irc.)
<Azure>
[Sep09 12:43:34AM] <Azure> Anyone got anything that they could point me towards?
<Azure>
[Sep09 12:43:45AM] <Azure> already searched google, and well, nothing.
<Azure>
blazes816, ^
rippa has joined #ruby
pu22l3r has joined #ruby
<blazes816>
so you want to push the new blog post notification
<blazes816>
?
<blazes816>
pub/sub server is probably your best bet
Elico1 has quit [Ping timeout: 260 seconds]
machty has joined #ruby
Elico1 has joined #ruby
mahmoudimus has quit [Quit: Computer has gone to sleep.]
pdtpatrick has joined #ruby
mahmoudimus has joined #ruby
<crocket>
What is unicorn?
coyo has joined #ruby
coyo has quit [Changing host]
coyo has joined #ruby
<davidcelis>
a mythical creature, essentially a horse with a spiral horn coming out of its forehead
<davidcelis>
most typically they are a pristine white
fbernier has joined #ruby
<Azure>
blazes816: yeah, I thought so. I should be able to access a wordpress blog and get those notifications for when it updates?
<blazes816>
unicorn is also a ruby http server
<blazes816>
Azure: you'd want to write a plugin for WP so that it publishes a notification to your pub sub server
mahmoudimus has quit [Client Quit]
<Azure>
I see. I would have to talk to the owners in that case. :p
<blazes816>
ah, i see
<blazes816>
the best you could do in that case is polling
<crocket>
Why is it so slow to execute "bundle exec unicorn_rails -c config/unicorn.rb -E production -D"?
<crocket>
apache httpd just starts within two seconds.
<crocket>
blazes816, 'bundle exec rake environment resque:work QUEUE=* RAILS_ENV=production BACKGROUND=yes' is also slow to start.
rippa has quit [Ping timeout: 244 seconds]
<crocket>
blazes816, It seems my ATOM cpu is too slow.
<blazes816>
crocket: sorry? things in prod tend to be slow. you can profile if you like.
<blazes816>
yeah, probably
<crocket>
Is unicorn faster than apache?
mmitchell has quit [Read error: Connection reset by peer]
mmitchell has joined #ruby
Z_Mass has joined #ruby
<blazes816>
are your trolling?
<crocket>
blazes816, no
crazed has joined #ruby
<snorkdude>
blazes816, get a chance to check it out?
<blazes816>
crocket: then read the unicorn docs and decide if it's preferable to passenger
<blazes816>
snorkdude: doc.xpath("//body").children.first.name, given that you have actual html. nokogiri will add <html><body></body></html> around fragments like your example
beachandbytes has joined #ruby
<snorkdude>
blazes816, the gist I showed you is just an extraction from a large html file.
<blazes816>
either way, if you want the root node, it will always be <html>. if you want the first child of <body>, that's how you get it
<blazes816>
left a comment on the gist but the html got fucked up, but you should get the idea
crazed has quit [Ping timeout: 250 seconds]
<snorkdude>
So that will work in an HTML file hundreds of lines long?
<blazes816>
billions if you had enough memory
<snorkdude>
Awesome, thanks
<blazes816>
np
crazed has joined #ruby
SCommette has quit [Quit: SCommette]
hsbt_ has quit [Ping timeout: 264 seconds]
AlbireoX has quit [Read error: Connection reset by peer]
crazed has quit [Ping timeout: 245 seconds]
AlbireoX`Laptop has joined #ruby
crazed has joined #ruby
Jamone has joined #ruby
Jamone has quit [Changing host]
Jamone has joined #ruby
arietis has joined #ruby
pu22l3r has quit [Remote host closed the connection]
hsbt_ has joined #ruby
blazes816 has quit [Quit: blazes816]
mr-rich has quit [Ping timeout: 240 seconds]
crazed has quit [Remote host closed the connection]
crazed has joined #ruby
Elico1 has quit [Ping timeout: 272 seconds]
crazed has quit [Ping timeout: 260 seconds]
ThatDudeGuy_ has quit [Quit: ThatDudeGuy_]
Elico1 has joined #ruby
mustnotfap has quit [Quit: maintenance]
uris has quit [Quit: leaving]
crazed has joined #ruby
Elico1 has quit [Ping timeout: 244 seconds]
Elico1 has joined #ruby
<RubyPanther>
How is Ruby 2 so fast?! I can hardly tell the difference between my Ruby and my C anymore.
<crocket>
RubyPanther, Not when it comes to 3D games.
GraemeLion has quit [Quit: out]
Erfankam has joined #ruby
<banisterfiend>
RubyPanther: why do you tell lies
<crocket>
ruby can't be faster than java, either.
jenrzzz has quit [Ping timeout: 248 seconds]
bluOxigen has quit [Ping timeout: 248 seconds]
<crocket>
interpreted languages are inherently slow.
crazed has quit [Ping timeout: 250 seconds]
Z_Mass has quit [Ping timeout: 240 seconds]
<RubyPanther>
Why not 3D games?
<RubyPanther>
The video card does the work
<crocket>
RubyPanther, too much overhead
<crocket>
CPU still does a lot of things.
<RubyPanther>
Like everything else, if there is something with overhead issues you use the C API
<Boohbah>
RubyPanther: lol
<RubyPanther>
You can still put your application logic in Ruby and your object model in Ruby
<crocket>
What about compatibility issues?
crazed has joined #ruby
<crocket>
Ruby syntax changes.
<crocket>
new interpreters wouldn't run old ruby games.
<RubyPanther>
My C extensions that I develop on linux compile without tweaking on windoze using the one-click dev-kit
<RubyPanther>
Ruby is very portable on the C side, and it extends right into your extensions if you use the same philosophy
<coyo>
good evening :D
crazed has quit [Ping timeout: 245 seconds]
rubious has joined #ruby
rubious has quit [Ping timeout: 240 seconds]
<Hanmac>
crocket liear ... i get the same FPS with Ogres SampleBrowser and my little stuff
diegoviola has quit [Ping timeout: 276 seconds]
<crocket>
Hanmac, What is it?
crazed has joined #ruby
arturaz has joined #ruby
freeayu has quit [Quit: 离开]
<Hanmac>
with mesa ~20FPS with fglrx >200FPS
<crocket>
Hanmac, Is it written in ruby?
tk___ has quit [Ping timeout: 255 seconds]
<Hanmac>
my first sample is
<banisterfiend>
crocket: btw ruby is not strictly an 'interpreted' language, many of the implementations have bytecode vms
love_col_ has joined #ruby
maletor has joined #ruby
<crocket>
Hanmac, Why is mesa 10 times slower than fglrx?
<Hanmac>
but it uses the Ogre's Loop so it might be not fair
tommyvyo has joined #ruby
mikepack has joined #ruby
<Hanmac>
crocket because the free radeon driver are slower than the proprietary driver from amd
Chryson has quit [Quit: Leaving]
<crocket>
It sucks.
tk___ has joined #ruby
Elico1 has quit [Ping timeout: 260 seconds]
tommyvyo has quit [Client Quit]
yubiwasabi2 has quit [Quit: Computer has gone to sleep.]
apok has quit [Quit: apok]
drago757 has joined #ruby
sabgenton has joined #ruby
<sabgenton>
why does appending '<<' somehow affect the base variable?
<Hanmac>
sabgenton because "base" an "a" reference to the same object
workmad3 has joined #ruby
<Hanmac>
you need: a = base.dup
love_col_ has quit [Remote host closed the connection]
rubious has joined #ruby
<sabgenton>
Hanmac: so unlike other langauges ruby kinda pointers stuff together
<sabgenton>
Hanmac: how come it works with += ?
mmitchell has quit [Ping timeout: 276 seconds]
pskosinski has joined #ruby
eldariof has joined #ruby
<Hanmac>
because a += "" is a = a + "" , unlike << it creates an new String wich is not affect the base string
Elico1 has quit [Ping timeout: 246 seconds]
<sabgenton>
but does += replace the reference type with an normal string type
<sabgenton>
I guess
beachandbytes has quit [Ping timeout: 276 seconds]
<Hanmac>
yea ... with += you get 2 strings (or more)
digitalcakestudi has quit [Ping timeout: 260 seconds]
jenrzzz has joined #ruby
workmad3 has quit [Ping timeout: 240 seconds]
ZachBeta has joined #ruby
<sabgenton>
Hanmac: ok so where I using think assignment equates to copy in ruby I think assignment equates to link
<sabgenton>
usually think
Elico1 has joined #ruby
answer_42 has joined #ruby
billyoc has quit [Ping timeout: 252 seconds]
<Hanmac>
>> base = "string"; a = base;[ "base object_id: #{base.object_id}","a object_id #{a.object_id}" ]
<al2o3cr>
(Array) ["base object_id: 20041460", "a object_id 20041460"]
<Hanmac>
>> base = "string"; a = base.dup;[ "base object_id: #{base.object_id}","a object_id #{a.object_id}" ]
<al2o3cr>
(Array) ["base object_id: 19722020", "a object_id 19722000"]
knightblader has quit [Ping timeout: 246 seconds]
mikepack has quit [Remote host closed the connection]
Elico1 has quit [Ping timeout: 244 seconds]
jenrzzz has quit [Ping timeout: 245 seconds]
pskosinski has quit [Read error: Connection timed out]
Elico1 has joined #ruby
fragmachine has joined #ruby
<fragmachine>
Does anyone know if there is a way to scrape sites that use javascript?
<sabgenton>
Hanmac: thx
pdtpatrick has quit [Quit: pdtpatrick]
<fragmachine>
I've been using mechanize but it won't work for JS sites...
fyolnish has joined #ruby
robustus has joined #ruby
AlbireoX`Laptop has quit [Read error: Connection reset by peer]
ananthakumaran has joined #ruby
drago757 has quit [Quit: drago757]
dimday has joined #ruby
dimday has quit [Client Quit]
dimday has joined #ruby
hsbt_ has quit [Ping timeout: 252 seconds]
knightblader has joined #ruby
dimday has quit [Remote host closed the connection]
ABK has joined #ruby
dimday has joined #ruby
ABK has quit [Read error: Connection reset by peer]
Elico1 has quit [Ping timeout: 240 seconds]
ABK has joined #ruby
dimday has quit [Remote host closed the connection]
areil has joined #ruby
Jackneill has joined #ruby
dimday has joined #ruby
Jackneill is now known as Guest81709
dimday has quit [Client Quit]
arkiver has quit [Quit: Leaving]
fragmachine has quit [Quit: leaving]
hsbt_ has joined #ruby
Elico1 has joined #ruby
jgrevich has joined #ruby
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
ZachBeta has quit [Quit: Computer has gone to sleep.]
stephenjudkins has quit [Quit: stephenjudkins]
sabgenton has quit [Quit: Page closed]
aces23up has joined #ruby
KuzcekPLT has joined #ruby
snorkdude has quit [Remote host closed the connection]
pskosinski has joined #ruby
Elico1 has quit [Ping timeout: 260 seconds]
Elico1 has joined #ruby
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
rubious has quit [Quit: Leaving...]
ryanf_ has joined #ruby
thone_ has joined #ruby
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
KuzcekPLT is now known as Catnaroek
thone has quit [Ping timeout: 264 seconds]
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
sambio has quit [Quit: Saliendo]
noyb has quit [Ping timeout: 260 seconds]
fbernier has quit [Ping timeout: 245 seconds]
Elico1 has quit [Ping timeout: 244 seconds]
banisterfiend has quit [Remote host closed the connection]
ABK has quit [Read error: Connection reset by peer]
<aces23up>
can't seem to find this, but i'm downloading a large file, and want to save it append the binary file per chunk to disk what IO function do I want for this?
fbernier has joined #ruby
ABK has joined #ruby
yoklov has quit [Quit: computer sleeping]
mmitchell has joined #ruby
Elico1 has joined #ruby
justsee has quit [Quit: Leaving...]
ABK has quit [Read error: Connection reset by peer]
nucc has joined #ruby
s1n4 has joined #ruby
Catnaroek is now known as KuzcekPLT
jenrzzz has joined #ruby
mmitchell has quit [Ping timeout: 246 seconds]
arturaz has quit [Remote host closed the connection]
hsbt_ has quit [Ping timeout: 272 seconds]
nucc has quit [Read error: Operation timed out]
hsbt_ has joined #ruby
<TTilus>
aces23up: net/http can do that
Bosox20051 has joined #ruby
<TTilus>
frogprince: maybe the site has a backround api you can tap to instead of the js rendered front?
<TTilus>
frogprince: and of course you can always run js scaper inside a real browser
seanstickle has quit [Quit: seanstickle]
jgrevich has quit [Quit: jgrevich]
<TTilus>
frogprince: or take a really big gun like selenium (+capybara)
<TTilus>
frogprince: look for webapp testing tools if you want to try out several
Xeago has joined #ruby
<TTilus>
frogprince: there are headless "browsers" that run js
ABK has joined #ruby
burgestrand has joined #ruby
nohonor has joined #ruby
Xeago_ has joined #ruby
crocket has left #ruby ["Leaving"]
Xeago has quit [Ping timeout: 248 seconds]
Elico1 has quit [Ping timeout: 245 seconds]
Elico1 has joined #ruby
justinmcp has joined #ruby
rakunHo has joined #ruby
nucc has joined #ruby
ABK has quit [Read error: Connection reset by peer]
thaz has joined #ruby
ABK has joined #ruby
burgestrand has quit [Quit: Leaving.]
ABK has quit [Read error: Connection reset by peer]
burgestrand has joined #ruby
ABK has joined #ruby
Elico1 has quit [Ping timeout: 245 seconds]
Elico1 has joined #ruby
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
nohonor has quit [Quit: Leaving]
piotr_ has joined #ruby
qwerxy has joined #ruby
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
smellynoser has joined #ruby
savage- has joined #ruby
MadMark has joined #ruby
savage- has quit [Remote host closed the connection]
yasushi has joined #ruby
piotr__ has joined #ruby
piotr_ has quit [Ping timeout: 246 seconds]
Elico1 has quit [Ping timeout: 268 seconds]
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
dangerousdave has joined #ruby
Criztian has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
MadMark has left #ruby ["Leaving"]
paul_andrew has joined #ruby
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
Elico1 has joined #ruby
ABK has quit [Read error: Connection reset by peer]
ABK has joined #ruby
ABK has quit [Read error: Connection reset by peer]
justinmcp has quit [Remote host closed the connection]
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
ABK has joined #ruby
bluOxigen has joined #ruby
Elico1 has quit [Ping timeout: 240 seconds]
kryl99_ has joined #ruby
Elico1 has joined #ruby
paul_andrew has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
bughle has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
yshh has joined #ruby
yasushi has quit [Remote host closed the connection]
ABK has quit [Ping timeout: 276 seconds]
fyolnish has quit [Remote host closed the connection]
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
<crocket>
How can I make unicorn issue a relative redirect instead of an absolute redirect?
sagax has quit [Ping timeout: 244 seconds]
jarred has quit [Quit: jarred]
banisterfiend has joined #ruby
paul_andrew has joined #ruby
banisterfiend has quit [Remote host closed the connection]
paul_andrew has quit [Read error: Connection reset by peer]
ph^ has joined #ruby
c0rn_ has joined #ruby
guns has quit [Ping timeout: 248 seconds]
hsbt_ has quit [Ping timeout: 246 seconds]
paul_andrew has joined #ruby
qwerxy has quit [Ping timeout: 246 seconds]
hsbt_ has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
br4ndon has joined #ruby
ph^ has quit [Read error: Connection reset by peer]
qwerxy has joined #ruby
ph^ has joined #ruby
seich- has joined #ruby
Guest2797 has joined #ruby
qwerxy has quit [Client Quit]
asshopo_ has quit [Read error: Operation timed out]
chussenot has joined #ruby
br4ndon has quit [Ping timeout: 245 seconds]
aibo has joined #ruby
asshopo has joined #ruby
eldar has joined #ruby
<aibo>
hello, what's the easiest way to merge 2 arrays removing items which present in both arrays leaving only items which present in just one of arrays?
elico has quit [Read error: Connection reset by peer]
elico has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
elico has quit [Client Quit]
havenn has quit [Remote host closed the connection]
Xeago_ has quit [Remote host closed the connection]
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
hsbt_ has quit [Ping timeout: 246 seconds]
Erfankam has quit [Read error: Connection reset by peer]
fantazo has quit [Remote host closed the connection]
znake has joined #ruby
<crocket>
How can I make passenger to run gitlab with resque?
<crocket>
resque is not launched when gitlab is run.
paul_andrew has joined #ruby
Erfankam has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
conor_ireland has joined #ruby
wobr has joined #ruby
justsee has quit [Quit: Leaving...]
havenn has joined #ruby
Elico1 has quit [Ping timeout: 244 seconds]
hsbt_ has joined #ruby
jarred has joined #ruby
elico has joined #ruby
justsee has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
jarred has quit [Ping timeout: 240 seconds]
dpk has quit [Quit: Asleep at the keyboard.]
Virunga has quit [Remote host closed the connection]
bluOxigen has quit [Ping timeout: 248 seconds]
Virunga has joined #ruby
znake has quit [Ping timeout: 260 seconds]
punkrawkR has joined #ruby
znake has joined #ruby
rprime has joined #ruby
rprime has quit [Read error: Connection reset by peer]
elico has quit [Ping timeout: 264 seconds]
fyolnish has quit [Remote host closed the connection]
Virunga has quit [Remote host closed the connection]
elico has joined #ruby
znake is now known as znake|away
havenn has quit [Remote host closed the connection]
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
c0rn_ has quit []
und3f has joined #ruby
Speed has joined #ruby
Speed has quit [Changing host]
Speed has joined #ruby
fbernier has quit [Ping timeout: 245 seconds]
hsbt_ has quit [Ping timeout: 268 seconds]
hsbt_ has joined #ruby
yxhuvud has joined #ruby
beachandbytes has joined #ruby
fbernier has joined #ruby
elico has quit [Ping timeout: 252 seconds]
paul_andrew has joined #ruby
Banistergalaxy has joined #ruby
AndChat- has quit [Read error: Connection reset by peer]
paul_andrew has quit [Read error: Connection reset by peer]
elico has joined #ruby
znake|away is now known as znake
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
jimeh has joined #ruby
Banistergalaxy has quit [Ping timeout: 272 seconds]
nicoulaj has joined #ruby
Virunga has joined #ruby
ryanf_ has joined #ruby
hsbt_ has quit [Ping timeout: 246 seconds]
hsbt_ has joined #ruby
ryanf has quit [Ping timeout: 255 seconds]
ryanf_ is now known as ryanf
elico has quit [Ping timeout: 246 seconds]
Takehiro has joined #ruby
elico has joined #ruby
<aibo>
who can help with datamapper question?
<burgestrand>
people who know datamapper
<aibo>
epic answer :)
<burgestrand>
and your question
Foxandxss has joined #ruby
<burgestrand>
nobody can help you with your question if they dont know it even if they know datamapper
<aibo>
I am getting datamapper collection after that query: Rating.all(:fields => 'psf_id', :ts_d => Time.now), but I need array to be able to deal with it
<fowl>
try #to_a
<aibo>
to be able to do `(a - b) + (a&b)`
NimeshNeema has quit [Excess Flood]
AndChat- has joined #ruby
paul_andrew has joined #ruby
<aibo>
fowl, that didn't help
paul_andrew has quit [Read error: Connection reset by peer]
<execat>
m3pow, and Rails guides are real quality stuff. If RoR is all you need, you can jump in there straightaway.
johnjohnson has quit []
<m3pow>
i did some research and i noticed that ruby is highly appreciated as a language
<m3pow>
easy to understand, learn and efficient
<Hanmac>
m3pow please learn ruby before you learn RoR ...
<m3pow>
understood !
<m3pow>
any tip would help me a lot at this moment
Virunga is now known as LennyLinux
fbernier has quit [Ping timeout: 245 seconds]
nucc has quit [Quit: Lost terminal]
fbernier has joined #ruby
havenn has joined #ruby
<execat>
Now for my question: I have some gems installed as root (in /root/.gem) and some as a normal user (~/.gem). So I have to execute sudo gem update and gem update separately for two different locations.
und3f has quit [Quit: Leaving.]
<execat>
Is there a way I can shift the .gem folder at once into either of the directory?
kobac has joined #ruby
und3f has joined #ruby
<execat>
Specifically, will merging /root/.gem and ~/.gem into ~/.gem (a normal move operation) help me achieve this?
und3f has quit [Client Quit]
und3f has joined #ruby
havenn has quit [Ping timeout: 246 seconds]
hoelzro|away is now known as hoelzro
yasushi has joined #ruby
cakehero has joined #ruby
parus_ has quit [Quit: leaving]
<seanstickle>
Some of those books are more properly computer science than programming.
<seanstickle>
But many of them are delightfully awesome
<m3pow>
from stackoverflow ?
<seanstickle>
Yah
parus has joined #ruby
<m3pow>
noticed that !
pigggie has joined #ruby
<m3pow>
and for RoR is just a single reference
<seanstickle>
I dearly love, for instance Hoare's Communicating Sequential Processes, but it is a dastardly thing to try and adopt it as a programming guide.
pigggie has left #ruby [#ruby]
freeayu has quit [Ping timeout: 255 seconds]
qwerxy has joined #ruby
risico has joined #ruby
atmosx has quit [Read error: Connection reset by peer]
yshh has joined #ruby
chussenot has quit [Quit: chussenot]
pigggie has joined #ruby
freeayu has joined #ruby
pigggie has left #ruby [#ruby]
und3f has quit [Quit: Leaving.]
und3f has joined #ruby
jasonkuhrt has quit [Quit: Leaving...]
insulator has joined #ruby
hoelzro is now known as hoelzro|away
zigomir_ has joined #ruby
verto|off is now known as verto
Elico1 has quit [Quit: elico1]
zigomir has quit [Ping timeout: 276 seconds]
bluenemo has quit [Remote host closed the connection]
bluOxigen has joined #ruby
jarred has joined #ruby
freeayu has quit [Remote host closed the connection]
jasonkuhrt has joined #ruby
jasonkuhrt has quit [Client Quit]
pen has quit [Remote host closed the connection]
jasonkuhrt has joined #ruby
jarred has quit [Ping timeout: 244 seconds]
<crocket>
charlock_holmes 0.6.8 and 0.6.9 are both installed
<crocket>
How can I remove 0.6.9?
<Hanmac>
why do you want to remove the newer version?
vaino has joined #ruby
jasonkuhrt has quit [Ping timeout: 244 seconds]
<Mon_Ouie>
gem uninstall specifying the version with -v (or interactively)
<vaino>
Have somone here played with sinatra + activerecord?
<matti>
Funny question :)
<matti>
How does one preserve FalseClass there: x = [false].shift || true
<matti>
:)
NiteRain has quit [Ping timeout: 246 seconds]
<crocket>
thanks
und3f has quit [Quit: Leaving.]
sonkei has joined #ruby
<seanstickle>
vaino: yup
und3f has joined #ruby
und3f has quit [Client Quit]
<vaino>
seanstickle: okey, i'm now to ruby so i tought sinatra was a good framework to start with.
und3f has joined #ruby
ltsstar has quit [Ping timeout: 276 seconds]
griffindy has joined #ruby
<vaino>
seanstickle: But to the problem.. i have made a create_migration and setup the file. But when i i do rake db:migrate it does not create any database.
<crocket>
charlock_holmes
und3f has quit [Client Quit]
<vaino>
I have set :databse 'sqlite://....' in my application but dosent help
Takehiro has quit [Remote host closed the connection]
<Spooner>
devnull_ : I don't know the system, but you need something like '(/(\w+))+' to match both paths
SCommette has joined #ruby
SCommette has quit [Client Quit]
<matti>
shevy: ?
Xeago has quit [Ping timeout: 264 seconds]
<shevy>
matti DEFEND
* matti
stabs shevy
<matti>
There.
<shevy>
ack
<Spooner>
shevy It is just a regexp question, not a Rails one. Just poorly presented to #ruby :)
qwerxy has joined #ruby
<devnull_>
Spooner: thanks but that returns wrong number of arguments (2 for 1) :( the version on the pastie works but only for /notfound not for /not/found
<Spooner>
devnull_ : You maybe want '(/(?:\w+))+' then, so it only captures the whole path.
resure has joined #ruby
<Spooner>
devnull_ : But, really, I don't know the Rails system. I'm fixing your regexp problem, not managing the oddities of Rails when you use the "correct" regexp.
nucc_ has joined #ruby
<Spooner>
The problem will be that you'll get "/mynonexistinpage" when you match the root page, not "mynonexistinpage" as you get now, but I'm sure you can manage that!
jarred has joined #ruby
nucc_ has left #ruby [#ruby]
nucc_ has joined #ruby
saurb has quit [Ping timeout: 252 seconds]
<shevy>
Spooner I swear I never saw class Page < R '/(\w+)' before
nucc has quit [Quit: nucc]
nucc_ is now known as nucc
nucc has left #ruby [#ruby]
nucc has joined #ruby
deryl has left #ruby [#ruby]
<Spooner>
shevy Neither did I, but then again, you never see most things that people post before, since they use their own classes or whatnot in it. Just looks exactly like Sinatra routing to me, which made it all make perfect sense.
<shevy>
Sinatra uses such crazy syntax things too?
<devnull_>
Spooner: right this is exactly what hapend :) this is camping BTW
Elico1 has quit [Quit: elico1]
<devnull_>
shevy: camping.io :)
<shevy>
hmm
yeltzooo7 has quit [Ping timeout: 252 seconds]
execat has quit [Read error: Connection reset by peer]
xyon has joined #ruby
yeltzooo has joined #ruby
<devnull_>
shevy: is like to define a route for the pages but if the page is not found shows camping error! which has some issues
s1n4 has quit [Quit: peace out]
digitalcakestudi has joined #ruby
mneorr has joined #ruby
horofox has joined #ruby
<devnull_>
Spooner: what you did works but doens't let me load the legitimate /admin/page that I define after
ananthakumaran has joined #ruby
<allsystemsarego>
how can I map a separately defined function over an array of objects
katherinem13 has quit [Quit: katherinem13]
<shevy>
array.map {|x| your_method_name_here(x) }
<Hanmac>
allsystemsarego: array.each(&:sym) ... or array.map(&:sym)
<allsystemsarego>
thanks, I'll try these solution
<allsystemsarego>
solutions
asiaticax has joined #ruby
horofox has quit [Quit: horofox]
atmosx has joined #ruby
<allsystemsarego>
ok, it's complaining that my function isn't a method in that class
<allsystemsarego>
I have a function that is external (not a method) to that class
ltsstar has joined #ruby
<Hanmac>
allsystemsarego than try shevy 's solution
Speed has joined #ruby
Speed has quit [Changing host]
Speed has joined #ruby
fyolnish has joined #ruby
<allsystemsarego>
ok, thanks, I thought I was missing out on an elegant solution
<shevy>
allsystemsarego all functions in ruby are methods in some ways
katherinem13 has joined #ruby
horofox has joined #ruby
joephelius has joined #ruby
execat has joined #ruby
execat has quit [Changing host]
execat has joined #ruby
drago757 has joined #ruby
SCommette has joined #ruby
joast has joined #ruby
deryl has quit [Quit: Leaving.]
deryl has joined #ruby
havenn has joined #ruby
qwerxy has quit [Quit: offski]
chimay has quit [Quit: WeeChat 0.3.9-rc1]
asiaticax has quit [Read error: Connection reset by peer]
nucc has quit [Quit: nucc]
jorum has joined #ruby
Jake232 has joined #ruby
mmitchell has joined #ruby
tk___ has quit [Quit: ばいばい]
butblack has left #ruby [#ruby]
asiaticaXXX has joined #ruby
execat has quit [Ping timeout: 246 seconds]
uris has joined #ruby
CarlB_the_great has quit [Remote host closed the connection]
centipedefarmer has joined #ruby
sonkei has joined #ruby
fyolnish has quit [Remote host closed the connection]
<RubyPanther>
I get married in 2.5 hours, I need a little snippet of Ruby to pin inside my jacket for good luck
Guest17362 has quit [Ping timeout: 240 seconds]
mmitchell has quit [Remote host closed the connection]
<horsey>
RubyPanther: binding.pry
<TTilus>
RubyPanther: writing it yourself would bring bad luck?
mneorr has quit [Ping timeout: 246 seconds]
mneorr has joined #ruby
<Spooner>
devnull_ : I explained that it would return "/frog", rather than "frog" for the base pages. If you need the latter, then you need to fix that yourself (it isn't rocket science :D).
iszak has joined #ruby
snorkdude has joined #ruby
<devnull_>
Spooner: yes thank you :)
<Mon_Ouie>
assert(I.love? you and you.love? me) while I.alive? and you.alive?
chimay has joined #ruby
chimay has quit [Changing host]
chimay has joined #ruby
<horsey>
Mon_Ouie is so romantic
Speed has quit [Ping timeout: 252 seconds]
asiaticaXXX has quit [Read error: Connection reset by peer]
<Spooner>
devnull_ : You should probably match '/(\w+)' (root page) and '.*' (404) separately though. Makes more sense really and separates out the two, quite different, routes.
<RubyPanther>
TTilus: I'm gonna write it myself, I just wanted some input other than from the butterflies :)
Poapfel has quit [Remote host closed the connection]
<TTilus>
RubyPanther: class << self; self; end
Poapfel has joined #ruby
<TTilus>
RubyPanther: metaclasses always bring good luck
<RubyPanther>
Mon_Ouie: Thanks, great ideas there, I probably won't with the test but I like while alive?
<devnull_>
Spooner: ok so based on my sample which works fine for root how would you create a smilar one with the .* bit ? :X
<RubyPanther>
TTilus: if metaclasses can get me through Dwemthy's Array alive, they can get me through today! :) :) :)
<TTilus>
exactly
<TTilus>
RubyPanther: but it is really not _that_ hard place to be
<Spooner>
devnull_ : Match '/', '/(\w+)' and '(.*)' in separate classes. Just make sure you create the matcher for the 404 AFTER the first two, so that it checks that last!
mwilson` has quit [Excess Flood]
<RubyPanther>
||= lol
<Spooner>
That is, most likely, how you'd do it in Sinatra, at least.
mwilson` has joined #ruby
moshee has joined #ruby
<RubyPanther>
def method_missing *args; spouse.love! end
yshh has quit [Remote host closed the connection]
<atmosx>
as a good ruby newbe I shall get fresh bread, coke and nutella from the super market
* atmosx
markes on it's to-buy list
<atmosx>
this freebsd machine took all the stamine in me
yoklov has joined #ruby
<RubyPanther>
caffeine, nutella, and Ruby, that's enough to build an app right there
<Spooner>
There is a caffeine gem, but no Nutella one. We are slacking...
<RubyPanther>
Nobody wanted to share
* atmosx
struggles to learn sinatra to write a web interface for his app
<Spooner>
atmosx : Just think "I could be having to do this with Rails instead" every time you work with Sinatra, and it will seem like a dream ;)
Speed has joined #ruby
Speed has quit [Changing host]
Speed has joined #ruby
AlbireoX has joined #ruby
<atmosx>
The thing with HTML/CSS/XHTML JavaScript and frameworks like Sinatra (or RoR) for that matter is that when you start reading one subect they 'assume' somehow that you know everything about everything else
horofox has quit [Quit: horofox]
<atmosx>
so you read the preface of a book about sinatra which says that you must be familiar with HTML/CSS *at least*
<atmosx>
you read CSS and sasys you shuold be familiar with HTML, you read HTML and says you should be familiar with CSS
<atmosx>
… it's like *wtf*
<Spooner>
There isn't a lot of point in writing a HTML tutorial in Sinatra, Rails and every other framework in every other language though.
<canton7>
well yeah. html doesn't rely on a programming framework. and html and css go hand in hand
<atmosx>
canton7: I know
ltsstar has quit [Ping timeout: 240 seconds]
<atmosx>
I know some basic HTML, and CSS … it's easy to understand actually. I edited my wordpress theme too many times… even the erb files, I've saw one yesterday for the time and was easy to debug
<atmosx>
Although this HAML thing looks much more easy and ruby-ish
cakehero has quit [Quit: Leaving...]
<Spooner>
atmosx : Try slim too. Both very similar so it is down to personal preference.
<RubyPanther>
Yeah, you have to read it all through the first time with no clue what it means, then the second pass the parts make sense
<canton7>
heh, someone who says css is 'easy' doesn't know enough css :P
<atmosx>
what is slim about? I enconuter the word somwhere
jarred has joined #ruby
<Spooner>
slim is pretty much the same as HAML, but slightly different.
<atmosx>
aha
<atmosx>
nah, I'll stick with erb since my book has 'erb's all over the place
<atmosx>
and then see what happens
<Spooner>
Erb is horrible (relatively).
<Spooner>
But then again, many people say HAML/slim is horrible ;)
<atmosx>
yeah but give me a break :-p reading the examples and makes trials/error in a code which I have to translate from first-time-seen-erb_to-first-time-seen-haml/slim is a tedious task
<Mon_Ouie>
ERB can be used for any kind of templates, it's not bound to outputting HTML/XML
<Spooner>
Well, OK, that is true.
<atmosx>
okay, I'll be going to the nutella/coke thing now, cya later
<Marwan_>
hi guys, anyone know how can i sort like in this page http://www.nanotch.com/servibell/products/ , and filter them by their categories and make some emotion while filtering - just like in the mentioned page
larissa has quit [Client Quit]
larissa has joined #ruby
<Marwan_>
oh - i am stupid - i forgot to change the channel to wordpress - sorry
Marwan_ has left #ruby [#ruby]
seanstickle has quit [Quit: seanstickle]
larissa has quit [Client Quit]
ZachBeta has joined #ruby
larissa has joined #ruby
larissa has quit [Remote host closed the connection]
larissa has joined #ruby
horsey has quit [Read error: Connection reset by peer]
Banistergalaxy has quit [Read error: Connection reset by peer]
sebastorama has joined #ruby
larissa has quit [Ping timeout: 264 seconds]
horsey has joined #ruby
luxurymode has quit [Quit: Computer has gone to sleep.]
larissa has joined #ruby
<matti>
LOL
larissa has left #ruby [#ruby]
gverri has joined #ruby
pskosinski has quit [Remote host closed the connection]
* atmosx
is listening to Diomidis Spinellis - Open Source and Professional Advancement, from the album IEEE Software's "Tools of the Trade" with Diomidis Spinellis [10:45 mins] [128 kbps MPEG audio file] [9,86 MB] [played 0 times]
eldar has joined #ruby
ly_gs has quit [Remote host closed the connection]
<matti>
?
Auraelius has quit [Quit: Auraelius]
mva3212 has joined #ruby
<canton7>
I don't know why people feel the need to do that...
sepp2k has quit [Read error: Connection reset by peer]
<mva3212>
#join #rails
<matti>
NEVER
guarrillaAsiatic has joined #ruby
<matti>
atmosx: Stop spamming please.
<atmosx>
matti: never
<matti>
Bastard.
<matti>
;/
* matti
cries
chrishunt has quit [Quit: WeeChat 0.3.8]
<deryl>
why not let him? you just know we all care what everyone else in the world is listening to!
<matti>
OK, dinner time.
* deryl
runs
eldariof has quit [Ping timeout: 240 seconds]
cantonic has quit [Ping timeout: 268 seconds]
chrishunt has joined #ruby
fyolnish has joined #ruby
* matti
stabs deryl just before he makes to the nearest exit
shevy has joined #ruby
<deryl>
damn you and your rubber knives!
<matti>
deryl: Rubber chicken.
<matti>
It was.
<deryl>
hahah!
<deryl>
dinner!
ianbrandt has joined #ruby
ianbrandt has quit [Excess Flood]
andrew__ has joined #ruby
andrew__ is now known as andrewhl
<deryl>
<song> Hey I just met you, and I have alzheimers. Hey I just met you!</song>
horsey has quit [Ping timeout: 260 seconds]
Banistergalaxy has quit [Read error: Connection reset by peer]
mmitchell has joined #ruby
ryanf has quit [Quit: broken pipes |||]
<atmosx>
I have nutella!
* atmosx
fear
<atmosx>
matti: you jelous chick
<andrewhl>
I'm parsing some web pages, and I want my parser to skip rows that contain invalid content. Currently my parse_row method raises an error when it finds invalid content, but I want it to just skip the current row and return to the parent method. How can I do this? https://gist.github.com/3685505
fyolnish has quit [Ping timeout: 246 seconds]
jgrevich has joined #ruby
havenn has quit [Remote host closed the connection]
kidoz has joined #ruby
sagax has quit [Ping timeout: 260 seconds]
fyolnish has joined #ruby
mmitchell has quit [Ping timeout: 246 seconds]
havenn has joined #ruby
elaptics is now known as elaptics`away
mmitchell has joined #ruby
fyolnish has quit [Ping timeout: 246 seconds]
guarrillaAsiatic has quit [Read error: Connection reset by peer]
sonkei has quit [Quit: Computer has gone to sleep.]
sepp2k has joined #ruby
seanyo has joined #ruby
mmitchell has quit [Ping timeout: 246 seconds]
sagax has joined #ruby
br4ndon has quit [Ping timeout: 244 seconds]
Banistergalaxy has joined #ruby
Banistergalaxy has quit [Read error: Connection reset by peer]
jarred has joined #ruby
havenn has quit [Remote host closed the connection]
bradyl0ve has joined #ruby
sebastorama has quit [Quit: Computer has gone to sleep.]
seanyo_ has joined #ruby
<Spooner>
andrewhl : You mean skip that row?
Banistergalaxy has joined #ruby
<Spooner>
Since you are using map, you can't really skip it directly. You could either return nil and use #compact on the resultant row or build the array and not add a nil returned to the array.
<austinbv>
irb cannot figure out the base path for require relative
<austinbv>
same thing with File.expand_path(path_to_gem, __FILE__)
havenn has joined #ruby
jarred has joined #ruby
mmitchell has joined #ruby
bluenemo has quit [Remote host closed the connection]
iszak has joined #ruby
<austinbv>
same thing with File.expand_path(path_to_gem, __FILE__)
<austinbv>
whoops
<Spooner>
austinbv : Yeah, irb doesn't have a file to be relative to. However, the require that is failing is in super_gem. That sort of require will only work if you have added the lib directory to the path (as is done automatically for gems when run properly).
<Spooner>
austinbv start IRB with: irb -Ilib
havenn_ has joined #ruby
pricees has joined #ruby
<austinbv>
it works when I just include it in a test.rb and then run that
<austinbv>
and include it in my spec_helper
<austinbv>
so I am good :)
<austinbv>
it's hard to test EM code in irb anyway
mmitchell has quit [Ping timeout: 246 seconds]
jaylevitt has joined #ruby
<Spooner>
OK.
Jay_Levitt has quit [Ping timeout: 240 seconds]
Jake232 has quit [Quit: Computer has gone to sleep.]
fsck3r has quit [Quit: Leaving...]
ZachBeta has joined #ruby
booginga has quit [Quit: This computer has gone to sleep]
havenn_ has quit [Ping timeout: 268 seconds]
pricees has quit [Ping timeout: 264 seconds]
savage- has quit [Remote host closed the connection]
ZachBeta has quit [Client Quit]
jaylevitt has quit [Ping timeout: 244 seconds]
sebastorama has quit [Quit: Computer has gone to sleep.]
gogiel has quit [Ping timeout: 276 seconds]
seanyo_ has quit [Ping timeout: 255 seconds]
jimeh has joined #ruby
chrishunt has quit [Read error: Connection reset by peer]
fantazo has joined #ruby
chrishunt has joined #ruby
dpk has joined #ruby
LennyLinux has quit [Remote host closed the connection]
larissa has joined #ruby
fowl has quit [Ping timeout: 245 seconds]
tr4656 has quit [Ping timeout: 246 seconds]
<vaino>
Building a pastebin site with sinatra+data_mapper. But when i output the source it commet out my php <!--?php ... http://vvt.nu/id/13 (check source)
<vaino>
canton7: about "Do the escaping in the model" u want me to do a function that escapes all fields? Or have datamapper function there i can pass it?
<vaino>
canton7: yeh i had it before but i thought it saved the first char ^^ unused to sqlite it saves booleans with t/f :P
<canton7>
in your datamapper model, define a method (e.g. paste_escaped or something) which returns the escaped value of paste? Actually no I've changed my mind. Do the escaping in the view
<canton7>
vaino, nah still 0/1 iirc. But datamapper's prolly smart enough to convert it to boolean
<Mon_Ouie>
I don't think exiting early is better than using if … else (plus it's not obvious to someone not familiar with Sinatra that calling redirect will exit)
beachandbytes has joined #ruby
<vaino>
canton7: yeh but i did a select directly with sqlite3 and it gave me T/F so i got confused :P
<canton7>
aha, fair enough. My memory's failing me in that case
ZachBeta has joined #ruby
<vaino>
canton7: okey u mean <%=CGI::escape...%> ?
<canton7>
yeah
pricees has joined #ruby
bluenemo has joined #ruby
bluenemo has quit [Changing host]
bluenemo has joined #ruby
<vaino>
canton7: sure but is it possible to make a alias of that function namne to some smaller :)?
paul_andrew has quit [Read error: Connection reset by peer]
<matti>
nohonor: Its a good book.
<matti>
nohonor: But if you know other languages, then start with ER first.
<nohonor>
i like deep, thorough explanations
<matti>
nohonor: There is no point to teach you want an integer is.
<nohonor>
matti, hah :-D
<nohonor>
i should think so
<matti>
:>
<matti>
Unless you are coming from PHP world.
havenn_ has quit [Ping timeout: 264 seconds]
<matti>
They you need exorcism.
<yxhuvud>
or javascript ..
<matti>
And then a book.
<matti>
yxhuvud: ;]
rakl has joined #ruby
<nohonor>
thankfully, that's not the case
<matti>
Yay
hadees has quit [Quit: hadees]
<nohonor>
then again, what's a good language to start out with?
<nohonor>
other than python i guess
<matti>
THey P. language
<matti>
He said the P. language name
<nohonor>
even if they're not as deformed as js and php
paul_andrew has joined #ruby
<matti>
Oh noess
<matti>
nohonor: Any I guess.
<nohonor>
python is simpler and more readable than ruby
<arubin>
Perl, clearly.
<nohonor>
so far as i can tell
<matti>
arubin: Oh hold on a minute.
<matti>
arubin: Hooold on a minite...
<matti>
;p
<matti>
nohonor: Ruby is super-readable.
<matti>
nohonor: Depends how you write it.
paul_andrew has quit [Read error: Connection reset by peer]
TheShadowFog has joined #ruby
<nohonor>
matti, if you have some experience i guess
<nohonor>
but py is closer to my idea of executable pseudocode
<matti>
nohonor: I did a lot of PY too.
<matti>
nohonor: And then fall in love with Ruby.
<nohonor>
yeah, i can imagine
<matti>
nohonor: And if one day I fine a girl whose name is also Ruby
<yxhuvud>
matti: ruby can be pretty hard to read depending on how much experience you have with it and your other experience.
<matti>
nohonor: Thats like win-win
<matti>
yxhuvud: Yeah
<nohonor>
it's powerful and elegant but i still don't think it's the best for a complete beginner
<matti>
I am just a little bit silly.
<matti>
;]
<matti>
nohonor: Its like with C code.
<nohonor>
anyway, about the books
<yxhuvud>
code without parenthesises + code execution in class scope is a sure way to confuse newbies :)
<matti>
nohonor: Nice C code is nice.
<nohonor>
'eloquent ruby' looks good
<nohonor>
the problem is there are so many
<nohonor>
how do i choose... i'm really tempted to read 'programming ruby' and 'the ruby way' but i'd end up with four books that repeat the same things
Takehiro has joined #ruby
Agis__ has joined #ruby
Guest81709 has quit [Ping timeout: 264 seconds]
sebastorama has joined #ruby
<GoHuyGo>
programming ruby is probably sufficient
kidoz has quit [Quit: Ухожу я от вас]
paul_andrew has joined #ruby
yxhvuud has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
Criztian has joined #ruby
nohonor has quit [Quit: Leaving]
yxhuvud has quit [Ping timeout: 260 seconds]
fyolnish_ has joined #ruby
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
richardcreme has quit [Remote host closed the connection]
mmitchell has joined #ruby
RudyValencia has quit [Quit: My IRC client doesn't advertise in /quit messages.]
fyolnish_ has quit [Ping timeout: 240 seconds]
centipedefarmer has joined #ruby
<karstensrage>
is the Devise::Strategies solely concerned with authentication?
SirFunk has quit [Ping timeout: 245 seconds]
<karstensrage>
package? module space? namespace?
drago757 has quit [Quit: drago757]
mmitchell has quit [Ping timeout: 276 seconds]
k_89 has joined #ruby
SirFunk has joined #ruby
dnyy__ has quit [Quit: Connection closed for inactivity]
pdtpatrick has quit [Quit: pdtpatrick]
subdigital has joined #ruby
gmci has joined #ruby
devnull_ has quit [Remote host closed the connection]
paul_andrew has joined #ruby
Solnse has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
iszak has joined #ruby
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
paul_andrew has joined #ruby
paul_andrew has quit [Read error: Connection reset by peer]
subdigital has left #ruby [#ruby]
jeff_sebring has joined #ruby
jeff_sebring has quit [Client Quit]
guns has quit [Ping timeout: 255 seconds]
eldar has quit []
mneorr has quit [Quit: Leaving.]
Takehiro has quit [Remote host closed the connection]
GraemeLion has joined #ruby
Z_Mass has joined #ruby
centipedefarmer has quit [Quit: Leaving]
Z_Mass has quit [Client Quit]
Takehiro has joined #ruby
beachandbytes has quit [Quit: Leaving]
GoGoGarrett has joined #ruby
sterex has joined #ruby
thunderstrike has joined #ruby
Jamone has quit [Read error: Connection reset by peer]
digitalcakestudi has quit [Quit: Leaving.]
digitalcakestudi has joined #ruby
<Azure>
I know that there's a term for this type of programming, but I cannot remember what it's called.
digitalcakestudi has quit [Read error: Connection reset by peer]
digitalcakestudi has joined #ruby
<Azure>
It's when you use returns/raises etc. at the top of methods in conjunction with conditionals
<atmosx>
I need to learn how to pass data from one method to another...
<atmosx>
the way I do it sucks big time.
<jrajav>
s/Hanmac/anyone ever/
<canton7>
atmosx, explain?
<atmosx>
canton7: sure let me gist my code
<fowl>
atmosx: the same way my parents communicate, with arguments ;_;
vitoravelino`afk is now known as vitoravelino
<atmosx>
canton7: https://gist.github.com/3687406 this is the method. I'm trying to display the data on sinatra, but I get nothing on sinatra while I get everything on the terminal...
tommyvyo has joined #ruby
tommyvyo has quit [Changing host]
tommyvyo has joined #ruby
<canton7>
that's because sinatra renders the return value from the block
<canton7>
while anything printed to stdout/stderr gets put on the console
timonv has joined #ruby
krnlsndrs has quit [Quit: Leaving]
<atmosx>
I need to create some sort of list or something … an array maybe or a hash and return it when the method is called with :options like arra_of_tweets {|tweet| tweet[:username] ...}
<canton7>
I'm guessing that's a helper? You want to be returning a value from that helper, and using the returned value to write something to a view
ZachBeta has quit [Quit: Computer has gone to sleep.]
<canton7>
you're slowly stumbling onto what a model is
<atmosx>
yes, although I don't clearly undersgtand your terminology (I'm playing with sinatra for a couple of days and as you can see I'm not good with ruby either
<atmosx>
anyway I was just trying to get ahead of my readings, I'll keep reading the book and I'm sure it will explain how to do it… but I need also to learn how to write methods that can pass data more naturally not just spit it out… (stdout)
<canton7>
yeah, your book will teach you that in short order ;)
<atmosx>
k
<atmosx>
fowl: ? wha arguments?
adeponte has quit [Remote host closed the connection]
<atmosx>
fowl: listen to your parents
<atmosx>
they either wrong or right, but if you don't what they'll tell you, you'll go to hell anyway
<atmosx>
scary place, no internet connection
ZachBeta has joined #ruby
<fowl>
atmosx: how to pass data; with arguments.. bad joke
<atmosx>
aah sorry didn't get it :-P
<atmosx>
I've seen a .push method somewhere hmm
<fowl>
#push is on Array
Danielpk_ has joined #ruby
<canton7>
not relevant here
<shevy>
#push is on your momma
<canton7>
just read your book haha
<shevy>
atmosx, << is so much nicer than #push
awarner has joined #ruby
ltsstar has quit [Quit: ltsstar]
<shevy>
whoever came up with #push was an evil evil man
<atmosx>
I never use push but I like push more
<shevy>
why!
<shevy>
it's longer!
jimeh has quit [Ping timeout: 244 seconds]
<atmosx>
however that's no thwat I wnated although I stumbled in this nice post
<shevy>
http://www.youtube.com/watch?v=rB1k02yh43A hehe too bad... look at what they were wearing... sexy outfits... now I still wonder what it has to do with aliens to wear sexy outfits...
<Hanmac>
its because they can :P
<atmosx>
I need to deine my method like that? my_method( width: 400, height: 50, show_border: false )
ZachBeta has quit [Quit: Computer has gone to sleep.]
ZachBeta has joined #ruby
<atmosx>
shevy: ruby 1.8 is pretty much dead
mmitchell has quit [Ping timeout: 276 seconds]
alanp has joined #ruby
alanp has quit [Read error: Connection reset by peer]
alanp_ has quit [Read error: Connection reset by peer]
timonv has quit [Remote host closed the connection]
alanp has joined #ruby
ZachBeta has quit [Client Quit]
beachandbytes has joined #ruby
maletor has joined #ruby
fbernier has quit [Ping timeout: 245 seconds]
<atmosx>
there are severely stupid web 2.0 services out there. I wonder if they make any revenue or just 'exist'
Averna has quit [Read error: Connection reset by peer]
<GoHuyGo>
exist
<atmosx>
yeah, cool.
<GoHuyGo>
hahaha
Xeago has joined #ruby
<GoHuyGo>
I made one as my first project
<GoHuyGo>
worst idea ever
<atmosx>
If they can live with a heroku worker that's cool, if not it's stupid
<GoHuyGo>
community building = difficult
<atmosx>
GoHuyGo: explain further
S1kx has quit [Remote host closed the connection]
fbernier has joined #ruby
<GoHuyGo>
not much to really explain
sterex has quit [Quit: sterex]
<GoHuyGo>
I'm new to rails (6 months in)
<atmosx>
nah, if you ask people about if something can or cannot b edone, they will alwyas say to you that it cannot. Then next guy arrives and does it (correctly).
<GoHuyGo>
(where users collaborate to plan a trip)
<GoHuyGo>
now I just use it as a playground
<atmosx>
I heard about an idea about a project like 4square on a Greek podcast in 2004 buy cosmix. Skilled guy, really skilled. But out of resources do it. Even if he had done something like this, I'm not sure it could 'fly' like 4sqr did
<GoHuyGo>
atmosx: are you learning or do you work?
<GoHuyGo>
yeah
jrist has joined #ruby
Averna has joined #ruby
<GoHuyGo>
with web 2.0, you never really know
<GoHuyGo>
look at twitter
<GoHuyGo>
if someone tried to pitch it to you
love_col_ has quit [Remote host closed the connection]
<GoHuyGo>
you'd probably think it's stupid
chussenot has quit [Quit: chussenot]
jimeh has joined #ruby
<jrajav>
Not really.. Twitter's not the only microblogging platform that has any traction
<jrajav>
It's just the only real player in America
atmosx_noauth has joined #ruby
<GoHuyGo>
really?
<atmosx_noauth>
I study pharmacy because my parents have one and in my country things are going as worst as it gets…
conor_ireland has quit [Quit: conor_ireland]
<GoHuyGo>
if somoene had pitched me a microblog that only allows you to send out 180char
<GoHuyGo>
I would have thought they were joking
<GoHuyGo>
(pre-twitter, of course)
<atmosx_noauth>
I think the 140 were a brilliant idea.
<GoHuyGo>
porwhy?
<atmosx_noauth>
You can't write too much shit on it
<GoHuyGo>
yeah
<GoHuyGo>
turned out to be a good thing
<atmosx_noauth>
well the follow-follow_me thing is good
workmad3 has joined #ruby
<atmosx_noauth>
I started following everyone who is following me, like follow back and I ended up with a busy/lame timeline
und3f has quit [Quit: Leaving.]
<atmosx_noauth>
Now I just follow people that "do something". It's incredible how stupid (especially girls) a user can be. I mean, wtf do I care about your feelings and status 24/7? ...
<atmosx_noauth>
the follow/follow me was the big idea.
atmosx has quit [Ping timeout: 245 seconds]
atmosx_noauth is now known as atmosx
<GoHuyGo>
mhm
<atmosx>
GoHuyGo: Anywya, I don't think the idea or 'an idea' alone is worthy. Ideas are cheap implementation costs and it's what counts...
<atmosx>
tweets at least procudes revenuew, facebook imho will never do that
<atmosx>
I was laughing a couple of years ago when they were comparing facebook to google… Facebook had a turnover of less then 1 bil while google had 50...
<atmosx>
FB was evaluated for something like 50 bl in the stock market though, pre-ipo
<atmosx>
years
<atmosx>
bubbles
<atmosx>
GoHuyGo: where r u from?
zigomir_ has quit [Ping timeout: 246 seconds]
<GoHuyGo>
California
<GoHuyGo>
SJ
<GoHuyGo>
agreed on implementation part
<GoHuyGo>
when I was working on the app
<GoHuyGo>
I saw many like it
<GoHuyGo>
but each was uniqu (some were obv better than others)