fflush changed the topic of #ruby to: Ruby 1.9.3-p194: http://ruby-lang.org || Paste > 3 lines of text on pastebin.com
lggr has joined #ruby
thisirs has quit [Remote host closed the connection]
tnk1 has quit [Read error: Connection reset by peer]
diverdude has quit [Ping timeout: 246 seconds]
dpk has joined #ruby
zigomir has quit [Ping timeout: 246 seconds]
diverdude has joined #ruby
emmanuelux has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 260 seconds]
mikepack has joined #ruby
lggr has joined #ruby
conor_ireland has quit [Quit: conor_ireland]
headius has quit [Quit: headius]
ltsstar has quit [Quit: ltsstar]
gngrwzrd has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
gngrwzrd has quit [Client Quit]
ledao has quit [Quit: Leaving.]
Takehiro has joined #ruby
Banistergalaxy has quit [Remote host closed the connection]
Tassis has joined #ruby
lggr has joined #ruby
Eplemosen has quit [Quit: NOPE]
zeromodulus has joined #ruby
Takehiro has quit [Ping timeout: 260 seconds]
Tombar has quit [Remote host closed the connection]
roadt has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
CodeFriar has joined #ruby
lggr has joined #ruby
<_bart> [{:segments=>2, :url=>"/1"}, {:segments=>2, :url=>"/1"}, {:segments=>3, :url=>"/1/2"}]
<_bart> how do I group that thing by amount of segments?
<_bart> so that it becomes: [[{:segments=>2, :url=>"/1"}, {:segments=>2, :url=>"/1"}], [{:segments=>3, :url=>"/1/2"}]]
rabidpraxis has joined #ruby
<_bart> I tried .group_by(&:segments) but that think work, undefined method `segments' for {:segments=>2, :url=>"/1"}:Hash (NoMethodError)
AlbireoX has joined #ruby
<_bart> that didn't*
sent-hil has quit [Remote host closed the connection]
<_bart> ah .group_by { |u| u[:segments] }
<_bart> got it
sent-hil has joined #ruby
havenn has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
jrist has joined #ruby
lggr has joined #ruby
<Vinz_> I've a question, with datamapper, is it better to handle form validation by JS or by datamapper validation ?
Guest29403 is now known as neersighted
<sent-hil> Vinz_: both
<Vinz_> Use both, or both are good ?
<blazes816> both
<blazes816> ;)
<blazes816> either or is fine, both is better
<blazes816> well, scratch taht
<Vinz_> Ok ! Thanks :)
<blazes816> that*
<blazes816> at least have model-layer validations
<blazes816> otherwise I could circumvent your JS
<sent-hil> use both, js for quick user response, backend to make sure user didn't turn off js or something
<sent-hil> Vinz_: ^
<Vinz_> sent-hil: Ok, I see :)
<Vinz_> I'll do that then :P
<blazes816> and unlike most on the RoR community and champion strong data-layer validation as well. i.e. proper constraints
hgf has quit [Quit: hgf]
lggr has quit [Ping timeout: 260 seconds]
Xeago has joined #ruby
S1kx has quit [Ping timeout: 240 seconds]
lggr has joined #ruby
<RubyPanther> There is always a large minority who still know how to use a db.
havenn has quit [Remote host closed the connection]
<dross> using an ORM all the time though will make you stupid
<dross> human minds are you forget what you don't use
<RubyPanther> I use an ORM, and I write stored procedures too, I don't buy it
<RubyPanther> The ORM helps me stuff legacy nightmares under the rug
SuperrMann has quit [Quit: Bye all :)]
saschagehlich has quit [Quit: saschagehlich]
lggr has quit [Ping timeout: 245 seconds]
hgf has joined #ruby
deadghost has quit [Ping timeout: 246 seconds]
sent-hil has quit [Remote host closed the connection]
JonnieCache has joined #ruby
cburyta has quit [Remote host closed the connection]
lggr has joined #ruby
cburyta has joined #ruby
joeycarmello has joined #ruby
bradyl0ve has joined #ruby
slainer68 has quit [Remote host closed the connection]
LouisGB has quit [Ping timeout: 260 seconds]
deadghost has joined #ruby
joeycarmello has quit [Ping timeout: 246 seconds]
sent-hil has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
rabidpraxis has quit [Remote host closed the connection]
rTypo has quit [Quit: Leaving]
parzorep has quit [Ping timeout: 246 seconds]
JonnieCache has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
hadees has quit [Quit: hadees]
cburyta has quit [Remote host closed the connection]
headius has joined #ruby
<_bart> [{:a => 'cookies', :b => 'boo'}, {:a => 'apples', :b => 'abc'}], how do I get the values of :a in an array?
<_bart> ah just map, nvm, .map { |x| x[:a] }
headius has quit [Client Quit]
ledao has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
parzorep has joined #ruby
luckyruby has quit [Remote host closed the connection]
<blazes816> I wish the block-to-proc syntax allowed params for stuff like that
hgf has quit [Quit: hgf]
lggr has joined #ruby
jroes has left #ruby [#ruby]
Takehiro has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
Pochacco has quit [Ping timeout: 246 seconds]
rabidpraxis has joined #ruby
lggr has joined #ruby
Takehiro has quit [Ping timeout: 260 seconds]
williamcotton has joined #ruby
TomJ has quit [Quit: TomJ]
Zaeyx has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ruby
Pochacco has joined #ruby
williamcotton has quit [Quit: williamcotton]
cburyta has joined #ruby
Pochacco has quit [Client Quit]
anomaly has joined #ruby
brianpWins has joined #ruby
brianpWins has quit [Client Quit]
Xeago has quit [Remote host closed the connection]
bradyl0ve has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 246 seconds]
Pochacco has joined #ruby
dpk has quit [Quit: Asleep at the keyboard.]
lggr has joined #ruby
Pochacco has left #ruby [#ruby]
jenrzzz has quit [Ping timeout: 248 seconds]
saschagehlich has joined #ruby
saschagehlich has quit [Client Quit]
jenrzzz has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
sirecote has quit [Ping timeout: 244 seconds]
luckyruby has joined #ruby
lggr has joined #ruby
havenn has joined #ruby
DarezGhost has joined #ruby
luckyruby has quit [Remote host closed the connection]
<DarezGhost> i'm having some trouble with sessions in my rails app. can someone help?
CodeFriar has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 245 seconds]
kyktommy has joined #ruby
sirecote has joined #ruby
mahmoudimus has quit [Ping timeout: 248 seconds]
pipopopo has joined #ruby
Ruler_Of_Heaven_ has quit [Ping timeout: 256 seconds]
cburyta has quit [Remote host closed the connection]
lggr has joined #ruby
havenn has quit [Ping timeout: 264 seconds]
tomku has joined #ruby
<sent-hil> !guru
<sent-hil> DarezGhost: just ask the question, if someone knows they'll answer
sirecote has quit [Ping timeout: 245 seconds]
<sent-hil> DarezGhost: also you should be in #rubyonrails or #rails
CodeFriar has joined #ruby
<DarezGhost> i did but no one seems to be around :P
<DarezGhost> anyway
<DarezGhost> let me ask it here
<DarezGhost> so, it appears that my sessions are not being recognized
<DarezGhost> I use session object to store user ID of users that have logged in
sent-hil has quit [Remote host closed the connection]
Guedes has quit [Ping timeout: 260 seconds]
sent-hil has joined #ruby
g-ram has joined #ruby
<DarezGhost> I set the user ID in the session when a user logs in
<DarezGhost> and then for other methods in my controller, I query the user ID
<DarezGhost> pretty usual stuff
<DarezGhost> if I use a web browser to access my app
<DarezGhost> the session objects have the correct data
<DarezGhost> but when I use iOS's NSURLRequest, the server doesn't seem to be able to retrieve the active session
<DarezGhost> the session object is always empty
<DarezGhost> HOWEVER
sepp2k1 has joined #ruby
<DarezGhost> if I check the "cookies" object in my rails app
<DarezGhost> I can see the session ID is in there!
<DarezGhost> so the client is in fact sending the cookie back with the correct session ID
sirecote has joined #ruby
<DarezGhost> but for some reason the server doesn't seem to be able to use it to retrieve the session object
<DarezGhost> it always creates a new session instead
<DarezGhost> I'm using Passenger Phusion
<DarezGhost> anyone know what could be happening?
<Paradox> sounds like an iOS problem
sepp2k has quit [Ping timeout: 260 seconds]
<Paradox> does it happen in the simulator?
lggr has quit [Ping timeout: 246 seconds]
bluenemo has quit [Remote host closed the connection]
Jellyg00se has joined #ruby
<DarezGhost> yep
jenrzzz has quit [Ping timeout: 246 seconds]
<DarezGhost> i'm dissected the crap out of it from the ios side
<DarezGhost> looked closely at the http headers being sent
<DarezGhost> made sure the cookie is correct
lggr has joined #ruby
<DarezGhost> in fact, even the rails app is able to see the cookie and it has the correct session id in it
jenrzzz has joined #ruby
roadt has quit [Ping timeout: 246 seconds]
manizzle has joined #ruby
F1skr has quit [Quit: WeeChat 0.3.9]
Takehiro has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
hgf has joined #ruby
jimeh2 has quit [Ping timeout: 240 seconds]
lggr has joined #ruby
icole has quit [Remote host closed the connection]
Takehiro has quit [Ping timeout: 260 seconds]
nwertman has quit [Quit: nwertman]
sirecote has quit [Ping timeout: 245 seconds]
Bosox20051 has joined #ruby
Tombar has joined #ruby
sirecote has joined #ruby
lggr has quit [Ping timeout: 264 seconds]
mengu has quit [Remote host closed the connection]
artnez has joined #ruby
lggr has joined #ruby
radic has quit [Disconnected by services]
radic_ has joined #ruby
sirecote has quit [Ping timeout: 245 seconds]
charliesome has joined #ruby
colinbm has joined #ruby
Tombar_ has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
tk___ has joined #ruby
shammancer has joined #ruby
artnez has quit [Quit: artnez]
Tombar has quit [Ping timeout: 240 seconds]
notVert has quit [Read error: Connection reset by peer]
artnez has joined #ruby
lggr has joined #ruby
sirecote has joined #ruby
colinbm has quit [Quit: colinbm]
DarezGhost has quit [Ping timeout: 240 seconds]
kiyoura has quit [Quit: Leaving]
notVert has joined #ruby
anomaly has left #ruby ["Leaving"]
iamjarvo has quit [Ping timeout: 246 seconds]
SohKai has joined #ruby
lggr has quit [Ping timeout: 240 seconds]
iamjarvo has joined #ruby
a_a_g has joined #ruby
lggr has joined #ruby
icole has joined #ruby
bapa has joined #ruby
gmci has quit [Quit: Computer has gone to sleep.]
artnez has quit [Remote host closed the connection]
artnez has joined #ruby
sent-hil has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 264 seconds]
Bosma has joined #ruby
quest88 has quit [Quit: quest88]
lggr has joined #ruby
jenrzzz has quit [Ping timeout: 264 seconds]
AndChat718256 has joined #ruby
sepp2k1 has quit [Remote host closed the connection]
AndChat718256 has quit [Quit: Bye]
hiroyuki has quit [Ping timeout: 246 seconds]
dominikh has quit [Ping timeout: 260 seconds]
iamjarvo has quit [Ping timeout: 245 seconds]
sirecote has quit [Ping timeout: 245 seconds]
sirecote has joined #ruby
sr___ has quit [Quit: Connection closed for inactivity]
lggr has quit [Ping timeout: 240 seconds]
lggr has joined #ruby
jenrzzz has joined #ruby
delinquentme has joined #ruby
<delinquentme> in a .each loop .... variables used to store objects created within that loop ... should be instance variables right?
iamjarvo has joined #ruby
swarley has joined #ruby
<delinquentme> BECAUSE the variables are only used ONCE per loop ... and thus will be marked for removal sooner in the garbage collection ja?
x1337807x has joined #ruby
lggr has quit [Ping timeout: 264 seconds]
joofsh has quit [Remote host closed the connection]
lggr has joined #ruby
n_blownapart has joined #ruby
JonnieCache has joined #ruby
Takehiro has joined #ruby
<n_blownapart> hi I'm not sure what is going on in the 2nd and 3rd regex examples here. thanks: http://pastie.org/4906423
Banistergalaxy has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
fantazo has joined #ruby
Takehiro has quit [Ping timeout: 255 seconds]
lggr has joined #ruby
daniel_- has quit [Ping timeout: 246 seconds]
<x1337807x> n_blownapart: Have you seen rubular.com? It's a great place to play with regexes.
bradyl0ve has joined #ruby
lggr has quit [Ping timeout: 264 seconds]
<n_blownapart> thanks x1337807x I've played with it. I'm confused about line 7, where $1 and $2 return "line" "here"
kyktommy has quit [Quit: kyktommy]
kyktommy has joined #ruby
lggr has joined #ruby
<n_blownapart> Banistergalaxy: hey wondering if you've seen this band cinematic orchestra: http://www.youtube.com/watch?v=bjjc59FgUpg
kyktommy has quit [Client Quit]
swarley_ has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
bnagy_ is now known as bnagy
roadt has joined #ruby
Banistergalaxy has quit [Ping timeout: 246 seconds]
mahmoudimus has joined #ruby
a_a_g has quit [Quit: Leaving.]
lggr has quit [Ping timeout: 246 seconds]
quest88 has joined #ruby
lggr has joined #ruby
FifthWall has joined #ruby
jrajav has quit []
n_blownapart has quit [Remote host closed the connection]
g_bleezy has joined #ruby
bradyl0ve has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 246 seconds]
nightfalcon has joined #ruby
JonnieCache has quit [Ping timeout: 252 seconds]
notVert has quit [Remote host closed the connection]
lggr has joined #ruby
jamjam has quit [Ping timeout: 246 seconds]
Juv1228 has left #ruby ["Leaving"]
drbawb has quit [Ping timeout: 246 seconds]
deryl-android has joined #ruby
shammancer has left #ruby ["Leaving"]
lggr has quit [Ping timeout: 255 seconds]
deryl-android has quit [Remote host closed the connection]
deryl-android has joined #ruby
Takehiro has joined #ruby
deryl-android has quit [Client Quit]
lggr has joined #ruby
shammancer has joined #ruby
jamjam has joined #ruby
abstrusenick has joined #ruby
erichmenge has quit [Quit: Linkinus - http://linkinus.com]
shammancer has quit [Quit: Leaving]
shammancer has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
axl_ has quit [Quit: axl_]
shammancer has quit [Client Quit]
drbawb has joined #ruby
shammancer has joined #ruby
lggr has joined #ruby
dominikh has joined #ruby
shammancer has quit [Client Quit]
shammancer has joined #ruby
Adran has quit [Quit: Your nick was overruled.]
delinquentme has quit [Quit: Leaving]
lggr has quit [Ping timeout: 246 seconds]
manizzle has quit [Ping timeout: 246 seconds]
colinbm has joined #ruby
fantazo has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
oldB has joined #ruby
hiroyuki has joined #ruby
colinbm has quit [Quit: colinbm]
bapa has quit [Ping timeout: 246 seconds]
beachandbytes has joined #ruby
fantazo has joined #ruby
lagzilla has quit [Quit: Leaving]
lggr has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
oldB has quit [Quit: oldB]
rubious has joined #ruby
mahmoudimus has quit [Quit: Computer has gone to sleep.]
lggr has quit [Ping timeout: 256 seconds]
bradleyprice has joined #ruby
lggr has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
oldB has joined #ruby
reset has joined #ruby
lggr has joined #ruby
mahmoudimus has joined #ruby
anandhegde has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
lggr has joined #ruby
noyb has joined #ruby
sarmiena_ has joined #ruby
eikko has quit [Ping timeout: 246 seconds]
jaw2 has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
jaw2 is now known as Matoch
lggr has joined #ruby
answer_42 has joined #ruby
abstrusenick has quit [Quit: abstrusenick]
Playb3yond has joined #ruby
grizlo42 has quit [Quit: Leaving.]
reset has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 240 seconds]
tralart has joined #ruby
lggr has joined #ruby
oldB has quit [Quit: oldB]
swarley_ has quit [Quit: Leaving]
tdubz has joined #ruby
thomas has quit [Read error: Connection reset by peer]
Bosox20051 has quit [Quit: Leaving]
lggr has quit [Ping timeout: 252 seconds]
lordnaz has quit [Quit: WeeChat 0.3.7]
<whackatre> is there a reason why i get "No such file or directory - a (Errno::ENOENT)" whenever i call gets?
lggr has joined #ruby
beachandbytes has quit [Ping timeout: 252 seconds]
khakimov_ has joined #ruby
khakimov has quit [Ping timeout: 252 seconds]
lggr has quit [Ping timeout: 260 seconds]
pen has joined #ruby
Matoch has left #ruby [#ruby]
Nisstyre-laptop has quit [Remote host closed the connection]
Tombar_ has quit [Remote host closed the connection]
<whackatre> problem fixed; STDIN.gets works. thanks anyway.
Playb3yond has quit [Read error: Connection reset by peer]
bradleyprice has quit [Remote host closed the connection]
lggr has joined #ruby
Bosma has quit [Ping timeout: 255 seconds]
FlowState has joined #ruby
FlowState has joined #ruby
FlowState has quit [Changing host]
apok has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
grizlo42 has joined #ruby
lggr has joined #ruby
g-ram has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
Takehiro has quit [Remote host closed the connection]
icooba has quit [Quit: Textual IRC Client: www.textualapp.com]
lggr has quit [Ping timeout: 246 seconds]
quest88 has quit [Quit: quest88]
Nisstyre-laptop has joined #ruby
lggr has joined #ruby
JonnieCache has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
codefyre has joined #ruby
lggr has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
monkegjinni has joined #ruby
TriTodd has quit [Ping timeout: 244 seconds]
ananthakumaran has joined #ruby
skogis has joined #ruby
nightfalcon has quit [Quit: Lost terminal]
lggr has quit [Ping timeout: 255 seconds]
TriTodd has joined #ruby
<pen> anyone using ruby in your work?
lggr has joined #ruby
prox|a has quit [Ping timeout: 256 seconds]
virtualentity has joined #ruby
iamjarvo has quit [Ping timeout: 245 seconds]
fridim_ has quit [Ping timeout: 245 seconds]
rabidpraxis has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 248 seconds]
prox|a has joined #ruby
lggr has joined #ruby
virtualentity has quit [Ping timeout: 246 seconds]
monsieurp has left #ruby [#ruby]
hgf has quit [Quit: hgf]
diverdude has quit [Ping timeout: 256 seconds]
lggr has quit [Ping timeout: 240 seconds]
icole has quit [Remote host closed the connection]
rakl has joined #ruby
AlbireoX has quit [Remote host closed the connection]
Takehiro has joined #ruby
rakunHo has joined #ruby
lggr has joined #ruby
dangerousdave has joined #ruby
futilegames has joined #ruby
mucker has joined #ruby
Tassis has left #ruby [#ruby]
lggr has quit [Ping timeout: 264 seconds]
lordnaz has joined #ruby
lordnaz has quit [Client Quit]
lggr has joined #ruby
daslicious has quit [Quit: daslicious]
glyytchy has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
hadees has joined #ruby
tdubz is now known as thomas
lggr has joined #ruby
Nisstyre-laptop has quit [Read error: Connection reset by peer]
frameworks has joined #ruby
daniel_hinojosa has quit [Quit: Leaving.]
frameworks has quit [Client Quit]
timonv has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
idlecool has left #ruby ["Linkinus - http://linkinus.com"]
zigomir has joined #ruby
lggr has joined #ruby
reset has joined #ruby
rakl has quit [Ping timeout: 260 seconds]
und3f has joined #ruby
codefyre has quit [Quit: Leaving]
lggr has quit [Ping timeout: 246 seconds]
FifthWall has quit [Quit: Zzzzzzzzzzzzz]
anandhegde has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
phar0e has quit [Read error: Operation timed out]
murz has joined #ruby
<Mon_Ouie> whackatre: Prefer $stdin.gets
glyytchy has quit [Quit: Leaving...]
<Mon_Ouie> And the reason for the error is that gets is implicitly ARGF.gets
glyytchy has joined #ruby
Banistergalaxy has joined #ruby
JonnieCache has quit [Ping timeout: 260 seconds]
saschagehlich has joined #ruby
rubious has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 256 seconds]
lot49 has joined #ruby
workmad3 has joined #ruby
rippa has joined #ruby
swarley has quit []
glyytchy has quit [Quit: Leaving...]
alanp has joined #ruby
lggr has joined #ruby
zigomir has quit [Ping timeout: 246 seconds]
ryanlecompte has joined #ruby
lot49 has quit [Ping timeout: 256 seconds]
__class__ has quit [Read error: Connection reset by peer]
sarmiena_ has quit [Quit: sarmiena_]
ZubKonst has joined #ruby
ThatOneGuy_ has joined #ruby
<ThatOneGuy_> I get "/usr/lib/ruby/1.8/irb.rb:12:in `require': no such file to load -- e2mmap (LoadError) " when I run the command "irb"
<ThatOneGuy_> Any ideas?
lggr has quit [Ping timeout: 246 seconds]
glyytchy has joined #ruby
ZubKonst_ has quit [Ping timeout: 240 seconds]
justinmcp has joined #ruby
lggr has joined #ruby
<Mon_Ouie> e2mmap is part of stdlib. Don't youu have a /usr/lib/ruby/1.8/e2mmap.rb file?
c0rn_ has joined #ruby
ThatOneGuy_ has left #ruby [#ruby]
fixl has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
icole has joined #ruby
margle has joined #ruby
__class__ has joined #ruby
glyytchy has quit [Quit: Leaving...]
wallerdev has quit [Quit: wallerdev]
arturaz has joined #ruby
futilegames has quit [Quit: futilegames]
lggr has quit [Ping timeout: 264 seconds]
icole has quit [Ping timeout: 246 seconds]
Solnse has joined #ruby
cakehero has quit [Quit: Computer has gone to sleep.]
jer1ko has joined #ruby
tralart has quit [Read error: Operation timed out]
lggr has joined #ruby
jer1ko has left #ruby [#ruby]
stephenjudkins has quit [Quit: stephenjudkins]
grizlo42 has quit [Quit: Leaving.]
RubyPanther has quit [Ping timeout: 246 seconds]
khakimov_ has quit [Quit: Computer has gone to sleep.]
grizlo42 has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
und3f has quit [Ping timeout: 256 seconds]
RubyPanther has joined #ruby
Iszak has joined #ruby
Iszak has quit [Changing host]
Iszak has joined #ruby
lggr has joined #ruby
Solnse has quit [Quit: Leaving.]
Solnse has joined #ruby
und3f has joined #ruby
Solnse has quit [Client Quit]
Solnse has joined #ruby
lot49 has joined #ruby
Solnse has quit [Client Quit]
justinmcp has quit [Remote host closed the connection]
hakunin has quit [Remote host closed the connection]
margle has quit [Read error: Connection reset by peer]
hakunin has joined #ruby
lot49 has quit [Client Quit]
Forevernade has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 260 seconds]
Hamed-R has joined #ruby
Solnse has joined #ruby
emergion has joined #ruby
lggr has joined #ruby
hakunin has quit [Ping timeout: 260 seconds]
margle has joined #ruby
apok has quit [Quit: apok]
lggr has quit [Ping timeout: 252 seconds]
Criztian has joined #ruby
mikepack has quit [Remote host closed the connection]
lggr has joined #ruby
timonv has quit [Remote host closed the connection]
x1337807x has quit [Ping timeout: 260 seconds]
emergion has quit [Quit: Computer has gone to sleep.]
cakehero has joined #ruby
sashman has joined #ruby
mengu has joined #ruby
Solnse2 has joined #ruby
ryanlecompte has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 246 seconds]
Solnse has quit [Ping timeout: 255 seconds]
pmros has joined #ruby
ryanlecompte has joined #ruby
<pmros> hi!
Solnse2 has quit [Ping timeout: 260 seconds]
Solnse has joined #ruby
lggr has joined #ruby
timonv has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
pen has quit [Remote host closed the connection]
<pmros> it's so quiet...
lggr has joined #ruby
ryanlecompte has quit [Remote host closed the connection]
<pmros> I've update my ruby project...
dangerousdave has quit [Quit: Leaving...]
colinbm has joined #ruby
<pmros> it's called troshka
<pmros> it's a gui repl
<pmros> sorry, this is not an advertisement
<pmros> but it seems...
Iszak has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
workmad3 has quit [Ping timeout: 260 seconds]
awestroke has joined #ruby
mucker has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 256 seconds]
<pmros> everyone is sleeping... zzzzzzzzz
icole has joined #ruby
undersc0re97 has quit [Quit: i use linux l o l]
lggr has joined #ruby
margle has quit [Quit: Computer has gone to sleep.]
justinmcp has joined #ruby
undersc0re97 has joined #ruby
chimay has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
icole has quit [Ping timeout: 264 seconds]
Solnse2 has joined #ruby
sepp2k has joined #ruby
justinmcp has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
Solnse has quit [Ping timeout: 244 seconds]
lggr has quit [Ping timeout: 252 seconds]
pskosinski has joined #ruby
Solnse2 has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
<RubyPanther> are you sure it isn't an advertisement?
postmodern has quit [Quit: Leaving]
eroc has joined #ruby
<pmros> sorry
<pmros> it's disgusting
<RubyPanther> most GUIs are
<pmros> it's depend on user
reset has quit [Quit: Leaving...]
margle has joined #ruby
arturaz has quit [Remote host closed the connection]
samphippen has joined #ruby
<shevy> pmros did you make a gem?
<pmros> yes, I did
lggr has quit [Ping timeout: 245 seconds]
<shevy> oh dang
<pmros> troshka
<shevy> Error installing troshka: troshka requires Ruby version >= 1.9.0.
<shevy> I am currently on 1.8.x again
<pmros> oh, I'm sorry
<pmros> it does requiere ruby version >= 1.9.0
postmodern has joined #ruby
dfmoser has joined #ruby
<pmros> RubyPanther, shevy, thank you for your feedback
<pmros> I've to go
<pmros> see you!
pmros has quit [Quit: Konversation terminated!]
lggr has joined #ruby
prtksxna has joined #ruby
Xeago has joined #ruby
jgrevich has quit [Quit: jgrevich]
margle has quit [Quit: Computer has gone to sleep.]
lggr has quit [Ping timeout: 264 seconds]
lggr has joined #ruby
pskosinski has quit [Read error: Connection timed out]
pskosinski has joined #ruby
bluOxigen has joined #ruby
JonnieCache has joined #ruby
lggr has quit [Ping timeout: 240 seconds]
AMfish has joined #ruby
lggr has joined #ruby
mvangala has quit [Ping timeout: 248 seconds]
Companion has quit [Ping timeout: 252 seconds]
JonnieCache has quit [Ping timeout: 246 seconds]
eroc has quit [Quit: eroc]
timonv has quit [Remote host closed the connection]
Companion has joined #ruby
Companion has joined #ruby
Companion has quit [Changing host]
lggr has quit [Ping timeout: 240 seconds]
vlad_starkov has joined #ruby
lggr has joined #ruby
LouisGB has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
<shevy> hmm
piotr_ has joined #ruby
margle has joined #ruby
sspiff has quit [Remote host closed the connection]
lggr has joined #ruby
awestroke has quit [Remote host closed the connection]
arietis has joined #ruby
AndChat| has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
robustus has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
AndChat- has joined #ruby
Banistergalaxy has quit [Ping timeout: 260 seconds]
Banistergalaxy has joined #ruby
lggr has joined #ruby
AndChat| has quit [Ping timeout: 256 seconds]
margle has quit [Quit: Computer has gone to sleep.]
AndChat- has quit [Ping timeout: 256 seconds]
ryanf has quit [Quit: leaving]
Zai_ has joined #ruby
bluOxigen has quit [Ping timeout: 246 seconds]
AndChat| has joined #ruby
vlad_starkov has joined #ruby
AndChat- has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
niklasb has joined #ruby
lggr has joined #ruby
futilegames has joined #ruby
SeySayux_ has joined #ruby
Banistergalaxy has quit [Ping timeout: 256 seconds]
Xeago has quit [Read error: Connection reset by peer]
SeySayux has quit [Ping timeout: 240 seconds]
AndChat| has quit [Ping timeout: 260 seconds]
Xeago has joined #ruby
SeySayux_ is now known as SeySayux
Villadelfia has quit [Ping timeout: 245 seconds]
Banistergalaxy has joined #ruby
AndChat| has joined #ruby
eldariof has joined #ruby
Villadelfia has joined #ruby
AndChat- has quit [Ping timeout: 260 seconds]
justinmcp has joined #ruby
Iszak has joined #ruby
Iszak has quit [Changing host]
Iszak has joined #ruby
Xeago has quit [Read error: Connection reset by peer]
lggr has quit [Ping timeout: 260 seconds]
Xeago has joined #ruby
dpk has joined #ruby
a_a_g has joined #ruby
reuf has joined #ruby
Banistergalaxy has quit [Ping timeout: 260 seconds]
Xeago has quit [Read error: Connection reset by peer]
bigmeow has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
Xeago has joined #ruby
fantazo has quit [Remote host closed the connection]
morozovm has joined #ruby
a_a_g1 has joined #ruby
a_a_g1 has quit [Client Quit]
a_a_g has quit [Ping timeout: 245 seconds]
Banistergalaxy has joined #ruby
AndChat- has joined #ruby
bigmeow has joined #ruby
awestroke has joined #ruby
x0F has quit [Disconnected by services]
x0F_ has joined #ruby
AndChat| has quit [Ping timeout: 260 seconds]
x0F_ is now known as x0F
lggr has quit [Ping timeout: 256 seconds]
Banistergalaxy has quit [Ping timeout: 240 seconds]
seme has joined #ruby
seme is now known as Guest29553
<arietis> is there any email address parser for ruby?
<arietis> i have .doc file with e-mails
<arietis> and i wanna parse it out
lggr has joined #ruby
colinbm has quit [Quit: colinbm]
Guest29553 is now known as _seme
ltsstar has joined #ruby
Neomex has joined #ruby
mahmoudimus has quit [Quit: Computer has gone to sleep.]
futilegames_ has joined #ruby
futilegames has quit [Ping timeout: 256 seconds]
futilegames_ is now known as futilegames
lggr has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
<_seme> hey guys can anyone think of a reason that (from irb) when I type instances[0][:instance].inspect it prints "\"NA0 (SSL) \"" and "NA0 (SSL) ".strip prints "NA0 (SSL)" but instances[0][:instance].strip prints "NA0 (SSL) ".... freaking anonying :)
IPGlider has joined #ruby
<_seme> and I've tried strip! with the same result
IPGlider is now known as Guest4365
murz has quit [Quit: Leaving...]
<_seme> I'm about ready to pull my hair out
bigmeow has quit [Ping timeout: 244 seconds]
Guest4365 has quit [Client Quit]
ltsstar has quit [Ping timeout: 260 seconds]
IPGlider_ has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
arturaz has joined #ruby
fixl has joined #ruby
bigmeow has joined #ruby
hackeron has quit [Remote host closed the connection]
IPGlider_ is now known as IPGlider
lggr has joined #ruby
timonv has joined #ruby
Banistergalaxy has joined #ruby
AndChat| has joined #ruby
icole has joined #ruby
grizlo42 has quit [Quit: Leaving.]
lggr has quit [Ping timeout: 252 seconds]
<_seme> ok I think I figured it out
<_seme> it appears that there is a bug in strip where it doesn't actually strip teh remaining whitespace on a string that ends with some multi-byte (ie UTF8) characters
AndChat- has quit [Ping timeout: 240 seconds]
Banistergalaxy has quit [Ping timeout: 252 seconds]
lggr has joined #ruby
ltsstar has joined #ruby
icole has quit [Ping timeout: 260 seconds]
apeiros_ has joined #ruby
Iszak has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
reuf has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 240 seconds]
slainer68 has joined #ruby
Xeago has quit [Remote host closed the connection]
LouisGB has quit [Ping timeout: 248 seconds]
lggr has joined #ruby
vjt has quit [Ping timeout: 272 seconds]
Xeago has joined #ruby
Hamed-R has quit [Ping timeout: 246 seconds]
chussenot has joined #ruby
nilg has quit [Ping timeout: 256 seconds]
daniel_- has joined #ruby
Virunga has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
Eplemosen has joined #ruby
lggr has joined #ruby
moshee has quit [Ping timeout: 246 seconds]
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
chussenot has quit [Ping timeout: 255 seconds]
gyre008 has joined #ruby
Banistergalaxy has joined #ruby
<gyre008> have a question..I need to include a path to libraries to my ruby file but can't figure out how to do that...
AndChat- has joined #ruby
<gyre008> im a ruby n00b
<gyre008> sysad…not a programmer
<apeiros_> $LOAD_PATH is what ruby searches for libraries
<apeiros_> it's a plain array, so you can modify it within ruby code. alternatively you can use the -I (capital i) option with the ruby executable.
<apeiros_> another alternative would be to use gems.
lggr has quit [Ping timeout: 240 seconds]
AndChat| has quit [Ping timeout: 252 seconds]
<gyre008> apeiros_, thanks…basically I have the following file https://gist.github.com/3847899 which is located in /usr/sbin …and I need it to be aware of the libraries which are in /usr/lib/ruby/vendor_ruby/chef/
Banistergalaxy has quit [Ping timeout: 260 seconds]
triptec has joined #ruby
mucker has joined #ruby
A124 has joined #ruby
Dawne has joined #ruby
lggr has joined #ruby
<gyre008> not really sure what to do :)
ChampS666 has joined #ruby
Virunga has quit [Remote host closed the connection]
Banistergalaxy has joined #ruby
AndChat| has joined #ruby
Xeago has quit [Remote host closed the connection]
kirun has joined #ruby
<gyre008> apeiros_, cheers…sorted! :)
<gyre008> apeiros_, great stuff man…thanks a lot
<apeiros_> ok. $: is the same as $LOAD_PATH btw.
<apeiros_> (it's its ugly perl step-brother)
fixl has quit [Quit: KVIrc 4.3.1 Aria http://www.kvirc.net/]
<gyre008> yeah I googled it and figured it out….thanks for pointing me to the right direction with the LOAD_PATH stuff mate
Banistergalaxy has quit [Ping timeout: 260 seconds]
AndChat- has quit [Ping timeout: 260 seconds]
<apeiros_> theoretically you shouldn't run into load path issues with things you install, though
lggr has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
nazty has quit [Quit: Leaving]
lggr has quit [Ping timeout: 260 seconds]
KillerFox has joined #ruby
lggr has joined #ruby
vjt has joined #ruby
demian`_ has joined #ruby
zommi has joined #ruby
Boohbah_ has quit [Ping timeout: 255 seconds]
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
lggr has quit [Ping timeout: 260 seconds]
oz has quit [Ping timeout: 246 seconds]
frogprince_mac has joined #ruby
JonnieCache has joined #ruby
Boohbah has joined #ruby
oz has joined #ruby
lggr has joined #ruby
icole has joined #ruby
ltsstar has quit [Remote host closed the connection]
ltsstar has joined #ruby
sagax has quit [Quit: Ухожу я от вас]
Boohbah is now known as Guest86326
lggr has quit [Ping timeout: 264 seconds]
JonnieCache has quit [Ping timeout: 256 seconds]
icole has quit [Ping timeout: 264 seconds]
lggr has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
arturaz has quit [Remote host closed the connection]
lggr has joined #ruby
daniel_- has quit [Ping timeout: 246 seconds]
kitofr_ has joined #ruby
kitofr has quit [Ping timeout: 248 seconds]
lggr has quit [Ping timeout: 260 seconds]
rTypo has joined #ruby
rTypo has quit [Changing host]
rTypo has joined #ruby
lggr has joined #ruby
deadalus has joined #ruby
kitofr has joined #ruby
deadalus has quit [Changing host]
deadalus has joined #ruby
kitofr_ has quit [Ping timeout: 245 seconds]
Neomex has quit [Quit: Neomex]
codefyre has joined #ruby
hackeron has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
Virunga has joined #ruby
lggr has joined #ruby
dfmoser has quit [Quit: dfmoser]
dfmoser has joined #ruby
IPGlider has quit []
jimeh2 has joined #ruby
lggr has quit [Ping timeout: 264 seconds]
zommi has quit [Quit: Leaving.]
chimay has quit [Remote host closed the connection]
emergion has joined #ruby
lggr has joined #ruby
timonv has quit [Remote host closed the connection]
chimay has joined #ruby
jimeh2 has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 246 seconds]
JonnieCache has joined #ruby
daniel_- has joined #ruby
AMfish has quit [Ping timeout: 260 seconds]
psychouroboros has joined #ruby
timonv has joined #ruby
deadalus has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
bluenemo has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
justinmcp has quit [Remote host closed the connection]
eldariof has quit []
bluOxigen has joined #ruby
Jork1 has joined #ruby
icole has joined #ruby
lggr has joined #ruby
hgf has joined #ruby
eldariof has joined #ruby
timonv has quit [Remote host closed the connection]
icole has quit [Ping timeout: 252 seconds]
F1skr has joined #ruby
hackeron_ has joined #ruby
jenrzzz has quit [Ping timeout: 256 seconds]
lggr has quit [Ping timeout: 248 seconds]
daniel_- has quit [Ping timeout: 245 seconds]
emergion has quit [Quit: Computer has gone to sleep.]
hackeron has quit [Ping timeout: 252 seconds]
lggr has joined #ruby
justinmcp has joined #ruby
_seme has quit [Ping timeout: 256 seconds]
icole has joined #ruby
icole has quit [Read error: Connection reset by peer]
gmci has joined #ruby
icole has joined #ruby
F1skr has quit [Quit: WeeChat 0.3.9]
lggr has quit [Ping timeout: 260 seconds]
F1skr has joined #ruby
lggr has joined #ruby
icole has quit [Ping timeout: 256 seconds]
piotr__ has joined #ruby
timonv has joined #ruby
piotr_ has quit [Ping timeout: 246 seconds]
jimeh2 has joined #ruby
etherdev has joined #ruby
etherdev has quit [Client Quit]
Oprr has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
`brendan has quit [Read error: Connection reset by peer]
`brendan has joined #ruby
lggr has joined #ruby
framling has quit [Quit: Lost terminal]
AMfish has joined #ruby
justinmcp has quit [Remote host closed the connection]
framling has joined #ruby
`brendan has quit [Ping timeout: 264 seconds]
<_bart> boo!
demian`_ has quit [Quit: demian`_]
timonv has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 260 seconds]
timonv has joined #ruby
margle has joined #ruby
jimeh2 has quit [Ping timeout: 256 seconds]
lggr has joined #ruby
rTypo has quit [Read error: No route to host]
rTypo has joined #ruby
answer_42 has quit [Remote host closed the connection]
answer_42 has joined #ruby
rTypo has quit [Read error: Connection reset by peer]
rTypo has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
Dawne has quit [Quit: Leaving.]
timonv has quit [Remote host closed the connection]
lggr has joined #ruby
arkiver has joined #ruby
alex__ has joined #ruby
jcoglan has quit [Quit: Leaving]
rTypo has quit [Ping timeout: 245 seconds]
psychouroboros is now known as deadalus
deadalus has quit [Changing host]
deadalus has joined #ruby
elico has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
ChampS666 has quit [Ping timeout: 246 seconds]
BMF has joined #ruby
triptec has quit [Quit: triptec]
lggr has joined #ruby
ChampS666 has joined #ruby
futilegames has quit [Quit: futilegames]
maxok has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
codefyre has quit [Quit: Leaving]
anandhegde has joined #ruby
lggr has joined #ruby
axl_ has joined #ruby
F1skr has quit [Quit: WeeChat 0.3.9]
JonnieCa1he has joined #ruby
apeiros_ has quit [Remote host closed the connection]
alex__ has quit [Ping timeout: 264 seconds]
joofsh has joined #ruby
sashman has quit [Ping timeout: 276 seconds]
t0rc has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
kain has joined #ruby
lggr has joined #ruby
<kain> hello, I have a normal ruby class with instance methods calling external services and they can potentially throw the same set of exceptions. I'd like to know what's the best way to have those exceptions rescued in a common place in the code
chimkan_ has joined #ruby
<t0rc> best way is the way that works best for your application.
AMfish has quit []
jimeh2 has joined #ruby
arkiver has quit [Quit: Leaving]
<kain> t0rc, actually I'm trying to unite in a single instance method all the actions that performs the external calls to have a single place where to rescue from, but it's getting hairy
<JonnieCache> the problem with that is all your code will have to pass through that single place
<JonnieCache> which will suck
chimkan_ has left #ruby [#ruby]
<JonnieCache> probably
<kain> ye
<t0rc> yeah that seems like it would get a little hairy
alex__ has joined #ruby
<JonnieCache> unless for example its a server which has some sort of dispatch method that runs everything
<JonnieCache> thats how rails allows you to catch all exceptions in the applicationcontroler
<canton7> kain, 2 potential options: http://pastie.org/4927499
vectorshelve has joined #ruby
Criztian has quit [Remote host closed the connection]
<kain> canton7, I like the second solution, thanks
elico has quit [Quit: elico]
<vectorshelve> what is yield exactly ?
<canton7> called, of course, as do_risky_thing{ my_risky_func }
bigmeow has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 252 seconds]
<canton7> vectorshelve, calls the block passed to that method
<kain> yeah I thought about going with a block
<kain> nice thanks, going back to the implementation ;)
jimeh2 has quit [Ping timeout: 264 seconds]
hgf has left #ruby [#ruby]
Puck6633 has joined #ruby
lggr has joined #ruby
vectorshelve has quit [Ping timeout: 240 seconds]
vectorshelve has joined #ruby
JonnieCache has quit [Quit: Lost terminal]
<vectorshelve> sorry got logged offf.. what is yield
bigmeow has joined #ruby
<Puck6633> It's a keyword (I think) that runs the block attached to current method. I think it has other uses but that's the main one.
<burgestrand> That’s the one use.
timonv has joined #ruby
<burgestrand> vectorshelve: ^
<vectorshelve> Puck6633: cool.. any simple example you could give.. I have seen yield being used more often in rails as well
<canton7> vectorshelve, so `def my_method; yield; end` is equivalent to `def my_method(&block); block.call; end`
<vectorshelve> canton7: hmm... getting it.. any use case?
gyre008 has left #ruby ["Leaving"]
<canton7> think of all the library methods you know which take a block
lggr has quit [Ping timeout: 248 seconds]
<vectorshelve> canton7: nice.. got it..
<canton7> methods which take a block use one of those 2 ways to call it
<vectorshelve> well.. is there any way other than through ruby mechanize that I can get results from a web page.. since I dont have an API. This is for writing a gem
futilegames has joined #ruby
arielpts has quit [Ping timeout: 260 seconds]
Zai_ has quit [Quit: Zai_]
<quazimodo> how do we scalar multiplay an array?
<canton7> open-uri ? net/http ?
lggr has joined #ruby
arielpts has joined #ruby
<quazimodo> [0, 1, 2, 3] * 4 = [0, 4, 8, 12] sorta deal
<vectorshelve> canton7: isnt ruby mechanize better than open-uri and net/http ?
<canton7> probably. more complex for sure
<canton7> quazimodo, #map ?
<vectorshelve> canton7: and also.. I will have to parse html at some point using dom elements.. which isnt I believe quite a consistent way to do it.. ryt.. wt if tomorrow they change the page ? :-/
<canton7> vectorshelve, parsing html = nokogiri
<quazimodo> oh cool
<quazimodo> canton7: /me hugs you
<quazimodo> also [1..5] to make [1, 2, 3, 4, 5] ?
<vectorshelve> canton7: well.. why did u say mechanize is complex.. I can use it without having to explicitly use nokogiri :)
<vectorshelve> canton7: is there an api for good dictionary? I am trying to write a gem for dictionary
<t0rc> I've got a few functions, such as searching/locating files, that are shared throughout my program so I've placed them in a module. Is there any common naming scheme to follow with things like this? i.e. like calling it "FileActions" or something?
<t0rc> (the module that is)
lggr has quit [Ping timeout: 244 seconds]
<canton7> vectorshelve, it *is* more complex than net/http. That's not to say it's harder to use, just that it does mroe
<canton7> quazimodo, (1..5).to_a
<vectorshelve> canton7: ok
alex__ has left #ruby ["Leaving"]
lggr has joined #ruby
rakunHo has quit [Remote host closed the connection]
<quazimodo> canton7: ah
postmodern has quit [Quit: Leaving]
vectorshelve has quit [Quit: Page closed]
emmanuelux has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
prtksxna has quit [Remote host closed the connection]
lggr has joined #ruby
icole has joined #ruby
iamjarvo has joined #ruby
conor_ireland has joined #ruby
icole has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 255 seconds]
margle has quit [Quit: Computer has gone to sleep.]
maxok has quit [Quit: Linkinus - http://linkinus.com]
AndChat| has quit [Ping timeout: 260 seconds]
nari has joined #ruby
BMF has quit [Remote host closed the connection]
lggr has joined #ruby
<_bart> so I have an array with consonants: ["B", "C", "D", "F", "G", "H", "J", "K", "L", "M", "N", "P", "Q", "R", "S", "T", "V", "W", "X"]
dfmoser has quit [Quit: dfmoser]
<_bart> how do I check a string, for examples 'apple', how many % it consists of consonants?
bobcat has joined #ruby
bobcat is now known as Guest43453
Guest43453 is now known as _bobcat_
_bobcat_ has quit [Client Quit]
Takehiro has quit [Remote host closed the connection]
<canton7> _bart, "abcde".count("abcfgh") => 3
<canton7> look at String#count
<_bart> cool!
<_bart> thanks
lggr has quit [Ping timeout: 245 seconds]
Zai_ has joined #ruby
wrist has joined #ruby
slainer68 has quit [Remote host closed the connection]
lggr has joined #ruby
Takehiro has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
ryanlecompte has joined #ruby
emmanuelux has quit [Quit: emmanuelux]
lggr has joined #ruby
JonnieCa1he has quit [Ping timeout: 246 seconds]
wrist_ has joined #ruby
wrist has quit [Read error: Connection reset by peer]
und3f has quit [Ping timeout: 255 seconds]
wrist_ has quit [Read error: Connection reset by peer]
wrist has joined #ruby
Jork1 has quit [Quit: Jork1]
wrist has quit [Remote host closed the connection]
wez has joined #ruby
ph^ has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 246 seconds]
ph^ has joined #ruby
<shevy> LONG LIVE RUBY
<shevy> cool
lggr has joined #ruby
Jork1 has joined #ruby
<shevy> did not know about .count able to do that
<shevy> once again canton7 shows that he knows a lot more than I do
<shevy> hmm
<shevy> #python-unregistered has 640 folks
dfmoser has joined #ruby
<canton7> heh, I have the magic of ruby-doc and ctrl-f
<canton7> I was expecting to have to do something along the lines of string.each_char.count{ |c| the_array.include?(c) } ...
colinbm has joined #ruby
ph^ has quit [Remote host closed the connection]
emmanuelux has joined #ruby
jrajav has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
wez has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
axl_ has quit [Quit: axl_]
colinbm has quit [Quit: colinbm]
lggr has joined #ruby
<shevy> hmm
<shevy> yeah
<shevy> I would have done something like that too haha
<shevy> but now I know, thanks to you, .count can do so on its own
<shevy> canton7, you are better than any documentation :)
* shevy clicks on canton7
iamjarvo has quit [Ping timeout: 246 seconds]
anandhegde has quit [Ping timeout: 260 seconds]
und3f has joined #ruby
irleif has joined #ruby
<canton7> heh,only when i'm around :P
dnstbr has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
lggr has joined #ruby
daniel_- has joined #ruby
abstrusenick has joined #ruby
iamjarvo has joined #ruby
<_bart> :)
lggr has quit [Ping timeout: 248 seconds]
AlbireoX has joined #ruby
Mon_Ouie has quit [Ping timeout: 260 seconds]
roadt has quit [Read error: Connection reset by peer]
<_bart> I know \w+ would select 'sdd75s', but how do I specify that I only want to select it if it contains at least 1 number?
Zai_ has quit [Quit: Zai_]
<canton7> \w*[0-9]\w*
lggr has joined #ruby
<canton7> or, indeed, \w*\d\w*
ledao1 has joined #ruby
<_bart> that's very cool, thanks!
ledao has quit [Ping timeout: 260 seconds]
RJ3000_ has quit [Remote host closed the connection]
<_bart> canton7: how do I extend that and specify it should also contain at least 1 \w character?
<_bart> ehh
<_bart> [a-zA-Z] character
CaptainJet has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
nm7 has joined #ruby
<_bart> (\w*[a-z]\d\w*)
<_bart> but that wouldn't work for 125214a
piotr_ has joined #ruby
piotr__ has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
bigmeow has quit [Ping timeout: 244 seconds]
<_bart> http://rubular.com/r/PpTnlxcvFL why am I unable to use { } on the group? :/
joofsh has quit [Ping timeout: 256 seconds]
bigmeow has joined #ruby
ledao1 has quit [Quit: Leaving.]
<canton7> _bart, that's working as expected
<sepp2k> _bart: What do you mean you're unable?
<canton7> wait, no
<canton7> if you replace the {3,} with, say, {10} it fails
sonnym has joined #ruby
ledao has joined #ruby
<_bart> No, when I do (\w*\d\w*) it selects everything correctly:: http://rubular.com/r/tVHCG6HkoM
lggr has quit [Ping timeout: 246 seconds]
awestroke has quit [Remote host closed the connection]
<_bart> but when I add a {6,} to filter out the shortest one, I only see one group matched and it's doing weird things?
<canton7> the {} syntax isn't saying "find 3 or more matches"
<sepp2k> _bart: If you add {6,} I'd expect there to be no matches.
<canton7> e.g. /a{3}/ will match "aaa" but not "aa"
<jrajav> (\w*([a-z]\w*\d|\d\w*[a-z)\w*)
<quazimodo> ruby XD
<jrajav> Replace with [a-zA-Z] if desired
<jrajav> Let simmer
<jrajav> Enjoy
<jrajav> Oops, missed a ]
anandhegde has joined #ruby
anandhegde has quit [Client Quit]
<_bart> jrajav: :)
lggr has joined #ruby
anandhegde has joined #ruby
<jrajav> You might also be able to work some black magic with + (one or more) instead of *
<jrajav> But I think this way is clearer
glyytchy has joined #ruby
abstrusenick has quit [Quit: abstrusenick]
awarner has joined #ruby
_marvin_ has quit [Read error: Connection reset by peer]
fcoury has quit [Remote host closed the connection]
relix has quit [Read error: Connection reset by peer]
dekz has quit [Remote host closed the connection]
dotemacs has quit [Remote host closed the connection]
SeanTAllen has quit [Remote host closed the connection]
NimeshNeema has quit [Remote host closed the connection]
rcsheets has quit [Remote host closed the connection]
anildigital_work has quit [Remote host closed the connection]
notbrent has quit [Remote host closed the connection]
_marvin_ has joined #ruby
dekz has joined #ruby
prtksxna has joined #ruby
glyytchy has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 260 seconds]
Agis__ has joined #ruby
piotr__ has joined #ruby
lggr has joined #ruby
piotr_ has quit [Ping timeout: 260 seconds]
NimeshNeema has joined #ruby
<t0rc> Good way to serialize/deserialize objects to and from JSON?
sonnym has quit [Read error: Connection timed out]
anandhegde has quit [Quit: Linkinus - http://linkinus.com]
rcsheets has joined #ruby
<shevy> by praying to the gods!
<shevy> I usually use yaml
<canton7> t0rc, require 'json'
<canton7> t0rc, JSON.parse(stuff); stuff.to_json
tommylommykins is now known as jvkTommy
<shevy> doesn't json have some way to deserliaze and load from a file, like yaml has?
sonnym has joined #ruby
<jrajav> shevy: That seems superfluous, reading from a file belongs in modules for reading from a file
<jrajav> Modular code, DRY, blah blah
lggr has quit [Ping timeout: 260 seconds]
<canton7> both the json and yaml libs can load from an io-like object iirc
<shevy> I really dont know, I only use yaml so far :)
<shevy> anything except XML really
wallerdev has joined #ruby
relix has joined #ruby
dotemacs has joined #ruby
SeanTAllen has joined #ruby
lggr has joined #ruby
iamjarvo has quit [Ping timeout: 245 seconds]
mahmoudimus has joined #ruby
hakunin has joined #ruby
ZubKonst has quit [Read error: Connection reset by peer]
<t0rc> canton7: right so that gets me reading in JSON and sending that hash back to JSON but I mean more converting objects to JSON, etc. I think to_json method or is that outdated? and just use the JSON, and go to and from the hashmap?
<canton7> t0rc, hrm?
<canton7> the the JSON module defines #to_json
ZubKonst has joined #ruby
<t0rc> canton7: right. I keep finding references to stuff like this though: http://www.skorks.com/2010/04/serializing-and-deserializing-objects-with-ruby/
Criztian has joined #ruby
<canton7> what's your point? I'm confused...
lggr has quit [Ping timeout: 260 seconds]
bradyl0ve has joined #ruby
Z0idberg has quit [Read error: Connection reset by peer]
anildigital_work has joined #ruby
<bnagy> json sucks balls
fcoury has joined #ruby
<canton7> it has its place
lggr has joined #ruby
<bnagy> true, if I'm looking for a really slow format that doesn't handle binary data and is worse in every measurable way than yaml and Marshal
<bnagy> json every time
zigomir has joined #ruby
<t0rc> !war
glyytchy has joined #ruby
<canton7> don't mock. json's a subset of yaml
<canton7> the more compact subset, in fact
<canton7> so if you want to use yaml, but want to send it over a socket and don't want all that whitespace
<canton7> json!
<shaman42> seems to me that json is THE markup for api's
<bnagy> :|
<bnagy> msgpack
<shaman42> <- iOS dev who has to parse json responses about every fking day.
<t0rc> canton7: to turn my custom class into a valid JSON string, what must I do? that's my question. I can read in using JSON.parse, to get a Hash. Should I modify that hash inside my object, and just run to_json on that object again? or should I instead create a method that explicitly generates something else? Seems modifying the hash may provide more problems with more complex members.
dnstbr has quit [Quit: Computer has gone to sleep.]
ScottNYC has joined #ruby
<canton7> t0rc, ah I see. if the default #to_json doesn't do want you want, just define your own for your class
<canton7> in terms of deserializing, not sure
<ScottNYC> whats best practice, installing ruby and gems system wide, or installing as user, or installing ruby system wide and gems as user?
r1ddl3r has joined #ruby
thunderstrike has joined #ruby
verbad has joined #ruby
<bnagy> imho always install everything as a user
<t0rc> That has to depend on setup ScottNYC. I would prefer user.
<canton7> bnagy, msgpack looks interesting. is it ruby-only?
<ScottNYC> no
ryanlecompte has quit [Remote host closed the connection]
<canton7> ah no, I see
lggr has quit [Ping timeout: 256 seconds]
<ScottNYC> ruby gems everything
<bnagy> canton7: no they have stuff for quite a few langs
<canton7> sweet, looks nice. does take away from the human-readable element though
verbad has quit [Client Quit]
<bnagy> yeah, it's not for that
Markvilla has joined #ruby
<bnagy> I use yaml for that stuff :/
ScottNYC has quit [Remote host closed the connection]
Jork1 has quit [Quit: Jork1]
piotr_ has joined #ruby
lggr has joined #ruby
piotr__ has quit [Ping timeout: 246 seconds]
cantonic_ has joined #ruby
Jork1 has joined #ruby
nm7 has quit [Quit: ZNC - http://znc.sourceforge.net]
Oprr has quit [Read error: Operation timed out]
nm7 has joined #ruby
cantonic has quit [Ping timeout: 240 seconds]
cantonic_ is now known as cantonic
lggr has quit [Ping timeout: 246 seconds]
notbrent has joined #ruby
Meon has joined #ruby
lggr has joined #ruby
nm7 has quit [Quit: ZNC - http://znc.sourceforge.net]
nm7 has joined #ruby
<_bart> How do I turn a 0.0 - 1.0 scale to a 1.0 - 0.0 - 1.0 scale (the old 0.5 being the new 0.5)
<_bart> # 0.0 => 1.0
<_bart> # 0.5 => 0.0
<_bart> # 1.0 => 1.0
<canton7> I'm lost. Mind re-phrasing that?
chimkan_ has joined #ruby
Oprr has joined #ruby
<canton7> something like (x-0.5).abs*2 ?
<tos9> Also, (x % 0.5) * 2
<t0rc> yup. Shift and then scale
<_bart> cool!
<_bart> thanks
<canton7> tos9, that doesn't turn 0 into 1 ?
lggr has quit [Ping timeout: 246 seconds]
iamjarvo has joined #ruby
<tos9> Oh, indeed it doesn't, never mind, didn't read carefully.
workmad3 has joined #ruby
SegFault1X is now known as SegFaultAX
joofsh has joined #ruby
<_bart> (x-0.5).abs*2 is the thing
irleif has quit [Quit: Computer has gone to sleep.]
lggr has joined #ruby
<_bart> it uses the fraction of consonants and numbers and non-consonants to determine wether the string is a real word or not
<_bart> :)
Rydefalk_ has joined #ruby
Rydefalk has quit [Read error: Connection reset by peer]
<bnagy> ..
<canton7> considered using digraphs?
<_bart> matching with /usr/share/dict/words on the file system would be cool but that's quite a file
<bnagy> Syzygy
Bosox20051 has joined #ruby
glyytchy has quit [Quit: Leaving...]
atmosx has joined #ruby
<_bart> ?
<bnagy> it's a word
fridim_ has joined #ruby
frogprince_mac has quit [Ping timeout: 256 seconds]
glyytchy has joined #ruby
<canton7> is that the one that's a cheat in minesweeper?
lggr has quit [Ping timeout: 252 seconds]
<canton7> ah no
<canton7> that's xyzzy :P
<bnagy> xyzzy is like ancient
<bnagy> it's the magic word from advent
<bnagy> like 70s text adventure
Takehiro has quit [Remote host closed the connection]
<bnagy> also like rhythym, but I like syzygy better
<bnagy> ok bedtime
lggr has joined #ruby
nohonor has quit [Quit: Leaving]
take_cheeze has joined #ruby
dmiller has joined #ruby
havenn has joined #ruby
alanp_ has joined #ruby
AMfish has joined #ruby
alanp has quit [Read error: Connection reset by peer]
shevy has quit [Ping timeout: 244 seconds]
busybox42 has quit [Quit: Leaving.]
busybox42 has joined #ruby
Takehiro has joined #ruby
sashman has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
JonnieCache has joined #ruby
lggr has joined #ruby
F1skr has joined #ruby
iamjarvo has quit [Ping timeout: 245 seconds]
ananthakumaran has quit [Quit: Leaving.]
AMfish has quit []
Virunga has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 246 seconds]
ShiintoRyuu has joined #ruby
wpaulson has joined #ruby
Neomex has joined #ruby
shevy has joined #ruby
JonnieCache has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
Bosma has joined #ruby
awestroke has joined #ruby
jrist has quit [Ping timeout: 260 seconds]
r1ddl3r has quit [Ping timeout: 246 seconds]
Morkel has joined #ruby
chimay has quit [Quit: WeeChat 0.4.0-dev]
codefyre has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
no_worries has joined #ruby
Solnse has joined #ruby
lggr has joined #ruby
thunderstrike has quit [Ping timeout: 255 seconds]
Solnse2 has joined #ruby
iamjarvo has joined #ruby
mikeycgto has quit [Ping timeout: 246 seconds]
r1ddl3r has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
zii has quit [Read error: Connection reset by peer]
Solnse has quit [Ping timeout: 245 seconds]
zii has joined #ruby
zii has quit [Changing host]
zii has joined #ruby
Virunga has joined #ruby
workmad3 has quit [Ping timeout: 240 seconds]
lggr has joined #ruby
CodeFriar has quit [Quit: Leaving...]
CodeFriar has joined #ruby
tk___ has quit [Quit: ばいばい]
khakimov has joined #ruby
Orcris has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
awestroke has quit [Remote host closed the connection]
r1ddl3r has quit [Quit: Leaving.]
cakehero has quit [Quit: Computer has gone to sleep.]
lggr has joined #ruby
irleif has joined #ruby
no_worries has quit [Remote host closed the connection]
hadees has quit [Quit: hadees]
mikepack has joined #ruby
tos9 has quit [Ping timeout: 246 seconds]
havenn has quit [Remote host closed the connection]
mikeycgto has joined #ruby
mikeycgto has quit [Changing host]
mikeycgto has joined #ruby
codefyre has quit [Quit: Leaving]
lggr has quit [Ping timeout: 256 seconds]
relix has quit [Quit: Connection closed for inactivity]
ananthakumaran has joined #ruby
WrErase has joined #ruby
mucker has quit [Quit: leaving]
S1kx has joined #ruby
S1kx has quit [Changing host]
S1kx has joined #ruby
Solnse2 has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
tos9 has joined #ruby
Solnse has joined #ruby
zenformatics1 has joined #ruby
glyytchy has quit [Quit: Leaving...]
joeycarmello has joined #ruby
daniel_- has quit [Ping timeout: 260 seconds]
stephenjudkins has joined #ruby
tos9 has quit [Ping timeout: 240 seconds]
FlowState has quit [Quit: Ex-Chat]
Xeago has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
zodiak has quit [Read error: Connection reset by peer]
tos9 has joined #ruby
wpaulson has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
Mon_Ouie has joined #ruby
lggr has joined #ruby
ananthakumaran has quit [Quit: Leaving.]
savant has joined #ruby
r1ddl3r has joined #ruby
SegFaultAX|work has joined #ruby
deadalus has quit [Ping timeout: 246 seconds]
fantazo has joined #ruby
joeycarmello has quit [Remote host closed the connection]
awestroke has joined #ruby
jbw has quit [Ping timeout: 240 seconds]
SegFaultAX|work has quit [Quit: Lost terminal]
wedtm|away is now known as wedtm
hadees has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
chimkan__ has joined #ruby
chimkan__ has quit [Remote host closed the connection]
chimkan__ has joined #ruby
CodeFriar has quit [Quit: Leaving...]
r1ddl3r has quit [Ping timeout: 245 seconds]
r1ddl3r has joined #ruby
chimkan_ has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
jbw has joined #ruby
_seme has joined #ruby
dangerousdave has joined #ruby
Solnse has quit [Ping timeout: 240 seconds]
ChampS666 has quit [Ping timeout: 244 seconds]
WrErase has quit [Quit: Leaving]
lggr has quit [Ping timeout: 244 seconds]
jgrevich has joined #ruby
kain has quit [Ping timeout: 246 seconds]
SegFaultAX|work has joined #ruby
moshee has quit [Ping timeout: 256 seconds]
lggr has joined #ruby
moshee has joined #ruby
moshee has joined #ruby
moshee has quit [Changing host]
piotr__ has joined #ruby
piotr_ has quit [Ping timeout: 246 seconds]
sonnym has quit [Quit: Leaving.]
sonnym has joined #ruby
slainer68 has joined #ruby
<xuser> is 'price' in line 11 a method? http://sprunge.us/QcVD?ruby
Markvilla has quit [Quit: Computer has gone to sleep.]
jgrevich_ has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
<atmosx> xuser: price in line 11 should be an integer.
jgrevich has quit [Ping timeout: 240 seconds]
jgrevich_ is now known as jgrevich
<atmosx> it's not defined though, so if that's the code, it comes out with an undefined variable
hadees has quit [Quit: hadees]
<xuser> atmosx: if I do, book = BookInStocknew('ISBN', 7.5)
Oprr has quit [Ping timeout: 246 seconds]
<canton7> you probably want @price
Neomex has quit [Quit: Neomex]
lggr has joined #ruby
<xuser> and then puts "Price = #{book.price_in_cents}" it works
<atmosx> xuser: you want @price = price.to_f
<atmosx> and then use @price not price.
<xuser> like this: http://sprunge.us/EEPD?ruby
<xuser> atmosx: why does my code works?
<atmosx> xuser: doesnt.
<atmosx> xuser: your code doesn't work. I tried it. It comes out with 2 errors.
grizlo42 has joined #ruby
<xuser> atmosx: you tried my last paste?
<xuser> weird it works for me
<canton7> xuser, it's good practice generally to use @price not price there
<atmosx> at line 11, ruby doesn't know what 'price' is. That's why you setup @price = price, in order to use @price all over your scope which is your class in this example.
<canton7> atmosx, see line 3
<canton7> the method 'price' is defined
<atmosx> then price is a string, if you don't convert it to an integer or float (float is more suitable in your case) ruby doesn't know how to add a string to an integer. Stupid ruby!
ph^ has joined #ruby
<canton7> atmosx, why is it a string?
<xuser> canton7: so 'price' in line 11 is a method right?
<canton7> looks like a float for me
<canton7> xuser, correct
lggr has quit [Ping timeout: 256 seconds]
<canton7> xuser, and it's the method generated by your 'attr_accessor' on line 3
<xuser> canton7: that was my doubt, thanks, I'll take your advice of using @price instead of price there
quest88 has joined #ruby
jamjam has quit [Ping timeout: 245 seconds]
ph^ has quit [Remote host closed the connection]
<atmosx> canton7: hmm didn't work for me, I had to do the changes I mentioned to make it work. However, you're right. attr_accessor is defined and I used quotes '' which make the number a string :-P
iamjarvo has quit [Ping timeout: 245 seconds]
BMF has joined #ruby
lggr has joined #ruby
<xuser> atmosx: well yes, I actually had @price = Float(price) there :)
<xuser> in the initialize method
jamjam has joined #ruby
<atmosx> xuser: then you're all set I guess.
zodiak has joined #ruby
tommyvyo has joined #ruby
kain has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
irleif has quit [Quit: Computer has gone to sleep.]
lggr has joined #ruby
fridim_ has quit [Ping timeout: 260 seconds]
prtksxna has quit [Remote host closed the connection]
cascalheira has joined #ruby
Matoch has joined #ruby
cascalheira has quit [Client Quit]
joeycarmello has joined #ruby
hadees has joined #ruby
Takehiro has quit [Remote host closed the connection]
<t0rc> can someone explain what is going on with these string comparisons? http://codepad.org/EKj5ZAUG
kiyoura has joined #ruby
<t0rc> #inspect shows them to be equivalent as well
Matoch has quit [Remote host closed the connection]
Eplemosen has quit [Quit: NOPE]
kain has quit [Ping timeout: 260 seconds]
Matoch has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
iamjarvo has joined #ruby
piotr__ has quit [Read error: Connection reset by peer]
<t0rc> nevermind. I'm a moron.
lggr has joined #ruby
<t0rc> mmm actually I take that back.
Neomex has joined #ruby
<zipkid> ol
<zipkid> lol too
<t0rc> I'm trying to use Hash#has_key?
<t0rc> and it's failing yet the strings are content-equal
joofsh has quit [Quit: Leaving]
margle has joined #ruby
piotr_ has joined #ruby
aharris_ has joined #ruby
<t0rc> yep nevermind agian. I'm a moron.
<zipkid> i agree... :-D
<zipkid> not that i followed...
khakimov has quit [Quit: Computer has gone to sleep.]
iamjarvo has quit [Ping timeout: 245 seconds]
mensvaga has joined #ruby
<t0rc> lolol
<t0rc> longs story short: the strings weren't content equal.
<t0rc> was adding whitespace at the end
<t0rc> -s
Russell^^ has joined #ruby
lggr has quit [Ping timeout: 252 seconds]
<mensvaga> I'm doing some HTML form processing, and the variables in a form get passed in to my script in a variable called @param
<mensvaga> err, param
<mensvaga> param[:ip_address], for instance.
artm has joined #ruby
Iszak has joined #ruby
Iszak has quit [Changing host]
Iszak has joined #ruby
<mensvaga> If I have an array ['ip_address','mac_address','hostname'] , how do I convert that so I can refer to the symbols in the param object?
<mensvaga> param[:mac_address], param[:hostname], etc.
cburyta has joined #ruby
<mensvaga> I have an associative array which also contians data with those key names, but they're not in "symbol form"
Jork1 has quit [Quit: Jork1]
lggr has joined #ruby
unsymbol has joined #ruby
unsymbol has left #ruby [#ruby]
ph^ has joined #ruby
<t0rc> mensvaga: param[0].to_sym
irleif has joined #ruby
Nisstyre-laptop has joined #ruby
<mensvaga> OK. I'll try to_sym.
<mensvaga> Thanks.
<aharris_> mensvaga: if you want to covert all of them, try -> params.map! { |p| p.to_sym } (http://www.ruby-doc.org/core-1.9.3/Array.html#method-i-map-21)
<burgestrand> mensvaga: careful converting things to_sym willy-nilly. Symbols are not garbage collected, so if you have no control of what things may be converted your application will eventually eat up all your RAM.
<aharris_> @param.map, sorry. just noticed you had it in an instance variable.
davidcelis has quit [Quit: K-Lined.]
<burgestrand> mensvaga: as far as parameters from web requests goes they are usually passed as strings for this very reason.
Jork1 has joined #ruby
<mensvaga> burgestrand: I'm using sinatra, and the usage example shows param[:some_variable]
<burgestrand> mensvaga: both sinatra and rails allow access to the request parameters with both symbols and string
<burgestrand> mensvaga: internally, they are both converted to strings
jrajav has quit []
lggr has quit [Ping timeout: 252 seconds]
<mensvaga> Ah, I haven't exactly run the part of the program that grabs the parameters; I was writing it and then saw the symbol thing.
cburyta has quit [Ping timeout: 246 seconds]
<mensvaga> If I can refer to it by just a regular string key, that's moar awesome.
<mensvaga> Symbols in ruby are over used and mostly misunderstood.
<Xeago> 'they look so pretty'
<Xeago> is what my colleagues say
<burgestrand> They’re gold in my editor.
<burgestrand> I mean, come on. Gold.
<savant> persinally I like pokemon silver
<savant> but to each his own
<mensvaga> I haven't been coding ruby for long, but when a "seasoned" ruby programmer explained symbols to me, I said, "an immutable, non-garbage collected hash table of strings designed to cut down on memory usage?"
<mensvaga> him, "Huh?"
<mensvaga> err, immutable strings
ph^ has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
<mensvaga> lunacy for beginners. Complete lunacy.
irleif has quit [Quit: Computer has gone to sleep.]
<shevy> well
<shevy> mensvaga, keep in mind the most important thing about symbols
<shevy> they are BORING
Agis__ has quit [Quit: Agis__]
<shevy> so if one uses fancy words to describe them
<shevy> they still remain a boring thing to have
futilegames has quit [Quit: futilegames]
<shevy> newcomers are so excited "whoa COOL A SYMBOL MAN... how could I have lived without it for all my life!"
jimeh2 has joined #ruby
irleif has joined #ruby
<mensvaga> They're terrible.
BMF has quit [Remote host closed the connection]
kain has joined #ruby
lggr has quit [Ping timeout: 264 seconds]
jimeh2 has quit [Ping timeout: 244 seconds]
bbttxu has joined #ruby
Takehiro has joined #ruby
jamjam has quit [Ping timeout: 246 seconds]
<Xeago> I guess the following meaning when I first started ruby: symbols are used as identifications of values
lggr has joined #ruby
<atmosx> Whoah! a SYMBOL! How could i have lived without using a symbol all my life!!!
<atmosx> I don't use symbols actually, at all..
<atmosx> but anyway
sepp2k has quit [Remote host closed the connection]
<Xeago> which is imo, the easiest explanation, wil it is incomplete it is completely correct
<Xeago> s/wil/while*
daniel_- has joined #ruby
hmans has joined #ruby
awarner has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
JonnieCache has joined #ruby
rabidpraxis has joined #ruby
erichmenge has joined #ruby
_md has joined #ruby
erichmenge has quit [Client Quit]
kain has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 255 seconds]
hadees has quit [Quit: hadees]
davidcelis has joined #ruby
Takehiro has quit [Remote host closed the connection]
lggr has joined #ruby
mikepack has quit [Remote host closed the connection]
Mon_Ouie has quit [Ping timeout: 246 seconds]
Mon_Ouie has joined #ruby
workmad3 has joined #ruby
bradyl0ve has quit [Quit: Leaving...]
CodeFriar has joined #ruby
hmans has quit [Quit: Linkinus - http://linkinus.com]
lggr has quit [Ping timeout: 240 seconds]
ryanlecompte has joined #ruby
savant has left #ruby [#ruby]
ph^ has joined #ruby
<RubyPanther> I think it is a very valuable thing to have code identifiers that are clearly different than the data, it aids separation
davidcelis has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
conor_ireland has quit [Quit: conor_ireland]
<RubyPanther> And in C you get your identifiers as some type of integer with a fixed size, so it is also very practical and you don't have to worry about using short identifiers
davidcelis has joined #ruby
iamjarvo has joined #ruby
cascalheira has joined #ruby
ph^ has quit [Ping timeout: 256 seconds]
jamjam has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
reset has joined #ruby
Matoch has quit [Quit: Matoch]
t0rc has quit [Ping timeout: 244 seconds]
zii has quit [Read error: Connection reset by peer]
zii has joined #ruby
Takehiro has joined #ruby
mengu has quit [Quit: Konversation terminated!]
hadees has joined #ruby
lggr has joined #ruby
kain has joined #ruby
tommyvyo has quit [Quit: Computer has gone to sleep.]
vlad_starkov has quit [Remote host closed the connection]
<booyakah> Anyone know a gem for Minecraft?
<booyakah> nvm found one :P
chimkan__ has quit [Quit: chimkan__]
haxrbyte has joined #ruby
<shevy> atmosx they have two nice advantages though
<shevy> one, they are more efficient in a hash
<shevy> two, if you get a string back from an object, you can modify it. but if you get a symbol back, you can't quite sensibly modify it, so it leaks out less from the object
<shevy> not that I actually ever return a symbol from any of my methods hmmmmmmmm
* shevy scratches his head.
rippa has quit [Ping timeout: 245 seconds]
lggr has quit [Ping timeout: 260 seconds]
<workmad3> shevy: you could return a frozen clone of the data
nlpplz has joined #ruby
morozovm has quit [Quit: morozovm]
<shevy> poor clone... I'd rather have a warm clone than a frozen one :(
<shevy> sorry workmad3 I am out of beer, and it makes me... funny in awkward ways :P
<workmad3> :)
joeycarmello has quit [Remote host closed the connection]
lggr has joined #ruby
apeiros_ has joined #ruby
und3f has quit [Quit: Leaving.]
wedtm is now known as wedtm|away
awestroke has quit [Remote host closed the connection]
dmiller has quit [Ping timeout: 246 seconds]
t0rc has joined #ruby
apeiros_ has quit [Remote host closed the connection]
cburyta has joined #ruby
Zai_ has joined #ruby
<_bart> '2010-blabla-20-10', I know I can match this using (\d{4}-blabla-\d{2}-\d{2}) but is it possible to remove the 'blabla' from the result? I tried to wrap it in (?:..) but that didn't work
lggr has quit [Ping timeout: 255 seconds]
Iszak has quit [Quit: Computer has gone to sleep.]
<_bart> I thought (\d{4}-(?:blabla)-\d{2}-\d{2}) would remove blabla from the captured match.
bluenemo has quit [Remote host closed the connection]
Neomex has quit [Quit: Neomex]
Nisstyre-laptop has quit [Read error: Connection reset by peer]
robustus has quit [Quit: ZNC - http://znc.in]
Zai_ has left #ruby [#ruby]
rabidpraxis has quit [Remote host closed the connection]
murz has joined #ruby
lggr has joined #ruby
CodeFriar has quit [Quit: Leaving...]
cburyta has quit [Ping timeout: 246 seconds]
haxrbyte has quit [Ping timeout: 256 seconds]
Takehiro has quit [Remote host closed the connection]
Iszak has joined #ruby
Iszak has quit [Changing host]
Iszak has joined #ruby
Iszak has quit [Client Quit]
haxrbyte has joined #ruby
ph^ has joined #ruby
dmiller has joined #ruby
margle has quit [Quit: Computer has gone to sleep.]
no_worries has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
heftig has quit [Quit: leaving]
heftig has joined #ruby
mikepack has joined #ruby
lggr has joined #ruby
haxrbyte has quit [Ping timeout: 245 seconds]
icole has joined #ruby
margle has joined #ruby
ph^ has quit [Ping timeout: 260 seconds]
LouisGB has joined #ruby
eldariof has quit []
lggr has quit [Ping timeout: 264 seconds]
parzorep has quit [Quit: parzorep]
jimeh2 has joined #ruby
lggr has joined #ruby
margle has quit [Quit: Computer has gone to sleep.]
reset has quit [Quit: Leaving...]
jbw has quit [Ping timeout: 246 seconds]
margle has joined #ruby
iamjarvo has quit [Ping timeout: 260 seconds]
joeycarmello has joined #ruby
hgf has joined #ruby
Morkel has quit [Quit: Morkel]
r1ddl3r has quit [Ping timeout: 245 seconds]
timonv has quit [Remote host closed the connection]
Mon_Ouie has quit [Read error: Connection reset by peer]
jimeh2 has quit [Ping timeout: 264 seconds]
daslicious has joined #ruby
mikeycgto has quit [Ping timeout: 260 seconds]
Mon_Ouie has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
bladder has joined #ruby
joeycarm_ has joined #ruby
joeycarmello has quit [Read error: Connection reset by peer]
lggr has joined #ruby
hadees has quit [Quit: hadees]
answer_42 has quit [Quit: WeeChat 0.3.9]
SegFaultAX|work has quit [Ping timeout: 248 seconds]
goraxe has joined #ruby
joeycarm_ has quit [Ping timeout: 260 seconds]
Virunga has quit [Remote host closed the connection]
AlbireoX has quit [Remote host closed the connection]
nilg has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
<burgestrand> _bart: it doesn’t, it just forms a capturing group without capturing the group
s0ber_ has joined #ruby
<burgestrand> _bart: I would suggest you use two groups (one for the part before blabla, one for the part after), and concatenate them to retrieve your final result
bradyl0ve has joined #ruby
ph^ has joined #ruby
lggr has joined #ruby
s0ber has quit [Ping timeout: 260 seconds]
s0ber_ is now known as s0ber
Nisstyre-laptop has joined #ruby
nilg has quit [Remote host closed the connection]
nilg has joined #ruby
atmosx has quit [Quit: WeeChat 0.3.8]
monkegjinni has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 240 seconds]
SegFaultAX|work has joined #ruby
bladder has quit [Quit: Page closed]
CodeFriar has joined #ruby
hadees has joined #ruby
nilg has quit [Remote host closed the connection]
baphled has joined #ruby
TheFuzzball has quit [Ping timeout: 240 seconds]
lggr has joined #ruby
TheFuzzball has joined #ruby
TTilus has quit [Ping timeout: 246 seconds]
Markvilla has joined #ruby
TTilus has joined #ruby
eikko has joined #ruby
sent-hil has joined #ruby
jbw has joined #ruby
Agis__ has joined #ruby
clop has quit [Ping timeout: 264 seconds]
justinmcp has joined #ruby
aharris_ has quit [Quit: aharris_]
_seme has quit [Quit: leaving]
lggr has quit [Ping timeout: 256 seconds]
cakehero has joined #ruby
bradyl0ve has quit [Quit: Leaving...]
otters has quit [Ping timeout: 245 seconds]
A124 has quit [Quit: Leaving.]
g-ram has joined #ruby
daslicious has quit [Quit: daslicious]
clop has joined #ruby
otters has joined #ruby
lggr has joined #ruby
hgf_ has joined #ruby
margle has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
ryanlecompte has quit [Remote host closed the connection]
hgf_ has quit [Client Quit]
tommyvyo has joined #ruby
ph^ has quit [Remote host closed the connection]
joeycarmello has joined #ruby
hgf has quit [Ping timeout: 246 seconds]
cburyta has joined #ruby
irleif has quit [Quit: Computer has gone to sleep.]
brianpWins has joined #ruby
irleif has joined #ruby
jimeh2 has joined #ruby
cburyta has quit [Ping timeout: 240 seconds]
lggr has quit [Ping timeout: 246 seconds]
postmodern has joined #ruby
jvkTommy is now known as tommylommykins
lggr has joined #ruby
tommyvyo has quit [Quit: Computer has gone to sleep.]
joeycarmello has quit [Ping timeout: 255 seconds]
tommyvyo has joined #ruby
tommyvyo has quit [Client Quit]
Agis__ has quit [Quit: Agis__]
tommyvyo has joined #ruby
c0rn_ has quit []
wedtm|away is now known as wedtm
cburyta has joined #ruby
lggr has quit [Ping timeout: 244 seconds]
cburyta has quit [Remote host closed the connection]
My_Hearing has joined #ruby
artm has quit [Quit: artm]
justinmcp has quit [Remote host closed the connection]
lggr has joined #ruby
[Neurotic] has joined #ruby
c0rn_ has joined #ruby
Mon_Ouie has quit [Ping timeout: 246 seconds]
irleif has quit [Quit: Computer has gone to sleep.]
lggr has quit [Ping timeout: 240 seconds]
baphled has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
eikko has quit [Ping timeout: 245 seconds]
chrisja has joined #ruby
Markvilla has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
thone_ has joined #ruby
tommyvyo has quit [Quit: Computer has gone to sleep.]
ltsstar has quit [Quit: ltsstar]
lggr has quit [Ping timeout: 245 seconds]
grizlo42 has quit [Quit: Leaving.]
thone has quit [Ping timeout: 240 seconds]
icole has quit [Remote host closed the connection]
lggr has joined #ruby
dangerousdave has quit [Ping timeout: 252 seconds]
noyb has quit [Quit: Lost terminal]
joeycarmello has joined #ruby
Dawne has joined #ruby
zigomir has quit [Quit: Leaving]
fkrauthan has joined #ruby
Jork1 has quit [Quit: Jork1]
c0rn_ has quit []
<fkrauthan> Hey I have a problem. If I do ruby -v it says: ruby 1.9.3p0 (2011-10-30 revision 33570) [x86_64-linux] but if I do a bundle install it says: Your Ruby version is 1.8.7, but your Gemfile specified 1.9.3
Russell^^ has quit [Quit: Russell^^]
alanp has joined #ruby
_Mon_Ouie_ has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
fkrauthan is now known as fkrauthan|off
tommyvyo has joined #ruby
fkrauthan|off is now known as fkrauthan
ddd is now known as deryldoucette
deryldoucette is now known as ddd
bapa has joined #ruby
ShiintoRyuu has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
no_worries has quit [Remote host closed the connection]
dmiller has quit [Remote host closed the connection]
pskosinski has quit [Quit: A few unofficial Red Eclipse 1.3.1 (r4131) servers: http://altred.tk/toggle.rb (and no more global banning for saying that main dev is not very smart, what is truth anyway)]
My_Hearing has quit [Ping timeout: 246 seconds]
t0rc has quit [Quit: WeeChat 0.3.9]
lggr has joined #ruby
alanp_ has quit [Ping timeout: 252 seconds]
cascalheira has quit [Ping timeout: 246 seconds]
skogis has quit [Ping timeout: 246 seconds]
katherinem13 is now known as katherinem13_afk
burgestrand has quit [Read error: Connection reset by peer]
sent-hil has quit [Remote host closed the connection]
burgestrand has joined #ruby
eikko has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
icole has joined #ruby
<RubyPanther> fkrauthan: that could mean something like, you have rvm and you didn't install bundler with rvm's gem but you did install it with the system gem
bradyl0ve has joined #ruby
iblue has joined #ruby
saschagehlich has quit [Quit: saschagehlich]
Forevernade has joined #ruby
Liquid_X has quit [Ping timeout: 256 seconds]
lggr has joined #ruby
justinmcp has joined #ruby
tommyvyo has quit [Quit: Computer has gone to sleep.]
Liquid_X has joined #ruby
<fkrauthan> Hmm I think I have something really wrong on my server
<fkrauthan> :D
<fkrauthan> maybe I should clean up everything
lggr has quit [Ping timeout: 256 seconds]
booyakah has quit [Quit: ZNC - http://znc.sourceforge.net]
booyakah has joined #ruby
eikko has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
grizlo42 has joined #ruby
jamjam has quit [Ping timeout: 240 seconds]
vjt has quit [Ping timeout: 272 seconds]
JonnieCache has quit [Ping timeout: 248 seconds]
thillux has joined #ruby
lggr has quit [Ping timeout: 264 seconds]
hadees has quit [Quit: hadees]
davidcelis has quit [Quit: K-Lined.]
lggr has joined #ruby
c0rn_ has joined #ruby
eikko has joined #ruby
piotr_ has quit [Remote host closed the connection]
otters has quit [Ping timeout: 252 seconds]
undersc0re97 has quit [Read error: Operation timed out]
undersc0re97 has joined #ruby
undersc0re97 has quit [Changing host]
undersc0re97 has joined #ruby
fridim_ has joined #ruby
CodeFriar has quit [Quit: Linkinus - http://linkinus.com]
slainer68 has quit [Ping timeout: 248 seconds]
mengu has joined #ruby
deadalus has joined #ruby
lggr has quit [Ping timeout: 264 seconds]
aharris_ has joined #ruby
eikko has quit [Ping timeout: 246 seconds]
davidcelis has joined #ruby
fkrauthan is now known as fkrauthan|off
fkrauthan|off is now known as fkrauthan
fkrauthan has left #ruby [#ruby]
lggr has joined #ruby
workmad3 has quit [Ping timeout: 246 seconds]
emmanuelux has quit [Quit: emmanuelux]
iblue has left #ruby [#ruby]
notVert has joined #ruby
eikko has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
bluOxigen has quit [Ping timeout: 256 seconds]
ryanlecompte has joined #ruby
thillux has quit [Remote host closed the connection]
Orcris has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
deadalus has quit [Ping timeout: 252 seconds]
shoe has joined #ruby
<shoe> Which Enumerable method does this? [:a, :b, :c, :d].foo([2, 0, 1]) -> [:c, :a, :b]
c0rn_ has quit []
ForevernadeAFK has joined #ruby
tommyvyo has joined #ruby
AlbireoX has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
Forevernade has quit [Ping timeout: 256 seconds]
<heftig> shoe: Array has values_at
<heftig> [:a, :b, :c, :d].values_at(*[2, 0, 1])
josh^ has joined #ruby
sashman has quit [Remote host closed the connection]
lggr has joined #ruby
<shoe> heftig: aha! thanks. I couldn't remember.
sashman has joined #ruby
deadalus has joined #ruby
kirun has quit [Quit: Client exiting]
Synthead has joined #ruby
lggr has quit [Ping timeout: 240 seconds]
bier has quit [Ping timeout: 260 seconds]
hadees has joined #ruby
Foxandxss has joined #ruby
lggr has joined #ruby
emmanuelux has joined #ruby
g-ram has quit [Quit: Computer has gone to sleep.]
wedtm is now known as wedtm|away
icole has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 256 seconds]
gmci has quit [Ping timeout: 246 seconds]
gmci has joined #ruby
mikepack has quit [Remote host closed the connection]
lggr has joined #ruby
icole has joined #ruby
bier has joined #ruby
zodiak has quit [Ping timeout: 246 seconds]
niklasb has quit [Read error: Operation timed out]
A124 has joined #ruby
lggr has quit [Ping timeout: 248 seconds]
Criztian has quit [Remote host closed the connection]
lkba has quit [Ping timeout: 260 seconds]
niklasb has joined #ruby
lggr has joined #ruby
<A124> Anyone knows anything about bindings and extensions? I need to adjust one to read and output strings instead of taking file handles. Anyone to give a hand?
mxweas has joined #ruby
arietis has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
otters has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
F1skr has quit [Quit: WeeChat 0.3.9]
LouisGB has quit [Ping timeout: 246 seconds]
emmanuelux has quit [Quit: emmanuelux]
SegFaultAX|work has quit [Ping timeout: 264 seconds]
lggr has joined #ruby
emmanuelux has joined #ruby
shoe has left #ruby ["ERC Version 5.3 (IRC client for Emacs)"]
wez has joined #ruby
niklasb has quit [Ping timeout: 244 seconds]
kstephens has quit [Read error: Connection reset by peer]
LouisGB has joined #ruby
sashman has quit [Ping timeout: 276 seconds]
lggr has quit [Ping timeout: 240 seconds]
rabidpraxis has joined #ruby
kstephens has joined #ruby
lggr has joined #ruby
Averna has joined #ruby
no_worries has joined #ruby
moted has quit [Ping timeout: 246 seconds]
deadghost has quit [Read error: Connection reset by peer]
wez has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
t0rc has joined #ruby
_md has quit [Quit: Linkinus - http://linkinus.com]
deadghost has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
RudyValencia- has joined #ruby
RudyValencia- has quit [Client Quit]
joeycarmello has quit [Remote host closed the connection]
lggr has joined #ruby
cburyta has joined #ruby
MikeyV27 has quit [Quit: MikeyV27]
Banistergalaxy has joined #ruby
wpaulson has joined #ruby
wpaulson has quit [Client Quit]
jenrzzz has joined #ruby