apeiros_ changed the topic of #ruby to: Ruby 2.1.2; 2.0.0-p481; 1.9.3-p545: http://ruby-lang.org || Paste >3 lines of text on http://gist.github.com || this channel is logged at http://irclog.whitequark.org, other public logging is prohibited
iamcalledrob has quit [Ping timeout: 260 seconds]
Hanmac has joined #ruby
timonv has quit [Ping timeout: 248 seconds]
<bahar> bricker`LA: hunh. that's weird. the count stays at 0 the entire way through. and User.all displays 0 results. but i still get the "email has already been taken" error. WTF: https://gist.github.com/wasafiri/fe3aad82bc0d36e9e8e0
Noob101 has quit [Ping timeout: 246 seconds]
bradhe has quit [Remote host closed the connection]
ta has quit [Read error: Connection reset by peer]
<bricker`LA> bahar: can you gist your new spec_helper
ta has joined #ruby
<bricker`LA> bahar: maybe you found a bug in your email validation :)
aspires has quit []
bradhe has joined #ruby
<bahar> bricker`LA sure but i didn't move the database cleaner stuff in yet
<bahar> let me do that first. sec
<bricker`LA> bahar: oh, lol
<bricker`LA> bahar: this is the dumbest circular logic problem
<bricker`LA> bahar: you're creating a user, and then trying to create a user with the info you just created
<bricker`LA> use FactoryGirl.build(:user)
<bricker`LA> well, at least your learned some debugging techniques :)
<bricker`LA> you*
<bahar> oh, ha
<bahar> blimey
<bahar> yes... i think the debugging techniques alone were very much worth it =D
aspires has joined #ruby
<bahar> error goes away by using build
benlieb has quit [Read error: Connection reset by peer]
dapz has joined #ruby
benlieb has joined #ruby
<bahar> thanks for the help bricker`LA
Hanmac1 has joined #ruby
blackmesa has quit [Ping timeout: 260 seconds]
Noob101 has joined #ruby
<bricker`LA> no problem
lw has quit [Quit: s]
<bricker`LA> oh hey we're in #ruby
<bricker`LA> how did that happen
Zenigor has quit [Remote host closed the connection]
<bahar> i have no idea =D
<bricker`LA> haha
britneywright has joined #ruby
benlieb has quit [Read error: Connection reset by peer]
<bahar> bricker`LA have you ever used something like email_spec before?
<bricker`LA> no, what's it supposed to do?
Prandium has joined #ruby
<Noob101> Hello everyone, I hope you're having a wonderful day.
gnfz has quit [Quit: Leaving]
<bahar> what i'm trying to use it for (and saw it suggested on stackoverflow for such a purpose) is to open a confirmation email that's sent out after a user signs up, and click the confirmation link
dapz has quit [Client Quit]
Hanmac has quit [Ping timeout: 272 seconds]
sandbags has quit [Remote host closed the connection]
<bahar> bricker`LA but i'm not even sure if that's a good spec, or even an useful way to test something like that
<bricker`LA> bahar: I've never tried feature testing a confirmation e-mail to that extent *shrug*
wallerdev has joined #ruby
sandbags has joined #ruby
<bahar> setting aside that i can't seem to get the gem working, is there a more idiomatic way to test that kind of stuff, or is it just unnecessary?
<bricker`LA> bahar: usually I just asset that e-mail body contains the right stuff
<benzrf> Noob101: i try
<bricker`LA> assert*
ddv has quit [Ping timeout: 245 seconds]
<bahar> bricker`LA ok
phoo1234567 has quit [Quit: Leaving]
<Noob101> benzrf: It's ok, we all do. I'll pray for you if I remember to.
ddv has joined #ruby
<bahar> im new to rspec too and i get feedback like, don't test the database, dont test rails, but i'm not yet completely sure what those things mean
lw has joined #ruby
bradhe has quit [Ping timeout: 252 seconds]
xcv has joined #ruby
GriffinHeart has joined #ruby
<bahar> anyone got any advice on that front? :)
sandbags has quit [Ping timeout: 252 seconds]
<bricker`LA> bahar: Just remember that almost every gem, library, piece of software your app is using already has a full suite of passing tests. And the most important thing to test is the API - that your methods and controllers are returning the expected result. Your tests shouldn't care how they do it.
linduxed has quit [Ping timeout: 264 seconds]
xcv_ has joined #ruby
charlied3 has quit [Ping timeout: 264 seconds]
enebo has joined #ruby
yfeldblum has quit [Remote host closed the connection]
yfeldblum has joined #ruby
lolmaus has quit [Ping timeout: 264 seconds]
<pipework> bricker`LA: Well, not all of the gems do, but hopefully so.
<bricker`LA> pipework: yeah I was being optimistic
<bricker`LA> the point is that they *should*
kireevco has joined #ruby
<bahar> bricker`LA how do you TDD then? it's a concept struggle for me
<bricker`LA> and if they don't, your app isn't where they should be
GriffinHeart has quit [Ping timeout: 255 seconds]
<pipework> bahar: Depends, are you BDD'ing or TDD'ing?
CorpusCallosum has joined #ruby
wallerdev has quit [Quit: wallerdev]
<bahar> some of both
<pipework> Write a test from the user's perspective given your definition of user and the interface they'll make use of.
xcv has quit [Ping timeout: 248 seconds]
<bricker`LA> bahar: you write code to make a test pass. I don't like it, personally.
Hanmac1 has quit [Ping timeout: 264 seconds]
<bahar> correct bricker`LA
<bahar> that's how i've been instructed to do it.... it pretty much just slows down development 3x.
<bahar> ha
<pipework> Then when you step in and need to integrate with another library, you should wrap that library into an interface to keep your system isolated from dependencies.
<pipework> bahar: It only slows down those who don't do it well.
zorak has quit [Ping timeout: 248 seconds]
nfk has quit [Quit: yawn]
<pipework> Your wrapper should just assert that the wrapping library calls the library appropriately. That's the API test that will fail if something changes, which is the exact kind of failure you want to be aware of.
<bahar> pipework so the better test is just to make sure your code is using the gem properly?
<pipework> The rest is just behaviour testing that your app gets reasonable things from the wrapper like any other kind of behaviour ducktype test.
lw has quit [Quit: s]
<pipework> bahar: Only if you're going to write a wrapping interface. Otherwise, go with whatever feels best.
Hanmac has joined #ruby
<bahar> Practice makes perfect. this is the first suite of tests i've written (24 so far). The last few apps, I didn't TDD. Now it feels like a slog, but absolutely it will get faster the more I do it.
beak has quit []
oo_ has joined #ruby
dapz has joined #ruby
enebo has quit [Quit: enebo]
yubrew has joined #ruby
lw has joined #ruby
nasj has joined #ruby
linduxed has joined #ruby
gabmorg has joined #ruby
yubrew has quit [Ping timeout: 252 seconds]
<gabmorg> hey ruby
tectonic has quit []
nasj has quit [Ping timeout: 272 seconds]
<gabmorg> jekyll is not finding my installation of rdiscount. any idea why?
sgen has joined #ruby
zz_karupa is now known as karupa
oo_ has quit [Remote host closed the connection]
Jam_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
banjara has joined #ruby
jxf has joined #ruby
CorpusCallosum has quit [Ping timeout: 264 seconds]
Wolland_ has quit [Remote host closed the connection]
linduxed has quit [Ping timeout: 252 seconds]
Wolland has joined #ruby
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
banjara has quit [Client Quit]
linduxed has joined #ruby
yfeldblum has quit [Read error: Connection reset by peer]
yfeldblum has joined #ruby
Wolland has quit [Ping timeout: 248 seconds]
oo_ has joined #ruby
stytown has quit [Quit: stytown]
chipotle has quit [Read error: Connection reset by peer]
lolmaus has joined #ruby
chipotle has joined #ruby
eka has joined #ruby
iamjarvo has joined #ruby
aemeredith has joined #ruby
CodeLicker has quit [Excess Flood]
Dr3amc0d3r|away has quit [Ping timeout: 260 seconds]
xcv_ has quit [Remote host closed the connection]
CodeLicker has joined #ruby
endash has quit [Quit: endash]
mercwithamouth has quit [Ping timeout: 252 seconds]
xcv has joined #ruby
CorpusCallosum has joined #ruby
kies has quit [Ping timeout: 264 seconds]
iamcalledrob has joined #ruby
LexicalScope has quit [Ping timeout: 260 seconds]
Dr3amc0d3r|away has joined #ruby
linduxed has quit [Ping timeout: 272 seconds]
rkazak_ has joined #ruby
linduxed has joined #ruby
kireevco has quit [Quit: Leaving.]
Darkchaos has quit [Ping timeout: 272 seconds]
iamcalledrob has quit [Ping timeout: 272 seconds]
brunops has quit [Ping timeout: 260 seconds]
brunops has joined #ruby
User458764 has joined #ruby
sputnik13 has joined #ruby
<bricker`LA> gabmorg: bad path?
larsam has joined #ruby
linduxed has quit [Ping timeout: 264 seconds]
awkwords has joined #ruby
mercwithamouth has joined #ruby
<mjuszcza1> I have an attribute hash defined like so: http://pastebin.com/QggkRMQS -- I need to somehow pass a list into a template of only users that have "true" set. What's the easiest way to break that down in ruby so that my template simply gets: user1, user3
mgberlin has quit [Remote host closed the connection]
sputnik13 has quit [Client Quit]
<pipework> #select
kies has joined #ruby
LexicalScope has joined #ruby
simoz1111115 has joined #ruby
<bricker`LA> hsh.select
<bricker`LA> oops
<bricker`LA> hsh.select { |_, v| v }
SouL___ has quit [Remote host closed the connection]
badhatter has quit [Remote host closed the connection]
<bricker`LA> mjuszcza1: Also, I don't know how you're populating that hash, but you might find this useful: http://www.ruby-doc.org/stdlib-2.1.2/libdoc/set/rdoc/Set.html
mercwithamouth has quit [Ping timeout: 264 seconds]
icarus has quit [Remote host closed the connection]
mercwithamouth has joined #ruby
zorak has joined #ruby
maximski has joined #ruby
sputnik13 has joined #ruby
tplpnm has joined #ruby
maximski has quit [Client Quit]
SouL___ has joined #ruby
LexicalScope has quit [Ping timeout: 260 seconds]
thesheff17 has joined #ruby
SouL___ has quit [Read error: Connection reset by peer]
gabmorg has quit [Quit: Page closed]
User458764_NotHe has quit [Ping timeout: 272 seconds]
jxf has quit [Ping timeout: 260 seconds]
moritzschaefer has joined #ruby
sputnik13 has quit [Client Quit]
meinside has joined #ruby
ARCADIVS has quit [Quit: WeeChat 0.4.3]
moritzs has quit [Ping timeout: 260 seconds]
mercwithamouth has quit [Ping timeout: 248 seconds]
mercwithamouth has joined #ruby
robustus has quit [Ping timeout: 252 seconds]
yubrew has joined #ruby
robustus has joined #ruby
PanPan has joined #ruby
emergion has joined #ruby
mercwithamouth has quit [Ping timeout: 255 seconds]
yubrew has quit [Ping timeout: 255 seconds]
mercwithamouth has joined #ruby
mrmargolis has joined #ruby
lyuzashi has joined #ruby
nasj has joined #ruby
<mjuszcza1> Thanks bricker!
ghr has joined #ruby
_808chris has joined #ruby
<mjuszcza1> (and others)
kireevco has joined #ruby
<_808chris> anyone down for a code review?
GriffinHeart has joined #ruby
<mjuszcza1> bricker`LA: That selects both the user and true -- how can I just return the user?
<mjuszcza1> IE: it's coming back as "user1 => true" instead of just user1... it did successfully filter out user2, though.
ejnahc has quit [Remote host closed the connection]
nasj has quit [Ping timeout: 264 seconds]
Wolland has joined #ruby
ejnahc has joined #ruby
mgberlin has joined #ruby
ghr has quit [Ping timeout: 272 seconds]
<bricker`LA> mjuszcza1: .keys
<bricker`LA> mjuszcza1: or you could use a set
<mjuszcza1> sweet!
timonv has joined #ruby
JoshGlzBrk has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Wolland has quit [Remote host closed the connection]
Wolland has joined #ruby
timonv has quit [Ping timeout: 255 seconds]
dapz has joined #ruby
aemeredith has quit [Remote host closed the connection]
mercwithamouth has quit [Ping timeout: 272 seconds]
Aryasam has joined #ruby
aemeredith has joined #ruby
Hanmac1 has joined #ruby
Arkaniad|Laptop has quit [Ping timeout: 272 seconds]
Wolland has quit [Ping timeout: 255 seconds]
Hanmac has quit [Ping timeout: 255 seconds]
hamakn has quit [Remote host closed the connection]
mercwithamouth has joined #ruby
casheew has quit [Ping timeout: 260 seconds]
chipotle has quit [Quit: cya]
tus has quit []
aemeredith has quit [Ping timeout: 252 seconds]
casheew has joined #ruby
rkazak_ has quit [Quit: rkazak_]
acconrad has joined #ruby
neiled has joined #ruby
neiled has quit [Max SendQ exceeded]
casheew has quit [Read error: Connection reset by peer]
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
iamcalledrob has joined #ruby
mesamoo has quit [Quit: Konversation terminated!]
Wolland has joined #ruby
neiled has joined #ruby
neiled has quit [Max SendQ exceeded]
chipotle has joined #ruby
britneywright has joined #ruby
tokik has joined #ruby
iswell has quit [Remote host closed the connection]
Lewix has quit [Remote host closed the connection]
casheew has joined #ruby
arya_ has joined #ruby
neiled has joined #ruby
iamcalledrob has quit [Ping timeout: 264 seconds]
Aryasam has quit [Ping timeout: 252 seconds]
nateberkopec has joined #ruby
postmodern has joined #ruby
MatthewsFace has joined #ruby
kireevco has quit [Quit: Leaving.]
Panicky has quit [Ping timeout: 252 seconds]
tplpnm has quit []
wallerdev has joined #ruby
darkxploit has quit [Ping timeout: 264 seconds]
rkazak_ has joined #ruby
freerobby has joined #ruby
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
_fumk has joined #ruby
mercwithamouth has quit [Ping timeout: 248 seconds]
fumk has quit [Ping timeout: 252 seconds]
benzrf is now known as benzrf|offline
oo_ has quit [Remote host closed the connection]
Hanmac1 has quit [Ping timeout: 264 seconds]
_808chris has quit [Ping timeout: 248 seconds]
mercwithamouth has joined #ruby
wallerdev has quit [Quit: wallerdev]
Georg3 has joined #ruby
charliesome has quit [Ping timeout: 260 seconds]
fwaokda has quit [Ping timeout: 255 seconds]
xcv has quit [Remote host closed the connection]
larsam has quit []
oo_ has joined #ruby
benzrf|offline is now known as benzrf
n^izzo has joined #ruby
blackgoat has quit [Quit: reboot]
sevenseacat has joined #ruby
hamakn has joined #ruby
Hanmac has joined #ruby
Georg3 has quit [Ping timeout: 248 seconds]
freerobby has quit [Quit: Leaving.]
iswell has joined #ruby
Lewix has joined #ruby
<n^izzo> when I prit to the terminal I get a "%" at the end, any idea on how to stop that
<n^izzo> e.g. "2 + 2 is: 4%"
<benzrf> n^izzo: how are you printing
<n^izzo> print "2 \+ 2 is: ", 2 + 2
sgen has quit [Quit: Leaving]
<benzrf> i dont think thats how print works
neiled has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<benzrf> maybe im wrong
<benzrf> oh looks like it is
<benzrf> why \+
aemeredith has joined #ruby
<n^izzo> I removed the \ and have the same bug
yubrew has joined #ruby
charliesome has joined #ruby
<n^izzo> benzrf, it prnts so just with some free chars
aemeredith has quit [Read error: Connection reset by peer]
lw has quit [Quit: s]
acconrad has quit [Quit: acconrad]
rkazak_ has quit [Quit: rkazak_]
aemeredi_ has joined #ruby
yubrew has quit [Ping timeout: 248 seconds]
matled has quit [Remote host closed the connection]
krz has joined #ruby
MatthewsFace has quit [Quit: This computer has gone to sleep]
Atttwww has joined #ruby
fwaokda has joined #ruby
jxf has joined #ruby
aemeredi_ has quit [Ping timeout: 264 seconds]
BadQuanta has quit [Remote host closed the connection]
jxf has quit [Ping timeout: 264 seconds]
luckyruby has joined #ruby
sevenseacat has quit [Quit: Leaving.]
mercwithamouth has quit [Ping timeout: 240 seconds]
britneywright has joined #ruby
<luckyruby> https://gist.github.com/luckyruby/947acc8a58646bd17f37 Working on a poker engine in ruby. Is this a decent way of determining a flush?
gr33n7007h has joined #ruby
mercwithamouth has joined #ruby
sevenseacat has joined #ruby
nasj has joined #ruby
ta_ has joined #ruby
thrownaway has quit [Ping timeout: 240 seconds]
Davey has quit [Quit: afk]
ta has quit [Read error: Connection reset by peer]
Davey has joined #ruby
timgauthier has joined #ruby
RubyPanther has quit [Quit: self.exit(:stage=>:left)]
<bricker`LA> luckyruby: maybe just `suits.uniq.length > 5`
<bricker`LA> >= I mean
n^izzo has quit [Quit: Leaving]
<benzrf> luckyruby: try storing cards as numbers internally
<benzrf> then formatting them with names when you print em
timgauthier has quit [Client Quit]
<benzrf> *i mean, card values
<benzrf> i.e. store 11 instead of jack
Georg3 has joined #ruby
nasj has quit [Ping timeout: 240 seconds]
<luckyruby> benzrf: good idea
<benzrf> luckyruby: also, you could try sorting by card value
<benzrf> then chunk by continued +1
<benzrf> see what the longest subsection is
<luckyruby> bricker`LA: I don't think that would work
rkazak has joined #ruby
timgauthier has joined #ruby
<luckyruby> %w(s c c c d c c).uniq #=> ['s','c','d']
GeraldoRamos has joined #ruby
mercwithamouth has quit [Ping timeout: 240 seconds]
radic has quit [Ping timeout: 240 seconds]
yfeldblum has quit [Ping timeout: 264 seconds]
radic has joined #ruby
mercwithamouth has joined #ruby
<bricker`LA> luckyruby: oh yeah, I had it backwards
<bricker`LA> :(
acconrad has joined #ruby
<bricker`LA> luckyruby: suits.uniq.length <= 2
<bricker`LA> >> %w[ s c c c d c c ].uniq.length <= 2
<eval-in_> bricker`LA => false (https://eval.in/169923)
<bricker`LA> >> %w[ s c c c d c c ].uniq
<eval-in_> bricker`LA => ["s", "c", "d"] (https://eval.in/169924)
<bricker`LA> >> %w[ s c c c d c c ].uniq.length <= 3
yfeldblum has joined #ruby
<bricker`LA> 3 I mean
sgen has joined #ruby
timgauthier has quit [Quit: Textual IRC Client: www.textualapp.com]
blackgoat has joined #ruby
narcan has quit [Quit: -[AppDelegate installMalware]: unrecognized selector sent to instance 0x156109c0]
aspires has quit []
thomasxie has joined #ruby
iswell has quit [Remote host closed the connection]
Lewix has quit [Remote host closed the connection]
Arkaniad|Laptop has joined #ruby
arya_ has quit [Ping timeout: 255 seconds]
benzrf is now known as benzrf|offline
Butcho has joined #ruby
iamcalledrob has joined #ruby
nateberkopec has quit [Quit: Leaving...]
benzrf|offline is now known as benzrf
moritzschaefer has quit [Ping timeout: 260 seconds]
yfeldblum has quit [Remote host closed the connection]
yfeldblum has joined #ruby
Daiyousei has quit [Ping timeout: 260 seconds]
tectonic has joined #ruby
iamcalledrob has quit [Ping timeout: 248 seconds]
nasj has joined #ruby
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
thomasxie has quit [Remote host closed the connection]
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
braincrash has quit [Quit: bye bye]
nasj has quit [Ping timeout: 255 seconds]
Beoran has quit [Ping timeout: 255 seconds]
braincrash has joined #ruby
kireevco has joined #ruby
chipotle has quit [Quit: cya]
LexicalScope has joined #ruby
yubrew has joined #ruby
diegoviola has joined #ruby
thesheff17 has quit [Quit: Leaving]
narcan has joined #ruby
thesheff17 has joined #ruby
elico has joined #ruby
aemeredith has joined #ruby
<elico> What "file based database" support concurrency such as sqlite?
Beoran has joined #ruby
aemeredith has quit [Read error: Connection reset by peer]
aemeredi_ has joined #ruby
lw has joined #ruby
yubrew has quit [Ping timeout: 260 seconds]
charlied3 has joined #ruby
awkwords has quit [Ping timeout: 240 seconds]
arya_ has joined #ruby
iamcalledrob has joined #ruby
Butcho has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
aemeredi_ has quit [Ping timeout: 240 seconds]
JoshGlzBrk has joined #ruby
Butcho has joined #ruby
MatthewsFace has joined #ruby
lw has quit [Quit: s]
nateberkopec has joined #ruby
Ankhers has quit [Remote host closed the connection]
aspires has joined #ruby
Ankhers has joined #ruby
<luckyruby> benzrf: https://gist.github.com/luckyruby/a13ca6e897ee511d6b4a Is there a more efficient way to do this?
<pipework> luckyruby: Read the documentation for #gsub
timonv has joined #ruby
<benzrf> luckyruby: dont use strings
<benzrf> use objects
<benzrf> orr @ least hashes
mercwithamouth has quit [Read error: Connection reset by peer]
aemeredith has joined #ruby
<benzrf> ruby isnt stringly typed
mercwithamouth has joined #ruby
<pipework> Or just use #gsub with a hash.
<luckyruby> do you prefer hash or ostruct to represent a card?
<sevenseacat> i would so just keep a hash mapping between internal/external representation
aspires has quit [Client Quit]
drawingthesun has quit [Read error: Connection reset by peer]
drawingthesun has joined #ruby
<luckyruby> I think I'll use a hash. {value: 2, suit: 's', display: '2s'}
timonv has quit [Ping timeout: 272 seconds]
ghr has joined #ruby
<godd2> benzrf I thought Ruby was strongly typed
<pipework> It's duckly typed.
<benzrf> godd2 it is
<benzrf> i didnt say it isnt
nateberkopec has quit [Ping timeout: 240 seconds]
Georg3 has quit [Quit: Computer has gone to sleep.]
<benzrf> luckyruby: no, dont store display
<benzrf> calculate it
<benzrf> luckyruby: the more redundant data you store the better chance it becomes out of sync
<luckyruby> The attributes of a card shouldn't change.
ghr has quit [Ping timeout: 248 seconds]
Butcho has quit [Quit: Textual IRC Client: www.textualapp.com]
<godd2> luckyruby a better name for that key might be 'rank', so {rank: 2, suit: 's', display: '2s'}
LexicalScope has quit [Ping timeout: 260 seconds]
<luckyruby> godd2: i agree
<godd2> plus, that way you don't have card.keys returning value. could be confusing
Lewix has joined #ruby
iswell has joined #ruby
aemeredith has quit [Remote host closed the connection]
aemeredith has joined #ruby
Takle has joined #ruby
<luckyruby> https://gist.github.com/luckyruby/60254a5d026e879ec641 Should I be using dup or clone?
<luckyruby> or does it not make a difference in this case
<benzrf> luckyruby: uh
<benzrf> why are you making a class Deck
<benzrf> oh i guess i follow
aemeredith has quit [Ping timeout: 240 seconds]
<benzrf> >> l = [1, 2, 3]; l.shuffle; l
<eval-in_> benzrf => [1, 2, 3] (https://eval.in/169945)
<benzrf> >> l = [1, 2, 3]; l.shuffle
<eval-in_> benzrf => [2, 3, 1] (https://eval.in/169946)
<benzrf> >> l = [1, 2, 3]; l.shuffle; l
<eval-in_> benzrf => [1, 2, 3] (https://eval.in/169947)
<pipework> >> [1,2,3].shuffle.tap(&:first)
<eval-in_> pipework => [3, 1, 2] (https://eval.in/169948)
<pipework> Oh right, not tap.
<pipework> >> [1,2,3].shuffle.first
<eval-in_> pipework => 2 (https://eval.in/169949)
whyy has joined #ruby
<pipework> Or I suppose he doesn't want first, anyways, I've not been drinking and I'm going to fix that.
Takle has quit [Ping timeout: 272 seconds]
thrownaway has joined #ruby
<luckyruby> benzrf: I probably don't need a deck class. Anyway, my plan was to #shuffle and #shift to deal out the cards.
mercwithamouth has quit [Read error: Connection reset by peer]
<benzrf> luckyruby: yeah you could make those methods on Deck
<benzrf> Deck.new
<benzrf> thedeck.deal 4
<benzrf> or something
dayepa has quit [Read error: Connection reset by peer]
FarLight has joined #ruby
mercwithamouth has joined #ruby
dayepa has joined #ruby
<godd2> luckyruby: this is a bit more condensed version of the deck class: https://gist.github.com/nicklink483/adf10f488b225cd0b141
<luckyruby> godd2: thanks, that's way better
havenwood has joined #ruby
whyy_ has joined #ruby
quazimodo has joined #ruby
AlanWatts has joined #ruby
<benzrf> godd2: why not use map
<pipework> Or flat_map!
AlanWatts has left #ruby ["Leaving..."]
mr_snowf1ake has left #ruby ["Leaving"]
whyy has quit [Ping timeout: 260 seconds]
MissionCritical has quit [Ping timeout: 264 seconds]
<godd2> that's way cleaner. plus, that way you can do Card.new(r, s) if you want to make a card class
mrmargolis has quit [Remote host closed the connection]
drawingthesun has quit [Read error: Connection reset by peer]
nasj has joined #ruby
sgen has quit [Quit: Leaving]
drawingthesun has joined #ruby
<havenwood> #sample
charlied3 has quit [Quit: WeeChat 0.4.2]
Ankhers has quit [Ping timeout: 264 seconds]
ta has joined #ruby
<havenwood> though ya you've gotta remove it, so pick your poison
bluOxigen has joined #ruby
ta_ has quit [Read error: Connection reset by peer]
earthquake has joined #ruby
anaeem1 has joined #ruby
drawingthesun has quit [Read error: Connection reset by peer]
<godd2> luckyruby you need to use shuffle! not shuffle
drawingthesun has joined #ruby
<luckyruby> good catch
yubrew has joined #ruby
whyy_ has quit []
<gr33n7007h> luckyruby, why you using T for 10?
qsun has quit [Ping timeout: 248 seconds]
<luckyruby> gr33n7007h: that's the convention in the online poker world
tobago has joined #ruby
<gr33n7007h> oh was just curious thats all
yubrew has quit [Ping timeout: 248 seconds]
why_away has joined #ruby
qsun has joined #ruby
MissionCritical has joined #ruby
codabrink has quit [Ping timeout: 255 seconds]
hobodave has joined #ruby
GeraldoRamos has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<godd2> plus it conveniently makes every rank abbr a single character
hobodave has quit [Remote host closed the connection]
arya_ has quit [Ping timeout: 252 seconds]
aemeredith has joined #ruby
jfpoole has quit [Quit: jfpoole]
brunops has quit [Ping timeout: 248 seconds]
aemeredith has quit [Read error: Connection reset by peer]
aemeredith has joined #ruby
rkazak has quit [Quit: rkazak]
ARCADIVS has joined #ruby
<gr33n7007h> godd2, good observation
<gr33n7007h> didn't think of that :p
aemeredith has quit [Ping timeout: 240 seconds]
mercwithamouth has quit [Read error: Connection reset by peer]
mercwithamouth has joined #ruby
<godd2> is this inside a hand class? where is @full_hand coming from?
jxf has joined #ruby
<luckyruby> refresh the gist
Channel6 has quit [Quit: Leaving]
aemeredith has joined #ruby
nasj has quit [Remote host closed the connection]
Georg3 has joined #ruby
srnty has joined #ruby
srnty has quit [Client Quit]
nateberkopec has joined #ruby
oo_ has quit [Remote host closed the connection]
larsam has joined #ruby
saarinen has joined #ruby
Mon_Ouie has quit [Quit: WeeChat 0.4.3]
theharshest has quit [Quit: This computer has gone to sleep]
<godd2> that looks like it will work, but you haven't left much room for growth
aemeredith has quit [Ping timeout: 255 seconds]
robbyoconnor has quit [Max SendQ exceeded]
Georg3 has quit [Ping timeout: 264 seconds]
robbyoconnor has joined #ruby
sputnik13 has joined #ruby
robbyoconnor has quit [Changing host]
robbyoconnor has joined #ruby
theharshest has joined #ruby
<luckyruby> godd2: yea, for now I plan on adding methods to detect 4 of a kind, full house, 3 of a kind, etc. Then I'll reorganize it into a diff class.
<godd2> also, on line 22 you have a puts, but the return from flush? is nil since extract_flush's last command is to puts something. when you want to puts the result of a method call, youll want that method to eventually return a string
thesheff17 has quit [Quit: Leaving]
nateberkopec has quit [Ping timeout: 240 seconds]
phutchins has quit [Ping timeout: 264 seconds]
Dr3amc0d3r|away has quit [Changing host]
Dr3amc0d3r|away has joined #ruby
sputnik13 has quit [Client Quit]
thesheff17 has joined #ruby
Dr3amc0d3r|away is now known as Dr3amc0d3r
chipotle has joined #ruby
CaptainJet has quit []
<luckyruby> yea, that puts shouldn't be there. rewritten the code a few times already and that got left behind
oo_ has joined #ruby
sputnik13 has joined #ruby
mgberlin_ has joined #ruby
mehlah has quit [Quit: Leaving...]
oo_ has quit [Remote host closed the connection]
mgberlin has quit [Ping timeout: 240 seconds]
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
sputnik13 has joined #ruby
mercwithamouth has quit [Ping timeout: 255 seconds]
FarLight has quit [Changing host]
FarLight has joined #ruby
sigurding has joined #ruby
arya_ has joined #ruby
GriffinHeart has quit [Remote host closed the connection]
nasj has joined #ruby
Wolland has quit [Remote host closed the connection]
Wolland has joined #ruby
<godd2> luckyruby: here's a beginning layout of some classes for such card games. give it a look through and use anything you want out of it: https://gist.github.com/nicklink483/b344fe502e76332e3a3e
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
Wolland has quit [Ping timeout: 248 seconds]
oo_ has joined #ruby
yubrew has joined #ruby
sputnik13 has joined #ruby
mgberlin_ has quit [Remote host closed the connection]
nateberkopec has joined #ruby
ARCADIVS has quit [Ping timeout: 260 seconds]
simoz1111115 has quit [Ping timeout: 272 seconds]
chihhsin_ has quit [Ping timeout: 264 seconds]
<luckyruby> godd2: nice
sputnik13 has quit [Client Quit]
chihhsin has joined #ruby
timonv has joined #ruby
MatthewsFace has quit [Quit: This computer has gone to sleep]
yubrew has quit [Ping timeout: 264 seconds]
<luckyruby> godd2: for your deal method, any reason why you didn't just go with @card.shift(n)?
<luckyruby> @cards.shift(n)
lulzmachine has joined #ruby
nateberkopec has quit [Ping timeout: 240 seconds]
lulzmachine_ has joined #ruby
aganov has joined #ruby
saarinen has quit [Quit: saarinen]
GriffinHeart has joined #ruby
lulzmachine_ has quit [Client Quit]
lulzmachine has quit [Client Quit]
codabrink has joined #ruby
<luckyruby> I really like what you have.
ta has quit [Read error: Connection reset by peer]
ta_ has joined #ruby
brunops has joined #ruby
oo_ has quit [Remote host closed the connection]
User458764 has joined #ruby
lulzmachine has joined #ruby
lulzmachine has quit [Client Quit]
<godd2> in this case pop and shift do the same thing, since we expect the cards to be in a random order.
<godd2> plus, pop is two letters fewer than shift, so less typing
<luckyruby> but 1 line vs 3
dumdedum has joined #ruby
<godd2> oh just change it to @cards.pop n
stytown has joined #ruby
sputnik13 has joined #ruby
oo_ has joined #ruby
Morkel has joined #ruby
nasj has quit [Remote host closed the connection]
Slarv has joined #ruby
nasj has joined #ruby
nasj has quit [Remote host closed the connection]
FarLight has left #ruby ["Leaving"]
nasj has joined #ruby
_maes_ has joined #ruby
nasj has quit [Remote host closed the connection]
sputnik13 has quit [Client Quit]
aemeredith has joined #ruby
aemeredi_ has joined #ruby
aemeredith has quit [Read error: Connection reset by peer]
Azure has quit [Quit: My MBP went to sleep.]
qpls has quit [Ping timeout: 240 seconds]
<luckyruby> godd2: learned a lot from your gist
qpls has joined #ruby
<luckyruby> didn't know about Comparable mixin and that you can omit {} for string interpolation of instance variables
<godd2> yea don't ever be afraid to make a new class for something. there will be a time when you make too many classes, but then youll learn to trim it back
Georg3 has joined #ruby
<godd2> yea Comparable is pretty sexy. I used it in a musical gem Im making to compare pitches and notes for 'free'
JasmeetQA has joined #ruby
idiocrash has quit [Ping timeout: 255 seconds]
User458764 is now known as User458764_NotHe
<luckyruby> what's the purpose of your music gem? Is it to make music?
User458764 has joined #ruby
<luckyruby> or analyze
Georg3 has quit [Ping timeout: 260 seconds]
echevemaster has quit [Quit: Leaving]
dc_ has quit [Remote host closed the connection]
pontiki has joined #ruby
<pontiki> hi
User458764_NotHe has quit [Ping timeout: 255 seconds]
mengu has joined #ruby
techsethi has joined #ruby
tagrudev has joined #ruby
ARCADIVS has joined #ruby
dc_ has joined #ruby
why_away is now known as whyy
Morkel_ has joined #ruby
Morkel has quit [Ping timeout: 255 seconds]
Morkel_ is now known as Morkel
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
starkhalo has quit [Ping timeout: 272 seconds]
relix has joined #ruby
tonini_ is now known as tonini
EasyCo has quit [Quit: Connection closed for inactivity]
_justin has joined #ruby
User458764 is now known as User458764_NotHe
alem0lars has joined #ruby
aemeredi_ has quit [Remote host closed the connection]
rezzack has quit [Quit: Leaving.]
<Slarv> hello pontiki
chipotle has quit [Quit: cya]
<pontiki> hi Slarv
User458764_NotHe has quit [Ping timeout: 260 seconds]
bluOxigen has quit [Ping timeout: 264 seconds]
heftig has quit [Quit: Quitting]
bluOxigen has joined #ruby
dc_ has quit [Remote host closed the connection]
theharshest has quit [Quit: This computer has gone to sleep]
JoshGlzBrk has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
arrubin has quit [Quit: Textual IRC Client: www.textualapp.com]
brunops has quit [Ping timeout: 248 seconds]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
brunops has joined #ruby
brunops has quit [Client Quit]
schaerli has quit [Ping timeout: 272 seconds]
Wolland has joined #ruby
Dr3amc0d3r is now known as Dr3amc0d3r|away
coderhs has joined #ruby
kyb3r_ has joined #ruby
coderhs has quit [Client Quit]
iamcalledrob has quit [Quit: Computer has gone to sleep.]
Wolland has quit [Remote host closed the connection]
Doppp has joined #ruby
yubrew has joined #ruby
havenwood has quit [Remote host closed the connection]
timonv has quit [Remote host closed the connection]
iamcalledrob has joined #ruby
dc_ has joined #ruby
havenwood has joined #ruby
emergion has quit [Quit: Connection closed for inactivity]
apeiros has quit [Remote host closed the connection]
apeiros has joined #ruby
kireevco has quit [Quit: Leaving.]
jprovazn has joined #ruby
shredding has joined #ruby
yubrew has quit [Ping timeout: 248 seconds]
iamcalledrob has quit [Ping timeout: 252 seconds]
ylluminate has quit [Read error: Connection reset by peer]
havenwood has quit [Ping timeout: 264 seconds]
sputnik13 has joined #ruby
<shevy> wheeee it's a pontiki without a ponbiki
<shevy> though there is also another pon... ponyfleisch lol
<shevy> "fleisch" = german for "meat"
Wolland has joined #ruby
apeiros has quit [Ping timeout: 264 seconds]
MatthewsFace has joined #ruby
nateberkopec has joined #ruby
<godd2> luckyruby: yea it's gonna write songs by itself.
tokik has quit [Ping timeout: 272 seconds]
ylluminate has joined #ruby
iamjarvo has joined #ruby
<luckyruby> interesting
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
niftylettuce_ has joined #ruby
bal has joined #ruby
Mon_Ouie has joined #ruby
Mon_Ouie has joined #ruby
<shevy> https://www.python.org/ has something cool
<shevy> it shows features of the language in an intro-like way
nateberkopec has quit [Ping timeout: 240 seconds]
<luckyruby> all we have is a puts "Hello World"
<shevy> hehehe
<shevy> you are funny luckyruby
MatthewsFace has quit [Quit: Leaving]
luckyruby has quit [Quit: Leaving...]
tokik has joined #ruby
Doppp has quit [Read error: Connection reset by peer]
dc_ has quit [Remote host closed the connection]
diegoviola has quit [Quit: WeeChat 0.4.3]
dc_ has joined #ruby
quazimodo has quit [Ping timeout: 248 seconds]
frank_____ has joined #ruby
ta_ has quit [Read error: Connection reset by peer]
Georg3 has joined #ruby
ta has joined #ruby
Slarv has quit [Read error: Connection reset by peer]
ta_ has joined #ruby
ta has quit [Read error: Connection reset by peer]
zkay11 has quit [Quit: Leaving.]
Georg3 has quit [Ping timeout: 264 seconds]
iamcalledrob has joined #ruby
iswell has quit [Remote host closed the connection]
ta has joined #ruby
ta_ has quit [Read error: Connection reset by peer]
havenwood has joined #ruby
Lewix has quit [Ping timeout: 260 seconds]
iamcalledrob has quit [Ping timeout: 264 seconds]
Photism has quit [Quit: Leaving]
havenwood has quit [Ping timeout: 264 seconds]
cobakobodob has quit [Ping timeout: 240 seconds]
Xeago has joined #ruby
apeiros has joined #ruby
cobakobodob has joined #ruby
yfeldblum has quit [Remote host closed the connection]
yfeldblum has joined #ruby
ta_ has joined #ruby
IceDragon has quit [Quit: Space~~~]
ta has quit [Read error: Connection reset by peer]
bigkevmcd has joined #ruby
ddv has joined #ruby
ddv has quit [Changing host]
uresu has joined #ruby
jxf has quit [Ping timeout: 248 seconds]
yfeldblum has quit [Ping timeout: 248 seconds]
ta has joined #ruby
ta_ has quit [Read error: Connection reset by peer]
dapz has joined #ruby
mary5030 has joined #ruby
earthquake has quit [Quit: earthquake]
Hobogrammer_ has joined #ruby
kiri has joined #ruby
Hobogrammer has quit [Ping timeout: 260 seconds]
shredding has quit [Quit: shredding]
claymore has joined #ruby
yubrew has joined #ruby
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bato has quit [Ping timeout: 255 seconds]
jerius has joined #ruby
nasj has joined #ruby
yubrew has quit [Ping timeout: 260 seconds]
<certainty> tagrudev: moin
Darkchaos has joined #ruby
<tagrudev> certainty, yolo
dangerousdave has joined #ruby
timonv has joined #ruby
nasj has quit [Ping timeout: 252 seconds]
fabrice31 has joined #ruby
nasj has joined #ruby
fabrice31 has quit [Remote host closed the connection]
himsin has joined #ruby
fabrice31 has joined #ruby
beakr has joined #ruby
timonv has quit [Ping timeout: 252 seconds]
nateberkopec has joined #ruby
fabrice31 has quit [Client Quit]
fabrice31 has joined #ruby
descala has quit [Ping timeout: 255 seconds]
yfeldblum has joined #ruby
<apeiros> tagrudev: you're so yestermillenia. haven't you heard? it's now just "yo"
<apeiros> ;-)
narcan has quit [Quit: -[AppDelegate installMalware]: unrecognized selector sent to instance 0x156109c0]
Macaveli has joined #ruby
<tagrudev> it's not a fashion apeiros, it's a culture :D
<apeiros> culture is just slow fashion
<apeiros> (and that's not even a joke)
stytown has quit [Quit: stytown]
sk87 has joined #ruby
<tagrudev> :D
uresu has quit [Quit: uresu]
rdark has joined #ruby
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
nateberkopec has quit [Ping timeout: 240 seconds]
blackmesa has joined #ruby
yfeldblum has quit [Ping timeout: 264 seconds]
Robbo` has joined #ruby
<Robbo`> lmfao I just encountered this
<Robbo`> <Debolaz> Robbo`: PHP is miles better than Ruby.
<Robbo`> I didn't know those people still existesd
jack_rabbit has quit [Ping timeout: 240 seconds]
benzrf is now known as benzrf|offline
guinslym has joined #ruby
moritzschaefer has joined #ruby
<beakr> Robbo: scary thought
camilasan has joined #ruby
<Robbo`> beakr: he was full serious too I think
codezomb has joined #ruby
ndrei has joined #ruby
CorpusCallosum has quit [Ping timeout: 272 seconds]
duncannz has quit [Ping timeout: 252 seconds]
codezomb has quit [Client Quit]
codezomb has joined #ruby
<beakr> Robbo: I know the whole thing, "each language has its own advantages"... but PHP doesn't really compare.
<Robbo`> yeah I just php and ruby
dangerousdave has quit [Read error: Connection reset by peer]
<Robbo`> but I damn well know which one is better
havenwood has joined #ruby
<Robbo`> and im far better at php because I have a lot of experience there
dangerousdave has joined #ruby
codezomb has quit [Client Quit]
codezomb has joined #ruby
codezomb has quit [Client Quit]
codezomb has joined #ruby
<guinslym> hi! I'm getting an error ; Expected "wrong number of arguments (0 for 2)" to match /__/ (gist:: https://gist.github.com/guinslym/2709f3dae5ac1a0a4e7c)
<sevenseacat> because you didnt fill in the answer
<sevenseacat> the __ is where the answer goes
tacos1de has quit [Ping timeout: 264 seconds]
<guinslym> ook sevenseacat but when I put "wrong number of arguments (0 for 2)" I'm getting an error : type mismatch: String given ?
<sevenseacat> code?
moritzschaefer has quit [Quit: Verlassend]
senayar has joined #ruby
<guinslym> gist(https://gist.github.com/guinslym/2709f3dae5ac1a0a4e7c) file about_methods.rb
codezomb has quit [Client Quit]
tacos1de has joined #ruby
<sevenseacat> well match is for a regex
<sevenseacat> ypu
<sevenseacat> you've replaced the regex with a string
CorpusCallosum has joined #ruby
tectonic has quit []
oo_ has quit [Remote host closed the connection]
oo_ has joined #ruby
iamcalledrob has joined #ruby
nasj has quit [Remote host closed the connection]
Takle has joined #ruby
Royalb15 has joined #ruby
<guinslym> ok thanks for the clue. the test is now passed
<sevenseacat> :)
alex88 has joined #ruby
alem0lars has quit [Quit: Going AFK...]
uresu has joined #ruby
iamcalledrob has quit [Ping timeout: 252 seconds]
bluOxigen has quit [Read error: Connection reset by peer]
tectonic has joined #ruby
lxsameer has joined #ruby
bluOxigen has joined #ruby
Takle has quit [Ping timeout: 264 seconds]
blackmesa has quit [Ping timeout: 248 seconds]
tectonic has quit []
febuiles has quit [Remote host closed the connection]
nasj has joined #ruby
mijicd has joined #ruby
CorpusCallosum has quit [Ping timeout: 260 seconds]
mijicd has quit [Client Quit]
yubrew has joined #ruby
mijicd has joined #ruby
JoshGlzBrk has joined #ruby
blueOxigen has joined #ruby
whowantstolivef1 is now known as whowantstolivefo
shredding has joined #ruby
bluOxigen has quit [Ping timeout: 264 seconds]
LiohAu has joined #ruby
yubrew has quit [Ping timeout: 252 seconds]
jerius has quit []
ghr has joined #ruby
monomyth has quit [Ping timeout: 252 seconds]
beakr has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
Joulse has joined #ruby
mary5030 has quit [Remote host closed the connection]
drawingthesun has quit [Ping timeout: 264 seconds]
tesuji has joined #ruby
yfeldblum has joined #ruby
doev has joined #ruby
mikecmpbll has joined #ruby
Poky has joined #ruby
larsam has quit [Quit: Exit]
oo_ has quit [Remote host closed the connection]
larsam has joined #ruby
yfeldblum has quit [Ping timeout: 264 seconds]
frankjpinto has joined #ruby
whyy has quit [Remote host closed the connection]
oo_ has joined #ruby
nateberkopec has joined #ruby
sevenseacat has quit [Quit: Leaving.]
<guinslym> About arrays; I don't understand why array[5,0] doesn't have the same result as array[4,0] gist => https://gist.github.com/guinslym/9e8506ed73cd3528cf7f
<frankjpinto> odd
<DefV> that's one of Ruby's quirks
<guinslym> ok :)
<frankjpinto> according to docs should both return nil
<Mon_Ouie> No, it shouldn't, that's the expected behaviour
<krz> is instance_variable_set equivalent ||= ?
nateberkopec has quit [Ping timeout: 240 seconds]
<krz> if not, what is?
<Mon_Ouie> When you use slices, you have to look at it as if the indices are right before each element
godd2 has quit [Remote host closed the connection]
jackneill has joined #ruby
<frankjpinto> uh huh, so whats 4 right before?
<Mon_Ouie> Right before the end of the array. I had an image that explained it well but it seems to be gone :(
<krz> is there an instance_variable_set_get method?
<krz> i.e. equivalent to ||=
<frankjpinto> hm, let us know if you find it :)
<frankjpinto> I see
warprobot has joined #ruby
<frankjpinto> krz, no ||= method equivalent AFAIK
<frankjpinto> any reason you can't wrap it in an accessor?
linduxed has joined #ruby
<krz> frankjpinto: how so? i have https://gist.github.com/e7d4e0c03f185642e8b0 atm
<krz> frankjpinto: can i wrap that in an acessor?
<krz> i guess i need to do a instance_variable_get first
roolo has joined #ruby
<krz> if nil, then set
<frankjpinto> you can but it requires some meta magic that i'm a bit rusty on, let me look it up
Lewix has joined #ruby
iswell has joined #ruby
<frankjpinto> or yes, just use an if w/ instance_variable_get...would be clearer to anybody else reading it IMO
fwaokda has quit [Ping timeout: 252 seconds]
iswell has quit [Remote host closed the connection]
olivier_bK has joined #ruby
<krz> thanks
Lewix has quit [Ping timeout: 264 seconds]
elaptics`away is now known as elaptics
bradleyprice has quit [Remote host closed the connection]
bradleyprice has joined #ruby
mr_foobar_baz has joined #ruby
bradleyprice has quit [Ping timeout: 255 seconds]
iamcalledrob has joined #ruby
tvw has joined #ruby
einarj has joined #ruby
whyy has joined #ruby
fwaokda has joined #ruby
iamcalledrob has quit [Ping timeout: 255 seconds]
niftylettuce_ has quit [Quit: Connection closed for inactivity]
Takle has joined #ruby
lkba has quit [Ping timeout: 255 seconds]
timonv has joined #ruby
sigurding has quit [Quit: sigurding]
joonty has quit [Ping timeout: 272 seconds]
ephemerian has joined #ruby
Takle has quit [Remote host closed the connection]
mr_foobar_baz has quit [Quit: WeeChat 0.4.3]
Takle has joined #ruby
fluve has joined #ruby
yubrew has joined #ruby
lyuzashi has quit [Ping timeout: 272 seconds]
ndrei has quit [Ping timeout: 248 seconds]
ndrei has joined #ruby
aemeredith has joined #ruby
CADBOT has joined #ruby
<CADBOT> I'm running into the readline issue when compiling ruby on ubuntu. What's the best way to resolve?
<CADBOT> Specific error msg: readline.c:530:1: warning: ‘readline_pre_input_hook’ defined but not used [-Wunused-function]
yubrew has quit [Ping timeout: 248 seconds]
himsin has quit [Quit: himsin]
nfk has joined #ruby
ghr has quit []
Takle has quit [Remote host closed the connection]
dc__ has joined #ruby
shredding has quit [Ping timeout: 264 seconds]
dc_ has quit [Ping timeout: 240 seconds]
Dr3amc0d3r|away is now known as Dr3amc0d3r
joonty has joined #ruby
CADBOT has quit [Quit: ChatZilla 0.9.90.1 [Firefox 24.6.0/20140609182057]]
himsin has joined #ruby
Takle has joined #ruby
ghr has joined #ruby
yfeldblum has joined #ruby
ephemerian has quit [Quit: Leaving.]
shredding has joined #ruby
<krz> is there an after_initialize method in ruby?
<Hanmac> krz why do you need that?
<Cork> krz: you use the initialize method
<Cork> after_initialize is used by rails as they do some none instanciating optimizations in activerecord
yfeldblum has quit [Ping timeout: 255 seconds]
<Hanmac> "rails - because we does not know better" ;P
warprobot has quit [Remote host closed the connection]
ephemerian has joined #ruby
tacos1de has quit [Remote host closed the connection]
tacos1de has joined #ruby
pvb has joined #ruby
AntelopeSalad has joined #ruby
warprobot has joined #ruby
<Cork> heh
<Cork> talking about rails, i need to generate restful requests to a rails server
<Cork> is there a package to generate the in url id things?
blackmesa has joined #ruby
<Cork> or is #{ id } and so on the only option?
bluOxigen has joined #ruby
<Cork> been googling around and found absolutely nothing...
mijicd has quit [Remote host closed the connection]
spider-mario has joined #ruby
<krz> Cork: friendly url?
<Hanmac> Cork: #rubyonrails
<Cork> Hanmac: i'm not doing it in rails
nateberkopec has joined #ruby
sputnik13 has joined #ruby
blueOxigen has quit [Ping timeout: 255 seconds]
<Cork> krz: no
<Cork> i'm talking about "http://example.com/user/#{ id }" => "http://example.com/user/1234"
warprobot has quit [Ping timeout: 272 seconds]
<frankjpinto> do you have a model on your end of things? if so you can prob rip the model -> url functionality out of rails w/o too much effort
<Cork> frankjpinto: nope, no models
<Cork> just a tiny .rb file
<Cork> with 5 urls based on parameters
havenwood has quit [Remote host closed the connection]
aemeredith has quit [Remote host closed the connection]
<frankjpinto> so unless you wanna build a lil mock object that reponds to all the params the rails router uses for that conversion...i'd suggest just making your own function
<Cork> "http://example.com/user/#{ id }/member_name" is what i do today
nateberkopec has quit [Ping timeout: 240 seconds]
alem0lars has joined #ruby
aemeredith has joined #ruby
<Cork> hmm i might have gone about this the wrong way, what i'm really looking for is a template solution
<frankjpinto> def generate_url(id); "http://example.com/user/#{id}/member_name; end .... there you go! function written, desired functionality achieved B-)
<frankjpinto> haha
<Cork> frankjpinto: that is actually very close to what i do today :)
blackmesa has quit [Quit: WeeChat 0.4.3]
<Cork> frankjpinto: what i'm looking for is something like "http://example.com/user/:id/member_name".replace_keys(has_object)
<Cork> though it would have to do safe escape...
<Cork> bah...
<Cork> doesn't look worth the digging
<frankjpinto> ooo that exists!
<frankjpinto> have to find it
<frankjpinto> ok, cool
<Mon_Ouie> does it have to be formatted like :id?
<Cork> Mon_Ouie: no
<Mon_Ouie> Because if you can use another format you can use  Kernel#sprintf
<Mon_Ouie> Or more conveniently String#%
endash has joined #ruby
<Cork> Mon_Ouie: it needs to be formated in a unique identifier way
aemeredith has quit [Ping timeout: 252 seconds]
<Cork> as the hash_object could be in any order and with uneeded data
<shevy> I'd wish I could compile ruby 1.0.0
<Cork> so no sprintf isn't enough
<Mon_Ouie> Sure it is
<Mon_Ouie> >> "test: %{foo}" % {:foo => 1, :bar => 2}
<eval-in_> Mon_Ouie => "test: 1" (https://eval.in/169984)
<Cork> O_o
<Cork> wow
<Cork> didn't know you could do that with sprintf!
klaut has joined #ruby
<Cork> Mon_Ouie: thx, that will do nicely
_justin has quit [Quit: _justin]
ferr has joined #ruby
obs has joined #ruby
<frankjpinto> ^ says nobody ever :D
Joulse has quit [Quit: Joulse]
banister has joined #ruby
banister has quit [Max SendQ exceeded]
banister has joined #ruby
marr has joined #ruby
<frankjpinto> me neither, nice Mon_Ouie
francisfish has joined #ruby
dangerou_ has joined #ruby
vyorkin has joined #ruby
AntelopeSalad has quit [Remote host closed the connection]
dangerousdave has quit [Ping timeout: 248 seconds]
AntelopeSalad has joined #ruby
ta_ has joined #ruby
Joulse has joined #ruby
iamcalledrob has joined #ruby
ta has quit [Ping timeout: 272 seconds]
mengu has quit [Remote host closed the connection]
ta has joined #ruby
Atttwww has quit [Ping timeout: 272 seconds]
warprobot has joined #ruby
ta_ has quit [Ping timeout: 240 seconds]
warprobot has quit [Remote host closed the connection]
thesheff17 has quit [Ping timeout: 264 seconds]
warprobot has joined #ruby
<relix> hey guys - what's the alternative for setting $KCODE?
<relix> I'm using a library (xml builder) that depends on $KCODE being set for a feature
yubrew has joined #ruby
<relix> not sure if I can still use that or not
_justin has joined #ruby
iamcalledrob has quit [Ping timeout: 272 seconds]
<apeiros> eh? update your ruby?
<relix> "You can get UTF-8 encoded output by making sure that the XML encoding is set to "UTF-8" and that the $KCODE variable is set to "UTF8"."
<apeiros> $KCODE is <1.9 only
duncannz has joined #ruby
<relix> apeiros that's the thing I'm using a ruby which does not allow KCODE anymore
<relix> this library requires KCODE to be set
ponga has joined #ruby
<ponga> IDE recommendation for ruby & JS ?
<Edelwin> vim
<Edelwin> + nerdtree
<apeiros> relix: patch the lib
<apeiros> finding all instances of $KODE in it shouldn't be that hard
<relix> apeiros yeah
<apeiros> alternatively: don't use it. use one which works well with current rubies.
<apeiros> e.g. nokogiri's builder.
<relix> that's what I wish I had time for :)
schaerli has joined #ruby
<relix> I'll just patch the lib for this one thing
<relix> (famous last words, eh)
<apeiros> though it seems to me it doesn't directly use $KCODE
<apeiros> so you either need ruby 2.0+, where source code defaults to utf-8, or you set the `# encoding: utf-8` comment. might also need Encoding.default_internal, _external
<relix> apeiros I'm pretty sure it just checks if $KCODE == options.xml_encoding or something
yubrew has quit [Ping timeout: 260 seconds]
Squarepy has joined #ruby
obs has quit [Quit: Konversation terminated!]
<relix> which would explain why it doesn't work - I'm in ruby 2
RurouniJones has joined #ruby
obs has joined #ruby
<relix> "(@encoding != 'utf-8' or $KCODE != 'UTF8')"
<relix> :/
wildroman2 has joined #ruby
ephemerian has quit [Ping timeout: 260 seconds]
<apeiros> relix: *or*
<apeiros> use the @encoding then
aemeredith has joined #ruby
<relix> apeiros it needs to be false
lolmaus has quit [Ping timeout: 255 seconds]
<relix> the feature works if @encoding == utf-8 and kcode == UTF8
railzForDaiz has joined #ruby
<relix> it's just defined weirdly
<apeiros> :-/
<apeiros> patch time
<relix> dammit jim why did you have to die on us
Dr3amc0d3r is now known as Dr3amc0d3r|away
lolmaus has joined #ruby
obs has quit [Ping timeout: 264 seconds]
Takle has quit [Remote host closed the connection]
<frankjpinto> ponga, vim +1...ctrlp instead of nerdtree though ;)
<ponga> ok
aemeredith has quit [Ping timeout: 264 seconds]
Wolland has quit [Remote host closed the connection]
Wolland has joined #ruby
Takle has joined #ruby
yfeldblum has joined #ruby
arya_ has quit [Ping timeout: 255 seconds]
jw is now known as Guest58962
Wolland has quit [Ping timeout: 260 seconds]
roolo has quit [Quit: Leaving...]
arya_ has joined #ruby
yfeldblum has quit [Ping timeout: 248 seconds]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
railzForDaiz has quit [Ping timeout: 248 seconds]
sigurding has joined #ruby
drawingthesun has joined #ruby
sigurding has quit [Client Quit]
drawingthesun has quit [Max SendQ exceeded]
<relix> oh god
<relix> rails (= 3.2.17) ruby depends on
<relix> builder (~> 3.0.0) ruby
dc__ has quit [Remote host closed the connection]
<relix> I'm doomed
sandbags has joined #ruby
<relix> can't even upgrade the builder gem to 3.2 to support the encoding
drawingthesun has joined #ruby
frank_____ has quit [Quit: Connection closed for inactivity]
<relix> dependency hell nooo
drawingthesun has quit [Max SendQ exceeded]
drawingthesun has joined #ruby
obs has joined #ruby
<shevy> why
<shevy> what is your builder and rails version
warprobot has quit [Remote host closed the connection]
drawingthesun has quit [Max SendQ exceeded]
drawingthesun has joined #ruby
bradleyprice has joined #ruby
warprobot has joined #ruby
aemeredith has joined #ruby
mengu has joined #ruby
nateberkopec has joined #ruby
bradleyprice has quit [Ping timeout: 252 seconds]
havenwood has joined #ruby
Takle has quit [Remote host closed the connection]
karupa is now known as zz_karupa
anarang has joined #ruby
nateberkopec has quit [Ping timeout: 240 seconds]
mehlah has joined #ruby
uresu has quit [Quit: uresu]
havenwood has quit [Ping timeout: 264 seconds]
ephemerian has joined #ruby
Neomex has joined #ruby
kyb3r_ has quit [Read error: Connection reset by peer]
sandbags has quit [Ping timeout: 264 seconds]
ephemerian has left #ruby [#ruby]
yalue has quit [Read error: Connection reset by peer]
descala has joined #ruby
<olivier_bK> how can insert multiple value in mysql with apostrophe i do that connection.query("INSERT INTO ser (epName, epSurname) VALUES ('#{args[0]}', '#{args[1]}')")
<Mon_Ouie> Don't substitute strings in a query like that
<Mon_Ouie> Use prepared queries instead
<olivier_bK> ?
phinfonet has joined #ruby
guinslym has quit [Ping timeout: 264 seconds]
<olivier_bK> i dont really see what you mean can i have a short example
<Mon_Ouie> What happens if args[0] == "'; drop table ser %"? ;)
Hobogrammer has joined #ruby
wildroman2 has quit [Remote host closed the connection]
fluve has quit [Remote host closed the connection]
sevenseacat has joined #ruby
ringarin has joined #ruby
Hobogrammer_ has quit [Ping timeout: 248 seconds]
<olivier_bK> i dont want to dropt the table
_justin has quit [Quit: _justin]
<shevy> hehehe
<shevy> you french folks are a lot of fun
<Mon_Ouie> I know, the point is your code is vulnerable to sql injections
obs has quit [Ping timeout: 252 seconds]
ephemerian has joined #ruby
<shevy> I looked up to you ever since I watched you in the movie "The Holy Grail"
yubrew has joined #ruby
<shevy> Fetchez la vache!
PanPan has quit [Quit: ChatZilla 0.9.90.1 [Firefox 30.0/20140605174243]]
codecodecode123 has joined #ruby
<shevy> C'est un lapin, un lapin de bois.
codecodecode123 has left #ruby [#ruby]
<shevy> Un Cadeau!
torstein has quit [Remote host closed the connection]
RandyT has quit [Ping timeout: 240 seconds]
wildroman2 has joined #ruby
Takle has joined #ruby
iamcalledrob has joined #ruby
Joulse has quit [Quit: Joulse]
RandyT has joined #ruby
Morkel has quit [Ping timeout: 260 seconds]
joonty has quit [Ping timeout: 255 seconds]
_justin has joined #ruby
ValicekB has quit []
oo_ has quit [Remote host closed the connection]
oo_ has joined #ruby
<olivier_bK> shevy ...
<olivier_bK> :)
yubrew has quit [Ping timeout: 255 seconds]
<olivier_bK> shevy, la vache lol..
Hobogrammer_ has joined #ruby
<olivier_bK> shevy, your french is not bad biloute
<olivier_bK> !
<olivier_bK> Mon_Ouie, thanks
Lewix has joined #ruby
iswell has joined #ruby
iswell has quit [Remote host closed the connection]
JasmeetQA has quit [Read error: Connection reset by peer]
Hobogrammer has quit [Ping timeout: 255 seconds]
warprobot has quit []
iamcalledrob has quit [Ping timeout: 264 seconds]
Hobogrammer_ has quit [Ping timeout: 264 seconds]
obs has joined #ruby
britneywright has joined #ruby
<olivier_bK> shevy, i going to watch if
RurouniJones has quit [Remote host closed the connection]
Lewix has quit [Ping timeout: 264 seconds]
shredding has quit [Quit: shredding]
ValicekB has joined #ruby
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
havenwood has joined #ruby
britneywright has quit [Client Quit]
mercwithamouth has joined #ruby
craigp has joined #ruby
AntelopeSalad has quit [Read error: Connection reset by peer]
ValicekB has quit []
yfeldblum has joined #ruby
AntelopeSalad has joined #ruby
roolo has joined #ruby
joonty has joined #ruby
duncannz has quit [Ping timeout: 240 seconds]
yfeldblum has quit [Ping timeout: 264 seconds]
Lewix has joined #ruby
iswell has joined #ruby
jarray52 has left #ruby [#ruby]
moritzs has joined #ruby
mehlah_ has joined #ruby
mehlah has quit [Read error: Connection reset by peer]
britneywright has joined #ruby
JoshGlzBrk has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sputnik13 has joined #ruby
ValicekB has joined #ruby
havenwood has quit [Ping timeout: 264 seconds]
ringarin has quit [Quit: Leaving]
roolo has quit [Quit: Leaving...]
Lewix has quit [Remote host closed the connection]
iswell has quit [Remote host closed the connection]
maximski has joined #ruby
roolo has joined #ruby
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
jespada has joined #ruby
mercwithamouth has quit [Ping timeout: 248 seconds]
phutchins has joined #ruby
AntelopeSalad has quit [Remote host closed the connection]
AntelopeSalad has joined #ruby
ARCADIVS has quit [Quit: WeeChat 0.4.3]
phoo1234567 has joined #ruby
phoo1234567 has quit [Max SendQ exceeded]
phoo1234567 has joined #ruby
andrewlio has joined #ruby
nateberkopec has joined #ruby
User458764 has joined #ruby
lolmaus has quit [Read error: Connection reset by peer]
decoponio has joined #ruby
Hanmac1 has joined #ruby
p0sixpscl has joined #ruby
Soda has joined #ruby
<olivier_bK> shevy, i see the passage get the cow lol...
nateberkopec has quit [Ping timeout: 240 seconds]
Hanmac has quit [Ping timeout: 260 seconds]
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
s34n_ has quit [Ping timeout: 252 seconds]
whyy has quit [Remote host closed the connection]
Takle has quit [Remote host closed the connection]
iamjarvo has joined #ruby
havenwood has joined #ruby
mercwithamouth has joined #ruby
yubrew has joined #ruby
uresu has joined #ruby
User458764 is now known as User458764_NotHe
yubrew has quit [Ping timeout: 252 seconds]
frankjpinto has quit [Ping timeout: 264 seconds]
s34n has joined #ruby
zegerjan has joined #ruby
dorei has joined #ruby
User458764_NotHe has quit [Ping timeout: 240 seconds]
whyy has joined #ruby
yfeldblum has joined #ruby
mercwithamouth has quit [Ping timeout: 248 seconds]
forkyou has joined #ruby
<forkyou> Python is better than Ruby!
iamcalledrob has joined #ruby
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<olivier_bK> shevy, the entrax castel
<olivier_bK> lol
ponga has quit [Remote host closed the connection]
havenwood has quit [Ping timeout: 264 seconds]
JasmeetQA has joined #ruby
<dorei> forkyou: and COBOL is better than Python ;-)
yfeldblum has quit [Ping timeout: 264 seconds]
<bhaak> >> "Python" > "Ruby"
<eval-in_> bhaak => false (https://eval.in/170019)
<bhaak> sorry, forkyou, you have to argue with eval-in_ about that
User458764 has joined #ruby
iamcalledrob has quit [Ping timeout: 264 seconds]
pvb has quit [Quit: Leaving]
postmodern has quit [Quit: Leaving]
alem0lars has quit [Quit: alem0lars]
ldnunes has joined #ruby
mehlah_ has quit [Quit: Leaving...]
Noob101 has quit [Ping timeout: 246 seconds]
Hanmac1 has quit [Remote host closed the connection]
maximski has quit []
Fire-Dragon-DoL has joined #ruby
iamjarvo has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
dc_ has joined #ruby
Hanmac has joined #ruby
Eiam has quit [Ping timeout: 260 seconds]
Takle has joined #ruby
kiri_ has joined #ruby
kiri has quit [Ping timeout: 248 seconds]
Jam_ has joined #ruby
bradleyprice has joined #ruby
perlsyntax has joined #ruby
anaeem1 has quit [Remote host closed the connection]
xcv has joined #ruby
User458764 is now known as User458764_NotHe
awkwords has joined #ruby
momomomomo has joined #ruby
pabloh has joined #ruby
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mconnolly has joined #ruby
bradleyprice has quit [Ping timeout: 272 seconds]
User458764_NotHe has quit [Ping timeout: 248 seconds]
aemeredith has quit []
jdripper has joined #ruby
forkyou has quit [Quit: leaving]
jerius has joined #ruby
arya__ has joined #ruby
xcv_ has joined #ruby
arya_ has quit [Ping timeout: 264 seconds]
jerius has quit [Client Quit]
xcv has quit [Ping timeout: 264 seconds]
iamjarvo has joined #ruby
JasmeetQA has quit [Read error: Connection reset by peer]
sk87 has joined #ruby
ValicekB has quit []
xcv_ has quit [Remote host closed the connection]
ndrei has quit [Ping timeout: 260 seconds]
nateberkopec has joined #ruby
razum2um1 has quit [Quit: Leaving.]
zegerjan has quit [Ping timeout: 255 seconds]
perlsyntax has left #ruby ["Textual IRC Client: www.textualapp.com"]
razum2um has joined #ruby
maximski has joined #ruby
britneywright has joined #ruby
<aep> anyone knows how to deploy a middleman built site in rack?
paulfm has joined #ruby
Joulse has joined #ruby
jespada has quit [Remote host closed the connection]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<Cork> Mon_Ouie: is it possible to reference nested hash values with %{} ?
<Cork> { p: { value: "me" } }
yubrew has joined #ruby
mehlah has joined #ruby
shredding has joined #ruby
<wasamasa> hmm
<wasamasa> how would I match either three or six occurrences of a glyph with regular expressions?
Jam_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Squarepy has quit [Ping timeout: 272 seconds]
<dorei> wasamasa: should it match 4 occurrences?
<wasamasa> no
<wasamasa> only three or six
* wasamasa is doing a validation regex for hex color codes
sputnik13 has joined #ruby
sputnik13 has quit [Max SendQ exceeded]
sputnik13 has joined #ruby
sameerynho has joined #ruby
sameerynho has quit [Read error: Connection reset by peer]
<bhaak> aep: usually, you don't want the rack-based web server to serve your static content. but this might help do it if you really want to: https://devcenter.heroku.com/articles/static-sites-ruby
<aep> well ... heroku
bogeyd6 has quit [Read error: Connection reset by peer]
<aep> nah that one didnt work for me
yubrew has quit [Ping timeout: 264 seconds]
<wasamasa> >> "#FFFF"[/^#[0-9a-fA-F]{3}?[0-9a-fA-F]{3}$/]
<eval-in_> wasamasa => nil (https://eval.in/170040)
<wasamasa> >> "#FFF"[/^#[0-9a-fA-F]{3}?[0-9a-fA-F]{3}$/]
<eval-in_> wasamasa => "#FFF" (https://eval.in/170041)
lxsameer has quit [Ping timeout: 252 seconds]
<apeiros> "#FFF"[/^#\h{3}?\h{3}$/]
<apeiros> >> "#FFF"[/^#\h{3}?\h{3}$/]
<eval-in_> apeiros => "#FFF" (https://eval.in/170042)
<apeiros> less verbose
<wasamasa> oh nice
felipe has quit [Ping timeout: 252 seconds]
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
yfeldblum has joined #ruby
_whitelogger_ has joined #ruby
mroth has joined #ruby
daxroc_ has joined #ruby
drager_ has joined #ruby
dacamp_ has joined #ruby
comma8 has quit [Ping timeout: 252 seconds]
bauruine has quit [Ping timeout: 252 seconds]
Nightmare has quit [Ping timeout: 252 seconds]
nighter has quit [Ping timeout: 252 seconds]
nifty has joined #ruby
gyre007 has joined #ruby
andrewcarter has joined #ruby
cbetta has joined #ruby
adambeynon has joined #ruby
maloik_ has joined #ruby
nighter has joined #ruby
destructure has joined #ruby
Nightmare has joined #ruby
yo61 has joined #ruby
metadave has joined #ruby
jeffreybaird_ has joined #ruby
zzak__ has joined #ruby
haroldwu_ has joined #ruby
pdtpatr11k has joined #ruby
pipework has quit [Ping timeout: 245 seconds]
Nilium has quit [Ping timeout: 245 seconds]
DrCode has quit [Ping timeout: 264 seconds]
tacos1de has quit [Ping timeout: 264 seconds]
Kovensky has quit [Ping timeout: 245 seconds]
jso has quit [Ping timeout: 245 seconds]
jaredrhine has quit [Ping timeout: 245 seconds]
spacemud has quit [Ping timeout: 245 seconds]
vlad_starkov has quit [Ping timeout: 245 seconds]
seanmarcia has quit [Ping timeout: 245 seconds]
St_Marx has quit [Ping timeout: 264 seconds]
atmosx has quit [Ping timeout: 264 seconds]
nuck has quit [Ping timeout: 245 seconds]
stopbit has quit [Ping timeout: 245 seconds]
kaichanvong has quit [Ping timeout: 245 seconds]
go|dfish has quit [Ping timeout: 245 seconds]
emdub_ has quit [Ping timeout: 245 seconds]
kiki_lamb has quit [Ping timeout: 245 seconds]
isomorphismes has quit [Ping timeout: 245 seconds]
jwang has quit [Ping timeout: 245 seconds]
joast has quit [Ping timeout: 245 seconds]
gregf_ has quit [Ping timeout: 245 seconds]
sarlalian has quit [Ping timeout: 245 seconds]
Pro| has quit [Ping timeout: 245 seconds]
end_guy has quit [Ping timeout: 264 seconds]
exgf has quit [Ping timeout: 264 seconds]
pdtpatr1ck has quit [Ping timeout: 245 seconds]
jameyd has quit [Ping timeout: 245 seconds]
maloik has quit [Ping timeout: 245 seconds]
rblackwe has quit [Ping timeout: 245 seconds]
drager has quit [Ping timeout: 245 seconds]
destruct1re has quit [Ping timeout: 245 seconds]
dacamp has quit [Ping timeout: 245 seconds]
haroldwu has quit [Ping timeout: 245 seconds]
Schmidt has quit [Ping timeout: 245 seconds]
mumblerit has quit [Ping timeout: 245 seconds]
pipecloud is now known as pipework
skmp has joined #ruby
im0b has joined #ruby
alol__ has quit [Changing host]
alol__ has joined #ruby
ramblinpeck has joined #ruby
ramblinpeck has quit [Changing host]
leslie has joined #ruby
mroth has quit [Changing host]
mroth has joined #ruby
daxroc_ has quit [Changing host]
vlad_sta- has joined #ruby
daxroc_ has joined #ruby
sumark has joined #ruby
nifty has quit [Changing host]
nifty has joined #ruby
yo61 has quit [Changing host]
yo61 has joined #ruby
gyre007 has quit [Changing host]
gyre007 has joined #ruby
adambeynon has quit [Changing host]
adambeynon has joined #ruby
cbetta has quit [Changing host]
cbetta has joined #ruby
andrewcarter has joined #ruby
andrewcarter has quit [Changing host]
zzak__ has quit [Changing host]
zzak__ has joined #ruby
jeffreybaird_ has joined #ruby
metadave has joined #ruby
jeffreybaird_ has quit [Changing host]
metadave has quit [Changing host]
skmp has quit [Changing host]
skmp has joined #ruby
im0b has quit [Changing host]
im0b has joined #ruby
Nilium has joined #ruby
Schmidt has joined #ruby
yfeldblum has quit [Ping timeout: 272 seconds]
l3kn has joined #ruby
jameyd has joined #ruby
LBRapid has joined #ruby
DarkFoxDK has joined #ruby
K3dare has joined #ruby
bubbajones has joined #ruby
canton7 has joined #ruby
jso has joined #ruby
Affix has joined #ruby
RoryHughes has joined #ruby
go|dfish has joined #ruby
ndrei has joined #ruby
bauruine has joined #ruby
stopbit has joined #ruby
mumblerit has joined #ruby
sarlalian has joined #ruby
seanmarcia has joined #ruby
ValicekB has joined #ruby
mumblerit is now known as Guest25761
snath has quit [Ping timeout: 248 seconds]
Kovensky has joined #ruby
nisstyre has joined #ruby
jwang has joined #ruby
nuck has joined #ruby
kaichanvong has joined #ruby
spacemud has joined #ruby
Norrin has joined #ruby
ggherdov has joined #ruby
xcv has joined #ruby
chipotle has joined #ruby
comma8 has joined #ruby
poimen has joined #ruby
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Dwarf has joined #ruby
Channel6 has joined #ruby
tokik has quit [Ping timeout: 264 seconds]
vifino has joined #ruby
iamjarvo has joined #ruby
eka has quit [Quit: My computer has gone to sleep. ZZZzzz…]
chipotle has quit [Quit: cya]
vifino has quit [Remote host closed the connection]
vifino has joined #ruby
wildroman2 has quit [Remote host closed the connection]
arya__ has quit [Ping timeout: 264 seconds]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jokke has quit [Ping timeout: 260 seconds]
jokke has joined #ruby
himsin has quit [Quit: himsin]
syedasad has joined #ruby
syedasad has left #ruby [#ruby]
RandyT has quit [Ping timeout: 272 seconds]
oo_ has quit [Remote host closed the connection]
rdark has quit [Quit: leaving]
wildroman2 has joined #ruby
vadzimt has joined #ruby
rdark has joined #ruby
Takle has quit [Remote host closed the connection]
ndrei has quit [Ping timeout: 264 seconds]
mconnolly has quit [Quit: mconnolly]
RandyT has joined #ruby
mconnolly has joined #ruby
mconnolly has quit [Client Quit]
mconnolly has joined #ruby
starkhalo has joined #ruby
bmurt has joined #ruby
DivineEntity has quit [Quit: leaving]
camilasan has quit [Ping timeout: 240 seconds]
gruz0[russia] has joined #ruby
mconnolly has quit [Client Quit]
mconnolly has joined #ruby
doritostains has joined #ruby
techsethi has quit [Quit: techsethi]
Sammael has joined #ruby
ndrei has joined #ruby
doritostains has quit [Read error: Connection reset by peer]
doritostains has joined #ruby
dblessing has joined #ruby
iamcalledrob has joined #ruby
Takle has joined #ruby
qwyeth has joined #ruby
yubrew has joined #ruby
stylus has quit [Ping timeout: 272 seconds]
charliesome has joined #ruby
mconnolly has quit [Quit: mconnolly]
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mconnolly has joined #ruby
mengu has quit [Remote host closed the connection]
Zenigor has joined #ruby
joast has joined #ruby
yubrew has quit [Ping timeout: 264 seconds]
lw has joined #ruby
snath has joined #ruby
fwaokda has quit [Ping timeout: 264 seconds]
philevans_ has joined #ruby
binaryhat has quit [Ping timeout: 264 seconds]
<philevans_> I am using Ruby 2.1.2 in Linux. I am writing 1MB of data at a time to a file using File.write. It keeps using up all of the memory. I have narrowed it down to the File.write using up the memory. The memory used seems to tally with the amount of data being written. Any ideas?
mengu has joined #ruby
mengu has joined #ruby
mengu has quit [Changing host]
craigp has quit [Remote host closed the connection]
<bmurt> philevans_: all of the memory?
<bmurt> what do you mean
yfeldblum has joined #ruby
<philevans_> bmurt: Well it uses up about 6-8GB and then craps out with an out of memory exception
<philevans_> bmurt: It's a 128GB machine with nothing else running on it
<bmurt> are you closing after each write?
<philevans_> bmurt: No
<philevans_> I do a seek before every write
<philevans_> but I've confirmed that does not affect memory
kirun has joined #ruby
krz has quit [Quit: WeeChat 0.4.3]
kaspergrubbe has joined #ruby
yfeldblum has quit [Ping timeout: 252 seconds]
doritostains has quit [Read error: Connection reset by peer]
britneywright has joined #ruby
doritostains has joined #ruby
whowantstolivefo has quit [Ping timeout: 255 seconds]
craigp has joined #ruby
<toretore> philevans_: code?
iamjarvo has joined #ruby
<philevans_> Its very long winded as I was trying desperately to put things in to stop it using all the memory
djcp has joined #ruby
fwaokda has joined #ruby
dblessing has quit [Quit: dblessing]
<toretore> do you have some data i can run this with?
meinside has quit [Quit: Connection closed for inactivity]
ffranz has joined #ruby
alexju has joined #ruby
Hanmac1 has joined #ruby
dblessing has joined #ruby
<philevans_> Well the data is GBs
<philevans_> coming from stdout of another process
<toretore> ok
<philevans_> Let me see if I can reproduce with a simplified version...
yfeldblum has joined #ruby
sailias has joined #ruby
djcp has left #ruby ["WeeChat 0.4.3"]
yfeldblu_ has joined #ruby
Hanmac has quit [Ping timeout: 260 seconds]
jerius has joined #ruby
Channel6 has quit [Quit: Leaving]
jerius has quit [Client Quit]
iamcalledrob has quit [Quit: Computer has gone to sleep.]
jerius has joined #ruby
<toretore> are you on windows?
xcv has quit [Remote host closed the connection]
<philevans_> no, Linux
CorpusCallosum has joined #ruby
<toretore> then there's no use for the b mode
<toretore> in File.new
xcv has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
devdazed has quit [Quit: Bye]
ylluminate has quit [Remote host closed the connection]
ylluminate has joined #ruby
yfeldblu_ has quit [Ping timeout: 252 seconds]
<philevans_> Yeah I know that now - but that should just be ignored
bradleyprice has joined #ruby
<philevans_> if you make an empty file and run that with "-f <filename>" it will create a 16GB file but also fills up memory
<philevans_> used about 12GB RAM on mine
mrmargolis has joined #ruby
<philevans_> although -buffers/cache was OK - but it still eventually craps out with too much
Takle has quit [Remote host closed the connection]
nateberkopec has quit [Quit: Leaving...]
Quintus_q has joined #ruby
devdazed has joined #ruby
failshell has joined #ruby
nateberkopec has joined #ruby
sevenseacat has quit [Remote host closed the connection]
workmad3 has joined #ruby
bradleyprice has quit [Ping timeout: 272 seconds]
SilverKey has joined #ruby
haroldwu_ is now known as haroldwu
haroldwu has quit [Changing host]
haroldwu has joined #ruby
CorpusCallosum has quit [Ping timeout: 264 seconds]
Takle has joined #ruby
alem0lars has joined #ruby
freerobby has joined #ruby
Takle has quit [Remote host closed the connection]
Quintus_q has quit [Quit: WeeChat 0.4.3]
eka has joined #ruby
SBoolean has joined #ruby
eka has quit [Client Quit]
atmosx has joined #ruby
Takle has joined #ruby
<shevy> wow
<shevy> 12 gig
<shevy> your machine is on steroids philevans_
volk_ has joined #ruby
<Edelwin> :')
andrewhl has joined #ruby
_justin has quit [Quit: _justin]
zkay11 has joined #ruby
duggiefresh has joined #ruby
guinslym has joined #ruby
whyy has quit [Remote host closed the connection]
tesuji has quit [Ping timeout: 272 seconds]
<bmurt> shevy: he gets paid the big bucks
mattstratton has joined #ruby
Takle has quit [Remote host closed the connection]
dacamp_ is now known as dacamp
britneywright has quit [Ping timeout: 272 seconds]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<shevy> yeah
Joulse has quit [Quit: Joulse]
<shevy> damn those ferrari drivers
britneywright has joined #ruby
iamjarvo has joined #ruby
tus has joined #ruby
yubrew has joined #ruby
lemur has joined #ruby
<shevy> I'm gonna replace all my shell scripts with ruby scripts
Joulse has joined #ruby
vyorkin has quit [Ping timeout: 248 seconds]
kevind has joined #ruby
orlyyy has joined #ruby
ntz has joined #ruby
<ntz> hello
GeraldoRamos has joined #ruby
<orlyyy> hi
yubrew has quit [Ping timeout: 264 seconds]
<orlyyy> any web application developers here?
mikesplain has joined #ruby
SilverKey has quit [Quit: Halted.]
<ntz> I can't programme in ruby (yet) but now I need to write do some analysis .. can you please show me a ruby equivalent of this perl's >>perl -e 'print join("\n", stat("/etc/hosts"))'<< one-liner ?
<ntz> s/do some/some/
maximski has quit []
<wasamasa> orlyyy: think about it, how unlikely is it that there is not a single one web application developer in here
<orlyyy> I need someone who is willing to do some freelance work
CorpusCallosum has joined #ruby
<orlyyy> i have a small app/website that I need to be looked at
theharshest has joined #ruby
_justin has joined #ruby
GeraldoRamos has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Hanmac has joined #ruby
treehug88 has joined #ruby
wildroman2 has quit [Remote host closed the connection]
RaCx has joined #ruby
acconrad has quit [Quit: acconrad]
yfeldblum has joined #ruby
Hanmac1 has quit [Ping timeout: 252 seconds]
<Mattias> is Net::FTPTLS gone in ruby 2.0.0? What could I use instead for FTP with TLS?
nanodano has quit [Quit: Leaving.]
CingulateCortex has joined #ruby
theharshest has quit [Quit: This computer has gone to sleep]
SilverKey has joined #ruby
<workmad3> Mattias: looks like it went in 1.9.3
doritostains has quit [Quit: Leaving...]
<wasamasa> ntz: you can do something like `ruby -e 'puts File.stat("/etc/hosts").inspect'`
CorpusCallosum has quit [Read error: Connection reset by peer]
<wasamasa> ntz: which isn't an exact equivalent of the perl oneliner
<toretore> philevans_: works fine here. writes the 16gb without problems with 4gb ram
krz has joined #ruby
yubrew has joined #ruby
alem0lars has quit [Quit: Going AFK...]
tagrudev has quit [Quit: Me = Awesome]
tus has quit [Remote host closed the connection]
<ntz> wasamasa: okay, thanks
yfeldblum has quit [Ping timeout: 252 seconds]
<ntz> wasamasa: lemme test your command
tobago has quit [Remote host closed the connection]
_justin has quit [Quit: _justin]
wildroman2 has joined #ruby
wildroman2 has quit [Remote host closed the connection]
<ntz> wasamasa: okay, it's almost what i'd wanted :) however I'd prefer c-like stats without any postprocessing
<gregf__> ntz: f = File.stat("/etc/hosts"); puts %w{ dev ino mode nlink uid gid rdev size size atime mtime ctime blksize blocks }.map { |meth| "#{meth} - " + f.send(meth).to_s }
<ntz> thanks much !!!!
mengu has quit [Remote host closed the connection]
wildroman2 has joined #ruby
<wasamasa> gregf__: you've got size twice there
doritostains has joined #ruby
<ntz> two sizes are better than no size :)
chipotle has joined #ruby
Takle has joined #ruby
janfri has joined #ruby
craigp has quit [Remote host closed the connection]
chipotle has quit [Client Quit]
<wasamasa> the output is pretty much the same except for the prettier timestamps and column names
Squarepy has joined #ruby
vyorkin has joined #ruby
CingulateCortex has quit [Ping timeout: 264 seconds]
<gregf__> yeah :/; s/size size/size/
_maes_ has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
RaCx has quit [Quit: Computer has gone to sleep.]
janfri has left #ruby [#ruby]
banister has joined #ruby
Takle has quit [Ping timeout: 272 seconds]
britneywright has quit [Ping timeout: 272 seconds]
<ntz> gregf__: pff .. nice, your output is great .. may I request only changing that postprocessing of date strings to human readable format to the form as it is raw read from the file ?
<wasamasa> ntz: it's not postprocessed
craigp has joined #ruby
britneywright has joined #ruby
<wasamasa> at least not voluntary :P
<ntz> it must be .. C/perl returns just what ``perl -e 'print join("\n", stat("/etc/hosts"))''' prints out
yfeldblum has joined #ruby
tus has joined #ruby
<ntz> ok, thanks much chan !!
<ntz> gonna to read that
vyorkin has quit [Ping timeout: 248 seconds]
<wasamasa> read its sources
ssarah has quit [Ping timeout: 246 seconds]
mbwe has quit [Quit: WeeChat 0.4.2]
fjfish has joined #ruby
Zenigor has quit [Remote host closed the connection]
francisfish has quit [Ping timeout: 264 seconds]
jaimef has quit [Excess Flood]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Takle has joined #ruby
SBoolean has quit [Ping timeout: 240 seconds]
nasj has quit []
jaimef has joined #ruby
RaCx has joined #ruby
<olivier_bK> how i can gsub this ’ because when i try with ( ' ` ) or another one its 's but with this thing i get an error
<Mattias> workmad3: Yeah, looks like it. Couldn't find anything else which could also ignore certs. Python seems to have ftp with tls support built-in so I went with that and it works now :)
<olivier_bK> .gsub( / [ ' ] / , " ") it's okai
<workmad3> Mattias: don't ignore certs
_justin has joined #ruby
<ericwood> I always ignore certs for one-off scripts
claymore has quit [Ping timeout: 248 seconds]
<ericwood> open-uri ignores certs by default iirc
<Mattias> workmad3: it's a self-signed cert, and I only download from my own ftp server.
_justin has quit [Remote host closed the connection]
<workmad3> Mattias: so install the cert into the local cert repository
rayners has joined #ruby
aganov has quit [Remote host closed the connection]
<ericwood> Mattias: do it, workmad3 will MitM you D:
<workmad3> ericwood: ^^ :D
<ericwood> we take teaching people a lesson very seriously here
<Mattias> workmad3: Don't you need a CA which also costs?
<ericwood> we will destroy you
<workmad3> Mattias: no
ntz has left #ruby [#ruby]
<Mattias> So there is something I don't know yet :) Tell me more
<ericwood> Mattias: if you add your self-signed certs to the certs repo on your machine you're fine
CingulateCortex has joined #ruby
<ericwood> you have to say "HEY I trust this one"
<Mattias> Ah, I fully understand now
<Mattias> Of course I could do that :) kind of like how /etc/hosts works for domains
<ericwood> if you're on OS X you can do that via the keychain app
<ericwood> well
<ericwood> eh I forget ignore me
volk_ has quit [Quit: volk_]
<workmad3> Mattias: the only thing 'special' about a CA is that they have root certificates that are already in most certificate bundles ;)
oo_ has joined #ruby
volk_ has joined #ruby
<workmad3> Mattias: what you pay for with a commercial CA is then mostly insurance ;)
CingulateCortex is now known as CorpusCallosum
SBoolean has joined #ruby
Guest25761 is now known as mumblerit
<Mattias> Still, couldn't find a working ftp tls lib for ruby 2 :)
<workmad3> Mattias: could be they removed it in favour of people just using sftp ;)
<Mattias> Might be ^.^
<ericwood> sftp plz
<workmad3> Mattias: any reason not to use sftp on your own server?
<Mattias> I'm 50% sftp
<Mattias> sftp I don't know how to make virtual servers on
<Mattias> Some servers I have uses only sftp
<Mattias> virtual users on***
<ericwood> tbh all servers should only use sftp ever
<shevy> can we use ruby + sftp?
<Mattias> Tell me how to create a virtual user in sftp and I'll switch :)
<ericwood> you can do whatever you want
<workmad3> Mattias: pam
Zenigor has joined #ruby
alexherbo2 has quit [Quit: WeeChat 0.4.3]
<Mattias> pam can do that? O.o *investigates*
thesheff17 has joined #ruby
alexherbo2 has joined #ruby
obs has quit [Ping timeout: 255 seconds]
<workmad3> Mattias: I don't know exactly *how*... but sftp is over SSH, SSH uses (or can use) PAM, and PAM can do pretty much anything you want with user management ;)
zz_jrhorn424 is now known as jrhorn424
Senjai has left #ruby ["WeeChat 0.3.7"]
stytown has joined #ruby
obs has joined #ruby
<workmad3> Mattias: hell, searching for 'virtual users sftpd' gives you lots of links to 'https://help.ubuntu.com/community/vsftpd' and similar
devdazed has quit [Read error: Connection reset by peer]
* Mattias takes this new info to the lab server!
bal has quit [Quit: bal]
devdazed has joined #ruby
bal has joined #ruby
<workmad3> ah, vsftpd doesn't do sftp... stupid convergence of acronyms
DivineEntity has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
<shevy> haha!
binaryhat has joined #ruby
<wasamasa> workmad3: it stands for "Very secure FTP daemon"
Soda has quit [Remote host closed the connection]
stytown has quit [Ping timeout: 252 seconds]
<wasamasa> workmad3: which has nothing to do with actually secure ftp
claymore has joined #ruby
<workmad3> wasamasa: yeah, I see that now :P
<wasamasa> as guaranteed by using ssh
<wasamasa> because sftp is using ssh for ftp-like transfer of files
<workmad3> wasamasa: yeah... I know that :P
voodoofish has quit [Ping timeout: 248 seconds]
bal has quit [Quit: bal]
subraminion has joined #ruby
voodoofish has joined #ruby
subraminion has quit [Remote host closed the connection]
subraminion has joined #ruby
subraminion has quit [Changing host]
subraminion has joined #ruby
banister has joined #ruby
IceDragon has joined #ruby
jokke has quit [Quit: WeeChat 0.4.3]
banister has quit [Client Quit]
jezen has joined #ruby
apeiros has quit [Remote host closed the connection]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jokke has joined #ruby
apeiros has joined #ruby
RaCx has joined #ruby
enebo has joined #ruby
terrellt has joined #ruby
stytown has joined #ruby
doritostains has quit [Quit: Leaving...]
iamjarvo has joined #ruby
robertodecurnex has joined #ruby
techsethi has joined #ruby
hamakn has quit [Remote host closed the connection]
darkxploit has joined #ruby
apeiros has quit [Ping timeout: 248 seconds]
buub has joined #ruby
craigp has quit [Remote host closed the connection]
orlyyy has quit [Quit: http://www.kiwiirc.com/ - A hand crafted IRC client]
disorder20 has joined #ruby
<disorder20> hello, I'm studying ruby
<disorder20> is it possible to add a method to a class previously defined?
ndrei has quit [Ping timeout: 260 seconds]
xaxisx has joined #ruby
<csmrfx> yes
hgl has joined #ruby
<disorder20> let's say A is a class previously defined
<olivier_bK> how i can remove this character ’ its not a '
banjara has joined #ruby
<disorder20> do I just use class A ..... end ?
orionstein_away is now known as orionstein
jxf has joined #ruby
maximski has joined #ruby
fabrice31 has quit [Remote host closed the connection]
hgl has quit [Client Quit]
fabrice31 has joined #ruby
hgl has joined #ruby
hgl has quit [Max SendQ exceeded]
jezen is now known as jgt
lepht_ has joined #ruby
xcv has quit [Remote host closed the connection]
banjara1 has joined #ruby
hgl has joined #ruby
kiri_ has quit [Quit: Leaving]
hgl has quit [Max SendQ exceeded]
hgl has joined #ruby
banjara has quit [Read error: Connection reset by peer]
fabrice31 has quit [Ping timeout: 240 seconds]
<dorei> olivier_bK: some_str.gsub('’', '')
lepht_ is now known as lepht
<dorei> olivier_bK: i've just copy-pasted your character between the first pair of ' '
oo_ has quit [Remote host closed the connection]
Atttwww has joined #ruby
oo_ has joined #ruby
lolmaus has joined #ruby
rippa has joined #ruby
rebelshrug has joined #ruby
banjara1 has quit [Quit: Leaving.]
schaerli has quit [Remote host closed the connection]
_maes_ has joined #ruby
jfran has joined #ruby
cocotton has joined #ruby
havenn has joined #ruby
moted has joined #ruby
chipotle has joined #ruby
CaptainJet has joined #ruby
jgt has quit []
hgl has quit [Quit: Computer has gone to sleep.]
RaCx has quit [Quit: Computer has gone to sleep.]
Joulse has quit [Quit: Joulse]
IceDragon has quit [Ping timeout: 240 seconds]
maximski has quit [Read error: Connection reset by peer]
IceDragon has joined #ruby
uresu has quit [Quit: uresu]
sinfex has joined #ruby
sinfex has left #ruby [#ruby]
bradleyprice has joined #ruby
maximski has joined #ruby
nfk has quit [Ping timeout: 240 seconds]
guinslym has quit [Quit: Leaving]
banister has joined #ruby
theharshest has joined #ruby
apeiros has joined #ruby
Takle has quit [Remote host closed the connection]
Urocyon is now known as sfiggins
bradleyprice has quit [Ping timeout: 248 seconds]
T_Hunt has joined #ruby
<olivier_bK> dorei, i try to
<olivier_bK> i get the same error
nfk has joined #ruby
dideler has joined #ruby
yalue has joined #ruby
banjara has joined #ruby
maximski has quit []
Guest89056 has joined #ruby
havenn has quit [Quit: Leaving...]
mgberlin has joined #ruby
banjara has quit [Client Quit]
mconnolly has quit [Ping timeout: 255 seconds]
havenn has joined #ruby
godd2 has joined #ruby
felipe has joined #ruby
mconnolly has joined #ruby
dideler has quit [Ping timeout: 248 seconds]
geggam has joined #ruby
hamakn has joined #ruby
senayar has quit [Remote host closed the connection]
anarang has quit [Quit: Leaving]
senayar has joined #ruby
<aep> when just using rack, where do i get the env from in map '/' do {} ?
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
wldcordeiro has quit [Remote host closed the connection]
frankjpinto has joined #ruby
xaxisx has quit [Quit: xaxisx]
mconnolly has quit [Ping timeout: 255 seconds]
bradhe has joined #ruby
endash has quit [Quit: endash]
mgberlin has quit [Remote host closed the connection]
senayar has quit [Ping timeout: 252 seconds]
maoko has joined #ruby
shredding has quit [Quit: shredding]
frankjpinto_ has joined #ruby
<apeiros> aep: probably as the first param
<aep> nope
workmad3 has quit [Ping timeout: 255 seconds]
<apeiros> also it's either do/end or {}, not both
cocotton has quit [Remote host closed the connection]
brasten has joined #ruby
obs has quit [Quit: Konversation terminated!]
mconnolly has joined #ruby
<aep> map '/' {|x| will complain about wrong number of arguments
Takle has joined #ruby
mikepack has joined #ruby
<apeiros> going to the docs, http://rubydoc.info/github/rack/rack/Rack/Builder#map-instance_method , it shows me that you do: `map path do; run rackapp; end`
<apeiros> and rackapp is the common "anything responding to call" which gets the env as the first arg
xcv has joined #ruby
terrell_t has joined #ruby
frankjpinto has quit [Ping timeout: 264 seconds]
abilon has joined #ruby
<aep> yeah
terrellt has quit [Disconnected by services]
terrell_t is now known as terrellt
<aep> i think what i'm trying is wrong anyway because the map thing isnt re-evaluated for each request
<aep> so obviousl there is no env
workmad3 has joined #ruby
workmad3 has quit [Client Quit]
Hobogrammer has joined #ruby
<aep> is there a better way to wrap another middleware?
workmad3 has joined #ruby
awkwords has quit [Ping timeout: 248 seconds]
RaCx has joined #ruby
<aep> subclassing didnt work for me
yfeldblum has quit [Ping timeout: 255 seconds]
GeorgesLeYeti has joined #ruby
<GeorgesLeYeti> Hi
<GeorgesLeYeti> I have an array of hash with title and created_at
<GeorgesLeYeti> I want to return each title in a string order by created_at
<GeorgesLeYeti> Not sure if it's clear
bluOxigen has quit [Ping timeout: 264 seconds]
<apeiros> aep: write a middleware. or define "wrap".
jxf has quit [Ping timeout: 264 seconds]
<apeiros> GeorgesLeYeti: see Array#sort_by and Array#map
<GeorgesLeYeti> I find the way to order (sort_by!{|hsh| hsh[:created_at]}
<GeorgesLeYeti> ok
<ericwood> why not say hash
<apeiros> your sort_by looks correct
<ericwood> you're not saving much space by leaving out that a
<apeiros> ericwood: vowel cost $200 apiece
<ericwood> ouch
<godd2> shh
<aep> eh duh, i can have my middleware be called before the other one. i didnt get that
<havenn> my biggest problem with middleware is accidentally calling it middlewear
<shevy> it's like unix pipe chaining
bradhe has quit [Remote host closed the connection]
<shevy> how would you call middleware that is under, Havenn?
havenn is now known as havenwood
<shevy> wow
<shevy> we have a yeti here
<shevy> GeorgesLeYeti
<shevy> I applaude all my furry friends to program in ruby
<GeorgesLeYeti> :D
tvw has quit []
peret has joined #ruby
frankjpinto__ has joined #ruby
edgarjs_afk is now known as edgarjs
Royalb15_1 has joined #ruby
bradhe has joined #ruby
Zebroid has joined #ruby
alex88 has quit [Quit: Leaving...]
foo-bar- has joined #ruby
Royalb15 has quit [Ping timeout: 260 seconds]
frankjpinto_ has quit [Ping timeout: 264 seconds]
tacos1de has joined #ruby
dumdedum has quit [Quit: foo]
Takle has quit [Remote host closed the connection]
havenn has joined #ruby
CodeLicker has quit [Read error: Connection reset by peer]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
DrCode has joined #ruby
pietr0 has joined #ruby
exgf has joined #ruby
Zebroid has quit [Ping timeout: 240 seconds]
Takle has joined #ruby
doritostains has joined #ruby
acconrad has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
Spleeze has quit [Ping timeout: 240 seconds]
kaspergrubbe has quit [Remote host closed the connection]
havenwood has quit [Quit: Leaving...]
drawingthesun has quit [Quit: Leaving]
andrewhl has quit [Quit: andrewhl]
bricker`work has joined #ruby
Takle has quit [Ping timeout: 264 seconds]
cearls has joined #ruby
olivier_bK has quit [Ping timeout: 264 seconds]
Spleeze has joined #ruby
awkwords has joined #ruby
Ankhers has joined #ruby
ephemerian has quit [Quit: Leaving.]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ctp_ has joined #ruby
mjsmith2 has joined #ruby
j416 has joined #ruby
p0sixpscl has quit [Quit: p0sixpscl]
kireevco has joined #ruby
CodeLicker has joined #ruby
mattstratton has joined #ruby
ctp has quit [Ping timeout: 272 seconds]
troyready has joined #ruby
Dwarf has quit [Ping timeout: 272 seconds]
FDj has joined #ruby
craigp has joined #ruby
timonv has quit [Remote host closed the connection]
<daxroc_> Are there anytools to debug a gem repository?
end_guy has joined #ruby
<ericwood> irb/pry
<daxroc_> I get the error Gem::RemoteFetcher::FetchError: server did not return a valid file (http://mine/repo/infra/trunk/rubygems/specs.4.8.gz)
dapz has joined #ruby
Spleeze has quit [Excess Flood]
aspires has joined #ruby
cearls has quit [Remote host closed the connection]
stytown has quit [Quit: stytown]
cearls has joined #ruby
Ankhers has quit [Remote host closed the connection]
cearls has quit [Read error: Connection reset by peer]
andrewhl has joined #ruby
maximski has joined #ruby
deric_skibotn has joined #ruby
cearls has joined #ruby
Spleeze has joined #ruby
callumacrae is now known as nub
wildroman2 has quit [Ping timeout: 260 seconds]
<shevy> hmm
<shevy> perhaps your connection was flakey at the time
relix has joined #ruby
<shevy> that is a weird repo though
Aryasam has joined #ruby
xaxisx has joined #ruby
yfeldblum has joined #ruby
<daxroc_> It's a custom repo created with gem generate_index
d0lph1n98 has joined #ruby
Xeago has quit [Remote host closed the connection]
wallerdev has joined #ruby
ghr has quit [Ping timeout: 272 seconds]
LiohAu has quit [Quit: LiohAu]
mikecmpbll has quit [Ping timeout: 264 seconds]
Zebroid has joined #ruby
oo_ has quit [Remote host closed the connection]
Hanmac1 has joined #ruby
wallerdev has quit [Client Quit]
elaptics is now known as elaptics`away
timfoo has quit [Ping timeout: 255 seconds]
stytown has joined #ruby
pabloh has quit [Remote host closed the connection]
yfeldblum has quit [Ping timeout: 264 seconds]
User458764 has joined #ruby
Hanmac has quit [Ping timeout: 248 seconds]
djbkd has joined #ruby
sigurding has joined #ruby
kevind_ has joined #ruby
Soda has joined #ruby
vyorkin has joined #ruby
doritostains has quit [Ping timeout: 248 seconds]
craigp has quit [Remote host closed the connection]
Zebroid has quit [Ping timeout: 264 seconds]
aspires has quit []
kevind has quit [Ping timeout: 248 seconds]
kevind_ is now known as kevind
mikecmpbll has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
kireevco has quit [Read error: Connection reset by peer]
shanlar has joined #ruby
kireevco has joined #ruby
cocotton has joined #ruby
cocotton has quit [Remote host closed the connection]
cocotton has joined #ruby
moritzs has quit [Ping timeout: 272 seconds]
IcyDragon has joined #ruby
LiohAu has joined #ruby
carlo has joined #ruby
LiohAu has quit [Client Quit]
IceDragon has quit [Ping timeout: 255 seconds]
carlo is now known as Guest27310
dangerousdave has joined #ruby
x1337807x has joined #ruby
LiohAu has joined #ruby
d0lph1n98 has quit [Ping timeout: 264 seconds]
IcyDragon is now known as IceDragon
goganchic has joined #ruby
cocotton has quit [Remote host closed the connection]
Squarepy has quit [Quit: Leaving]
craigp has joined #ruby
cocotton_ has joined #ruby
cocotton_ has quit [Remote host closed the connection]
aspires has joined #ruby
kaspergrubbe has joined #ruby
cocotton has joined #ruby
dangerou_ has quit [Ping timeout: 264 seconds]
schaerli has joined #ruby
Ankhers has joined #ruby
timfoo has joined #ruby
jhass|off is now known as jhass
iamjarvo has joined #ruby
jaimef has quit [Excess Flood]
jaimef has joined #ruby
carraroj has joined #ruby
Poky has quit [Remote host closed the connection]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
poppingtonic has joined #ruby
chipotle has quit [Quit: cya]
LadyRainicorn has joined #ruby
klaut has quit [Remote host closed the connection]
Hobogrammer has quit [Ping timeout: 240 seconds]
mijicd has joined #ruby
saarinen has joined #ruby
saarinen has quit [Client Quit]
baroquebobcat has joined #ruby
baroquebobcat has quit [Client Quit]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
saarinen has joined #ruby
LadyRainicorn has quit [Read error: Connection reset by peer]
poppingtonic has quit [Read error: Connection reset by peer]
djbkd has quit [Remote host closed the connection]
LadyRainicorn has joined #ruby
qhartman has joined #ruby
jespada has joined #ruby
djbkd has joined #ruby
vyorkin has quit [Ping timeout: 264 seconds]
sigurding has quit [Quit: sigurding]
terrellt has quit [Remote host closed the connection]
Prandium has quit [Quit: Prandium]
dapz has joined #ruby
edgarjs is now known as edgarjs_afk
baroquebobcat has joined #ruby
banjara has joined #ruby
failshel_ has joined #ruby
cocotton has quit [Remote host closed the connection]
bradhe has quit [Remote host closed the connection]
banjara has quit [Client Quit]
terrellt has joined #ruby
banjara has joined #ruby
x1337807x has joined #ruby
cocotton has joined #ruby
terrellt has quit [Read error: Connection reset by peer]
terrellt has joined #ruby
failshe__ has joined #ruby
failshel_ has quit [Read error: Connection reset by peer]
cocotton has quit [Read error: Connection reset by peer]
disorder20 has quit [Ping timeout: 272 seconds]
cearls has quit [Remote host closed the connection]
cocotton has joined #ruby
banjara has quit [Client Quit]
cearls has joined #ruby
ghr has joined #ruby
baroquebobcat_ has joined #ruby
failshell has quit [Ping timeout: 264 seconds]
wallerdev has joined #ruby
fold has quit [Ping timeout: 264 seconds]
shredding has joined #ruby
iamcalledrob has joined #ruby
User4587_ has joined #ruby
treehug88 has quit [Ping timeout: 272 seconds]
Spami has joined #ruby
benzrf|offline is now known as benzrf
Spami has quit [Remote host closed the connection]
baroquebobcat has quit [Ping timeout: 264 seconds]
baroquebobcat_ is now known as baroquebobcat
endash has joined #ruby
terrellt has quit [Ping timeout: 248 seconds]
nanoyak has joined #ruby
cearls has quit [Ping timeout: 248 seconds]
User458764 has quit [Ping timeout: 264 seconds]
schaerli has quit [Remote host closed the connection]
sputnik13 has joined #ruby
ghr has quit [Ping timeout: 248 seconds]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
iamcalledrob has quit [Client Quit]
mattmcclure has joined #ruby
edgarjs_afk is now known as edgarjs
terrellt has joined #ruby
banjara has joined #ruby
mbwe has joined #ruby
RaCx has quit [Ping timeout: 260 seconds]
frankjpinto__ has quit [Ping timeout: 264 seconds]
Hobogrammer has joined #ruby
poppingtonic has joined #ruby
poppingtonic has left #ruby [#ruby]
sputnik13 has quit [Ping timeout: 252 seconds]
Spami has joined #ruby
reset has joined #ruby
uffs has joined #ruby
craigp has quit []
mikesplain has quit [Ping timeout: 264 seconds]
mikesplain has joined #ruby
jobewan has joined #ruby
j_mcnally has joined #ruby
bradhe has joined #ruby
banister has joined #ruby
dontwork has joined #ruby
mehlah has quit [Quit: Leaving...]
ctp_ has quit [Quit: Textual IRC Client: www.textualapp.com]
upsell5 has joined #ruby
<upsell5> Hi, when splitting, how could I automatically remote those values that have length of 0?
<ericwood> on an array?
<upsell5> “/cat/sub1/sub2/file”.split(“/“)
fold has joined #ruby
doev has quit [Quit: Verlassend]
<upsell5> the first item is empty…i just want to ignore that one.
banister_ has joined #ruby
pontiki has quit [Ping timeout: 252 seconds]
_maes_ has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
LiohAu has quit [Quit: LiohAu]
Takle has joined #ruby
craigp has joined #ruby
pontiki has joined #ruby
<dorei> upsell5: "/bin/lala".split("/").reject(&:empty?)
banister has quit [Ping timeout: 264 seconds]
_maes_ has joined #ruby
<havenn> >> "/cat/sub1/sub2/file".scan /\w+/
<eval-in_> havenn => ["cat", "sub1", "sub2", "file"] (https://eval.in/170136)
craigp has quit [Remote host closed the connection]
<upsell5> havenn: how could I do it with a map so I can use an if statement for other custom logic.
<upsell5> is map the right method to use here?
<havenn> upsell5: I don't understand what you're wanting to do. Maybe who an example on gist.github.com?
<havenn> s/who/show
<havenn> upsell5: What's the output you're wanting?
<upsell5> loop through array items, remove where string.length = 0
ixti has joined #ruby
<ericwood> [].reject(&:empty?)
<ericwood> >> ['a', '', 'b', 'c'].reject(&:empty?)
<eval-in_> ericwood => ["a", "b", "c"] (https://eval.in/170140)
<ericwood> TADA
<ericwood> eric saves the day again
brasten has quit [Quit: brasten]
p0sixpscl has joined #ruby
<upsell5> I’m trying to do this: “/a/b/c/d”.split(“/“).map { |x| if x.length > 0 }
<upsell5> but that doesn’t work.
drawingthesun has joined #ruby
einarj has quit [Remote host closed the connection]
<ericwood> upsell5: "/a/b/c/d".split("/").reject(&:empty?)
<ericwood> do it
<upsell5> thanks eric but I want to use an if statement as my logic will change
SilverKey has quit [Quit: Halted.]
<ericwood> upsell5: use reject then
<ericwood> upsell5: "/a/b/c/d".split("/").reject { |i| i.empty? }
<upsell5> i see ok
nanoyak has quit [Read error: Connection reset by peer]
<upsell5> ok I see cool.
jdripper has quit [Quit: Leaving.]
<upsell5> but could this also be done using a map?
<lemur> .reject(&:empty?)
Takle has quit [Ping timeout: 264 seconds]
<workmad3> upsell5: no
<ericwood> upsell5: just use reject
<workmad3> upsell5: map doesn't remove items from the collection
<ericwood> idk why you want map so badly :P
<havenn> >> "/cat/sub1/sub2/file".scan(/\w+/).select { |word| word.start_with?('s') }.map &:capitalize
<eval-in_> havenn => ["Sub1", "Sub2"] (https://eval.in/170151)
<upsell5> eric to learn :)
maoko has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
nanoyak has joined #ruby
<havenn> upsell5: #select, #reject, #map at will
<upsell5> i see, i’ll read up on those thanks.
<havenn> upsell5: chain all three together, whatever you want
maximski has quit []
nanoyak has quit [Read error: Connection reset by peer]
<ericwood> I recommend browsing this page: http://ruby-doc.org/core-2.1.2/Enumerable.html
<ericwood> lots of really handy things in there
<upsell5> ok map is more to modify each item correct?
<ericwood> yes
nanoyak has joined #ruby
<ericwood> tl;dr ruby
pontiki has quit [Ping timeout: 256 seconds]
pontiki has joined #ruby
synfin has joined #ruby
roolo has quit [Quit: Leaving...]
gruz0[russia] has quit [Quit: This computer has gone to sleep]
<synfin> Noob question, rubygems.org frontpage says '78145 gems cut since....', but when you browse 'all gems', there are 4951 gems, which I presume is the real total. So what does 'gems cut' mean for Ruby?
workmad3 has quit [Ping timeout: 252 seconds]
bricker`work has quit [Ping timeout: 240 seconds]
axisys has quit [Quit: leaving]
dwts has quit [Ping timeout: 252 seconds]
<havenn> synfin: 4951 gems begin with the letter 'a'
<havenn> synfin: "all gems starting with A"
<synfin> havenn: lol, thanks :)
<synfin> I figured it was easy
bradhe has quit [Remote host closed the connection]
<havenn> :)
User4587_ is now known as User458764_NotHe
dwts has joined #ruby
bricker`work has joined #ruby
axisys has joined #ruby
Zesty has joined #ruby
gigetoo has quit [Remote host closed the connection]
axisys has quit [Changing host]
axisys has joined #ruby
klaut has joined #ruby
gigetoo has joined #ruby
User458764 has joined #ruby
cocotton has quit [Quit: Leaving...]
Jon` has quit [Ping timeout: 240 seconds]
Zebroid has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
testcore has joined #ruby
<Sou|cutter> I'm not sure what it counts in there either - e.g. yanked gems?
<Sou|cutter> or gems for which all versions are yanked
User458764_NotHe has quit [Ping timeout: 260 seconds]
baroquebobcat has joined #ruby
disorder20 has joined #ruby
dapz has joined #ruby
sigurding has joined #ruby
maletor has joined #ruby
<maletor> Is there something like %w() that returns ints instead of strings?
<maletor> Is there something like %w() that returns ints instead of strings?
<dangerousdave> any idea about this error please? https://gist.github.com/deathwishdave/d651d16903b0b631f5fd
jrhorn424 is now known as zz_jrhorn424
<wallerdev> maletor: [,] ?
maximski has joined #ruby
<maletor> :)
<maletor> sure
yfeldblum has joined #ruby
kevind has quit [Ping timeout: 264 seconds]
Zebroid has quit [Ping timeout: 260 seconds]
SBoolean has quit [Ping timeout: 240 seconds]
SilverKey has joined #ruby
dapz has quit [Client Quit]
<philevans_> Is there any reason why IO::read(n) would read *more* than n bytes?
jxf has joined #ruby
banister_ has quit [Ping timeout: 260 seconds]
RaCx has joined #ruby
kevind has joined #ruby
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
andrewhl has quit [Quit: andrewhl]
alem0lars has joined #ruby
kevind has quit [Ping timeout: 264 seconds]
sparrovv has joined #ruby
bradleyprice has joined #ruby
sparrovv has quit [Client Quit]
User458764 has quit [Ping timeout: 255 seconds]
frankjpinto__ has joined #ruby
shredding has quit [Quit: shredding]
Atttwww has quit [Ping timeout: 272 seconds]
moritzs has joined #ruby
p0sixpscl has quit [Quit: p0sixpscl]
dscrd has joined #ruby
lepht has quit [Quit: Connection closed for inactivity]
whyy has joined #ruby
gruz0[russia] has joined #ruby
Mon_Ouie has quit [Ping timeout: 255 seconds]
Guest89056 is now known as duallain
exgf has quit [Remote host closed the connection]
cearls has joined #ruby
GeorgesLeYeti has quit [Quit: Quitte]
danielpclark has joined #ruby
maximski has quit []
andrewhl has joined #ruby
pontiki has quit [Ping timeout: 252 seconds]
stytown has quit [Quit: stytown]
WillAmes has joined #ruby
whyy has quit [Ping timeout: 272 seconds]
zly has quit [Changing host]
zly has joined #ruby
nanoyak has quit [Read error: Connection reset by peer]
pontiki has joined #ruby
Takle has joined #ruby
nanoyak has joined #ruby
yfeldblu_ has joined #ruby
yfeldblu_ has quit [Read error: Connection reset by peer]
jxf has quit [Ping timeout: 252 seconds]
shredding has joined #ruby
danielpclark is now known as daniel
yfeldblu_ has joined #ruby
daniel is now known as danielpclark
mattstratton has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
CodeLicker has quit [Ping timeout: 252 seconds]
Mon_Ouie has joined #ruby
Mon_Ouie has joined #ruby
Mon_Ouie has quit [Changing host]
soulcake has quit [Read error: Connection reset by peer]
soulcake has joined #ruby
rdark has quit [Quit: leaving]
sputnik13 has joined #ruby
sputnik13 has quit [Max SendQ exceeded]
dapz has joined #ruby
Rahul_Roy has joined #ruby
sputnik13 has joined #ruby
postmodern has joined #ruby
yfeldblu_ has quit [Read error: Connection reset by peer]
jxf has joined #ruby
yfeldblum has joined #ruby
Zesty has quit [Quit: Linkinus - http://linkinus.com]
goddamnyou is now known as goshdarnyou
shvelo has joined #ruby
aspires has quit []
lemur has quit [Remote host closed the connection]
lemur has joined #ruby
xcv has quit [Remote host closed the connection]
aspires has joined #ruby
mikepack has quit [Remote host closed the connection]
fresham has joined #ruby
timfoo has quit [Ping timeout: 255 seconds]
uffs has quit [Ping timeout: 264 seconds]
sailias has quit [Quit: Leaving.]
rrva has joined #ruby
jxf has quit [Ping timeout: 256 seconds]
<rrva> oj json parser cannot parse form stdin pipe, I get ESPIPE
yetanotherdave has joined #ruby
bluenemo has joined #ruby
<rrva> yajl can... what could be wrong?
<eam> rrva: ESPIPE means it's trying to seek()
bradhe has joined #ruby
<rrva> ah, I see fixes on github
dc_ has quit [Remote host closed the connection]
pontiki has quit [Ping timeout: 260 seconds]
pontiki has joined #ruby
alvaro_o has joined #ruby
ereslibre_laptop has quit [Quit: No Ping reply in 180 seconds.]
aalmenar has quit [Quit: No Ping reply in 180 seconds.]
sputnik13 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
ereslibre has joined #ruby
ereslibre has joined #ruby
icarus_ has joined #ruby
aalmenar has joined #ruby
aalmenar has quit [Changing host]
aalmenar has joined #ruby
M-Technic has joined #ruby
shredding has quit [Quit: shredding]
spider-mario has quit [Read error: Connection reset by peer]
stytown has joined #ruby
brunops has joined #ruby
nanoyak has quit [Read error: Connection reset by peer]
aspires has quit []
pontiki has quit [Ping timeout: 252 seconds]
shredding has joined #ruby
nanoyak has joined #ruby
alem0lars has quit [Quit: Going AFK...]
m8 has joined #ruby
pontiki has joined #ruby
kfs has quit [Quit: Connection closed for inactivity]
jerius has quit []
timfoo has joined #ruby
terrell_t has joined #ruby
aspires has joined #ruby
jerius has joined #ruby
mike24 has joined #ruby
jprovazn has quit [Quit: Odcházím]
Eiam has joined #ruby
benzrf is now known as benzrf|offline
aspires has quit [Client Quit]
aspires has joined #ruby
Macaveli has quit [Ping timeout: 240 seconds]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
terrellt has quit [Ping timeout: 260 seconds]
bigkevmcd has quit [Ping timeout: 252 seconds]
eka has joined #ruby
Zebroid has joined #ruby
benzrf|offline is now known as benzrf
cearls has quit [Remote host closed the connection]
pontiki has quit [Ping timeout: 260 seconds]
cearls has joined #ruby
sailias has joined #ruby
pontiki has joined #ruby
olivier_bK has joined #ruby
maximski has joined #ruby
Soda has quit [Remote host closed the connection]
Zebroid has quit [Ping timeout: 255 seconds]
Hobogrammer has quit [Ping timeout: 272 seconds]
nathamanath has joined #ruby
JBreit has joined #ruby
phinfonet has quit []
wildroman2 has joined #ruby
maximski has quit []
carraroj has quit [Quit: Konversation terminated!]
subraminion_ has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
JBreit has quit [Client Quit]
x1337807x has joined #ruby
Notte has joined #ruby
failshe__ has quit [Remote host closed the connection]
subraminion__ has joined #ruby
Guest27310 has quit [Read error: Connection reset by peer]
Hobogrammer has joined #ruby
subraminion has quit [Read error: Connection reset by peer]
failshell has joined #ruby
bradhe has quit [Remote host closed the connection]
shredding has quit [Quit: shredding]
charliesome has joined #ruby
xcv has joined #ruby
mikepack has joined #ruby
wallerdev_ has joined #ruby
subraminion_ has quit [Ping timeout: 240 seconds]
bradhe has joined #ruby
ericwood has quit [Quit: Changing server]
x1337807x has quit [Ping timeout: 255 seconds]
wallerdev has quit [Ping timeout: 260 seconds]
wallerdev_ is now known as wallerdev
mikeg has joined #ruby
tjr9898 has joined #ruby
terrell_t has quit [Remote host closed the connection]
treehug88 has joined #ruby
lolmaus_ has joined #ruby
terrellt has joined #ruby
subraminion___ has joined #ruby
subraminion___ has quit [Remote host closed the connection]
Morkel has joined #ruby
RedPunch has quit [Remote host closed the connection]
sdegutis has joined #ruby
jfran_ has joined #ruby
jfran_ has quit [Client Quit]
<sdegutis> What kind of algorithm would you use to find all items of an array that match a predicate and keep the immediately surrounding items (if present)?
Vivekananda has joined #ruby
aspires has quit []
subraminion___ has joined #ruby
subraminion__ has quit [Ping timeout: 272 seconds]
<sdegutis> For example, with an array of all numbers, if you wanted those divisible by 10 or their immediate neighbor, you'd get -1, 0, 1, 9, 10, 11, 19, 20, 21, etc
ericwood has joined #ruby
lolmaus has quit [Ping timeout: 255 seconds]
<sdegutis> I almost want to do something with take_while or drop_while.. I dunno
xcv has quit [Remote host closed the connection]
lemur has quit [Remote host closed the connection]
jfran has quit [Ping timeout: 272 seconds]
banister has joined #ruby
<godd2> sdegutis there's no built in method for that, but you can find a member, get its index, and then get the members of the array at index+1 and index-1
<sdegutis> sure sure, thanks.
<apeiros> sdegutis: .each_cons(3).select { …
<sdegutis> apeiros: <3
tjr9898 has quit [Remote host closed the connection]
wallerdev_ has joined #ruby
<sdegutis> apeiros: Your solution is so beautiful, it's unfortunate that I can't use it directly.
mikesplain has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<sdegutis> I had forgotten that it could be a range, not just one element.
<sdegutis> For example, if "9 and 10" matched my algorithm, I would need 8 and 11 too.
vyorkin has joined #ruby
<godd2> >> arrays = [];(-1..41).each_cons(3) {|a| arrays << a if a[1]%10==0 };p arrays.flatten
<eval-in_> godd2 => [-1, 0, 1, 9, 10, 11, 19, 20, 21, 29, 30, 31, 39, 40, 41] ... (https://eval.in/170179)
nathamanath has quit [Quit: WeeChat 0.4.2]
bradhe has quit [Remote host closed the connection]
yfeldblum has quit [Read error: Connection reset by peer]
yfeldblum has joined #ruby
treehug88 has quit [Ping timeout: 252 seconds]
matled has joined #ruby
LiohAu has joined #ruby
dapz has joined #ruby
LiohAu has quit [Client Quit]
sheperson has joined #ruby
<sdegutis> I just need a state machine.
wallerdev has quit [Ping timeout: 272 seconds]
wallerdev_ is now known as wallerdev
shredding has joined #ruby
LiohAu has joined #ruby
lemur has joined #ruby
acconrad has quit [Quit: acconrad]
yfeldblum has quit [Remote host closed the connection]
p0sixpscl has joined #ruby
senayar has joined #ruby
yfeldblum has joined #ruby
RaCx has quit [Ping timeout: 272 seconds]
djbkd has quit [Remote host closed the connection]
mikesplain has joined #ruby
Takle has quit [Remote host closed the connection]
djbkd has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
iamjarvo has joined #ruby
cearls has quit [Remote host closed the connection]
wallerdev has quit [Quit: wallerdev]
wallerdev has joined #ruby
wallerdev has quit [Client Quit]
<benzrf> ugh
mikespla_ has joined #ruby
cearls has joined #ruby
aspires has joined #ruby
spider-mario has joined #ruby
havenn has quit []
gemmy_ has joined #ruby
SJrX is now known as SJr
mikesplain has quit [Ping timeout: 245 seconds]
nathan1 has joined #ruby
SJr is now known as SJrX
SJrX is now known as SJR
shredding has quit [Quit: shredding]
cearls has quit [Ping timeout: 256 seconds]
ndrei has joined #ruby
girl26 has joined #ruby
banjara has quit [Quit: Leaving.]
Takle has joined #ruby
camilasan has joined #ruby
djbkd has quit [Remote host closed the connection]
bradhe has joined #ruby
cmoneylulz has joined #ruby
nir has joined #ruby
nir has left #ruby [#ruby]
girl26 has quit [Read error: Connection reset by peer]
kireevco has quit [Quit: Leaving.]
railzForDaiz has joined #ruby
Royalb15_1 has quit [Quit: Leaving]
bradhe has quit [Remote host closed the connection]
sepp2k has joined #ruby
tjr9898 has joined #ruby
girl26 has joined #ruby
RaCx has joined #ruby
ziyadb has quit [Quit: Connection closed for inactivity]
abilon has quit [Quit: Lingo - http://www.lingoirc.com]
sdegutis has left #ruby [#ruby]
tjr9898 has quit [Remote host closed the connection]
tjr9898 has joined #ruby
railzForDaiz has quit [Remote host closed the connection]
tjr9898 has quit [Client Quit]
girl26 has left #ruby [#ruby]
lemur has quit [Remote host closed the connection]
SBoolean has joined #ruby
bigkevmcd has joined #ruby
sheperson has quit [Ping timeout: 248 seconds]
SloggerKhan has quit [Quit: Leaving.]
cearls has joined #ruby
mikepack has quit [Remote host closed the connection]
wallerdev has joined #ruby
jerius has quit []
sheperson has joined #ruby
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
sheperson has quit [Client Quit]
Zebroid has joined #ruby
djbkd has joined #ruby
heftig has joined #ruby
jerius has joined #ruby
mikepack has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
IceyEC has joined #ruby
nanoyak has joined #ruby
dangerousdave has joined #ruby
stytown has quit [Quit: stytown]
sailias has quit [Quit: Leaving.]
djbkd has quit [Read error: Connection reset by peer]
Zebroid has quit [Ping timeout: 245 seconds]
whyy has joined #ruby
djbkd has joined #ruby
Jeticus has joined #ruby
JBreit has joined #ruby
bluOxigen has joined #ruby
mudtose has joined #ruby
CaptainJet has quit [Ping timeout: 264 seconds]
grvgr has joined #ruby
mary5030 has joined #ruby
rayners has quit [Ping timeout: 248 seconds]
gruz0[russia] has quit [Quit: Leaving]
Zesty has joined #ruby
<mudtose> Hello, #ruby, I'm in need of some assistance. I want to use this gem https://github.com/jebw/ftp_sync
bradhe has joined #ruby
JBreit has left #ruby [#ruby]
<mudtose> but it's outdated and it requires "net/ftp/list" in the code
<mudtose> I'm getting a LoadError because of it, can I just remove it if I'm using a newer Ruby?
cmoneylulz has quit [Remote host closed the connection]
brasten has joined #ruby
whyy has quit [Ping timeout: 240 seconds]
grvgr has quit [Client Quit]
shredding has joined #ruby
<goganchic> mudtose you can try
<mudtose> Do you know if "require net/ftp/list" has been deprecated in place of "require net/ftp"? That's basically my question
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
oo_ has joined #ruby
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
sigurding has quit [Quit: sigurding]
brandon__ has quit [Ping timeout: 264 seconds]
mattstratton has joined #ruby
<goganchic> mudtose net/ftp has list function, but you'd better not to use outdated gems
maestrojed has joined #ruby
<mudtose> it's unfortunate because it's the only thing with the functionality I want and I'm in a bit of a time crunch to reimplement it myself
<mudtose> which is recursive FTP downloading.
* katlogic would just popen lftp
oo_ has quit [Ping timeout: 245 seconds]
Zesty has quit [Quit: Linkinus - http://linkinus.com]
graft has joined #ruby
graft has joined #ruby
kireevco has joined #ruby
<goganchic> this gem is very small, I'm sure you can implement its functionality in a hour or two
wldcordeiro has joined #ruby
wildroman2 has quit [Read error: No route to host]
brunops has quit [Ping timeout: 252 seconds]
mijicd has quit [Remote host closed the connection]
wildroman2 has joined #ruby
<mudtose> I'll try
IceyEC has quit [Quit: IceyEC]
krz has quit [Quit: WeeChat 0.4.3]
wallerdev has quit [Quit: wallerdev]
<dangerousdave> can someone help please? odd error https://gist.github.com/deathwishdave/8177949d87f7b6556689
LiohAu has quit [Quit: LiohAu]
<goganchic> dangerousdave add this line at the beginning of your script: # -*- encoding : utf-8 -*-
<dangerousdave> goganchic, trying
Wolland has joined #ruby
<goganchic> dangerousdave I think you have ruby 2.0 or ruby 2.1 installed locally and ruby 1.9.3 on aws
fresham has quit [Quit: fresham]
Morkel has quit [Quit: Morkel]
<dangerousdave> goganchic, didn't work
<dangerousdave> goganchic, yes, thats spot on! how did you know?
<goganchic> dangerousdave, you you passed exactly the same string as I wrote? It should be the first line of your script and it should start with # char
<dangerousdave> goganchic
<goganchic> if it does not work, try this one: # encoding: utf-8
shredding has quit [Quit: shredding]
<dangerousdave> goganchic, i did, i will try again
agjacome has quit [Quit: leaving]
Mattx has joined #ruby
<Mattx> hey guys
<Mattx> what's the problem with this generator? https://gist.github.com/mparodi/6512d23591483f714ef3
<Mattx> it's not being executed when I do bundle install, even though the gem is installed correctly
lemur has joined #ruby
phutchins has quit [Ping timeout: 260 seconds]
<dangerousdave> goganchic, same error still :-(
<goganchic> dangerousdave hmm
<dangerousdave> goganchic, I tried both lines
<Mattx> in lib/generators there are 3 files: initializer_generator.rb, triplet.rb and triplet.yml
Notte has quit [Remote host closed the connection]
schaerli has joined #ruby
einarj has joined #ruby
x1337807x has joined #ruby
dontwork has quit [Remote host closed the connection]
<goganchic> dangerousdave can you show file with script?
<goganchic> SQSMailer.rb
duallain has quit [Read error: Connection reset by peer]
<goganchic> lines 1 - 10
<goganchic> may be 1 - 8
geggam has quit [Quit: Leaving]
brunops has joined #ruby
LiohAu has joined #ruby
jackneill has quit [Read error: Connection reset by peer]
kireevco has quit [Read error: Connection reset by peer]
kireevco has joined #ruby
Rahul_Roy has quit [Quit: Connection closed for inactivity]
<dangerousdave> note that line 8 did land on the require, i added puts to be sure where it had got to
heftig has quit [Ping timeout: 248 seconds]
<dangerousdave> goganchic, updated again with code that generated error https://gist.github.com/deathwishdave/8177949d87f7b6556689
LiohAu has quit [Ping timeout: 256 seconds]
subraminion___ has quit [Quit: Lingo - http://www.lingoirc.com]
subraminion has joined #ruby
shredding has joined #ruby
Jon` has joined #ruby
shredding has quit [Client Quit]
DivineEntity has quit [Quit: leaving]
shredding has joined #ruby
nanoyak has quit [Quit: Computer has gone to sleep.]
brunops has quit [Ping timeout: 256 seconds]
nanoyak has joined #ruby
mattstratton has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
IceyEC has joined #ruby
bradhe has quit [Remote host closed the connection]
lemur has quit [Remote host closed the connection]
maoko has joined #ruby
brunops has joined #ruby
nanoyak has quit [Client Quit]
wallerdev has joined #ruby
olivier_bK has quit [Ping timeout: 256 seconds]
bradhe has joined #ruby
lemur has joined #ruby
nanoyak has joined #ruby
shredding has quit [Quit: shredding]
lemur has quit [Remote host closed the connection]
klue has joined #ruby
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
brunops has quit [Changing host]
brunops has joined #ruby
theharshest has quit [Quit: This computer has gone to sleep]
goganchic has quit []
bradhe has quit [Remote host closed the connection]
dontwork has joined #ruby
Asher has quit [Quit: Leaving.]
fjfish has quit [Remote host closed the connection]
techsethi has quit [Quit: techsethi]
mikeg has quit [Remote host closed the connection]
stytown has joined #ruby
britneywright has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
moritzs has quit [Ping timeout: 260 seconds]
kireevco has quit [Read error: Connection reset by peer]
kireevco has joined #ruby
charliesome has joined #ruby
mudtose has quit [Ping timeout: 246 seconds]
andrewjanssen has joined #ruby
brunops has quit [Ping timeout: 255 seconds]
stytown has quit [Client Quit]
AntelopeSalad has quit [Quit: Leaving]
yfeldblum has quit [Remote host closed the connection]
dscrd has quit [Remote host closed the connection]
bradhe has joined #ruby
brandon has joined #ruby
mary5030 has quit [Read error: Connection reset by peer]
Ankhers has quit [Remote host closed the connection]
jfran has joined #ruby
brunops has joined #ruby
CrAzOiD has joined #ruby
StephenA1 has joined #ruby
mary5030 has joined #ruby
decoponio has quit [Quit: Leaving...]
olivier_bK has joined #ruby
claymore has quit [Ping timeout: 248 seconds]
mike24 has quit [Ping timeout: 256 seconds]
gemmy_ has left #ruby [#ruby]
bdnelson has joined #ruby
isthisreallife has joined #ruby
shredding has joined #ruby
isthisreallife has left #ruby [#ruby]
Fire-Dragon-DoL has quit [Quit: Leaving.]
SJR is now known as SJr
aspires has quit []
ldnunes has quit [Remote host closed the connection]
aspires has joined #ruby
wildroman2 has quit [Read error: Connection reset by peer]
testcore has quit [Remote host closed the connection]
wildroman2 has joined #ruby
djbkd has quit [Remote host closed the connection]
xcv has joined #ruby
mconnolly has quit [Quit: mconnolly]
ldnunes has joined #ruby
djbkd has joined #ruby
lw has quit [Quit: s]
tyfighter has joined #ruby
Zenigor has quit [Remote host closed the connection]
IceyEC has quit [Quit: iceyec]
mattstratton has joined #ruby
IceyEC has joined #ruby
cearls has quit [Remote host closed the connection]
yfeldblum has joined #ruby
cearls has joined #ruby
jfran_ has joined #ruby
claymore has joined #ruby
bradhe has quit [Remote host closed the connection]
tcstar has joined #ruby
bmurt has quit []
mikeg has joined #ruby
paulfm has quit []
jfran has quit [Ping timeout: 255 seconds]
shredding has quit [Quit: shredding]
bradhe has joined #ruby
schaerli has quit [Remote host closed the connection]
tcstar has quit [Remote host closed the connection]
jezen has joined #ruby
cearls has quit [Ping timeout: 240 seconds]
jezen is now known as jgt
theharshest has joined #ruby
StephenA1 has quit [Quit: StephenA1]
dapz has joined #ruby
SBoolean has quit [Remote host closed the connection]
shvelo has quit [Ping timeout: 264 seconds]
RaCx has quit [Quit: Computer has gone to sleep.]
lemur has joined #ruby
djbkd has quit [Remote host closed the connection]
IceyEC has quit [Quit: iceyec]
lemur has quit [Read error: Connection reset by peer]
lemur has joined #ruby
brasten has quit [Ping timeout: 256 seconds]
brasten_ has joined #ruby
robertodecurnex has quit [Remote host closed the connection]
jgt has quit []
volk_ has quit [Quit: volk_]
blackmesa has joined #ruby
shevy has quit [Ping timeout: 240 seconds]
mikeg has quit [Remote host closed the connection]
andrewjanssen has quit [Ping timeout: 245 seconds]
foo-bar- has quit [Remote host closed the connection]
duper has joined #ruby
grieg has joined #ruby
ramfjord has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
duggiefresh has quit []
bradhe has quit [Remote host closed the connection]
mostlybadfly has quit [Quit: Connection closed for inactivity]
cearls has joined #ruby
claymore has quit [Quit: Leaving]
endash has quit [Quit: endash]
wildroman2 has quit [Remote host closed the connection]
endash has joined #ruby
mjsmith2 has quit [Remote host closed the connection]
kireevco has left #ruby [#ruby]
endash has quit [Client Quit]
tcstar has joined #ruby
NinoScript has joined #ruby
nowthatsamatt has joined #ruby
ldnunes has quit [Quit: Leaving]
bluOxigen has quit [Ping timeout: 248 seconds]
stytown has joined #ruby
treehug88 has joined #ruby
ekinmur has joined #ruby
edgarjs is now known as edgarjs_afk
linoge has joined #ruby
endash has joined #ruby
lxsameer has joined #ruby
andrewhl has quit [Quit: andrewhl]
lxsameer has quit [Changing host]
lxsameer has joined #ruby
Zebroid has joined #ruby
edgarjs_afk is now known as edgarjs
x1337807x has joined #ruby
endash has quit [Client Quit]
linoge has quit [Client Quit]
edgarjs is now known as edgarjs_afk
<fwaokda> if im declaring an object in my ruby script should i name it "myobject" or "@myobject" to access it within a method defined later in the script file?
freerobby has quit [Quit: Leaving.]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
m8 has quit [Quit: Sto andando via]
olivier_bK has quit [Ping timeout: 240 seconds]
jobewan has quit [Ping timeout: 256 seconds]
mikespla_ has quit [Ping timeout: 245 seconds]
ta has quit [Read error: Connection reset by peer]
ta has joined #ruby
failshel_ has joined #ruby
alexju has quit [Remote host closed the connection]
jfran_ has quit [Quit: Going offline, see ya! (www.adiirc.com)]
momomomomo has quit [Quit: momomomomo]
snath has quit [Ping timeout: 264 seconds]
edgarjs_afk is now known as edgarjs
mary5030 has quit [Remote host closed the connection]
djbkd has joined #ruby
whyy has joined #ruby
<toretore> fwaokda: you should pass the object when running the method
failshell has quit [Ping timeout: 248 seconds]
<fwaokda> toretore, k thanks!
failshel_ has quit [Ping timeout: 248 seconds]
moritzs has joined #ruby
ohwhoa has joined #ruby
djbkd has quit [Remote host closed the connection]
frankjpinto__ has quit [Ping timeout: 264 seconds]
shvelo has joined #ruby
RaCx has joined #ruby
whyy has quit [Ping timeout: 240 seconds]
RaCx has quit [Remote host closed the connection]
lw has joined #ruby
havenwood has joined #ruby
RaCx has joined #ruby
djbkd has joined #ruby
shevy has joined #ruby
britneywright has joined #ruby
AntelopeSalad has joined #ruby
bluenemo has quit [Quit: Verlassend]
ndrei has quit [Ping timeout: 264 seconds]
sriehl has joined #ruby
klue has quit [Ping timeout: 240 seconds]
<zenspider_> minitest version 5.4.0 has been released! | software releases by ryan davis - http://blog.zenspider.com/releases/2014/07/minitest-version-5-4-0-has-been-released.html
bradhe has joined #ruby
duncannz has joined #ruby
cpruitt has joined #ruby
Zesty has joined #ruby
xaxisx has quit [Quit: xaxisx]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Soda has joined #ruby
x1337807x has joined #ruby
britneywright has quit [Client Quit]
x1337807x has quit [Client Quit]
Azure has joined #ruby
Shidash has joined #ruby
funktor has joined #ruby
<ericwood> yay
sriehl has quit [Client Quit]
mijicd has joined #ruby
frankjpinto__ has joined #ruby
bradhe has quit [Remote host closed the connection]
Photism has joined #ruby
Akuma has quit [Ping timeout: 240 seconds]
dblessing has quit [Quit: dblessing]
p0sixpscl has quit [Quit: p0sixpscl]
CorpusCallosum has quit [Ping timeout: 260 seconds]
frankjpinto__ has quit [Ping timeout: 240 seconds]
orionstein is now known as orionstein_away
echevemaster has joined #ruby
lw has quit [Quit: s]
vyorkin has quit [Ping timeout: 240 seconds]
SilverKey has quit [Quit: Halted.]
Wolland has quit [Remote host closed the connection]
cmoneylulz has joined #ruby
Wolland has joined #ruby
yfeldblu_ has joined #ruby
RaCx has quit [Quit: Computer has gone to sleep.]
stytown has quit [Quit: stytown]
mijicd has quit [Remote host closed the connection]
brasten_ has quit [Quit: brasten_]
RaCx has joined #ruby
neiled has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
Wolland has quit [Ping timeout: 240 seconds]
lemur has quit [Remote host closed the connection]
kirun has quit [Quit: Client exiting]
brasten has joined #ruby
mrmargolis has quit [Remote host closed the connection]
senayar has quit [Remote host closed the connection]
senayar has joined #ruby
dik_dak has joined #ruby
testcore has joined #ruby
mijicd has joined #ruby
robbyoconnor has quit [Excess Flood]
neiled has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
robbyoconnor has joined #ruby
Zesty has quit [Quit: Linkinus - http://linkinus.com]
cek has joined #ruby
klaut has quit [Remote host closed the connection]
mostlybadfly has joined #ruby
jhass is now known as jhass|off
dwts has quit [Ping timeout: 252 seconds]
bradhe has joined #ruby
bradhe has quit [Remote host closed the connection]
dwts has joined #ruby
senayar has quit [Ping timeout: 255 seconds]
heftig has joined #ruby
jimbow has joined #ruby
banjara has joined #ruby
<jimbow> what's wrong with my code?
graydot has joined #ruby
larissa has joined #ruby
<wallerdev> you never run the counter method
<jimbow> what do you mean?
<havenwood> jimbow: you have a method, you never call it
<wallerdev> >> def this_is_a_method; 2 + 2; end
<eval-in_> wallerdev => :this_is_a_method (https://eval.in/170238)
<havenwood> jimbow: also, the variable is out of scope anyways
<wallerdev> you gotta run the method for it to do anything
<wallerdev> youre just defining a block of code to run
frankjpinto has joined #ruby
cmoneylulz has quit [Remote host closed the connection]
<jimbow> don't i call it in the if statement?
<havenwood> jimbow: where do you see `counter` in the if statement?
jdj_dk has joined #ruby
<jimbow> oh that's how it works
<havenwood> jimbow: don't assign the local variable `chars` at all
<jimbow> i thought that since chars is inside counter it would be called
<havenwood> jimbow: no
bradhe has joined #ruby
<havenwood> jimbow: that isn't how it works :P
nateberkopec has quit [Quit: Leaving...]
<jimbow> it would be nice if that's how it worked
<havenwood> nuh uh
<jimbow> now i feel like i'm completely incompetent
<jimbow> i thought i was getting somewhere until now :(
<wallerdev> yeah just think of how cool thatd be, you have some method that calculates pi for example, then you just access the pi value and the program figures out what method to run to get you the answer
<wallerdev> very streamlined
nowthatsamatt has quit [Quit: nowthatsamatt]
robwilliamsuk has quit [Quit: http://www.youtube.com/watch?v=z99iVXJ8OtA]
<eam> are the ruby scoping rules documented anywhere?
stytown has joined #ruby
yubrew has quit []
<jimbow> i heard ruby is easy
nateberkopec has joined #ruby
<jimbow> whoever said ruby is easy, it isn't
riotjones has quit [Ping timeout: 260 seconds]
<Nilium> Ruby's easy if you know Ruby.
<jimbow> learning programming is the hardest thing i've done
jottr has joined #ruby
<toretore> ruby is programming and programming is not easy
alem0lars has joined #ruby
<gr33n7007h> I've heard Malbolge is pretty easy :)
<Nilium> I'm not sure if programming or really hard sudoku puzzles are harder
<jimbow> sudoku is much easier than programming
<havenwood> Write a sudoku solver, done.
<atmosx> sure is
<atmosx> depends how you play sudoku
<eam> specifically, I'm looking for an explanation of why an assignment in an un-executed conditional defines a variable
lw has joined #ruby
<fwaokda> has anyone used ruby to communicate with their raspberry pi's serial port?
<havenwood> atmosx: I play it thousands of games at a time with a Ruby script. :P
<atmosx> what does exactly the bittorrent open port do, does anyone know?
<Nilium> I play sudoku such that if I don't solve a puzzle in five minutes I'm unhappy
<atmosx> havenwood: hahahah that'scheating!
cearls has quit []
acconrad has joined #ruby
shvelo has quit [Ping timeout: 240 seconds]
einarj has quit [Read error: Connection reset by peer]
einarj has joined #ruby
<jimbow> would anyone recommend hiring a private tutor for programming?
ohwhoa has quit [Quit: woah!]
<Nilium> Would depend on the tutor.
mijicd has quit [Remote host closed the connection]
<jimbow> i feel like ripping my hair out
<atmosx> jimbow: with ruby?
treehug88 has quit []
<havenwood> jimbow: A coach could probably help a ton, but yeah depends.
<atmosx> how old are you?
<jimbow> 22
<atmosx> k
<jimbow> i'm old :(
<atmosx> maybe you should try something else, why do you wanna be a programmer?
<atmosx> I'm 32 and I'm an amateur
<atmosx> you're fine
T_Hunt has quit [Ping timeout: 264 seconds]
<jimbow> i have a lot of great ideas
<atmosx> I see.
<jimbow> like a lot
<jimbow> i am a very creative thinker
brasten has quit [Quit: brasten]
<banister> jimbow then read why's poignant guide ;)
<toretore> what sort of ideas jimbow?
<jimbow> i just want to translate my creative thinking into usable programs
<ericwood> I love _why
andrewhl has joined #ruby
<gr33n7007h> jimbow, http://pastie.org/9365473
<ericwood> I miss him
<jimbow> i'll check it out banister
andrewlio has quit [Quit: Leaving.]
Darkchaos has quit [Ping timeout: 248 seconds]
einarj has quit [Read error: Connection reset by peer]
<toretore> jimbow: to become good at programming you are going to have to enjoy it in itself to some degree
einarj_ has joined #ruby
<jimbow> toretore: i had an idea for uber back when i was 16
<havenwood> jimbow: be sure to listen to the soundtrack while you read it
<toretore> if it's just a means to an end it gets much harder
<ericwood> the soundtrack is awesome
SilverKey has joined #ruby
<ericwood> I actually really like listening to it
<ericwood> makes me excited to program
<jimbow> one of our "rich/successful" friends said that would be impossible because taxi licenses are very expensive
brasten has joined #ruby
<havenwood> jimbow: There's sorta a disconnect between example ruby with local vars and real code in classes and modules with instance variables.
<havenwood> jimbow: But it isn't so hard once you get used to it.
<dorei> a new york cab license is valuated at 1mil $
<jimbow> i guess my ideas come from asking "what's the problem?"
<havenwood> a ruby license is priceless
<jimbow> i want to change the world :)
<toretore> i have a license to kill
<toretore> -9
<havenwood> hack the planet!
<jimbow> nice :P
larissa has quit [Quit: Leaving]
<havenwood> i have your init process in my sights
<jimbow> thanks gr33n7007h
* havenwood puts on his roller blades
<jimbow> when should i use def?
<havenwood> jimbow: when you want to define a method
<jimbow> when would i want to do that?
<havenwood> jimbow: when you have a chunk of code to run in a class or module
mijicd has joined #ruby
<jimbow> oh
<jimbow> so it was completely pointless of me doing a def then
<jimbow> thank you :)
shevy has quit [Ping timeout: 248 seconds]
jespada has quit [Ping timeout: 264 seconds]
lw has quit [Quit: s]
charliesome has joined #ruby
shevy has joined #ruby
<ericwood> awww spotify doesn't have the _why's poignant guide soundtrack
bradleyprice has quit [Remote host closed the connection]
bradleyprice has joined #ruby
<havenwood> jimbow: classes, modules and methods are for helping humans organize code
<gr33n7007h> jimbow, http://pastie.org/9365482 start simple
bradhe has quit [Remote host closed the connection]
<jimbow> shouldn't there be two pipeline characters?
alem0lars has quit [Quit: Going AFK...]
<gr33n7007h> jimbow, why?
<jimbow> because of the placeholder thingy
<havenwood> jimbow: they aren't code, just a character in a string
<jimbow> oh
jerius has quit []
* jimbow feels stupid
bradhe has joined #ruby
<gr33n7007h> jimbow, || is logical or && is logical and
baroquebobcat has quit [Ping timeout: 260 seconds]
frankjpinto has quit [Ping timeout: 240 seconds]
shevy has quit [Ping timeout: 248 seconds]
<ericwood> | is binary or
<ericwood> which you rarely want
bradleyprice has quit [Ping timeout: 264 seconds]
<wallerdev> or is or and and is and
<ericwood> yeah
<havenwood> jimbow: if you knew these things before learning them it'd be spooky
senayar has joined #ruby
phoo1234567 has quit [Quit: Leaving]
<jimbow> but || has the same rules of precedence as parentheses right?
graydot has quit [Quit: graydot]
alem0lars has joined #ruby
<ericwood> no
<wallerdev> no?
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
funktor has quit [Remote host closed the connection]
<ericwood> NO
<ericwood> jk idk
<jimbow> havenwood: i knew about || && and ! before programming sadly
<havenwood> jimbow: `||` is just lower in precedence than `&&` and just higher than `..` and `...`
<pontiki> no, otherwise, what would a || (b && c) || d parse as?
<jimbow> i mean if you use || instead of or ruby will interpret that first
<havenwood> `and` and `or` are actually same precedence, but `||` and `&&` aren't
jfran_ has joined #ruby
<wallerdev> if you have to look up the rules of precendence you should probably just add parentheses is my opinion lol
<havenwood> i think memorize it
<havenwood> the math precedence we already know is most of it
<jimbow> is the poignant guide for sale in barnes and noble?
<ericwood> if you have to look up the rules of precedence you should rethink your code
<ericwood> jimbow: it's an online book
<ericwood> google it
<havenwood> jimbow: it is free online but hasn't been maintained
<jimbow> oh
<jimbow> i did google it
<ericwood> jimbow: it's not a great learning guide but it's an important part of ruby culture and a ton of fun
<ericwood> I miss _why ;_;
<jimbow> who was that guy?
<pontiki> i never knew them
<havenwood> wallerdev: good point on parens, just remove confusion
yfeldblu_ has quit [Remote host closed the connection]
senayar has quit [Remote host closed the connection]
<wallerdev> wh¥ was a cool dude
<wallerdev> but people werent cool to him
<jimbow> you guys are saying was like he died or something
senayar has joined #ruby
<wallerdev> so he disappeared
spider-mario has quit [Remote host closed the connection]
frankjpinto has joined #ruby
<ericwood> he's alive and well, but his persona is dead
dontwork has quit [Ping timeout: 248 seconds]
lxsameer has quit [Quit: Leaving]
<havenwood> i'm not sure the persona is dead so much as he isn't personally personifying it any longer
Vivekananda has quit [Ping timeout: 264 seconds]
<havenwood> though the printer spool stuff last year was a re-awakening
alem0lars has quit [Quit: alem0lars]
<pontiki> the persona is a legend, and legends don't die
<havenwood> or closure, depending on how you look at it
<havenwood> pontiki: i feel like we should fight zombies now
stytown has quit [Quit: stytown]
jfran_ has quit [Client Quit]
<havenwood> klabnik argues it's a mantle to be picked up
<pontiki> it could be
<havenwood> who is the next _why??
<pontiki> i like thinking of it as a closure as well :)
<jimbow> i'm going to be the next why!
mehlah has joined #ruby
<ericwood> there shouldn't be a next _why, but we should have people living some of his teachings
<havenwood> jimbow: then shhhhh, cause the `_` in _why is for anonymous :P
<pontiki> one does not simple call the closure _why!
jespada has joined #ruby
<zenspider_> wallerdev: people weren't cool to _why?
AntelopeSalad has quit [Remote host closed the connection]
<ericwood> at least we as a community still have friday hugs
<jimbow> why and i seem like we're almost identical…. but don't worry havenwood… i haven't learned ruby yet
<wallerdev> well he left when people posted his identity and personal info about him on pastebin and various other places
AntelopeSalad has joined #ruby
<jimbow> once i do i shall have an _ in my name and change it to something else so no one knows it's me
<wallerdev> most people liked him i imagine
<wallerdev> the community was upset he left and took down all his stuff
<jimbow> i can completely relate to why, i think we're nearly identical
nateberkopec has quit [Quit: Leaving...]
<jimbow> we like the same stuff
dontwork_ has joined #ruby
<zenspider_> oh, I thought it was mostly precipitated by tenderlove poopooing on hpricot w/ nokogiri :D
<pontiki> oh, stop it, now you're acting like an ass
<wallerdev> hah
<ericwood> poor hpricot :(
<ericwood> and camping
<zenspider_> to be fair, hpricot was a horrible mess and was really incompatible
<ericwood> ...as was most _why software
<havenwood> i blame Dostoyevsky
<ericwood> but in a loveable way
<zenspider_> yeah
<wallerdev> i really enjo¥ed his stories about teaching kids to code
<zenspider_> it needed competition. esp given that he really wasn't maintaining it or taking patches (I tried to speed it up ~40% and he just gave me the most cryptic response back)
<wallerdev> there was one about like a music program where people could write code to make notes play out of the computer and the kids really enjoyed that and did some cool stuff
awkwords has quit [Ping timeout: 252 seconds]
divbell has left #ruby [#ruby]
Connie has quit [Quit: Connie]
<ericwood> hackety hack has all of that stuff
<ericwood> klabnik took over that project, iirc it and shoes were migrated over to JRuby recently
<ericwood> but hey we still have gorbypuff
brunops has quit [Ping timeout: 240 seconds]
<havenwood> i think Potion is _why's coup de grace: https://github.com/perl11/potion#readme
vifino has quit [Quit: Ze Cat now leaves...]
<havenwood> 5 times: "Odelay!" print.
<jimbow> wow markaby is super cool!
maoko has quit [Quit: Textual IRC Client: www.textualapp.com]
ffranz has quit [Quit: Leaving]
<zenspider_> jimbow: not really. there's better options out there
mijicd has quit [Remote host closed the connection]
Lucky__ has joined #ruby
<jimbow> well, the concept of using ruby to make html code is awesome
<jimbow> you don't need closing tags
<zenspider_> look at tagz (my fav) or erector.
<jimbow> why was css and html easy for me but not ruby?
<ericwood> tbh after reading some pieces of the poignant guide I felt like he was suicidal
lolmaus has joined #ruby
<wallerdev> because html and css have no logic in them
<ericwood> jimbow: because those aren't programming languages
<havenwood> jimbow: because the former are markup and the latter is a turing complete language
<zenspider_> ericwood: he's not. he's just an artist. :)
<ericwood> haha fine line really
<ericwood> I was one of the winners of a golden comb during the whole closure bit :D
<zenspider_> I was so unsurprised by his going out. but my whole family are artists.
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<ericwood> it felt really good, kinda like I was a part of it
lolmaus_ has quit [Ping timeout: 240 seconds]
<jimbow> what is fast when describing a language?
<ericwood> that whole day at work we all just sat around waiting for the next piece to release
<ericwood> jimbow: not slow
<jimbow> erm, okay?
<wallerdev> same as when describing anything
<ericwood> it's all relative maaan
<jimbow> but what's fast?
<dorei> css3+html is sort of turing complete :p
<wallerdev> if i say someone runs fast it doesnt mean they run a 4 minute mile
<havenwood> dorei: was waiting for someone to say :P
<jimbow> you're fast if you're obese and run a mile in 2 hours
<ericwood> SASS is turing-complete :D
bradhe has quit [Remote host closed the connection]
RaCx has quit [Quit: Computer has gone to sleep.]
upsell5 has quit [Quit: upsell5]
Zebroid has quit [Remote host closed the connection]
chipotle has joined #ruby
<havenwood> dorei: but practically it'd be too painful to bear
<havenwood> and not simple
mr_snowf1ake has joined #ruby
kireevco has joined #ruby
arya_ has joined #ruby
dangerousdave has quit [Ping timeout: 255 seconds]
<dorei> havenwood: yeap, it's more of a hint that css3/html are rather complex
nicholas040 has joined #ruby
yfeldblum has joined #ruby
Atttwww has joined #ruby
<havenwood> a more advanced form of brainfuck
einarj_ has quit [Remote host closed the connection]
dinoex has quit [Ping timeout: 272 seconds]
<jimbow> what the hell is that?
<havenwood> s/turning complete/general purpose
dinoex has joined #ruby
<havenwood> jimbow: an esoteric language you code in for job security
bradhe has joined #ruby
<jimbow> not brainfuck, the tab thing
Neomex has quit [Quit: Leaving]
<havenwood> jimbow: tab thing?
<theharshest> I have two classes defined under same module but in different files. So I have two files with that start with same module same XYZ, and one has definition of class ABC1 and other has definition of class ABC2, but when I try to create an object of class ABC2 in ABC1, it gives an error that uninitialized constant ABC2.
andrewjanssen has joined #ruby
buub has quit [Remote host closed the connection]
<jimbow> theharshest: code?
Takle has quit [Remote host closed the connection]
<dorei> jimbow: it's an implemantion of automaton110 in pure css3/html, it's been proved that automaon 110 is turing complete
<jimbow> hmm
<jimbow> i have no idea what that means but i do know that turing complete is the idea where computers
<havenwood> theharshest: does the ABC1 code require the code where ABC2 is defined?
<theharshest> jimbow: Let me share it
<theharshest> havenwood: yes ABC1 need an object of ABC2
<theharshest> jimbow: can't share the code, sorry. I'm not permitted to do that. you can ask me if you need to diagnose the issue.
<jimbow> wow really?
<jimbow> why is code some sacred commodity?
<havenwood> theharshest: so you `require` the necessary file then?
<jimbow> can't everything be reversed engineered anyways?
<jimbow> i don't think there isn't anything a debugger can't handle
<theharshest> havenwood: I would try that. I was under an impression that if classes are under same module, they know about each other.
xcv has quit [Remote host closed the connection]
<theharshest> havenwood: thanks
<havenwood> theharshest: nope, no auto-require
vyorkin has joined #ruby
enebo has quit [Quit: enebo]
Deele has quit [Ping timeout: 255 seconds]
whyy has joined #ruby
andrewjanssen has quit [Remote host closed the connection]
nateberkopec has joined #ruby
blackmesa has quit [Ping timeout: 245 seconds]
Takle has joined #ruby
octarine_ is now known as octarine
jespada has quit [Quit: Leaving]
<theharshest> havenwood: it doesn't work, it says - cannot load such file -- ./abc2.rb
yeltzooo4 is now known as yeltzooo
<havenwood> theharshest: provide the relative path, consider using `require_relative` instead of `require` unless you have $LOAD_PATH configured
simoz1111115 has joined #ruby
<theharshest> havenwood: worked, thanks! :)
whyy has quit [Ping timeout: 240 seconds]
x1337807x has joined #ruby
peret has quit []
simoz1111116 has joined #ruby
Aryasam_ has joined #ruby
kireevco has left #ruby [#ruby]
brunops has joined #ruby
havenwood has quit []
<theharshest> jimbow: I'm absolutely new to ruby and working for a company. To provide the code, I would need to REDACT a lot of stuff before sharing it with you. If it would have been my personal code I would love to share it and I agree with all you said :)
dontwork_ has quit [Remote host closed the connection]
bradhe has quit [Remote host closed the connection]
Aryasam has quit [Ping timeout: 248 seconds]
subraminion_ has joined #ruby
simoz1111115 has quit [Ping timeout: 245 seconds]
<jimbow> i don't want to come across as a boaster, but i've used a debugger before and cracked software, i was also able to understand some statements they used to create a few things in code
jdj_dk has quit [Quit: Leaving...]
subraminion_ has quit [Client Quit]
<jimbow> but programming does not equal cracking
<jimbow> and if i can do it so can you :)
nateberkopec has quit [Ping timeout: 240 seconds]
disorder20 has quit [Quit: Konversation terminated!]
terrell_t has joined #ruby
subraminion has quit [Ping timeout: 240 seconds]
SilkFox has joined #ruby
terrellt has quit [Ping timeout: 240 seconds]
nathan1 has quit [Quit: WeeChat 0.4.2]
dapz has joined #ruby
bradhe has joined #ruby
absolutezeroff has quit [Ping timeout: 252 seconds]
mikecmpbll has quit [Quit: ciao.]
jimbow has quit [Remote host closed the connection]
DrCode has quit [Ping timeout: 264 seconds]
LadyRainicorn has quit [Ping timeout: 260 seconds]
nanoyak has quit [Quit: Computer has gone to sleep.]
_maes_ has quit [Quit: Miranda IM! Smaller, Faster, Easier. http://miranda-im.org]
nanoyak has joined #ruby
chrishough has joined #ruby
dik_dak has quit [Quit: Leaving]
brunops has quit [Ping timeout: 256 seconds]
nateberkopec has joined #ruby
NinoScript has quit [Read error: Connection reset by peer]
andrewjanssen has joined #ruby
NinoScript has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
moritzs has quit [Ping timeout: 264 seconds]
eladmeidar has joined #ruby
<eladmeidar> Hi kids.
<pontiki> hi dad
<eladmeidar> Top of the morning for ya!
mikepack_ has joined #ruby
<apeiros> hi mom
<toretore> hi uncle elad
dwts has quit [Ping timeout: 252 seconds]
<eladmeidar> you!
<eladmeidar> i actually missed you.
xargoon has quit [Ping timeout: 240 seconds]
<zenspider_> theharshest: you can strip it down to a minimal repro that doesn't show any IP. generally working through that will often answer your question
nateberkopec has quit [Ping timeout: 240 seconds]
dwts has joined #ruby
NinoScript has quit [Read error: Connection reset by peer]
<theharshest> zenspider_: sure
<toretore> eladmeidar: missed you too buddy
absolutezeroff has joined #ruby
NinoScript has joined #ruby
<toretore> u no online :/
<zenspider_> sounds like a simple require problem to me
<eladmeidar> toretore: m iz. just across the big blue thing.
cpruitt has quit [Quit: cpruitt]
peret has joined #ruby
<toretore> what blue thing?
mikepack has quit [Ping timeout: 255 seconds]
apeiros has quit [Remote host closed the connection]
<pontiki> i'm guessing a body of water
mikepack_ has quit [Ping timeout: 240 seconds]
<toretore> oh
Wolland has joined #ruby
apeiros has joined #ruby
<toretore> mediterreanean, which separates camel land from civilization
<eladmeidar> exactly that.
<eladmeidar> i haven't seen a camel in a while actually
NinoScript has quit [Read error: Connection reset by peer]
<eladmeidar> where are those pointy backed bastards?
<toretore> so how do you get to work?
<eladmeidar> pfft
<eladmeidar> a magic carpet maybe?
<eladmeidar> you know nothing tore tore.
x1337807x has joined #ruby
NinoScript has joined #ruby
shevy has joined #ruby
<toretore> at least im not a wildling
<pontiki> oo, GoT references
<toretore> i still remember that night in the cave fondly, eladmeidar
crocket has joined #ruby
<crocket> hi
<eladmeidar> oh.. the night in the cave... does your cave still burn?
<eladmeidar> (k)
<eladmeidar> crocket: hello!
<crocket> I want to manage app config in a SQLite3 database that is managed by database versioning tool.
<crocket> I think active record or standalone-migration would do the job.
<crocket> How do you think
<crocket> How do you think?
<toretore> don't need ar for that
<crocket> I need data manipulation and data definition in database migration scripts.
v0n has quit [Read error: Connection reset by peer]
DrCode has joined #ruby
<toretore> why are you making it so complicated?
<eladmeidar> AR seems to be an over kill.
<crocket> For data manipulation, I may need something beyond AR.
<eladmeidar> ^^
<crocket> toretore, Tell me a better solution, then.
<eladmeidar> go ahead toretore, do your thing
<crocket> toretore, A set of environment variables will lead to spaghetti configuration.
<toretore> i don't know anything about your problem, that's why i'm asking
JoshGlzBrk has joined #ruby
vyorkin has quit [Ping timeout: 240 seconds]
<ramfjord> crocket: can you just use the sqlite3 driver directly without activerecord?
sepp2k has quit [Read error: Connection reset by peer]
lolmaus has quit [Ping timeout: 240 seconds]
<crocket> toretore, I want people to know the exact set of configurations, and it's hard to manage if I have to notify environment variables via documentation.
T_Hunt has joined #ruby
<crocket> ramfjord, sqlite3 doesn't provide database migration.
<crocket> Plus, its API is crude at best.
NinoScript has quit [Read error: Connection reset by peer]
<crocket> What about standalone-migration?
<toretore> crocket: what makes your program different from all the others that are doing fine with env vars/whatever?
<ramfjord> or yaml config files
NinoScript has joined #ruby
<ramfjord> if you're loading it with migrations, you'll still have to keep passwords in version control
<ramfjord> but I see no problem with activerecord
<Eiam> can I coerce a type in a block into something else?
<crocket> ramfjord, I just don't want people to commit changes to config values.
<toretore> Eiam: elaborate
<crocket> People keep commiting little changes to config values, and that's annoying.
<eladmeidar> Eiam: a type in a block?
<Eiam> e.g. if i have blah = {"hello" => ["stuff"], "world"=>["stuff"]} and i want to blah.inject({}) {|sum,val|} I want Val to be the hash, not an array of it broken down
<eladmeidar> crocket: what would stop them from changing the db.
<crocket> eladmeidar, Changing the db requires changes to config keys.
<ramfjord> db perms
<Eiam> as it stands, Val is an array of [hello,["stuff"]]
narcan has joined #ruby
<toretore> Eiam: you probably want |sum, (key, value)|
<crocket> eladmeidar, They won't accidentally commit changes to config values.
* eladmeidar whispers "ask for ruby version..."
<crocket> ramfjord, What about standalone-migration?
<Eiam> hmm i guess that works yeah
<Eiam> that'll do
<eladmeidar> crocket: why are the config values, assuming they are currently in a file - are even in git?
<toretore> crocket: why is the config in the repo in the first place?
<Eiam> i can just reconstruct the object myself
<Eiam> thanks
<toretore> damnit elad
<eladmeidar> WHAT?
<crocket> toretore, I just want to specify config schema in the repo.
<toretore> you asked my question before me
dik_dak has joined #ruby
<toretore> crocket: what does that mean?
<crocket> toretore, My coworkers have put config in the repo because it's fast and cheap.
<toretore> and stupid
<toretore> as you've discovered