« Back to channel list

#ruby - 28 May 2015

« Back 1 day Forward 1 day »
[00:00:02] jstanton: has joined #ruby
[00:00:57] thiagovsk: has joined #ruby
[00:01:44] renanoronfle: has joined #ruby
[00:04:05] yh_: has joined #ruby
[00:06:14] nobitanobi: has joined #ruby
[00:07:05] rkazak: has joined #ruby
[00:07:22] RandyT: has joined #ruby
[00:07:25] kinduff: has joined #ruby
[00:07:37] wallerdev2: has joined #ruby
[00:07:45] baweaver: has joined #ruby
[00:08:55] jpfuente_: has joined #ruby
[00:10:51] leafybas_: has joined #ruby
[00:11:06] xxneolithicxx: oh man its water, its raining... take that california we have water! lol
[00:12:16] xxneolithicxx: oi on contrare, its very cool
[00:12:23] baweaver: Sharing is caring
[00:12:48] xxneolithicxx: we can ship snow, but i dont know if we are doing it with water yet, check your local costco
[00:13:12] baweaver: ACTION has heard costco mentioned 5 times today alone
[00:13:45] xxneolithicxx: i dont have any near me :-(
[00:14:13] shevy: there is so much water in the ocean
[00:14:38] Radar: nearest one to me is only 3.6km away TIL
[00:14:48] baweaver: But I can't dam the ocean shevy D:
[00:15:02] Radar: For those of you who still use Imperial that's approximately 5 buckets if my math is correct
[00:15:05] shevy: you'd have to be a giant beaver, or have like billion of beavers
[00:15:23] shevy: hmm actually you may run short of wood
[00:15:59] baweaver: Where there's a will there's a way
[00:16:10] pipework: In real imperials, that would be approximately 5 cubed feet of water per square inch.
[00:16:46] baweaver: We measure in obscure measurements of a person, so it'd be 4.35 Opera Hats, thank you.... @Radar
[00:16:59] Radar: baweaver: aha thank you
[00:17:05] Aeyrix: has left #ruby: ("#rubyonrails")
[00:17:20] sevenseacat: has joined #ruby
[00:17:34] baweaver: They still insist we're totally switching to Metric here in Elementary School
[00:17:42] baweaver: and have done so since the 70s
[00:19:24] rickmasta: has joined #ruby
[00:20:09] nateberkopec: has joined #ruby
[00:21:44] xxneolithicxx: shh dont think
[00:21:53] xxneolithicxx: pass your standardized test stupid
[00:22:46] baweaver: ACTION shrugs
[00:23:07] baweaver: I cared very little for school, just a piece of paper to get people's attention
[00:23:53] jpfuentes2: has joined #ruby
[00:23:54] bootstrappm: ACTION cared a lot
[00:24:14] bootstrappm: and now I'm in a country where very few people care about education for educations sake
[00:24:23] bootstrappm: just to get a job
[00:25:22] xxneolithicxx: isnt that how it is in most places
[00:25:56] xxneolithicxx: society equates being educated or smart with being an unpopular thing but makes it necessary for employment
[00:26:14] xxneolithicxx: and then wonder why kids dont want to get educated
[00:26:26] baweaver: Mind you I also read an average of 200 pages of fiction a day among other things
[00:26:42] xxneolithicxx: no no, im sorry thats just too damn high for me
[00:26:52] bootstrappm: haha yeah 200 is ambitious
[00:26:52] xxneolithicxx: im a slow reader
[00:27:12] bootstrappm: i think the highest i ever got was 100 in a day consistently and i was suuuuper into that series
[00:27:13] baweaver: I have 2 hours on a train for commute a day plus a bit extra at night
[00:27:14] xxneolithicxx: 50 pages and my brain tops out for one sitting
[00:27:17] bootstrappm: like obsessed
[00:27:24] bootstrappm: Wheel of Time if anybody knows it
[00:27:26] keen___________1: has joined #ruby
[00:27:36] baweaver: Read that in about a month and a half or so
[00:27:53] bootstrappm: the series? or some subset of books?
[00:28:11] baweaver: Mid August start and finished in early October
[00:28:20] baweaver: Look into Brandon Sanderson's works as well
[00:28:20] bootstrappm: really didn't like how it ended up but whatre you gonna do
[00:28:38] baweaver: Mistborn and The Stormlight Archive are great
[00:28:50] bootstrappm: yeah I wasn't a fan of how he finished the series once he got handed it ... maybe something thats more originally his will be better
[00:29:05] bootstrappm: i've heard really good things about mistborn
[00:29:06] baweaver: Though recently I've become fond of Arsene Lupin, Montmorency, and Eli Monpress novels.
[00:29:18] bootstrappm: i'm sad there weren't more derivative works of WoT
[00:29:26] bootstrappm: always wanted to make one
[00:29:46] baweaver: Give me about a year and I'll publish a fiction book in the same general fiction vein.
[00:30:30] baweaver: Somewhere north of 250 pages in the manuscripts so far and very near double that in notes and assorted musings
[00:31:54] baweaver: Granted I've also been working on that one since I was 15, so about 10 years now
[00:31:56] Radar: Brandon Sanderson is my hero
[00:32:02] Radar: true story
[00:32:17] Radar: baweaver: Have you read any of the Reckoners?
[00:32:18] bootstrappm: hahah at least you're still at it
[00:32:27] baweaver: His lectures are great too Radar
[00:32:35] baweaver: Not offhand
[00:32:38] baweaver: ACTION googles
[00:32:44] Oog: has joined #ruby
[00:32:51] moretti: has joined #ruby
[00:32:54] baweaver: Ah, that series
[00:32:54] Rager: is there a way to access @@ vars from the child class in a parent class?
[00:33:02] Rager: like... with some sort of late static binding
[00:33:02] baweaver: Saw it was YA and was a bit touchy about it
[00:33:27] blogjy: I looked here https://www.brightbox.com/docs/ruby/ubuntu/ I can't get this line to work $ ruby2.0 -S bundle -v <ENTER>
[00:33:27] blogjy: ruby2.0: No such file or directory -- bundle (LoadError)
[00:33:29] sevenseacat: i've heard a lot about wheel of time. never read them.
[00:33:32] baweaver: Not really, no.
[00:33:42] Oog: has joined #ruby
[00:33:45] baweaver: Rager: better question, why do you think you need to?
[00:33:54] Rager: let me source you some sorce
[00:34:01] Rager: and you can tell me why the way I'm doing things is improper
[00:34:10] Rager: http://hastebin.com/oroganurer.rb
[00:34:12] sevenseacat: theyre fantasy yeah? i think the only 'fantasy' books ive ever read in their entirety are game of thrones
[00:34:23] baweaver: sevenseacat: Worth it, but a bit slow to get into
[00:34:33] codex: has joined #ruby
[00:34:34] baweaver: ragar give me a sec to grok it
[00:34:38] charliesome: has joined #ruby
[00:34:56] Rager: and a child class: http://hastebin.com/govuzururo.vhdl
[00:35:11] sevenseacat: ACTION looks up first one and grabs it on Kindle
[00:35:13] Rager: problem is, I have more than one child class, but they all populate @@cleanup
[00:35:26] Rager: and they all share @@cleanup
[00:35:35] baweaver: http://www.dragonmount.com/forums/uploads/gallery/album_151/gallery_107_151_79433.jpg - sevenseacat
[00:35:46] baweaver: that scene in one of the later books makes it well worth it
[00:35:49] Radar: WoT has to be some of my favourite books
[00:36:18] bootstrappm: Battle of Dumai Wells as well
[00:36:29] Cache_Money: has joined #ruby
[00:37:02] baweaver: Ping me later at brandon_weaver@baweaver.com if you're interested in beta reading later
[00:37:05] Radar: Rager: Sounds like you want cattr_accessor from ActiveSupport, but I can't be sure.
[00:37:19] saadq: has joined #ruby
[00:37:21] baweaver: Rager: Almost looks like you just want to rename elements
[00:37:47] saadq: has joined #ruby
[00:37:58] baweaver: and the second is actually: http://hastebin.com/govuzururo.rb
[00:38:01] Rager: I want to create a mapping of good names to the bad names to be replaced
[00:38:32] dstarh: has joined #ruby
[00:38:32] mistermocha: has joined #ruby
[00:38:42] Rager: I figured I could just define a class that had the functionality
[00:38:55] shevy: class Improver
[00:38:56] Rager: maybe I should just put the common stuff into a module instead
[00:39:06] baweaver: More of a functional concept really, mapping between two hashes
[00:39:08] shevy: Improver.new(bad_name_here) # => returns 'good_name_here'
[00:39:11] Rager: that should probably at least sidestep the fact that child classes share @@ vars
[00:39:16] troyready: has joined #ruby
[00:39:16] Vile`: has joined #ruby
[00:39:30] baweaver: I'd solved this same thing some time earlier
[00:39:31] Rager: I just wanted a nice regular syntax for specifying the stuff
[00:39:34] baweaver: see if I can find it
[00:39:36] Rager: it works fine if I just have one class
[00:40:00] mordof: has joined #ruby
[00:40:11] _blizzy_: has joined #ruby
[00:40:35] michael_mbp: has joined #ruby
[00:40:58] Rager: not really looking to rip out my code to put in completely new code
[00:41:06] Rager: but it'd be nice to not rely on some sort of static var
[00:41:48] nobitanobi: has joined #ruby
[00:41:50] goodcodeguy: has joined #ruby
[00:41:58] baweaver: Just a sec, working out another version for it.
[00:43:12] baweaver: problem comes with collisions
[00:43:20] baweaver: what if you have more than one that comes up with one result?
[00:43:46] mrmargolis: has joined #ruby
[00:44:40] s2013: has joined #ruby
[00:46:45] shevy: this is a reason why beavers are considered nature's ecosystem engineers
[00:46:48] shevy: they think about that kind of stuff
[00:48:53] vikaton: >> [12,3,4]-[12,2,4]
[00:48:54] ruboto: vikaton # => [3] (https://eval.in/371514)
[00:52:20] sankaber: has joined #ruby
[00:52:53] cirn0: has joined #ruby
[00:53:11] dfockler: has joined #ruby
[00:53:12] commondream: has joined #ruby
[00:53:18] swgillespie: has joined #ruby
[00:53:58] goodcodeguy: has joined #ruby
[00:55:07] CloCkWeRX: has joined #ruby
[00:55:23] Rager: baweaver: I found the solution
[00:55:46] Rager: (for rails) just use class_attribute
[00:55:49] mello: has joined #ruby
[00:55:53] byprdct: has joined #ruby
[00:55:54] Rager: *so easy*
[00:55:57] robustus: has joined #ruby
[00:56:11] baweaver: http://hastebin.com/mesogepoda.rb
[00:56:18] baweaver: well if you want to mass rename hash elements
[00:58:17] Rager: you're going a little bit extremey
[00:58:35] Rager: this is to just produce a map of proper values onto lists of improper values
[00:59:02] MatthewsFace: has joined #ruby
[00:59:18] baweaver: Rename all impropers to proper
[00:59:20] sevenseacat: hastebin asploded
[00:59:27] baweaver: derivative of something I did earlier.
[00:59:29] sevenseacat: that link gives me a 500
[01:00:05] s2013: has joined #ruby
[01:00:07] baweaver: https://gist.github.com/baweaver/13c7cc798fc71332ff07
[01:00:29] chagel: has joined #ruby
[01:00:43] lampshades: has joined #ruby
[01:01:08] sevenseacat: its all about creating the awesome method interface :)
[01:01:46] baweaver: added example returns too at the bottom just now
[01:01:52] baweaver: Probably need better names but it works.
[01:02:10] codeFiend: has joined #ruby
[01:02:39] Rager: baweaver: I'm not trying to update a hash
[01:02:44] Rager: I'm trying to produce a hash for db updates
[01:02:48] RegulationD: has joined #ruby
[01:02:54] Rager: in any case, I have my solution
[01:02:59] prereflect: has joined #ruby
[01:03:20] Rager: http://hastebin.com/zuwesacake.rb
[01:03:35] Radar: "Application error"
[01:03:39] Radar: Rager: ?gist
[01:03:42] ruboto: https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[01:04:05] jacor: has joined #ruby
[01:04:08] Rager: https://bitbucket.org/snippets/AlanRager/AB7e
[01:04:10] Rager: hastebin's daed
[01:06:41] Rager: in any case, I found a *very* simple solution for the issue
[01:08:31] northfurr: has joined #ruby
[01:08:33] wallerdev2: has joined #ruby
[01:10:37] jpfuentes2: has joined #ruby
[01:11:58] iwishiwerearobot: has joined #ruby
[01:12:26] jacor_m: has joined #ruby
[01:13:09] qwertme: has joined #ruby
[01:15:25] mrsolo: has joined #ruby
[01:15:48] prereflect: has joined #ruby
[01:16:39] amclain: has joined #ruby
[01:16:50] luckyme: has joined #ruby
[01:19:09] tkuchiki: has joined #ruby
[01:19:16] Rubie: has joined #ruby
[01:20:30] blogjy: why is it that i can't send to channel #rubyonrails?
[01:20:42] bootstrappm: because you touch yourself at night
[01:20:44] pipework: blogjy: See /topic in #RubyOnRails
[01:21:09] afrianska: has joined #ruby
[01:21:23] Oog: has joined #ruby
[01:23:19] _seanc_: has joined #ruby
[01:25:19] pocketprotector: has joined #ruby
[01:25:32] nateberkopec: has joined #ruby
[01:27:48] garyserj: has joined #ruby
[01:27:53] bootstrappm: has left #ruby: ()
[01:28:05] garyserj: if i wanted to make an application with a GUI but not web, how would I go about that?
[01:29:52] baweaver: What have you tried?
[01:30:00] afrianska: has joined #ruby
[01:30:27] sevenseacat: not.... web..... doesnotcompute
[01:31:00] baweaver: ACTION smirks
[01:31:24] afrianska: helloo good morning..
[01:31:38] baweaver: garyserj: What have you tried?
[01:32:13] prereflect: has left #ruby: ("Textual IRC Client: www.textualapp.com")
[01:32:26] Cache_Money: has joined #ruby
[01:33:34] hewenhong: has joined #ruby
[01:34:40] pipework: garyserj: there's a plethora of unsatisfactory answers on this subject.
[01:34:46] baweaver: garyserj: Simple answer is you need to do some searching as this has been answered quite a few places already.
[01:34:48] danoo_: has joined #ruby
[01:34:48] NIGerGERmany: has joined #ruby
[01:34:57] NIGerGERmany: hi everyone i love ruby it's a great language
[01:35:02] baweaver: but in general, I wouldn't
[01:35:02] shtirlic: has joined #ruby
[01:35:12] sevenseacat: !ban NIGerGERmany
[01:35:17] rmoriz: has joined #ruby
[01:35:22] sevenseacat: dammit ruboto
[01:35:23] NIGerGERmany: i came here to help everyone
[01:35:26] RealMarc: has joined #ruby
[01:35:29] NIGerGERmany: i'm an experienced rubyist
[01:35:38] pipework: We're an exclusive club.
[01:35:39] NIGerGERmany: what did i do to deserve a ban?
[01:35:49] ChanServ: +o sevenseacat
[01:35:55] pipework: sevenseacat: Can you +b the web gateway for now?
[01:35:57] sevenseacat: +b *!6883d781@gateway/web/freenode/ip.
[01:35:59] sevenseacat: sevenseacat kicked NIGerGERmany: behavior is not conducive to the desired environment.
[01:36:13] baweaver: pipework: apeiros actually did some stats on that
[01:36:46] pipework: You shouldn't include the number between the ! and the @, just another asterisk would be preferable, but banning the whole web gateway for a few hours is often best when there's repetitive offenders.
[01:37:18] baweaver: Turns out to be something along the lines of 260 unique nicks and 30 some bans
[01:37:49] sparr: has joined #ruby
[01:38:15] larissa: has joined #ruby
[01:38:19] jalcine: has joined #ruby
[01:38:30] threh: has joined #ruby
[01:42:32] Radar: -b *!6883d781@gateway/web/freenode/ip.
[01:42:39] Radar: +b *!*@gateway/web/freenode/ip.
[01:42:58] Radar: pipework: happy?
[01:43:10] zreisman: has joined #ruby
[01:43:17] Radar: wow the #ruby ban list is full of nick bans
[01:43:29] shevy: garyserj did you try ruby-gnome bindings yet?
[01:44:03] pipework: Radar: Yeah should be fine. But if you see them pop up again from the web gateway, you should just ban *!*@gateway/web/freenode/* I think, but only for a few hours until the spam attack abates.
[01:44:13] sevenseacat: its probably me doing it wrong.
[01:44:19] shevy: garyserj there are not that many options ... ruby-gnome/ruby-gtk, ruby-qt, shoes, ruby-tk, ruby-wxwidgets... hmm fxruby in the past... I may have forgotten a few more
[01:44:43] shevy: cats do not do anything wrong by definition alone
[01:44:54] Radar: pipework: this is not an hourly thing. This is something that happens nearly every day
[01:44:57] pipework: They do things precisely as they mean for them to be done.
[01:45:09] Radar: pipework: banning the gateway means that we ban any regular users who are connected on that too
[01:45:12] pipework: Radar: No, there's an actual attack going on against a lot of freenode right miaow, that's what I mean.
[01:45:17] northfurr: has joined #ruby
[01:45:25] shevy: right miaow - you did that on purporse
[01:45:27] pipework: A large number of rather large channels are seeing much worse.
[01:45:39] yh_: has joined #ruby
[01:45:55] pipework: 4 hours of not being able to access this channel isn't that bad. I bet you could set a ban-forward though.
[01:46:16] Radar: A ban forward would be fine but I am not allowed to do things without consulting with other ops :)
[01:46:29] Radar: And it wouldn't completely solve the problem anyway, as those other users can just join whenever
[01:46:36] NIG_GERS: has joined #ruby
[01:46:41] NIG_GERS: who's the joker that klined me?
[01:46:46] pipework: Radar: I don't personally mind if someone just keeps banning these spammers.
[01:46:48] Radar: !ban NIG_GERS !T 1D
[01:46:49] ChanServ: +b NIG_GERS!*@*
[01:46:49] ChanServ: ChanServ kicked NIG_GERS: is banned from this channel
[01:46:56] Radar: I'm fine with banning them as they pop up.
[01:46:57] sevenseacat: oh thats how to do it.
[01:46:57] duderonomy: has joined #ruby
[01:46:59] pipework: That bot should be fixed.
[01:47:13] sevenseacat: ACTION writes notes
[01:47:18] ChanServ: -o sevenseacat
[01:47:20] pipework: I could keep the same IP and everything and just change the ident and rejoin.
[01:47:24] Radar: pipework: Yes.
[01:47:32] Radar: ACTION will stay op'd
[01:47:40] Radar: -b NIG_GERS!*@*
[01:47:42] pipework: Good luck and good hunting.
[01:47:51] Radar: pipework: How do I set a +b ban with a time limit?
[01:47:58] kinduff: has joined #ruby
[01:47:58] pipework: Radar: I don't think you can.
[01:48:06] longfeet: has joined #ruby
[01:48:30] pipework: Radar: Freenode staff sometimes disallows connecting from different gateways anways during these onslaughts.
[01:48:42] Radar: +b *!*@
[01:48:47] sevenseacat: when i went to ask them, they just told me to add +q ~a.
[01:48:50] Radar: -b *!*@
[01:48:51] sevenseacat: to the channel.
[01:48:53] Radar: -b *!*@*
[01:49:02] Radar: sevenseacat: :) That's right.
[01:49:09] Radar: That would totally abate these spammers imo
[01:49:17] sevenseacat: ACTION shrugs
[01:49:21] sevenseacat: that got shot down, so
[01:49:22] pipework: sevenseacat: Quiet all unidentified accounts works, but then you need to make web gateway users auth with nickserv.
[01:49:28] Radar: notice how #rubyonrails doesn't get those spammers?
[01:49:32] sevenseacat: pipework: i have no problem with that.
[01:49:39] pipework: Me neither.
[01:49:58] pipework: Just raises that bar a little more.
[01:50:09] sevenseacat: i would have no problem with disallowing the web gateway entirely.
[01:50:29] Hien: has joined #ruby
[01:50:38] Radar: how about we +q the web gateway?
[01:50:52] sevenseacat: better put it to another vote.
[01:53:00] Radar: *shrug* I will just ban people as they keep coming in
[01:53:06] Radar: I can keep it up longer than they can ;)
[01:53:11] pipework: Y'all might benefit from enlisting a freenode staffer that also likes ruby. There's generally workflows for handling this stuff that's an expected norm, so you don't need to democratize the situation if you want.
[01:53:27] sevenseacat: people will crack the shits if we dont.
[01:53:33] pipework: It's mostly just a solved problem on how to handle that stuff.
[01:53:41] that1guy: has joined #ruby
[01:53:44] Radar: sevenseacat: yup :)
[01:54:05] pipework: sevenseacat: I'd say they'd be amateurs, as there's IRC social protocol for ops that is likely older than the people who would get upset.
[01:54:48] pipework: But I'm just glad not to be an op. I'd have too much fun.
[01:55:22] mistermocha: has joined #ruby
[01:56:45] pontiki: has joined #ruby
[01:57:38] blazes816: has joined #ruby
[01:59:11] shevy: hey pontiki you missed a lot of troll-action today
[02:00:34] afrianska: has joined #ruby
[02:00:41] cleopatra: has joined #ruby
[02:00:48] cleopatra: helloooooooooooo
[02:00:58] marsjaninzmarsa: has joined #ruby
[02:01:10] claptor: has joined #ruby
[02:01:24] cleopatra: hello friend good ruby ebook?
[02:01:26] goodcodeguy: has joined #ruby
[02:02:09] prereflect: has joined #ruby
[02:02:12] pipework: cleopatra: yes
[02:02:21] marsjaninzmarsa: i'm doing GitLab instalation guide https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/install/installation.md
[02:02:27] cleopatra: hello pipework :) long time no see you
[02:02:46] marsjaninzmarsa: and in point: Check Application Status Check if GitLab and its environment are configured correctly
[02:02:48] pipework: cleopatra: Is ruby your first programming language?
[02:02:58] marsjaninzmarsa: is not described what to do if not...
[02:03:08] marsjaninzmarsa: http://paste.mac.info.pl/?8f750eb26b11d088#tgpe1poITXY/hNsWYatawUPL7KLwW2vI5dl21SNlYhY=
[02:03:28] pipework: I wonder where people get their obscure paste sites from.
[02:03:36] RegulationD: has joined #ruby
[02:04:02] marsjaninzmarsa: i'm not into ruby, but it it looks like problem with my gems. :D
[02:04:21] charliesome: has joined #ruby
[02:04:24] cleopatra: pipework no really I practice a litle c++
[02:04:50] pipework: cleopatra: Learn to Program might be good to get that boring but important basic knowledge down.
[02:05:36] cleopatra: i see pipework
[02:06:11] hewenhong: has joined #ruby
[02:06:18] Radar: Totally blanking on the Ruby shortcut for this: https://gist.github.com/radar/ae2c69ed608ec83b69ad
[02:06:25] Radar: I know there is one
[02:06:42] sevenseacat: [a+b, 0].max ?
[02:06:54] cleopatra: hello Radar my her0
[02:07:00] Radar: cleopatra: hello
[02:07:06] Radar: sevenseacat: that'll do the trick!
[02:07:14] cleopatra: and sevenseacat hi!
[02:07:18] sevenseacat: cleopatra: howdy :)
[02:07:32] cleopatra: I'm bored I would like to read a good book of ruby
[02:07:35] sevenseacat: thats one of the things i revert to phpisms on. i always want to write max([a+b, 0])
[02:07:59] marsjaninzmarsa: pipework: pastebin is cool, i'm using it out of habit for everything except Lisp... ^^'
[02:08:42] pipework: (a + b).abs maybe?
[02:09:06] pipework: Aww not quite.
[02:09:16] Radar: cleopatra: The Well-Grounded Rubyist is what I would recommend
[02:09:31] Scripore: has joined #ruby
[02:09:35] wallerdev: has joined #ruby
[02:11:06] cleopatra: Radar, http://www.manning.com/black2/ ??
[02:11:19] dru``: has joined #ruby
[02:11:21] sevenseacat: http://www.manning.com/black3/
[02:11:21] marsjaninzmarsa: whatever, how to debug it? looks like reinstalling this local gems (am I calling it right?) should do the trick, but how?
[02:11:55] cleopatra: thanks sevenseacat
[02:15:23] hewenhong: has joined #ruby
[02:17:23] GriffinHeart: has joined #ruby
[02:17:39] chipotle: has joined #ruby
[02:23:04] cirn0: has joined #ruby
[02:23:35] nateberkopec: has joined #ruby
[02:24:20] darkf: has joined #ruby
[02:25:30] aphprentice: has joined #ruby
[02:26:16] Cache_Money: has joined #ruby
[02:27:41] greenbagels: has joined #ruby
[02:28:58] mase-chatter: has joined #ruby
[02:29:04] kinduff: has joined #ruby
[02:30:29] ebonics: has joined #ruby
[02:32:38] penzur: has joined #ruby
[02:33:39] duderonomy: has joined #ruby
[02:37:15] nobitanobi: has joined #ruby
[02:40:19] jtdowney: has joined #ruby
[02:40:32] davedev24_: has joined #ruby
[02:43:06] Igorshp: has joined #ruby
[02:44:40] mello: has joined #ruby
[02:45:35] mrsolo: has joined #ruby
[02:46:17] saadq: has joined #ruby
[02:47:09] Hanmac: has joined #ruby
[02:47:11] Oog: has joined #ruby
[02:47:32] Channel6: has joined #ruby
[02:50:50] codex: has joined #ruby
[02:51:15] GPrime: has joined #ruby
[02:54:44] gambl0re: has joined #ruby
[02:57:25] mike_bueti: has joined #ruby
[02:58:18] sevenseacat: has joined #ruby
[02:58:20] rickmasta: has joined #ruby
[02:59:41] bronson: has joined #ruby
[03:00:24] StephenOTT: has joined #ruby
[03:02:06] someword: has joined #ruby
[03:02:39] vt102: has joined #ruby
[03:02:40] zreisman: has joined #ruby
[03:02:56] nahtnam: has joined #ruby
[03:02:56] crdpink: has joined #ruby
[03:04:32] that1guy: has joined #ruby
[03:04:54] Limix: has joined #ruby
[03:05:28] psye: has joined #ruby
[03:06:30] shevy: I still have not determined which colours are safe to use on which terminal
[03:07:01] tcrypt: has joined #ruby
[03:07:29] shevy: It is said that xterm has support for 256 colours
[03:07:53] that1guy: has joined #ruby
[03:09:10] Scripore: has joined #ruby
[03:10:46] wallerdev: has joined #ruby
[03:12:05] braincrash: has joined #ruby
[03:12:40] al2o3-cr: shevy: printf "\e[38;5;177mShevy\e[0m\n"
[03:13:25] shevy: yeah this is pinkish on my kde konsole
[03:13:31] shevy: and white on my xterm :(
[03:14:18] al2o3-cr: pink on both xterm xfce4-terminal on mine
[03:17:45] al2o3-cr: shevy: what color does this show printf "\e[38;5;190m\e[48;5;200mShevy\e[0m\n"
[03:17:57] Spami: has joined #ruby
[03:19:35] HotCoder: has joined #ruby
[03:20:18] shevy: on kde konsole it works... ugly yellow on ugly pinkish background
[03:20:22] shevy: you want to poke out my eyes :(
[03:20:52] shevy: interestingly, tput colors reports 256 on xterm
[03:21:03] elfuego: has left #ruby: ()
[03:21:18] al2o3-cr: I've just tried on xterm Eterm urxvt gnome-terminal xfce-terminal they all work hmm.
[03:21:26] that1guy: has joined #ruby
[03:21:35] shevy: al2o3-cr do you have a special environment variable set?
[03:22:45] shevy: I'll figure it out tomorrow, have to sleep soon
[03:25:06] swgillespie: has joined #ruby
[03:27:56] jpfuentes2: has joined #ruby
[03:27:58] bosma: has joined #ruby
[03:28:14] freerobby: has joined #ruby
[03:31:22] iamninja: has joined #ruby
[03:34:55] baweaver: has joined #ruby
[03:35:35] danoo_: has joined #ruby
[03:35:36] RealMarc: has joined #ruby
[03:35:41] shtirlic: has joined #ruby
[03:35:57] rmoriz: has joined #ruby
[03:36:44] hewenhong: has joined #ruby
[03:37:08] kiki_lamb: How can I chain / concatenate / append two Enumerators so that I can loop over both?
[03:37:36] chagel: has joined #ruby
[03:43:11] hololeap: has joined #ruby
[03:44:17] Deele: has joined #ruby
[03:48:05] parrow: has joined #ruby
[03:51:54] that1guy: has joined #ruby
[03:51:55] Hijiri: has joined #ruby
[03:52:24] RegulationD: has joined #ruby
[03:52:45] baweaver: kiki_lamb: Why?
[03:52:50] hewenhong: has joined #ruby
[03:53:51] ravenreborn: has joined #ruby
[03:55:30] baweaver: The cheap way would be to just unfold them into arrays
[04:03:36] bluOxigen: has joined #ruby
[04:03:38] bluOxigen: has joined #ruby
[04:03:44] blenny: has left #ruby: ("Bye")
[04:04:02] baweaver: Though if you really need to join them: https://gist.github.com/baweaver/0ede48ada992522c36d4
[04:05:47] blueOxigen: has joined #ruby
[04:05:56] baweaver: >> class Enumerator; def joins(other) Enumerator.new{|y|self.each {|i|y<< i};other.each{|i|y<< i}}end end; [1,2].to_enum.joins([3,4]).to_a
[04:05:57] ruboto: baweaver # => [1, 2, 3, 4] (https://eval.in/371531)
[04:08:07] CalvinnHobbes: has joined #ruby
[04:08:16] baweaver: or the cheeky way: def joins(other) Enumerator.new(self.to_a + other) end
[04:10:06] nobitanobi: has joined #ruby
[04:11:34] wallerdev: has joined #ruby
[04:13:32] BTRE: has joined #ruby
[04:17:05] michael_mbp: has joined #ruby
[04:18:01] zarubin: has joined #ruby
[04:19:44] yh_: has joined #ruby
[04:25:07] gusrub: has joined #ruby
[04:26:15] pocketpr1tector: has joined #ruby
[04:26:55] Channel6: has joined #ruby
[04:29:05] djbkd: has joined #ruby
[04:33:20] mello: has joined #ruby
[04:33:35] Oog: has joined #ruby
[04:37:09] charliesome: has joined #ruby
[04:39:39] ohaibbq: has joined #ruby
[04:39:41] riotjones: has joined #ruby
[04:40:10] hewenhong: has joined #ruby
[04:42:34] awwaiid: has joined #ruby
[04:44:20] rkazak: has joined #ruby
[04:45:35] workmad3: has joined #ruby
[04:46:09] rkazak: has joined #ruby
[04:47:59] rickmasta: has joined #ruby
[04:49:51] Brando753: has joined #ruby
[04:49:53] afrianska: has joined #ruby
[04:50:35] hololeap: hi everyone. if i have two modules which define a method and i include both, which will get the preference? does one erase the other or can it call the other's through super()?
[04:52:25] weemsledeux: has joined #ruby
[04:53:18] sevenseacat: the one you include later i believe.
[04:54:00] zodiak_: has joined #ruby
[04:55:57] johnny_dz: has joined #ruby
[04:58:23] A205B064: has joined #ruby
[04:59:02] Radar: hololeap: https://gist.github.com/radar/eb36c3e0f11934fb0034
[04:59:30] Radar: super in the class's method will call the most recently included one, but you can get to the method before that by calling super on that method.
[04:59:45] Radar: This is because of Cow's ancestors: irb(main):024:0> Cow.ancestors
[04:59:45] Radar: => [Cow, B, A, Object, Kernel, BasicObject]
[05:00:01] hololeap: Radar: awesome :) thank you
[05:00:15] pocketpr1tector: has joined #ruby
[05:00:26] NIGGGGERS: has joined #ruby
[05:00:43] ruboto: sepp2k, banisterfiend, fflush, apeiros, Mon_Ouie, seanstickle, zzak, Radar, Havenn, jhass, sevenseacat, miah, workmad3, Coraline, drbrain, zenspider, slyphon, Aria, rubyhacker1, ljarvis
[05:00:44] Radar: +b *!*@
[05:00:46] Radar: +b *!*@*
[05:00:49] Radar: -b *!*@
[05:00:51] Radar: !kick NIGGGGERS
[05:00:51] helpa: Radar: No.
[05:00:52] ruboto: ruboto kicked NIGGGGERS:
[05:00:52] ruboto: -o ruboto
[05:01:06] sevenseacat: !ban NIGGGGERS !T 1D
[05:01:06] ruboto: sevenseacat, could not find a matching user for "NIGGGGERS"
[05:01:21] Nilium: Good job, bot.
[05:02:01] baweaver: Could make an auto-ban on any variant of explitives
[05:02:58] mozzarella: that's racist
[05:03:26] hololeap: an auto-ban bot would probably get too many false positives, imo
[05:04:21] jack_rabbit: has joined #ruby
[05:04:30] towski_: has joined #ruby
[05:05:07] sevenseacat: one day that guy will get bored of being racist and leave us alone.
[05:05:32] commondream: has joined #ruby
[05:06:13] sinequanon: has joined #ruby
[05:07:53] ndrei: has joined #ruby
[05:08:22] chrissonar: has joined #ruby
[05:10:36] lkba: has joined #ruby
[05:13:20] Radar: It's probably 4chan or some other group
[05:13:28] Radar: Doubt it's just one person
[05:14:18] Radar: And judging by the previous IP, they're using digital ocean boxes
[05:14:49] baweaver: I guess you could say.....
[05:14:56] baweaver: they're on your Radar
[05:15:01] djbkd: has joined #ruby
[05:15:58] dru`: has joined #ruby
[05:16:24] baweaver: ACTION bows
[05:16:29] Radar: Of the last 3 bans, 2 of those have been digital ocean boxes.
[05:19:06] mozzarella: don't ban all of digitalocean, I'm using it
[05:19:33] Radar: mozzarella: Of course I wouldn't do that.I am using it too :)
[05:20:18] baweaver: They know O_O
[05:21:35] Radar: Opened a support ticket for DO to investigate: http://i.imgur.com/Bsgjfue.png
[05:22:51] MEATCHICKEN: has joined #ruby
[05:22:53] MEATCHICKEN: Why is this invalid? Date.parse("06/27/2005")
[05:22:59] Radar: meatchicken: why not?
[05:23:08] lkba: has joined #ruby
[05:23:13] miah: >> Date.parse("06/27/2005")
[05:23:15] ruboto: miah # => uninitialized constant Date (NameError) ...check link for more (https://eval.in/371580)
[05:23:25] Radar: >> require 'date'; Date.parse("06/27/2005")
[05:23:26] ruboto: Radar # => invalid date (ArgumentError) ...check link for more (https://eval.in/371581)
[05:23:45] Radar: meatchicken: Why are your dates not formatted sensibly? :)
[05:24:00] mozzarella: >> require 'date'; Date.parse("27/06/2005")
[05:24:01] ruboto: mozzarella # => #<Date: 2005-06-27 ((2453549j,0s,0n),+0s,2299161j)> (https://eval.in/371582)
[05:24:08] Radar: >> Date.strptime("06/27/2005","%m/%d/%Y")
[05:24:09] ruboto: Radar # => uninitialized constant Date (NameError) ...check link for more (https://eval.in/371583)
[05:24:11] hewenhong: has joined #ruby
[05:24:18] Radar: >> require 'date'; Date.strptime("06/27/2005","%m/%d/%Y")
[05:24:19] ruboto: Radar # => #<Date: 2005-06-27 ((2453549j,0s,0n),+0s,2299161j)> (https://eval.in/371584)
[05:24:20] tagrudev: has joined #ruby
[05:24:39] miah: interesting. i haven't used date much
[05:24:45] MEATCHICKEN: Radar: I thought that was standard format :P
[05:24:53] Radar: meatchicken: hahahahahahaha no
[05:25:06] Radar: http://3.bp.blogspot.com/_0X1ggm5ZqsA/TPUeed--TLI/AAAAAAAAJrI/xtW4XgR6Q_Y/s1600/whatamerica.png
[05:25:10] MEATCHICKEN: MM/DD/YYYY isn't okay?
[05:26:11] mozzarella: Radar: that's what I??think of when I see American dates
[05:26:22] tesuji: has joined #ruby
[05:26:29] Radar: meatchicken: Use Date.strptime like I showed.
[05:26:35] sevenseacat: lol american dates
[05:26:35] jenrzzz: has joined #ruby
[05:29:28] Soda: has joined #ruby
[05:29:43] miah: we're also stuck on imperal measurements
[05:31:33] awwaiid: has joined #ruby
[05:32:55] Robr3rd: has joined #ruby
[05:34:07] chinmay_dd: has joined #ruby
[05:34:39] Robr3rd: While running `rake test` (learning Ruby) and I'm running across this message from rake: "NoMethodError: undefined method `has_key?` for nil:NilClass" and am unsure of what to make of it. Google has been unhelpful. The method is being called ona hash.
[05:36:00] mozzarella: looks like it's being called on nil
[05:38:40] Robr3rd: Ah, I found it. Thanks
[05:39:02] hololeap: is there a way to get all the same functionality of `rails console` from irb?
[05:39:26] sevenseacat: why wouldnt you just use rails console
[05:39:26] last_staff: has joined #ruby
[05:39:32] hololeap: sevenseacat: it's not a rails app
[05:39:47] sevenseacat: so what functionality are you missing
[05:40:08] hololeap: sevenseacat: hmm, probably just autocompletion and reload!
[05:41:02] hololeap: sevenseacat: ok i found the autocompletion part: require 'irb/completion'
[05:42:33] hololeap: and i guess the reload! method is part of railties. i suppose i could just pull those in from the command line
[05:44:26] baweaver: hololeap: Pry
[05:44:34] flughafen: sup sevenseacat certainty shevy
[05:47:49] rocknrollMarc: has joined #ruby
[05:47:58] ahmetkapikiran: has joined #ruby
[05:52:16] mcpierce: has joined #ruby
[05:53:09] yeticry: has joined #ruby
[05:54:12] n008f4g_: has joined #ruby
[05:55:51] sigurding: has joined #ruby
[05:57:08] Takle: has joined #ruby
[05:58:38] yeticry: has joined #ruby
[06:00:30] sinkensabe: has joined #ruby
[06:00:53] riotjones: has joined #ruby
[06:01:05] aganov: has joined #ruby
[06:01:33] multi_io: has joined #ruby
[06:02:06] slucx: has joined #ruby
[06:02:16] krz: has joined #ruby
[06:02:18] DerisiveLogic: has joined #ruby
[06:02:39] Oog: has joined #ruby
[06:08:26] hewenhong: has joined #ruby
[06:09:17] Radar: DigitalOcean is looking at the support request \p/
[06:09:43] flughafen: go go Radar !
[06:11:52] hewenhong: has joined #ruby
[06:11:54] that1guy: has joined #ruby
[06:14:00] ahmetkapikiran: has joined #ruby
[06:16:00] fabrice31: has joined #ruby
[06:17:00] wallerdev: has joined #ruby
[06:17:20] bronson: has joined #ruby
[06:17:42] baweaver: The powers of the ban hammer range far and wide
[06:18:45] sevenseacat: so if that spammer is using DO, then they're *paying money* to annoy us?
[06:18:45] sinequanon: has joined #ruby
[06:18:55] zarubin: has joined #ruby
[06:19:01] fabrice31_: has joined #ruby
[06:19:19] alphaatom: has joined #ruby
[06:19:30] Kovensky: has joined #ruby
[06:19:35] afrianska: has joined #ruby
[06:19:39] dfockler: has joined #ruby
[06:20:38] alphaatom: has joined #ruby
[06:22:05] mello: has joined #ruby
[06:22:17] iamninja: has joined #ruby
[06:22:25] certainty: flughafen: o/
[06:22:30] flughafen: oi oi oi certainty
[06:22:38] alphaatom: has joined #ruby
[06:22:52] yardenbar: has joined #ruby
[06:22:59] stoffus: has joined #ruby
[06:23:51] alphaatom: has joined #ruby
[06:26:01] jack_rabbit: has joined #ruby
[06:27:33] flughafen: certainty: you don't ride motorcycles do you?
[06:27:44] certainty: flughafen: nope, i have no license
[06:28:10] crdpink2: has joined #ruby
[06:28:51] bosma: has joined #ruby
[06:29:05] eam: don't need a license to ride a motorcycle so long as your bike is faster than the cop's bike
[06:29:06] certainty: but sometimes i wish i had. sitting in the warm car seeing the motorcycles cruising the street
[06:29:07] roolo: has joined #ruby
[06:29:52] chinmay__: has joined #ruby
[06:29:55] ndrei: has joined #ruby
[06:31:56] sinequanon: has joined #ruby
[06:31:59] sandelius: has joined #ruby
[06:34:18] zipace: has joined #ruby
[06:34:38] Hounddog: has joined #ruby
[06:34:41] zipace: has joined #ruby
[06:34:41] zipace: has joined #ruby
[06:34:58] workmad3: has joined #ruby
[06:36:25] GriffinHeart: has joined #ruby
[06:36:31] towski_: has joined #ruby
[06:36:48] ta: has joined #ruby
[06:37:46] rht: has joined #ruby
[06:38:07] doublemalt_: has joined #ruby
[06:38:39] Macaveli: has joined #ruby
[06:39:01] andikr: has joined #ruby
[06:41:44] bayed: has joined #ruby
[06:44:49] charliesome: has joined #ruby
[06:45:26] Robr3rd: has joined #ruby
[06:45:35] awwaiid: has joined #ruby
[06:46:31] _blizzy_: has joined #ruby
[06:46:48] msgodf: has joined #ruby
[06:47:29] Robr3rd: Are there any simple-but-functional methods of implementing Rails' `.blank?` method in "pure" Ruby?
[06:48:34] lkba: has joined #ruby
[06:48:58] flughafen: certainty: does your car not have klima?
[06:49:02] wildroman2: has joined #ruby
[06:49:05] michael_mbp: has joined #ruby
[06:49:20] fabrice31: has joined #ruby
[06:49:42] flughafen: ACTION is having to deal with stupid tire crap with the motorcycle
[06:49:47] Robr3rd: I mean, I see this: http://stackoverflow.com/questions/5901701/duplicating-blank-in-standard-ruby I am just uncertain on how best to integrate it, and if I will need to also do the same for all data types (not just "String")
[06:49:49] certainty: flughafen: it does, but it takes time to cool down
[06:50:22] afrianska: has joined #ruby
[06:51:07] Alayde: has joined #ruby
[06:55:23] Coldblackice: has joined #ruby
[06:55:59] Macaveli: has joined #ruby
[06:56:02] gauke: has joined #ruby
[06:56:38] gluten_hell: has joined #ruby
[06:57:53] arup_r: has joined #ruby
[06:58:23] kriskropd: has joined #ruby
[07:00:00] Hijiri: has joined #ruby
[07:03:43] ravenreborn_: has joined #ruby
[07:03:49] lyuben_: has joined #ruby
[07:03:55] Oog: has joined #ruby
[07:09:22] apeiros: Robr3rd: rails' blank? is pure ruby. you can simply copy the code. alternatively you can depend on the active_support gem and require 'active_support/core_ext'
[07:12:38] wallerdev: has joined #ruby
[07:13:01] lkba: has joined #ruby
[07:13:59] Ilyes512: has joined #ruby
[07:14:40] antgel: has joined #ruby
[07:16:02] Radar: sevenseacat: Yes, it looks like the spammer is paying for the privilege. Looking at the other cases they're also using some VPN services to do the same thing. Whoever it is, they're pretty bored and wasting their time :)
[07:17:18] awwaiid: has joined #ruby
[07:17:26] saadq: has joined #ruby
[07:20:57] msgodf: has joined #ruby
[07:22:01] dcarmich: has joined #ruby
[07:22:42] GriffinHeart: has joined #ruby
[07:22:51] gluten_hell_: has joined #ruby
[07:22:55] mello: has joined #ruby
[07:23:37] chagel: has joined #ruby
[07:23:57] User458764: has joined #ruby
[07:26:49] Musashi007: has joined #ruby
[07:28:09] sdwrage: has joined #ruby
[07:29:41] quimrstorres: has joined #ruby
[07:30:12] RegulationD: has joined #ruby
[07:31:10] northfurr: has joined #ruby
[07:31:46] senayar: has joined #ruby
[07:31:53] Takle: has joined #ruby
[07:32:39] arietis: has joined #ruby
[07:33:14] Hanmac: has joined #ruby
[07:33:38] livathinos: has joined #ruby
[07:34:10] quimrstorres: has joined #ruby
[07:35:46] OrbitalKitten: has joined #ruby
[07:36:09] arietis: has left #ruby: ()
[07:36:34] KrzaQ: http://ruby-doc.org/core-2.2.2/Enumerable.html#method-i-chunk
[07:36:46] KrzaQ: the doc says chunk is deprecated, but doesn't offer anything instead
[07:37:26] ahmetkapikiran: has joined #ruby
[07:38:54] ljarvis: KrzaQ: group_by
[07:39:10] ljarvis: well, not exactly but you can do the same thing
[07:39:35] KrzaQ: well, I want to split the same keys, so to speak, into different records
[07:39:46] KrzaQ: oh, well, it's a one-time thing
[07:41:04] skammer: has joined #ruby
[07:41:14] ljarvis: actually I don't think the method is deprecated, it's just the state management that's been deprecated
[07:41:23] ljarvis: i.e chunk(initial_state)
[07:41:51] KrzaQ: that I can live with
[07:42:40] rippa: has joined #ruby
[07:43:12] KrzaQ: Can I use group_by with &:foo if :foo is a hash's key in an array of hashes?
[07:44:18] KrzaQ: .group_by{ |data| data
[07:44:25] KrzaQ: .group_by{ |data| data[:foo] } seems clunky to me
[07:44:33] KrzaQ: stupid enter key
[07:45:33] ljarvis: well, you could always map to an ostruct and then use &:foo but I'm gonna say that's more clunky and silly
[07:45:50] KrzaQ: I'm a newbie, I dunno what an ostruct is
[07:46:04] ljarvis: http://ruby-doc.org/stdlib-2.0/libdoc/ostruct/rdoc/OpenStruct.html
[07:46:37] ljarvis: items.map { |h| OpenStruct.new(h) }.map(&:foo) basically
[07:46:54] quimrstorres: has joined #ruby
[07:46:58] ljarvis: also, if the :foo key is last/first then you could use &:last / first
[07:47:04] ljarvis: but obviously that'll rely on the fact
[07:47:27] ljarvis: and it'll return the key and values iirc
[07:47:28] KrzaQ: it magically changes as I add more fields
[07:47:48] ljarvis: right, then group_by { |x| x[:foo] } it is :)
[07:51:38] ta: has joined #ruby
[07:52:47] charliesome: has joined #ruby
[07:53:24] KrzaQ: okay, this obviously isn't doing what I want
[07:53:47] tomphp: has joined #ruby
[07:54:03] KrzaQ: I have a telegram, identified let's say by id = "1" that can have 0 to ??? answers with id different than said "1"
[07:54:18] anisha: has joined #ruby
[07:54:24] KrzaQ: I want to group them in a way that always starts with the one with id = "1"
[07:54:36] ljarvis: KrzaQ: I think you should paste your code and desired output on gist.github.com
[07:56:09] codecop: has joined #ruby
[07:59:08] Takle: has joined #ruby
[08:01:05] jpfuentes2: has joined #ruby
[08:01:09] iamninja: has joined #ruby
[08:05:56] KrzaQ: ljarvis: http://melpon.org/wandbox/permlink/jVNV1nKD8nZBcslw
[08:06:21] sevenseacat: you give people a URL to paste stuff at, and they go away and find a different paste site
[08:06:45] KrzaQ: fast, ad-free, executes your code
[08:06:55] ljarvis: it's not loading for me
[08:07:04] ljarvis: ah nevermind
[08:07:07] KrzaQ: very well
[08:07:15] KrzaQ: https://gist.github.com/KrzaQ/0ba39962e8bc1a58d498
[08:07:20] Takle: has joined #ruby
[08:08:42] quimrstorres: has joined #ruby
[08:09:13] chthon: has joined #ruby
[08:09:41] ljarvis: >> (1..20).to_a.slice_before { |n| n % 3 == 0 }
[08:09:44] ruboto: ljarvis # => #<Enumerator: #<Enumerator::Generator:0x40fc3f60>:each> (https://eval.in/371653)
[08:09:47] ljarvis: >> (1..20).to_a.slice_before { |n| n % 3 == 0 }.to_a
[08:09:48] ruboto: ljarvis # => [[1, 2], [3, 4, 5], [6, 7, 8], [9, 10, 11], [12, 13, 14], [15, 16, 17], [18, 19, 20]] (https://eval.in/371654)
[08:10:32] KrzaQ: What if there are two consecutive threes, for example?
[08:10:52] KrzaQ: I'd like them to be kept in the same array, I guess
[08:10:58] sevenseacat: oh ho new requirements
[08:11:13] ljarvis: sevenseacat: is that something a pimp would say?
[08:11:15] KrzaQ: Obviously, you didn't expect my requirements not to change, did you? ;)
[08:11:34] apeiros: KrzaQ: it would have been a pleasant surprise, though
[08:11:56] sevenseacat: KrzaQ: to be fair, you're a programmer, we have slightly higher expectations
[08:12:01] apeiros: ljarvis: great. now I picture sevenseacat with fedora, fur coat and a pimp stick
[08:12:04] granthatcher: has joined #ruby
[08:12:07] Igorshp: has joined #ruby
[08:12:12] KrzaQ: I'm tired and in hurry :P
[08:12:16] sevenseacat: now i want a pimp stick
[08:12:34] dudedudeman: has joined #ruby
[08:13:09] adaedra: You're all weird in here >_>
[08:13:14] ljarvis: KrzaQ: open irb and play to your heards content
[08:13:19] apeiros: that said, I actually don't have any cliche on woman pimps. but I think the male pimp cliche is fabulous with women too :D
[08:13:36] yh_: has joined #ruby
[08:13:49] yeticry: has joined #ruby
[08:13:49] sevenseacat: ACTION bops noobs and spammers over the head with said pimp stick
[08:14:03] ljarvis: pimp stick bop
[08:14:05] KrzaQ: I have pry open
[08:14:07] ljarvis: that's the name of my band
[08:14:16] apeiros: ACTION enjoys waiting for his integration test with external API
[08:14:23] KrzaQ: someone recommended it over irb
[08:14:34] Takle: has joined #ruby
[08:14:34] KrzaQ: someone here*
[08:14:38] ljarvis: apeiros: that sounds teeth grindingly awesome
[08:14:38] sevenseacat: ACTION is sitting waiting for a deploy to finish
[08:14:40] apeiros: ACTION also loves the weakness of those tests because partner devs have no idea about automated tests???
[08:14:46] ljarvis: KrzaQ: sure, pry is nice too
[08:14:48] ghr: has joined #ruby
[08:14:56] ljarvis: is it bad if I'm not waiting for anything?
[08:15:21] ljarvis: but maybe not? I'll go with that
[08:15:37] ljarvis: actually I am waiting for an email reply
[08:15:41] ljarvis: from a week ago..
[08:16:29] mikecmpbll: has joined #ruby
[08:16:36] ljarvis: damn if pry vendors slop i will lose all of my delicious download figures
[08:16:49] tomphp: has joined #ruby
[08:17:16] apeiros: you know that tests are bad when you have IDs to query for in config files because they might change.
[08:17:41] senayar: has joined #ruby
[08:18:29] einarj: has joined #ruby
[08:19:27] yh__: has joined #ruby
[08:19:27] axwl: has joined #ruby
[08:19:29] Exponential: has joined #ruby
[08:19:43] zarubin: has joined #ruby
[08:19:49] ljarvis: i made a plugin for atom that i'm really regretting
[08:20:01] sevenseacat: hmm what should i work on now
[08:20:47] ljarvis: yeah i might, it's mostly because i don't use atom but there's pressure to update it so now i feel like a jerk
[08:20:59] dudedudeman: has joined #ruby
[08:21:03] wildroman2: has joined #ruby
[08:21:12] apeiros: eh, you don't owe anybody anything
[08:21:33] sevenseacat: put a note saying 'abandoned, free to good home'
[08:21:45] dumdedum: has joined #ruby
[08:21:51] Zai00: has joined #ruby
[08:21:53] apeiros: yeah, declaring abandonment is IMO good style.
[08:22:03] ljarvis: yep good idea
[08:22:08] Exponential: Hey guys, I am a ruby noob. I am getting an undefined method error. Could someone shine some light and also critique my code? http://pastebin.com/mmk9E5z2
[08:22:09] ruboto: Exponential, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/df79ec84f6543ab5ddd4
[08:22:09] ruboto: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
[08:22:09] sevenseacat: 'only tested with version x, use with newer versions at your own peril'
[08:22:34] sevenseacat: Exponential: without you even telling us with the error is?
[08:22:38] sevenseacat: ACTION gets crystal ball
[08:23:17] ghr: has joined #ruby
[08:23:38] adaedra: ACTION gets magic stick
[08:23:45] workmad3: has joined #ruby
[08:23:54] Exponential: sevenseacat: Sorry, still new to it. I only have the one method in the file, but I think I may have defined it incorrectly. https://gist.github.com/anonymous/df79ec84f6543ab5ddd4
[08:24:30] ljarvis: Exponential: please tell us what the error is, include it in your code as a comment
[08:24:41] ljarvis: because we don't know
[08:25:30] Exponential: ljarvis: Okay, I added a comment with the error. https://gist.github.com/anonymous/df79ec84f6543ab5ddd4
[08:26:03] ljarvis: Exponential: define your method before you use it
[08:26:24] neanderslob: has joined #ruby
[08:26:25] granthatcher: has joined #ruby
[08:26:31] ljarvis: nice filename
[08:26:41] Exponential: ljarvis: Ah, so its not like java in that you actually have to have the method above the point at which you use it?
[08:27:12] granthatcher: has joined #ruby
[08:27:42] adaedra: Exponential: Ruby will process your file in one pass, from begin to end. If you use something, you have to have made it before the use.
[08:27:53] ljarvis: Exponential: Ruby basically runs code line by line, so yeah things must exist before they're used
[08:28:30] Exponential: ljarvis adaedra : Awesome, thanks :D Any critique on my code?
[08:28:56] adaedra: Ruby guidelines say 2 spaces for indentation
[08:29:06] ljarvis: Exponential: yeah, a few things
[08:29:08] adaedra: :set sw=2 sts=2 et
[08:29:13] hewenhong: has joined #ruby
[08:29:34] adaedra: Don't use or, use ||
[08:29:37] Symphony_Dawn: has joined #ruby
[08:29:42] granthatcher: has joined #ruby
[08:29:50] ljarvis: Exponential: the first thing is that you read words.txt on every loop
[08:30:06] ljarvis: read it once
[08:30:35] ndrei: has joined #ruby
[08:30:49] hewenhong: has joined #ruby
[08:30:53] adaedra: The treatment you do in get_guessing word is also made at each loop, I think you could do it only once too
[08:30:57] ljarvis: also, you can do all of the string sorting once too
[08:31:42] hmnhf_: has joined #ruby
[08:32:46] ljarvis: there are other points about considering not slurping in your file and storing words differently but since this is homework, you should investigate those ideas yourself (we can point you in the right direction)
[08:35:05] Exponential: Okay, I changed things around a bit and got rid of the redundant re-reads. https://gist.github.com/RecursiveDefinition/3a9aefa232d9ea0b15fc. I feel like the whole finding the 2000 most frequency words could be done a lot tidier, any pointers?
[08:36:09] adaedra: `cat words | uniq -c | sort -n | head -n 2000`
[08:36:14] ljarvis: nice one that's better. I would store the words in a Hash though, with word => count; this way you're not adding duplicates and having to re-count them.
[08:36:50] ljarvis: then I wouldn't even add them if they don't match your criteria (i.e not 5-6 chars long)
[08:36:59] adaedra: If you're always taking just the 2000 first elements, just remove extra elements
[08:37:21] adaedra: taking a slice of 2000 elements to do a sample at each loop run is... :s
[08:37:47] edwinvdg_: has joined #ruby
[08:37:54] Exponential: adaedra: Problem is the words are not sorted or unique in the words.txt
[08:38:07] ljarvis: you could just use rand where x is guarenteed to be less than 2000
[08:38:19] Exponential: And I want the 2000 most common
[08:38:22] adaedra: But you don't resort them at each loop run
[08:38:51] adaedra: you could slice the [0,2000] range before the loop and don't slice anymore
[08:39:26] ljarvis: words.uniq.map { |word| [word, words.count(word)] }
[08:39:31] Symphony_Dawn: What am I seeing?
[08:39:32] ljarvis: Exponential: can you explain to me what you think that's doing?
[08:39:40] chinmay_dd: has joined #ruby
[08:40:13] edwinvdgraaf: has joined #ruby
[08:40:24] hewenhong: has joined #ruby
[08:40:31] Exponential: ljarvis: Creating a HashMap with unique entrys, with key/value word/count
[08:40:58] adaedra: also, for keeping the words (l6), I would rather use a range with #include? rather than this comparaison. It's a little bit more understandable, and is much easier to change
[08:41:14] dudedudeman: has joined #ruby
[08:41:19] ljarvis: Exponential: so you remove duplicates, and then count (presumably, for duplicates)
[08:42:41] Exponential: hash = Hash[words.map { |word| [word, words.count(word)] }]
[08:42:44] Exponential: Is that better?
[08:42:54] ljarvis: Exponential: fwiw you can create hashes with default values. like; word_count = Hash.new(0); word_count["foo"] += 1; which might be able to help you here?
[08:43:50] ljarvis: words.count(word) will traverse your entire array for every call; which seems like it could be generally slow
[08:44:08] ljarvis: since you do that for every word.. well, you can probably calculate how many times it happens
[08:44:32] ArchRogem: has joined #ruby
[08:45:10] Exponential: ljarvis: So in your above example, how would I replace "foo" with each word in the array?
[08:45:31] ljarvis: Exponential: well, you already know how to loop through an array, right?
[08:46:35] Exponential: hash.each { |word| hash[word] += 1}
[08:46:44] Exponential: Would that be faster than what I had before?
[08:46:54] ljarvis: much faster
[08:47:00] apeiros: except it's not hash.each but words.each
[08:47:13] adaedra: such performance
[08:48:17] Exponential: so to compress this line : words = file.select {|word| word.length == 5 || word.length == 6} I want to use a range, but simply changing it to words = file.select {|word| word.length == (5..6)} doesn't work?
[08:48:39] adaedra: (5..6).include? word.length
[08:49:06] apeiros: word.length.between?(5,6)
[08:49:22] ljarvis: yeah, I actually prefer what you have there; but this is a good example of different peoples styles
[08:49:38] adaedra: actually, I didn't know about #between? :x
[08:49:44] adaedra: Ruby has so many methods :x
[08:50:00] apeiros: it's faster and doesn't create temporary range :)
[08:50:06] apeiros: /nick premature_optimizer
[08:50:08] banister: has joined #ruby
[08:50:26] ljarvis: you wait, we'll about to discuss each_line
[08:50:27] Spami: has joined #ruby
[08:50:29] apeiros: though, that kind of thing is IMO not in the category of premature optimization.
[08:50:57] adaedra: so optimized, wow
[08:51:02] apeiros: very adaedra
[08:51:17] Exponential: Is this line too much : common_words = words.sort_by { |word| hash[word] }[0..1999], or would it be better to put the slice into a new variable?
[08:51:22] toretore: premature is fine as long as it's not at the cost of other things
[08:51:45] adaedra: I'd have used #slice!
[08:51:57] apeiros: .first(2000) :)
[08:51:59] ljarvis: Exponential: it's fine, though I prefer .first(2000) from a style perspective
[08:52:23] edwinvdg_: has joined #ruby
[08:52:28] Exponential: Wow, ruby has so many handy methods...
[08:53:24] adaedra: Too many, according to some people
[08:53:30] edwinvdg_: has joined #ruby
[08:53:40] ljarvis: too many aliases
[08:54:34] Zai00: has joined #ruby
[08:54:47] edwinvdgraaf: has joined #ruby
[08:54:55] jhass: apeiros: Range#include? is optimized for numbers
[08:55:08] ljarvis: you still have to create the range on every loop
[08:55:18] ljarvis: (that was his point i think)
[08:55:21] apeiros: jhass: sure. it still has a longer pathway to go through
[08:55:25] jhass: in other words, good morning!
[08:55:47] apeiros: moin jhass :)
[08:56:10] adaedra: Guten Morgen, jhass
[08:56:20] c0m0: has joined #ruby
[08:56:21] jokke: i'm having a weird problem with https://github.com/drbrain/net-http-persistent
[08:56:31] jokke: i can require net/http/persistent
[08:56:41] jokke: but get unknown constant Net::HTTP::Persistent
[08:56:54] jokke: any ideas?
[08:57:01] platzhirsch: has joined #ruby
[08:57:03] apeiros: seems in current ruby the performance difference became insignificant, though. ~10% here.
[08:57:25] apeiros: so the only question is how well GC is optimized :)
[08:57:30] jhass: jokke: does the require return true or false?
[08:58:08] jokke: jhass: lemme check
[08:59:20] jokke: jhass: true
[09:01:11] jokke: jhass: here's my code: http://p.jreinert.com/cIaIP/ruby
[09:01:13] platzhirsch: has left #ruby: ()
[09:01:59] jhass: jokke: what does gem which net/http/persistent say?
[09:02:22] jokke: /home/jokke/.gem/ruby/2.2.0/gems/net-http-persistent-2.9.4/lib/net/http/persistent.rb
[09:02:29] ljarvis: jokke: what does the following return on the command line? ruby -r 'net/http/persistent' -e 'Net::HTTP::Persistent'
[09:02:57] jokke: ljarvis: nothing
[09:03:01] ljarvis: then it's working
[09:03:06] ljarvis: there must be a different issue
[09:03:52] workmad3: has joined #ruby
[09:04:07] jokke: i got the error when running tests
[09:04:22] jokke: dunno if rspec could have something to do with it
[09:05:06] jhass: check inside the test if $LOADED_FEATURES.include? "/home/jokke/.gem/ruby/2.2.0/gems/net-http-persistent-2.9.4/lib/net/http/persistent.rb" is true
[09:05:20] yh_: has joined #ruby
[09:05:34] jhass: also Gem.find_files("net/http/persistent") in there might be interesting
[09:06:17] dudedudeman: has joined #ruby
[09:06:37] jokke: jhass: first returns true
[09:06:45] jokke: second returns ["/home/jokke/.gem/ruby/2.2.0/gems/net-http-persistent-2.9.4/lib/net/http/persistent.rb", "/home/jokke/.gem/ruby/2.2.0/gems/net-http-persistent-2.9.4/lib/net/http/persistent"]
[09:07:13] ljarvis: presumably defined?(Net::HTTP::Persistent) returns false in your test?
[09:07:16] jhass: can you share the complete output of the failing test run?
[09:07:34] jokke: ljarvis: yeah
[09:08:06] jokke: also tried ::Net...
[09:08:14] jokke: but the result is the same
[09:08:34] jokke: jhass: yeah
[09:08:37] unshadow: has joined #ruby
[09:08:42] jhass: spring or anything you can kill?
[09:08:55] jokke: no spring
[09:08:59] jokke: simple gem
[09:09:20] mikecmpbll: error with trace? who knows, might be a clue in there.
[09:09:56] jokke: http://p.jreinert.com/q8pL/
[09:10:15] jhass: empty for me
[09:10:51] mikecmpbll: or maybe there's no error? you're hallucinating
[09:10:56] jokke: for me too...
[09:11:00] jokke: http://p.jreinert.com/q8pL
[09:11:10] jokke: something wrong with the lexer..
[09:11:32] mikecmpbll: http://p.jreinert.com/q8pL/rmd also
[09:11:40] mello: has joined #ruby
[09:12:00] jokke: now it works btw.
[09:12:43] ljarvis: the error isn't correct
[09:12:56] gigetoo: has joined #ruby
[09:13:16] ljarvis: but now my phone is ringing brb
[09:13:27] mikecmpbll: the tension ..
[09:13:36] jokke: mikecmpbll: :D
[09:14:06] nfk: has joined #ruby
[09:14:40] jokke: maybe he means this: undefined method `scheme' for #<Net::HTTP::Get GET>
[09:16:00] bluOxigen: has joined #ruby
[09:16:01] mikecmpbll: jokke: where's the `enumerator.each { |_| }` bit come from?
[09:16:17] bluOxigen: has left #ruby: ()
[09:16:34] mikecmpbll: oh nvm that's the test
[09:16:36] mikecmpbll: not used to rspec output.
[09:17:04] startupality: has joined #ruby
[09:17:12] Musashi007: has joined #ruby
[09:17:13] jokke: it's a bug in the gem
[09:17:55] jokke: without using Net::HTTP::Get it works
[09:18:07] jokke: (passing the url as is
[09:18:41] jokke: self.class.http.request(@uri)
[09:18:43] jokke: that works
[09:19:04] mikecmpbll: how on earth
[09:19:07] RegulationD: has joined #ruby
[09:19:12] mikecmpbll: even leaving line 21 in?
[09:20:03] jokke: no i took line 21 out
[09:20:11] mikecmpbll: and what about with it in? :d
[09:20:41] mikecmpbll: ACTION waits ...
[09:20:44] jokke: i'm just happy it works... :P
[09:20:48] jokke: alright..
[09:21:21] jokke: yup works
[09:21:42] senayar: has joined #ruby
[09:21:42] senayar: has joined #ruby
[09:22:33] Oog: has joined #ruby
[09:22:53] jokke: mikecmpbll: the error is very weird though
[09:22:54] dEPy: has joined #ruby
[09:23:15] Exponential: ljarvis adaedra: Thanks for the help, attended a ruby intro today at campus and they gave us the challenge to make a scrambler word game. This is my implementation https://gist.github.com/RecursiveDefinition/309cb60f64529abfe6ae. Your guys help was great :D Already love the Ruby community
[09:24:05] mikecmpbll: jokke: the error is happening in the call to .http which is before you even do the .request call :/
[09:24:12] mikecmpbll: #doesnotunderstand
[09:24:29] jokke: mikecmpbll: you're right :D
[09:24:49] jokke: ACTION doesn't understand either
[09:24:49] Scripore: has joined #ruby
[09:24:53] mikecmpbll: i could maybe get it if referencing the Net::HTTP::Get constant somehow unloaded Net::HTTP::Persistent
[09:25:04] mikecmpbll: but you said that even with the reference it works so, meh
[09:25:22] jokke: i do some const stubbing in my tests :P
[09:25:57] ljarvis: well you've basically figured it out so great
[09:26:04] jokke: ljarvis: yeah \o/
[09:26:28] ljarvis: naughty stubbing
[09:27:06] mikecmpbll: rather stub my toe.
[09:27:28] KrzaQ: if I have { 1 => [ 2, 3] }, can I easily turn this into [[1,2], [1,3]]? Support for nesting would be nice. I want to flatten my data
[09:28:13] jhass: .map {|k, v| [k, v.flatten] } ?
[09:29:02] KrzaQ: I am nesting maps right not
[09:29:38] jhass: .each_with_object([]) {|(k, values), pairs| values.flatten.each do |v| pairs << [k, v] end end
[09:29:40] mikecmpbll: your limited example doesn't give much of an idea what you want to do, but ..
[09:29:40] KrzaQ: .map{|k,v| v.map{|u,x| [k, u, x] }}
[09:29:45] KrzaQ: but I'm running out of letters fast
[09:29:52] apeiros: *sob*, rails magic again???
[09:31:10] mikecmpbll: .map{ |k,v| v.map{ |i| [k,i] }}.flatten(1)
[09:31:20] mikecmpbll: oh you did that.
[09:31:35] mikecmpbll: or similar ..
[09:31:43] mikecmpbll: not sure why you're using three vars in the inner map
[09:31:49] KrzaQ: but it turns ugly, fast, when x is a hash/array
[09:31:53] apeiros: mikecmpbll: flat_map
[09:32:12] mikecmpbll: forgot about that gem
[09:32:20] mikecmpbll: (in the figurative sense)
[09:32:37] canton7: >> {1 => [2, 3]}.flat_map{ |k,v| v.zip([k].cycle) }
[09:32:38] ruboto: canton7 # => [[2, 1], [3, 1]] (https://eval.in/371689)
[09:32:49] mikecmpbll: close, no cigar :p
[09:32:50] canton7: just reverse the inner tuples, and done!
[09:32:53] anisha: has joined #ruby
[09:33:07] Scripore: has joined #ruby
[09:35:16] fu2ristiq: has joined #ruby
[09:35:29] fu2ristiq: hi everyone
[09:36:17] mikecmpbll: fu2ristiq: hi
[09:36:35] roshanavand: has joined #ruby
[09:37:22] marr: has joined #ruby
[09:37:34] phutchins: has joined #ruby
[09:37:37] _blizzy_: has joined #ruby
[09:37:54] fu2ristiq: so, what's up/
[09:38:01] roshanavand: has left #ruby: ()
[09:38:06] fu2ristiq: has left #ruby: ("WeeChat 1.1.1")
[09:38:11] roshanavand: has joined #ruby
[09:38:31] mikecmpbll: well that was congenial.
[09:39:54] apeiros: trying to add a convenient way to have custom normalized & validated AR attributes. it's annoying, though. and I don't know enough about AR's inner workings. *sobs again*
[09:40:29] MafProd: has joined #ruby
[09:40:31] mikecmpbll: custom normalized & validated?
[09:40:59] quimrstorres: has joined #ruby
[09:41:22] bluOxigen: has joined #ruby
[09:41:29] apeiros: f.ex. in your model: `credit_card_number :colname`. adds a validation for colname. and the setter will normalize input. such as strip dashes etc.
[09:43:20] apeiros: and why I always write Valdiator instead of Validator is beyond me :D
[09:44:06] mikecmpbll: seems like it should be relatively straight forward, unless I'm misintepreting it?
[09:44:10] OrbitalKitten: has joined #ruby
[09:44:50] withnale_: has joined #ruby
[09:44:57] apeiros: depends on how much ugly you want to accept.
[09:45:03] krz: has joined #ruby
[09:45:14] mikecmpbll: i'd just extend AR::Base with a credit_card_number method which adds a validation and overrides the setter
[09:45:58] apeiros: see, and I'd prefer to have that stuff in reusable modules. and then the fight with AR's magic begins :)
[09:46:34] mikecmpbll: reusable how? hm
[09:46:36] fu2ristiq: has joined #ruby
[09:46:41] apeiros: such as `validate :col, custom_validator: true` expecting precisely a class named CustomValidatorValidator. which must either be toplevel or in a module you include into the model.
[09:47:17] apeiros: well, I guess I just close my eyes and live with the ugly.
[09:47:32] apeiros: lunch time
[09:48:05] mikecmpbll: see validates_with, perhaps.
[09:49:38] mikecmpbll: or even better, validates :cc, credit_card: true; and then define a CreditCardValidator
[09:49:47] ljarvis: apeiros: that's the kind of thing I'd just use a model and extend
[09:49:48] mikecmpbll: works out the box.
[09:50:18] ljarvis: mikecmpbll: does that allow you to mutate the column?
[09:50:20] ljarvis: i guess it would
[09:50:28] ljarvis: module and extend*
[09:50:52] mikecmpbll: ljarvis: /shrugs, forgot about that bit. probably could get there.
[09:52:41] ljarvis: apeiros: I'd do something like this probably https://gist.github.com/leejarvis/b950d68c34e8e2c5089f
[09:52:48] ljarvis: but I like keeping things in separate modules
[09:54:28] mikecmpbll: although .. include not extend
[09:54:47] ljarvis: I changed it, you were to quick to click
[09:55:40] bronson: has joined #ruby
[09:57:23] sandelius: has joined #ruby
[09:58:29] rdark: has joined #ruby
[09:59:17] edwinvdgraaf: has joined #ruby
[10:00:14] centrx: has joined #ruby
[10:00:58] sandelius: So rack has its own Rack::Builder in config.ru with run app at the end. Most frameworks creates their own Rack::Builder stack and builds it inside the call(env) method. So that means that we have to build two stacks. Why is that?
[10:01:15] prereflect: has joined #ruby
[10:01:20] Chagel_: has joined #ruby
[10:01:35] ahmetkapikiran: has joined #ruby
[10:02:08] Takle: has joined #ruby
[10:03:02] rht: When using GTK3 and glade, what's best practice: should I subclass Gtk::Builder or wrap a Gtk::Builder instance?
[10:03:47] jhass: _ht: I'd say wrap
[10:04:59] rht: And do I make each form-element I use into a instance variable, or do I make the builder instance into an instance variable and use @builder.get_object "name" to accesss form elements?
[10:05:28] wjimenez5271: has joined #ruby
[10:05:48] edwinvdg_: has joined #ruby
[10:07:22] Oog: has joined #ruby
[10:07:33] tomphp: has joined #ruby
[10:08:00] ta: has joined #ruby
[10:08:20] weemsledeux: has joined #ruby
[10:09:34] krz: has joined #ruby
[10:12:33] qwertme: has joined #ruby
[10:12:45] jhass: I don't think there are big advantages over either, pick what you prefer
[10:13:19] rht: All right
[10:13:56] jacor: has joined #ruby
[10:17:17] chagel: has joined #ruby
[10:17:50] chagel: has left #ruby: ()
[10:18:58] leafybasil: has joined #ruby
[10:20:30] zarubin: has joined #ruby
[10:20:30] rickmasta: has joined #ruby
[10:22:26] selu: has joined #ruby
[10:22:29] startupality: has joined #ruby
[10:23:22] Papierkorb: has joined #ruby
[10:24:16] mike_bueti: has joined #ruby
[10:24:30] iamninja: has joined #ruby
[10:25:58] cookieburra: has joined #ruby
[10:26:04] sdothum: has joined #ruby
[10:26:11] cookieburra: hello everyone!
[10:26:21] CloCkWeRX: has joined #ruby
[10:26:28] wildroman2: has joined #ruby
[10:27:02] shevy: hi cookieburra
[10:27:04] shevy: you make me hungry
[10:27:34] cookieburra: haha, sorry for that
[10:27:48] skammer: has joined #ruby
[10:27:58] roshanavand: has left #ruby: ()
[10:28:05] cookieburra: hey, have you used Rubocop?
[10:28:32] cookieburra: I don't think I understand how it determines the need for comments in code
[10:28:56] cookieburra: it keeps screaming for a documentation comments to my classes, and I have no idea how to make it stop
[10:29:34] jimms: has joined #ruby
[10:29:40] adaedra: look at documentation, you can disable tests
[10:29:55] cookieburra: yeah, I know that
[10:30:09] cookieburra: but I assumed it's working correctly, and it's me that is buggy ;)
[10:31:00] cookieburra: I assume Rubocop expects RDoc-compatible documentation/comments
[10:31:03] adaedra: do you have a documentation tool to generate it?
[10:31:14] quimrstorres: has joined #ruby
[10:31:23] cookieburra: this is the moment when I feel like a fool
[10:31:38] adaedra: on a hill?
[10:32:05] workmad3: cookieburra: https://github.com/bbatsov/rubocop/blob/master/lib/rubocop/cop/style/documentation.rb <-- there's the cop for documentation checks :)
[10:32:18] arup_r: has joined #ruby
[10:32:49] cookieburra: workmad3, thank you :) I had a look at it before
[10:33:30] cookieburra: ok, so it seems like I haven't connected the dots
[10:33:42] hmnhf_: has joined #ruby
[10:33:44] cookieburra: and realized I need GENERATED documentation for the classes
[10:33:56] cookieburra: I assumed it just needs to be properly commented in code
[10:35:14] x44x45x41x4E: has joined #ruby
[10:35:15] Musashi007: has joined #ruby
[10:35:38] shevy: cookieburra yeah I used it; you can use a file called rubocop.yml to govern its behaviour. rubocop adheres to some guideline
[10:35:46] tvw: has joined #ruby
[10:37:40] workmad3: cookieburra: looking at the code, it seems like a non-empty class or module just needs at least one comment above it that isn't an annotation like 'FIXME:' or 'TODO:'
[10:38:08] adaedra: cookieburra: doesn't seems to check for generated documentation, just require to document your classes
[10:39:40] apeiros: ljarvis: thanks for your example
[10:40:42] deavid: has joined #ruby
[10:41:23] cookieburra: adaedra,yup seems like it. I still don't get why my comments are not OK with Rubocop
[10:41:36] workmad3: cookieburra: !gist your offending code maybe?
[10:41:36] helpa: cookieburra: http://gist.github.com - Put your codes online with pretty syntax highlighting and the ability to embed it into other pages.
[10:41:58] workmad3: ?gist even :)
[10:41:58] ruboto: even, https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[10:44:16] cookieburra: yup, on it :)
[10:45:17] krz: has joined #ruby
[10:46:07] GriffinHeart: has joined #ruby
[10:47:02] cookieburra: https://gist.github.com/anonymous/47f0c05e43f23b983ade
[10:47:07] cookieburra: that's the file, basically
[10:47:19] cookieburra: what is weird, is that I get the error for lacking comment
[10:47:27] cookieburra: but just for the first 2 out of 3 classes in the file
[10:48:25] workmad3: I'm surprised rubocop isn't complaining about multiple classes in the one file, personally
[10:48:44] decoponio: has joined #ruby
[10:48:56] cookieburra: seriously? I should separate those?
[10:49:10] northfurr: has joined #ruby
[10:49:14] cookieburra: I had no idea, I'm new (as if you didn'
[10:49:36] scottstamp: has joined #ruby
[10:49:59] chipotle: has joined #ruby
[10:50:38] workmad3: cookieburra: yeah, it's pretty standard in ruby to have one class per file... makes it much easier to find things in the file system
[10:50:42] adaedra: One day I'll take time and setup a real power-vim
[10:50:45] sdothum: has joined #ruby
[10:51:27] workmad3: adaedra: and that day is... today!!!
[10:51:46] adaedra: Unfortunately not.
[10:52:05] GriffinHeart: has joined #ruby
[10:53:28] Paradox: has joined #ruby
[10:53:52] Juanchito: has joined #ruby
[10:54:04] adaedra: I'd like too, but I have a lot of work to do
[10:54:06] doublemalt_: has joined #ruby
[10:54:35] workmad3: pfft, deadlines were made to be broken
[10:54:42] dudedudeman: has joined #ruby
[10:55:11] xMopxShell: has joined #ruby
[10:55:18] workmad3: adaedra: or, in the words of JoCo: "All I know is work is easy when you don't stress out about deadlines "
[10:55:37] adaedra: I just want to finish this thing, actually
[10:56:02] Ilyes512: has joined #ruby
[10:56:24] KC9YDN: has joined #ruby
[10:56:24] KC9YDN: has joined #ruby
[10:57:15] yosafbridge: has joined #ruby
[10:57:26] mello: has joined #ruby
[10:57:43] gluten_hell_: has joined #ruby
[10:57:43] Ilyes512: has joined #ruby
[10:58:20] gluten_hell_: has joined #ruby
[10:58:31] cirn0: has joined #ruby
[10:59:15] nux443: has joined #ruby
[11:00:04] rodfersou: has joined #ruby
[11:00:14] cookieburra: I've separated the classes, but I still get a "Missing top-level class documentation comment."
[11:00:50] garyserj: has joined #ruby
[11:00:52] gluten_hell_: has joined #ruby
[11:01:05] dstarh: has joined #ruby
[11:01:10] pengin: has joined #ruby
[11:01:11] Hien: has joined #ruby
[11:01:43] quimrstorres: has joined #ruby
[11:01:58] sdothum: has joined #ruby
[11:05:14] yosafbridge: has joined #ruby
[11:05:43] fabrice31: has joined #ruby
[11:05:43] xMopxShell: has joined #ruby
[11:07:58] RegulationD: has joined #ruby
[11:08:18] iamninja: has joined #ruby
[11:09:25] shevy: then add a top level comment
[11:09:32] shevy: or disable that warning
[11:10:51] yosafbridge: has joined #ruby
[11:11:07] mmazing: has joined #ruby
[11:11:54] cookieburra: I have a comment right on top of each class, I assumed that's enough
[11:11:55] joonty: has joined #ruby
[11:12:09] pengin: has joined #ruby
[11:12:58] jenrzzz: has joined #ruby
[11:15:09] Someguy123: has joined #ruby
[11:15:37] flughafen: workmad3: i love deadlines and the whooshing noise they make as they fly by
[11:16:43] workmad3: flughafen: douglas adams ftw! :)
[11:16:44] joonty: https://twitter.com/hashtag/ClickBaitAMovie
[11:16:48] joonty: wrong channel
[11:16:51] joonty: but still a good link
[11:18:15] adaedra: Could this v be written better?
[11:18:16] adaedra: headers && JSON.load(headers) rescue errors.add(:headers, 'is not a valid JSON document')
[11:18:46] thebastl: has joined #ruby
[11:19:06] apeiros: inline rescue swallows errors, I'd not use that
[11:19:13] sigurding: has joined #ruby
[11:19:41] dorei: has joined #ruby
[11:19:42] Someguy123: has joined #ruby
[11:19:47] adaedra: I want to make sure that (if not nil), headers is a valid JSON document, and add an error if not
[11:20:03] ljarvis: rescue JSON::ParseError
[11:20:05] ljarvis: (I think it is)
[11:20:15] cookieburra: has joined #ruby
[11:20:18] ljarvis: so yeah, dont inline it
[11:20:46] apeiros: >> require 'json'; JSON.load(nil)
[11:20:48] ruboto: apeiros # => nil (https://eval.in/371787)
[11:21:02] apeiros: you can also save the &&
[11:21:03] ljarvis: cool, no need for the nil check
[11:21:28] ljarvis: >> require 'json'; JSON.load('{wot')
[11:21:29] ruboto: ljarvis # => 795: unexpected token at '{wot' (JSON::ParserError) ...check link for more (https://eval.in/371788)
[11:21:35] ljarvis: I was close
[11:21:36] commondream: has joined #ruby
[11:21:38] ljarvis: forgot the r!
[11:21:44] adaedra: poor forgot.
[11:21:55] adaedra: who are these people who use a common word as nick?
[11:22:35] adaedra: Immagine someone who would be named 'ruby' in here :p
[11:22:36] Someguy123: has joined #ruby
[11:22:55] ahmetkapikiran: has joined #ruby
[11:23:11] Paradox: has joined #ruby
[11:23:33] garyserj: has joined #ruby
[11:24:05] yosafbridge: has joined #ruby
[11:24:16] MuffinPimp: has joined #ruby
[11:24:29] livathinos: has joined #ruby
[11:25:22] xMopxShell: has joined #ruby
[11:27:15] dudedudeman: has joined #ruby
[11:27:30] yosafbridge: has joined #ruby
[11:29:49] yosafbridge: has joined #ruby
[11:33:05] yosafbridge: has joined #ruby
[11:33:42] ldnunes: has joined #ruby
[11:33:44] sigurding: has joined #ruby
[11:34:30] Scripore: has joined #ruby
[11:34:41] OrbitalKitten: has joined #ruby
[11:35:23] flughafen: adaedra: or the nick adaedra
[11:35:34] yosafbridge: has joined #ruby
[11:36:53] MuffinPimp: has joined #ruby
[11:38:43] zz_Outlastsheep: has joined #ruby
[11:39:56] DEA7TH: has joined #ruby
[11:40:05] v0n: has joined #ruby
[11:40:30] dudedudeman: has joined #ruby
[11:41:44] kp666: has joined #ruby
[11:41:55] n008f4g_: has joined #ruby
[11:43:39] selu: has joined #ruby
[11:43:56] davedev24_: has joined #ruby
[11:45:05] edwinvdgraaf: has joined #ruby
[11:45:46] sgambino: has joined #ruby
[11:48:41] izzol: I'm checking the type of the file, that works fine for me, but I'm also checking if file is compressed (tgz) if yes I'm decompressing it and again I'm checking the type of the file. That works fine too :P. The problem I have is that when the compressed file has a directory which has compressed file wich has directories which has again compressed files and so on.
[11:49:01] izzol: How to write such as method to check all those steps?
[11:49:15] xMopxShell: has joined #ruby
[11:49:56] izzol: I neved know how many files there will be or directories. I'm reading about the Composite Pattern, but not sure yet if this is what I'm looking...
[11:50:00] quimrstorres: has joined #ruby
[11:50:02] kp666: has joined #ruby
[11:51:42] mosez: has joined #ruby
[11:51:58] ddv: izzol: just write a recursive method
[11:55:03] Guest29816: has joined #ruby
[11:55:26] izzol: ddv: yes, this is what I need to have... I guess.
[11:55:28] izzol: Thanks :)
[11:57:45] quarcu: has joined #ruby
[11:57:48] sdothum: has joined #ruby
[11:58:06] but3k4: has joined #ruby
[11:58:50] xMopxShell: has joined #ruby
[11:59:44] banister: has joined #ruby
[12:00:05] hewenhong: has joined #ruby
[12:00:43] gauke: has joined #ruby
[12:01:34] banister: has joined #ruby
[12:01:39] sepp2k: has joined #ruby
[12:02:38] ta: has joined #ruby
[12:04:17] cubesandcode: has joined #ruby
[12:06:03] edwinvdg_: has joined #ruby
[12:06:24] OrbitalKitten: has joined #ruby
[12:06:30] rindolf: has joined #ruby
[12:08:14] nateberkopec: has joined #ruby
[12:09:18] Scripore: has joined #ruby
[12:12:17] fgo: has joined #ruby
[12:14:38] alphaatom: has joined #ruby
[12:16:20] krz: has joined #ruby
[12:17:29] selu: has joined #ruby
[12:17:43] tesuji: has joined #ruby
[12:18:41] OrbitalKitten: has joined #ruby
[12:18:50] ponga: has joined #ruby
[12:19:32] TheNumb: has joined #ruby
[12:20:25] OrbitalKitten: has joined #ruby
[12:21:05] Zai00: has joined #ruby
[12:21:10] zarubin: has joined #ruby
[12:21:41] northfurr: has joined #ruby
[12:22:16] v0n: has joined #ruby
[12:22:56] phutchins: has joined #ruby
[12:23:25] thebastl: has joined #ruby
[12:25:16] OrbitalKitten: has joined #ruby
[12:25:24] bluOxigen: has joined #ruby
[12:26:46] Takle: has joined #ruby
[12:26:55] goodcodeguy: has joined #ruby
[12:29:57] Alina-malina: has joined #ruby
[12:31:02] but3k4: has joined #ruby
[12:33:18] zz_Outlastsheep: has joined #ruby
[12:33:50] shevy: I once wrote a class called class AlphabeticalHash
[12:34:41] mike: has joined #ruby
[12:34:54] zack6849: has joined #ruby
[12:34:54] zack6849: has joined #ruby
[12:35:08] senayar: has joined #ruby
[12:35:11] Ilyes512: has joined #ruby
[12:35:11] fabrice31: has joined #ruby
[12:36:01] jacor: has joined #ruby
[12:39:03] pulgolino: has joined #ruby
[12:39:26] x44x45x41x4E: has joined #ruby
[12:40:33] sdothum: has joined #ruby
[12:44:09] SalexW: has joined #ruby
[12:46:11] mello: has joined #ruby
[12:47:38] pulgolino: has joined #ruby
[12:47:50] vivekananda: has joined #ruby
[12:49:04] poguez_: has joined #ruby
[12:54:59] mike___1234: has joined #ruby
[12:55:26] griffindy: has joined #ruby
[12:56:09] Scripore: has joined #ruby
[12:56:22] DEA7TH: has joined #ruby
[12:56:52] RegulationD: has joined #ruby
[12:59:37] gambl0re: has joined #ruby
[12:59:40] edwinvdgraaf: has joined #ruby
[13:00:19] edwinvdg_: has joined #ruby
[13:00:25] bmurt: has joined #ruby
[13:00:30] jokke: i need to track down a memory leak
[13:00:38] banister: has joined #ruby
[13:00:41] jokke: in a basic ruby app
[13:00:46] jokke: (not rails)
[13:00:56] yh_: has joined #ruby
[13:01:05] jokke: it's basically just an etl
[13:01:49] startupality: has joined #ruby
[13:02:06] jokke: are there any gems that would profile the memory usage in parts of the code?
[13:02:10] rickmasta: has joined #ruby
[13:02:19] jokke: well, that's not possible i guess..
[13:02:31] ndrei: has joined #ruby
[13:02:37] jokke: but something that would indicate what the problem might be
[13:03:11] psye: has joined #ruby
[13:03:22] dblessing: has joined #ruby
[13:04:16] psye: has joined #ruby
[13:04:37] xxneolithicxx: has joined #ruby
[13:05:01] tomphp: has joined #ruby
[13:07:28] [k-: has joined #ruby
[13:09:23] kubunto: has joined #ruby
[13:09:41] arup_r: has joined #ruby
[13:10:45] nfk: has joined #ruby
[13:11:19] jhass: jokke: you might like rbkit
[13:12:24] code1o6: has joined #ruby
[13:13:00] jokke: jhass: cool, i'll give it a try
[13:13:22] ddv: jokke: you could also run your app on jruby and use some of the profiling apps available for java
[13:15:56] jerius: has joined #ruby
[13:17:27] Oog: has joined #ruby
[13:18:28] dudedudeman: has joined #ruby
[13:22:24] speaking1ode: has joined #ruby
[13:25:36] michael_mbp: has joined #ruby
[13:28:36] michael_mbp: has joined #ruby
[13:28:44] sinkensabe: has joined #ruby
[13:28:45] dudedudeman: has joined #ruby
[13:29:30] arup_r: has joined #ruby
[13:30:18] sinkensabe: has joined #ruby
[13:31:14] sinkensa_: has joined #ruby
[13:32:03] mrchris: has joined #ruby
[13:32:28] Tux_007__: has joined #ruby
[13:33:01] bronson: has joined #ruby
[13:34:34] jokke: jhass: hm can't compile the client
[13:34:44] jokke: 'aclocal-1.14' is missing on your system.
[13:34:51] jokke: i have aclocal
[13:34:53] jokke: version 1.15
[13:34:54] phale: has joined #ruby
[13:34:57] dfockler: has joined #ruby
[13:34:58] jhass: -dev / -devel package?
[13:35:07] jokke: jhass: yeah
[13:35:17] jokke: (archlinux)
[13:35:32] mrmargolis: has joined #ruby
[13:35:35] jhass: uh, I had that running on arch once
[13:36:06] michael_mbp: has joined #ruby
[13:36:14] jhass: just worked for me iirc
[13:36:34] jokke: maybe aclocal was version 1.14 back then :/
[13:36:41] sankaber: has joined #ruby
[13:36:55] startupality: has joined #ruby
[13:37:08] jokke: it's weird because the makefile really tries to execute a file called aclocal-1.14
[13:37:28] jhass: aha, that might be
[13:37:37] jhass: I'd just edit it to .15 :P
[13:37:52] jokke: http://p.jreinert.com/vp8tEp/
[13:38:23] mujou: has joined #ruby
[13:38:28] jhass: that said there's automake-1.14 in the AUR
[13:38:29] phale: jokke: you see, there's an error
[13:38:43] jokke: jhass: hmm
[13:38:57] ddv: jokke: fix the pkgfile
[13:38:58] agarie: has joined #ruby
[13:39:08] jokke: ddv: huh?
[13:39:13] jokke: what's wrong with it?
[13:39:36] ddv: apparantly it wants aclocal-1.14 and you have 1.15
[13:41:06] michael_mbp: has joined #ruby
[13:41:47] CustosLimen: has joined #ruby
[13:42:40] baweaver: has joined #ruby
[13:42:52] y0da: has joined #ruby
[13:43:13] jokke: jhass: autobuild-1.14 fails to build.. :/
[13:43:18] jokke: *automake
[13:44:17] umgrosscol: has joined #ruby
[13:44:18] hewenhong: has joined #ruby
[13:44:34] jhass: jokke: https://aur.archlinux.org/packages/automake-1.14/ try the comment?
[13:44:58] jhass: mmh, but we want aclocal renamed too
[13:45:28] kp666: has joined #ruby
[13:45:50] jhass: ah I see, no try the comment
[13:46:16] jokke: jhass: yeah
[13:46:49] dudedudeman: has joined #ruby
[13:47:23] jokke: jhass: one step further
[13:47:40] jokke: http://p.jreinert.com/rTIqhp/
[13:48:07] livathinos: has joined #ruby
[13:48:32] lavros: has joined #ruby
[13:49:31] phale: im crying
[13:49:32] jhass: does autoreconf-1.14 help?
[13:49:36] jhass: phale: sup?
[13:49:44] jhass: not getting enough attention?
[13:49:47] phale: jhass: my wife wants to kill me
[13:50:02] ddv: jhass: why not adjust the pkgfile and let it use 1.15?
[13:50:10] ddv: maybe it works
[13:50:23] jhass: idk, you have to guide them through that ;)
[13:50:41] ahmetkapikiran: has joined #ruby
[13:51:13] cubesandcode: has joined #ruby
[13:51:22] startupality: has joined #ruby
[13:51:51] hewenhong: has joined #ruby
[13:51:57] User458764: has joined #ruby
[13:52:42] mary5030: has joined #ruby
[13:52:54] ismaelga: has joined #ruby
[13:53:58] phale: has left #ruby: ("Leaving")
[13:55:11] mrsolo: has joined #ruby
[13:55:13] haxrbyte: has joined #ruby
[13:55:16] jokke: never mind
[13:55:19] jokke: make clean
[13:55:27] iamninja: has joined #ruby
[13:55:36] jokke: was still having some autoreconf-1.15 stuff hanging around i guess
[13:56:27] RegulationD: has joined #ruby
[13:56:55] nateberkopec: has joined #ruby
[13:57:07] michael_mbp: has joined #ruby
[13:58:22] mrmargolis: has joined #ruby
[13:59:35] jokke: would've been too good to be true if it compiled now
[13:59:36] michael_mbp: has joined #ruby
[13:59:38] jokke: undefined reference to `crypto_box_afternm'
[13:59:52] jokke: undefined reference to `crypto_box_open_afternm'
[13:59:59] jokke: undefined reference to `crypto_box_keypair'
[14:02:21] thiagovsk: has joined #ruby
[14:02:38] sevenseacat: has joined #ruby
[14:02:39] CustosLimen: has joined #ruby
[14:03:06] Ropeney: has joined #ruby
[14:03:31] elev: has joined #ruby
[14:04:47] ndrei: has joined #ruby
[14:05:01] mrmargol_: has joined #ruby
[14:05:13] rbennacer: has joined #ruby
[14:05:52] yalue: has joined #ruby
[14:06:09] bluOxigen: has joined #ruby
[14:06:16] bluOxigen: has left #ruby: ()
[14:07:06] michael_mbp: has joined #ruby
[14:07:44] jhass: uh, isn't that like openssl?
[14:08:08] spyderman4g63: has joined #ruby
[14:08:15] elev: do jhass live on irc?
[14:08:28] jokke: jhass: no
[14:08:49] krz: has joined #ruby
[14:08:52] jokke: that's probably this: crypto_box_afternm
[14:08:56] jokke: http://nacl.cr.yp.to/box.html
[14:09:13] jokke: and it's required by zeromq
[14:09:30] n008f4g_: has joined #ruby
[14:09:36] jhass: interesting that you don't have it yet
[14:10:31] jokke: community/libsodium 1.0.3-1 [installed]
[14:10:33] yfeldblum: has joined #ruby
[14:10:38] dudedudeman: has joined #ruby
[14:10:39] jokke: P(ortable|ackageable) NaCl-based crypto library
[14:10:50] jokke: dunno if that's the thing
[14:11:07] dudedudeman: has joined #ruby
[14:11:33] jokke: but there's also nacl in aur
[14:12:46] rdark: has joined #ruby
[14:13:42] alex88: has joined #ruby
[14:14:41] Kricir: has joined #ruby
[14:15:11] jokke: which doesn't build
[14:16:13] jokke: it was worth a try
[14:16:24] podman: has joined #ruby
[14:16:57] xelim: has joined #ruby
[14:17:24] _ixti_: has joined #ruby
[14:18:51] michael_mbp: has joined #ruby
[14:18:57] failshell: has joined #ruby
[14:20:27] dhosterman: has joined #ruby
[14:21:11] dru`: has joined #ruby
[14:22:18] zarubin: has joined #ruby
[14:22:27] Ilyes512: has joined #ruby
[14:23:03] Kricir: has joined #ruby
[14:23:29] dudedudeman: so many names!
[14:24:15] fu2ristiq: has joined #ruby
[14:24:57] havenwood: has joined #ruby
[14:26:48] balazs: has joined #ruby
[14:27:38] someword: has joined #ruby
[14:27:40] Igorshp: has joined #ruby
[14:28:09] lavros: has joined #ruby
[14:28:19] kobain: has joined #ruby
[14:29:50] gaboesquivel: has joined #ruby
[14:30:07] michael_mbp: has joined #ruby
[14:30:46] gambl0re: has joined #ruby
[14:30:46] porfa: has joined #ruby
[14:31:40] senayar: has joined #ruby
[14:31:40] senayar: has joined #ruby
[14:32:23] porfa: hello guys, how can i fetch the .text that's in the last element? https://gist.github.com/anonymous/7974045b7752957b02e5
[14:32:37] joast: has joined #ruby
[14:32:42] porfa: element name = "strong"
[14:33:03] jhass: .children.last.text ?
[14:33:36] ljarvis: or use last-child
[14:33:56] porfa: jhass: yeah ! thank you
[14:33:56] yh: has joined #ruby
[14:34:04] bruno-: has joined #ruby
[14:34:05] porfa: thank you so much!! :D
[14:34:45] dudedudeman: ha, just noticed this when jumping in to #ruby-lang: "The topic for #ruby-lang is: this channel will redirect to #ruby the morning of June 1, Pacific Time"
[14:34:57] mello: has joined #ruby
[14:35:15] ljarvis: not long now
[14:35:21] Robr3rd: has joined #ruby
[14:35:27] ljarvis: our worlds will merge and take over the universe
[14:35:29] ljarvis: or something
[14:35:44] dudedudeman: long live #ruby
[14:37:32] commondream: has joined #ruby
[14:37:58] Takle: has joined #ruby
[14:37:59] zotherstupidguy: has joined #ruby
[14:38:02] kubunto: has left #ruby: ()
[14:39:52] enebo: has joined #ruby
[14:40:31] Pumukel: has joined #ruby
[14:44:39] agarie: much better that way
[14:45:09] paulcsmith: has joined #ruby
[14:47:59] Scripore: has joined #ruby
[14:48:51] quimrstorres: has joined #ruby
[14:51:07] jenrzzz: has joined #ruby
[14:51:32] hectortrope: has joined #ruby
[14:54:04] that1guy: has joined #ruby
[14:54:43] Takle: has joined #ruby
[14:59:23] rdar: has joined #ruby
[15:00:07] vt102: has joined #ruby
[15:00:48] someword: has joined #ruby
[15:00:58] izzol: this recursive method is really creazy.
[15:01:31] jhass: as long as it doesn't turn craezy
[15:01:52] ljarvis: creazy is already too much for me
[15:01:53] serivich: has joined #ruby
[15:02:05] paulcsmith: has joined #ruby
[15:02:11] izzol: I mean crazy ;-)
[15:03:59] cubesandcode: has joined #ruby
[15:04:01] mrsolo: has joined #ruby
[15:05:25] riotjones: has joined #ruby
[15:08:35] freerobby: has joined #ruby
[15:09:14] izzol: I cannot understand one thing.
[15:09:22] izzol: If I have something like:
[15:09:36] ruboto: https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[15:10:09] izzol: https://gist.github.com/wolfedale/91b23dfa73e40f66d6f0
[15:10:33] izzol: And I call it: append([], 10)
[15:11:00] izzol: I understand that there will be a return if n < 0.
[15:11:11] adaedra: >> [] + (0..10).to_a
[15:11:13] ruboto: adaedra # => [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10] (https://eval.in/371935)
[15:11:13] izzol: and if not, it will call append() again with number 9 in my case.
[15:11:26] izzol: and then 8, 7 and so on.
[15:11:38] izzol: but, why it will print "shit" each time?
[15:11:44] jhass: adaedra: not the same and clearly not the point ;)
[15:11:52] snockerton: has joined #ruby
[15:11:53] adaedra: izzol: because l4?
[15:12:09] jhass: izzol: add p caller
[15:12:13] izzol: adaedra: but why line 4 is executed when line 3 is comming back?
[15:12:23] jhass: izzol: compare the output for each shit n
[15:12:27] kobain: has joined #ruby
[15:12:27] kinduff: has joined #ruby
[15:12:37] jhass: why wouldn't it?
[15:12:47] adaedra: jhass: mmh, yes, but it's not too far away
[15:12:51] mistermocha: has joined #ruby
[15:13:40] izzol: In my understanding when I call the method with number 8 it will execute append(array, 8-1) and this will execute append(array, 7-1)
[15:13:55] izzol: so not sure why puts "shit... is executed ech time as well
[15:13:59] OrbitalKitten: has joined #ruby
[15:14:13] adaedra: ah no, there's no real push
[15:14:20] jhass: izzol: add some output before the append call
[15:14:31] mistermo_: has joined #ruby
[15:14:34] jhass: adaedra: also no unreal one ;)
[15:14:51] adaedra: jhass: the name confused me
[15:15:00] adaedra: also, stop highlighting random people
[15:15:09] ljarvis: izzol: because you're down the rabbit hole
[15:15:22] quimrsto_: has joined #ruby
[15:15:25] ljarvis: each append calls itself so you get further down the stack
[15:15:36] ljarvis: then the puts executes on the way back up
[15:15:46] ljarvis: so it'll print the numbers backwards
[15:15:49] ljarvis: (probably)
[15:16:03] CloCkWeRX: has left #ruby: ()
[15:16:16] kinduff_: has joined #ruby
[15:16:29] ljarvis: it's not append() append() append() like your brain might be thinking, it's append(append(append(append())))) etc
[15:17:17] adaedra: you can try to print the call stack when you're at 0 (throwing anything could do it) to see it
[15:17:30] ljarvis: so the inner append runs first (hence printing the 0)
[15:18:36] cubesandcode: has joined #ruby
[15:18:38] kinduff: has joined #ruby
[15:18:39] nateberkope: has joined #ruby
[15:18:56] kinduff: good morning
[15:19:18] aryaching: has joined #ruby
[15:19:19] adaedra: or afternoon, I never know
[15:19:46] jhass: adaedra: ugt ;)
[15:20:06] jhass: adaedra: http://www.total-knowledge.com/~ilya/mips/ugt.html
[15:20:51] ljarvis: izzol: https://gist.github.com/leejarvis/496c2017488be2d1588c -- as jhass explains, caller would probably help you identify this
[15:21:06] Cache_Money: has joined #ruby
[15:21:25] adaedra: jhass: it doesn't respond to the problem of the limit between afternoon and evening.
[15:21:45] jhass: adaedra: it does, by eliminating the afternoon
[15:21:55] sorbo_: has joined #ruby
[15:21:56] ljarvis: that's what happens when i drink
[15:22:18] Peteykun: has joined #ruby
[15:22:19] commondream: has joined #ruby
[15:23:26] postmodern: has joined #ruby
[15:26:31] commondream: has joined #ruby
[15:27:03] ndrei: has joined #ruby
[15:30:35] Macaveli: has joined #ruby
[15:31:30] lkba: has joined #ruby
[15:31:59] gambl0re: does (f * 2) = ff?
[15:32:21] jhass: ?try gambl0re
[15:32:21] ruboto: gambl0re, Why don't you try it and see for yourself?
[15:32:33] jokke: jhass: i gave ruby-prof a try
[15:33:00] jokke: but even though i set measuring mode to memory i don't see any memory related info in the output
[15:33:31] Scripore: has joined #ruby
[15:33:42] jokke: https://p.jreinert.com/aEhK/
[15:33:55] jokke: http://p.jreinert.com/aEhK/
[15:34:13] dudedudeman: >> (f *2) == ff?
[15:34:14] ruboto: dudedudeman # => undefined method `f' for main:Object (NoMethodError) ...check link for more (https://eval.in/371946)
[15:35:06] jhass: jokke: never really worked with it
[15:35:25] ismaelga: has joined #ruby
[15:35:41] gambl0re: how does that makse sense though?
[15:35:51] ismaelga: has joined #ruby
[15:36:02] gambl0re: multiple a letter to a number
[15:36:05] iamjarvo: has joined #ruby
[15:36:34] gambl0re: >> (blahblahblah * 100)
[15:36:35] ruboto: gambl0re # => undefined local variable or method `blahblahblah' for main:Object (NameError) ...check link for more (https://eval.in/371947)
[15:36:45] jhass: it's a variable
[15:36:47] ruboto: Please show your real code to illustrate your problem. Using fake code often hides it or won't bring up the best possible solution.
[15:37:40] garyserj: has joined #ruby
[15:38:17] gambl0re: >> (blah * 2) == blahblah?
[15:38:18] ruboto: gambl0re # => undefined local variable or method `blah' for main:Object (NameError) ...check link for more (https://eval.in/371952)
[15:38:41] sorbo_: gambl0re: ruby overloads * for strings to do copying/repetition
[15:38:42] jokke: >> 'blah' * 2
[15:38:42] sorbo_: http://ruby-doc.org/core-2.2.0/String.html#method-i-2A
[15:38:43] ruboto: jokke # => "blahblah" (https://eval.in/371953)
[15:38:44] sorbo_: that's just how ruby works
[15:38:53] kinduff: ruboto talked?
[15:39:03] gambl0re: >> ("blah" * 2)
[15:39:04] ruboto: gambl0re # => "blahblah" (https://eval.in/371954)
[15:39:08] gambl0re: >> ("blah" * 100)
[15:39:09] ruboto: gambl0re # => "blahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahblahbla ...check link for more (https://eval.in/371955)
[15:40:10] jhass: !fact mk experiment Please use your local irb or pry (see ?pry) to experiment, ruboto's eval functionality is for demonstration purposes only.
[15:40:10] ruboto: jhass, I will remember that experiment is Please use your local irb or pry (see ?pry) to experiment, ruboto's eval functionality is for demonstration purposes only.
[15:40:44] failshell: ruboto: make me a sandwich
[15:40:45] Rubie: has joined #ruby
[15:41:55] HotCoder: has joined #ruby
[15:42:27] mikecmpb_: has joined #ruby
[15:42:58] kinduff: rubuto sudo make me a sandwich
[15:43:31] hewenhong: has joined #ruby
[15:44:02] jhass: ?botsnack
[15:44:03] ruboto: nomnomnomnom
[15:44:13] rom1504: he ate your sandwich
[15:44:41] kinduff: >> (Float::NAN.to_s * 10) + " Batman!"
[15:44:42] ruboto: kinduff # => "NaNNaNNaNNaNNaNNaNNaNNaNNaNNaN Batman!" (https://eval.in/371959)
[15:45:13] mistermocha: has joined #ruby
[15:45:19] Soda: has joined #ruby
[15:45:48] dudedudeman: who created rubuto?
[15:45:58] i: has joined #ruby
[15:45:58] dudedudeman: or did ruboto assimilate
[15:46:13] ruboto: I'm the channel bot, linker of the rules, adept of the facts, wielder of the banhammer.
[15:46:14] rom1504: he created himself
[15:46:17] baweaver: has joined #ruby
[15:46:25] dudedudeman: is that like, ultron?
[15:46:36] dudedudeman: ?ruboto ultron?
[15:46:37] ruboto: ultron?, I'm the channel bot, linker of the rules, adept of the facts, wielder of the banhammer.
[15:46:49] mistermo_: has joined #ruby
[15:46:52] ljarvis: that worked out well
[15:46:57] Guest4634: has left #ruby: ()
[15:47:00] izzol: ok I think I understand now :P
[15:47:10] dudedudeman: i push buttons good
[15:47:22] dopie: has joined #ruby
[15:47:42] kinduff: >> e=(0/0.0); "#{"#{e}"*10}"+ ' Batman!'
[15:47:43] ruboto: kinduff # => "NaNNaNNaNNaNNaNNaNNaNNaNNaNNaN Batman!" (https://eval.in/371962)
[15:48:23] kinduff: didnt knew "#{"#{}"}" was possible
[15:48:44] kinduff: >> "#{"#{yes}"}"
[15:48:45] ruboto: kinduff # => undefined local variable or method `yes' for main:Object (NameError) ...check link for more (https://eval.in/371963)
[15:48:54] kinduff: >> "#{"#{"yes"}"}"
[15:48:55] ruboto: kinduff # => "yes" (https://eval.in/371964)
[15:49:02] jpfuentes2: has joined #ruby
[15:49:07] apeiros: kinduff: any valid expression can be nested in #{}
[15:49:12] kinduff: >> "#{"#{"yes"}".count}.to_s"
[15:49:13] ruboto: kinduff # => wrong number of arguments (0 for 1+) (ArgumentError) ...check link for more (https://eval.in/371965)
[15:49:20] adaedra: >> % #{% }
[15:49:22] ruboto: adaedra # => /tmp/execpad-3f53c66b7a89/source-3f53c66b7a89:3: syntax error, unexpected tCONSTANT, expecting keywo ...check link for more (https://eval.in/371966)
[15:49:31] aryaching: has joined #ruby
[15:50:19] adaedra: >> % #{% } .to_s
[15:50:20] ruboto: adaedra # => "" (https://eval.in/371967)
[15:50:25] vdamewood: has joined #ruby
[15:50:26] Agoldfish: has joined #ruby
[15:50:35] adaedra: If you remove my spaces, it doesn't work, ruboto
[15:50:44] mello: has joined #ruby
[15:51:26] mrmargolis: has joined #ruby
[15:51:29] Scripore: has joined #ruby
[15:52:00] ljarvis: >> ???->(_){%|00|}.($/):??
[15:52:01] ruboto: ljarvis # => /tmp/execpad-bcbd99e93cd9/source-bcbd99e93cd9:2: warning: string literal in condition ...check link for more (https://eval.in/371968)
[15:52:10] gluten_hell_: has joined #ruby
[15:52:12] dfockler: has joined #ruby
[15:52:37] jhass: I see, we need to found #ruby-golf
[15:52:50] paulcsmith: has joined #ruby
[15:53:05] bluish: has joined #ruby
[15:53:08] casadei: has joined #ruby
[15:53:10] aphprentice: has joined #ruby
[15:53:53] nateberkopec: has joined #ruby
[15:56:00] n3vtelen: has joined #ruby
[15:56:08] n3vtelen: how do I get response
[15:56:14] n3vtelen: without hostname
[15:56:28] n3vtelen: response = Net::HTTP.get_response("http://ip.jsontest.com/")
[15:56:33] eam: >> %{#{%}#{%}#{%}#{%}#{%}what.}}}}}}}}}}}
[15:56:34] ruboto: eam # => "what." (https://eval.in/371980)
[15:56:54] ljarvis: n3vtelen: without hostname?
[15:57:38] ljarvis: that method expects a URI object, not a string
[15:57:46] pietr0: has joined #ruby
[15:57:50] ljarvis: get_response(URI("http://ip.jsontest.com"))
[15:57:59] CorySimmons: has joined #ruby
[15:58:17] n3vtelen: ljarvis: tnx, what's the difference
[15:58:43] ljarvis: n3vtelen: "foo" is a string, URI("foo") would return a URI instance, which is what get_response expects
[15:59:01] n3vtelen: ljarvis: oh, types :D
[15:59:31] ljarvis: http://ruby-doc.org/stdlib-2.2.2/libdoc/net/http/rdoc/Net/HTTP.html#class-Net::HTTP-label-GET+with+Dynamic+Parameters
[16:00:01] marr: has joined #ruby
[16:00:28] User458764: has joined #ruby
[16:01:37] n3vtelen: I have a ruby with ruby 2.2.2p95 version, is it update?
[16:01:37] baroquebobcat: has joined #ruby
[16:01:42] ljarvis: n3vtelen: yes
[16:01:49] n3vtelen: ljarvis: tnx
[16:02:45] commondream: has joined #ruby
[16:02:53] alnoo: has joined #ruby
[16:03:26] alnoo: Total ruby noob. Is this in the standard library, or is this a gem I have to download? http://ruby-doc.org/stdlib-2.0/libdoc/rubygems/rdoc/Gem/Package/TarReader.html
[16:03:46] adaedra: URI says stdlib
[16:03:52] ljarvis: alnoo: it's in the stdlib, inside the rubygems gem
[16:04:25] alnoo: so if I want to use is it, I call Gem::Package::TarReader.new( ... ?
[16:04:31] ruboto: Why don't you try it and see for yourself?
[16:04:51] haxrbyte: has joined #ruby
[16:04:53] jpfuente_: has joined #ruby
[16:04:57] alnoo: Sorry, let me be more transparent
[16:05:11] alnoo: that does not work. Trying to figure out if that's the right way to call something from the stdlib
[16:05:29] n3vtelen: has left #ruby: ()
[16:06:03] commondream: has joined #ruby
[16:06:13] jhass: alnoo: require "rubygems/package"; should do
[16:07:15] _n3vtelen: has joined #ruby
[16:07:33] alnoo: so I don't want to get off topic, but this is a rails model I'm working on. Do I still require rubygems/package like I would in a regular ruby file?
[16:07:46] ljarvis: alnoo: yes
[16:08:06] alnoo: ok, will give this a shot. thanks everyone.
[16:08:15] nobitanobi: has joined #ruby
[16:08:23] ljarvis: you could also require it in an initializer, though I would require it directly in the model
[16:09:10] jamesaxl: has joined #ruby
[16:09:35] towski_: has joined #ruby
[16:12:06] yh: has joined #ruby
[16:13:44] n3vtelen: has joined #ruby
[16:13:45] mistermocha: has joined #ruby
[16:14:18] cirn0: has joined #ruby
[16:14:24] mistermocha: has joined #ruby
[16:14:47] baweaver: has joined #ruby
[16:14:51] mrsolo: has joined #ruby
[16:15:03] edwinvdgraaf: has joined #ruby
[16:16:59] jpfuentes2: has joined #ruby
[16:17:41] tomaszbalon: has joined #ruby
[16:18:59] havenwood: has joined #ruby
[16:19:48] rbennacer: has joined #ruby
[16:20:33] edwinvdg_: has joined #ruby
[16:22:19] n3vtelen: has joined #ruby
[16:22:59] Drewch: has joined #ruby
[16:23:11] wca: has joined #ruby
[16:24:46] chrisja: has joined #ruby
[16:25:38] wca: hi, is there a way to interrupt a ruby program running with byebug so that byebug gets invoked in the current context? similar to what would happen if you run a C program under gdb?
[16:25:54] wca: i'm not seeing anything in byebug's documentation about doing something like that :-/
[16:26:08] mrsolo: has joined #ruby
[16:26:24] baweaver: wca: You do realize that's what Pry does right?
[16:26:30] baweaver: and why you have binding.pry
[16:26:38] Ecco: has joined #ruby
[16:26:39] wca: afraid not, will look at it
[16:26:42] baweaver: Look into binding, interesting read for later.
[16:26:44] havenwood: wca: https://github.com/deivid-rodriguez/pry-byebug#pry-byebug
[16:26:59] Alayde: has joined #ruby
[16:27:02] havenwood: wca: binding.pry ftw
[16:27:08] pengin: has joined #ruby
[16:27:10] baweaver: wca: https://www.youtube.com/watch?v=jDXsEzOHb2M
[16:28:00] wca: I haven't used it, and when I looked briefly it doesn't mention being able to catch ^C to invoke the debugger input mode
[16:28:09] havenwood: https://www.youtube.com/watch?v=D9j_Mf91M0I
[16:28:12] _seanc_: has joined #ruby
[16:28:23] treehug88: has joined #ruby
[16:28:28] havenwood: Quick, link to a cirwin talk!
[16:28:34] jhass: wca: pry-rescue
[16:29:00] baweaver: cirwin is never on #ruby anymore
[16:29:01] wca: oh, that first youtube looks very interesting, using pry instead of irb :)
[16:29:04] jhass: and/or Signal.trap(:INT) { binding.pry } + pry-stack_explorer
[16:29:11] baweaver: I'll have to ask him about that later.
[16:29:37] havenwood: REPL Driven Development (RDD) is good but how does it hold up compared to Hammock Driven Development (HDD)?
[16:29:47] baweaver: https://gist.github.com/baweaver/13c7cc798fc71332ff07 - Also I did bad things to Ruby again.
[16:29:53] wca: The ? command must be using RDoc to lookup method documentation?
[16:29:53] woodennails: has joined #ruby
[16:30:05] wildroman2: has joined #ruby
[16:30:17] avril14th: has joined #ruby
[16:30:19] jhass: add pry-doc for core & stdlib documentation, else it just parses what's in the files
[16:30:23] havenwood: wca: It's an alias for `show-doc` in Pry. Check `help` for the commands.
[16:30:30] havenwood: wca: gem install pry-doc
[16:30:45] jhass: I wonder if somebody wrapped attaching with gdb and calling binding.pry into a nice gem
[16:31:49] wca: Thanks folks.
[16:31:57] dudedudeman: what is it with gdb today. I've heard three different people bring it up today for completely different reasons
[16:32:26] wca: jhass: I've used a gem that lets you call Ruby methods from gdb :) Can't remember what it's called.
[16:33:15] andylolz: has joined #ruby
[16:33:35] Scripore: has joined #ruby
[16:34:21] andylolz: hello can someone who speaks ruby & python help?! I???m looking for the ruby equiv of: `{x: op(y) for x, y in lst.items() if x == cond}`
[16:34:31] DerisiveLogic: has joined #ruby
[16:35:13] toretore: has joined #ruby
[16:35:13] andylolz: i.e. a conditional map that creates a hash
[16:35:43] Channel6: has joined #ruby
[16:35:44] _ixti_: has joined #ruby
[16:36:23] apeiros: andylolz: probably: lst.items.select { |x,y| op(y) }.to_h
[16:36:38] Spami: has joined #ruby
[16:36:45] kinduff: has joined #ruby
[16:36:48] andylolz: that looks like the right sort of thing! Thanks, apeiros :)
[16:36:58] apeiros: or well, lst.items.select { |x,y| x == cond }.map { |x,y| [x, op(y)] }.to_h
[16:37:17] wca: andylolz: is that setting x = op(y) in the hash when x == cond, otherwise omitting x?
[16:37:22] apeiros: ruby does not have list comprehensions. you'll usually use map and/or select instead.
[16:37:43] MatthewsFace: has joined #ruby
[16:37:50] andylolz: sorry yeah ??? I should have written it as a map in python
[16:38:17] andylolz: wca: exactly. Omitting the kev/val combo was the bit I was failing on
[16:38:42] Spami: has joined #ruby
[16:38:57] wca: andylolz: isn't lst supposed to be a dict?
[16:39:15] andylolz: wca: haha sorry yeah. Wow ??? bad example
[16:39:40] wca: andylolz: so you're effectively creating a new hash from an existing one but with omitted/modified key-value pairs
[16:40:02] andylolz: that???s exactly what I???m after.
[16:40:33] wca: andylolz: so you want something like this: lst.inject({}) {|h, kv| x, y = *kv; h[x] = op(y) if x == cond; h}
[16:40:48] jacor_m: has joined #ruby
[16:40:53] jhass: wca: each_with_object
[16:41:22] andylolz: wca: could I alternatively use `select`?
[16:41:34] jhass: but for small hashes I think .select { }.map { }.to_h is the most clear
[16:41:44] wca: jhass: ah, that avoids having to ensure that the last statement is the argument to inject
[16:42:10] wca: personally, I prefer to use inject vs select.map because it avoids creating unnecessary objects
[16:42:24] baweaver: ACTION prefers reduce
[16:42:29] Igorshp: has joined #ruby
[16:42:37] Igorshp: has joined #ruby
[16:43:29] MatthewsFace: has joined #ruby
[16:43:40] baweaver: and you do realize you can use parens to explode args
[16:43:51] it_tard: has joined #ruby
[16:44:19] baweaver: >> [[1,2], [3,4]].reduce(0) { |acc, (a,b)| acc + a + b }
[16:44:20] ruboto: baweaver # => 10 (https://eval.in/372022)
[16:44:42] jhass: explode, I sense a PHP dev :P
[16:45:03] baweaver: I quit programming because of PHP
[16:45:11] baweaver: then again that was when I was 14
[16:45:39] baweaver: Java and PHP are two languages I pretty well won't touch.
[16:45:42] wca: baweaver: thanks for the tip, makes sense.
[16:46:02] dfockler: ahh the old explode method
[16:46:11] wca: baweaver: just curious, what are your specific reasons for Java?
[16:46:26] ed112211: has joined #ruby
[16:46:31] baweaver: Clunky, and really really hellish for Big Data
[16:46:45] pvb: has joined #ruby
[16:47:01] wca: I was hoping for something a bit more technical :)
[16:47:18] baweaver: Key concept? MapReduce
[16:47:39] baweaver: Where do those come from? Functional Programming
[16:47:53] baweaver: What is Java? About as anti-FP as possible
[16:48:00] bluOxigen: has joined #ruby
[16:48:08] baweaver: ex0ns: I use it.
[16:48:20] ex0ns: I try to use it as well
[16:48:31] ex0ns: but I really have hard time getting used to it
[16:48:45] bronson: has joined #ruby
[16:49:15] baweaver: I'm actually driving some of the initiative to switch to Scala for Spark processing jobs at work, including teaching people Scala.
[16:49:50] mrmargol_: has joined #ruby
[16:49:59] ex0ns: I had to use Spark for a specitic task, it was really nice
[16:51:31] OrbitalKitten: has joined #ruby
[16:52:12] ex0ns: One thing I really love about scala (and what I miss the most when writing ruby) is pattern matching
[16:52:31] agarie: Scala is a nice language indeed, we started using it in the last company I worked
[16:52:44] agarie: I have very high hopes for Julia
[16:53:35] ex0ns: Oh... another language I had never heard of...
[16:53:48] rbennacer: has joined #ruby
[16:54:19] tjbiddle: has joined #ruby
[16:54:53] roolo: has joined #ruby
[16:55:17] shevy: Romeo beats Julia
[16:56:01] baweaver: shevy: http://shakespearelang.sourceforge.net/report/shakespeare/
[16:56:20] ex0ns: baweaver: definitely the future
[16:56:29] ex0ns: of programming
[16:56:31] shevy: Am I better than you?
[16:56:37] shevy: If so, let us proceed to scene III.
[16:56:42] shevy: I can see the if else clause
[16:56:44] shevy: like a marriage
[16:57:05] shevy: this programming language would make me very violent though
[16:57:06] paulcsmith: has joined #ruby
[16:57:31] pengin_: has joined #ruby
[16:57:55] edwinvdgraaf: has joined #ruby
[16:58:10] miah: enough to kill several Capulets
[16:58:42] yh: has joined #ruby
[16:58:50] shevy: Capulets?
[16:58:57] baweaver: miah: Oi! Spoilers!
[17:00:07] miah: shakespear spoilers
[17:00:33] baweaver: ACTION is just being cheeky at this point
[17:00:43] Hanmac: shevy do you have any osx hardware?
[17:00:55] baweaver: It was enough to kill a Montague too
[17:01:11] sparr: has joined #ruby
[17:01:17] sorbo_: I feel about Scala the same way I feel about C++
[17:01:21] northfurr: has joined #ruby
[17:01:30] sorbo_: insofar as I have no idea which part of the language I should use
[17:01:58] shevy: hanmac nope; only linux and windows here
[17:02:13] Hanmac: baweaver: i wouldnt trust sourceforge anymore ... they are manipulating the software and adding adware into it
[17:02:33] pandaant: has joined #ruby
[17:02:34] baweaver: hanmac: It was more of to point out that there was such a thing as a Shakespear language
[17:02:40] shevy: sorbo_ well you can see that about parts about ruby too, for instance the @@ - I never seem to really need them
[17:02:51] baweaver: If anyone actually downloads/uses that, well that's a whole other can of worms
[17:03:00] shevy: like lolcode?
[17:03:14] Hanmac: baweaver: i like the language "piet"
[17:03:15] baweaver: Language wise, it's either not enough libraries / features or too much to ever possibly get through
[17:03:26] baweaver: Hodor or Groot for me
[17:04:36] finisherr: has joined #ruby
[17:05:03] spyderman4g63: has joined #ruby
[17:05:39] finisherr: I???m doing ruby koans and having some issues understanding the block syntax for the string replacement method .sub
[17:05:42] finisherr: here is the problem: http://pastebin.com/5AcbbEyX
[17:05:43] ruboto: finisherr, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/d9684554dd9cdedc46ab
[17:05:43] ruboto: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
[17:05:52] quimrstorres: has joined #ruby
[17:05:56] aryaching: has joined #ruby
[17:06:18] jhass: finisherr: $1 is the result of the first capture group
[17:06:23] SouL_|_: has joined #ruby
[17:06:27] jhass: s the t\w* part
[17:06:54] finisherr: not sure about the [0, 1] bit
[17:06:55] shevy: "one two-three".sub(/(t\w*)/) { $1[0, 1] }
[17:07:01] jhass: finisherr: $1 is a String
[17:07:15] shevy: so [0,1] means first character?
[17:07:33] jhass: shevy: you don't have enough patience :(
[17:07:37] finisherr: ohhhh, right, indexing the string
[17:07:37] Psy-Q: has joined #ruby
[17:07:54] shevy: jhass we need shortcuts!
[17:08:00] sorbo_: shevy, that's true
[17:08:11] shevy: imagine 10 lines of php code to achieve the same
[17:08:13] sorbo_: I've actually gone and converted most of my class variables to class instance variables, since it turns out you don't really need @@ much
[17:08:24] shevy: sorbo_ yeah
[17:08:52] shevy: >> class Foo; @bar = 'bar'; end; Foo.instance_variables
[17:08:53] ruboto: shevy # => [:@bar] (https://eval.in/372034)
[17:09:01] finisherr: Koan is telling me the result is: "one t-three"
[17:09:30] shevy: >> "one two-three".sub(/(t\w*)/) { $1[0, 1] }
[17:09:30] ruboto: shevy # => "one t-three" (https://eval.in/372036)
[17:09:35] finisherr: but i???m not sure I get that. It basicaly just wiped out the two characters after the first match
[17:09:37] shevy: ruboto confirms
[17:09:48] jhass: finisherr: well, what does the regex match?
[17:09:53] shevy: well you replaced something via .sub
[17:10:08] balazs: any dashing experts here ? How do I disable drag&drop ?
[17:10:18] finisherr: looks like the regex matches any number of words starting with t
[17:10:29] shevy: well you do use a "t" there :)
[17:10:37] jhass: finisherr: no, \w is short for [a-zA-Z0-9_]
[17:11:07] jhass: it's still matching on single characters, not words
[17:11:12] ljarvis: balazs: I am a dashing expert, but never used the software
[17:11:14] finisherr: right right
[17:11:41] jhass: so in this example, what does it match?
[17:11:53] andylolz: has left #ruby: ()
[17:11:54] finisherr: it is saying match the first capture
[17:12:13] arup_r: has joined #ruby
[17:12:26] jhass: right, so what's $1[0, 1] ?
[17:12:27] balazs: ljarvis: pun ? :)
[17:12:39] pwattstbd: has joined #ruby
[17:12:47] jhass: and there we are, it replaces two with t
[17:12:49] dudedudeman: noob ish question, guys..
[17:13:01] ljarvis: balazs: yes sorry, I imagine you'd have to do it in JS
[17:13:03] finisherr: Ok, yeah, that makes sense
[17:13:05] sarkyniin: has joined #ruby
[17:13:10] dudedudeman: i run my app with: ruby app.rb "argvs"
[17:13:16] finisherr: Thanks folks
[17:13:18] dudedudeman: i want to just do app "argvs"
[17:13:30] sarkyniin: dudedudeman: #/usr/bin/env ruby
[17:13:31] miah: your script needs a #!/usr/bin/env ruby
[17:13:32] sarkyniin: at the top of your script
[17:13:33] edwinvdg_: has joined #ruby
[17:13:34] sarkyniin: then chmod +x
[17:13:38] sarkyniin: oh yea the bang
[17:13:41] dudedudeman: i have the shbang
[17:13:46] jhass: then mv app{.rb,}
[17:13:57] dudedudeman: the chmod, ahh. is it not chmod 777?
[17:13:58] miah: after that ./app should work
[17:14:05] sarkyniin: chmod +x alone makes it executable
[17:14:07] sarkyniin: which is all you want
[17:14:09] miah: 755 will work
[17:14:19] miah: 777 means _anybody_ can write to your file
[17:14:24] miah: as well as execute it
[17:14:55] dudedudeman: ah! ok. i learned something. not to chmod 777 the heck out of things
[17:14:58] sarkyniin: Anyone has a set of exercises to practice with while reading the pickaxe book?
[17:15:00] miah: http://en.wikipedia.org/wiki/Chmod#Octal_modes
[17:15:06] sarkyniin: I haven't found any while googling
[17:15:18] dudedudeman: miah: sarkyniin, jhass, thank you
[17:15:22] jhass: dudedudeman: prefer the ugo+rwx form
[17:15:29] jhass: so you know what you're doing
[17:15:39] dudedudeman: jhass: i'm not familiar with that? i'll be honest
[17:15:49] dwithers: has joined #ruby
[17:15:54] jhass: u+x add x flag for the owner
[17:16:02] wallerdev: has joined #ruby
[17:16:09] jhass: o-r take the read flag for everybody else
[17:16:20] jhass: g=w group has write flag, no others
[17:16:26] miah: u = user, g = group, o = other
[17:16:32] jhass: and lots of combinations of that
[17:16:44] mwlang: has joined #ruby
[17:16:48] miah: saying u+x for owner is kinda confusing =)
[17:16:52] sdwrage: has joined #ruby
[17:17:03] dudedudeman: i'm easily confused, no worries
[17:17:19] miah: learn octal mode, it wont take you long
[17:17:29] jhass: I still struggle...
[17:17:45] shevy: ... with cooking
[17:17:54] jhass: well, and I find user of the file less obvious than owner of the file :P
[17:18:06] shevy: you capitalist!
[17:18:14] pocketpr1: has joined #ruby
[17:18:17] dudedudeman: shevy: stop talking about cooking. i'm having to take my lunch an hour later than normal, and i'm all out of snacks
[17:18:18] Alayde: has left #ruby: ("WeeChat 1.0")
[17:18:26] mwlang: What???s the easiest way to unescape escaped HTML? For example: ???&lt;STRONG&gt;Stacy Pratt McDermott&lt;/STRONG&gt; is Assistant Director??????
[17:18:28] shevy: dudedudeman I got home buying food an hour ago or so :)
[17:18:40] dudedudeman: miah: I'll dig in to that, thank you. you too, jhass
[17:18:42] shevy: I even have one beer... but I drank orange juice, so now beer does not fit...
[17:18:43] mwlang: (this is not rails project, btw)
[17:18:46] jhass: mwlang: CGI has something, unescapeHTML or so
[17:19:01] alex88: has joined #ruby
[17:19:02] shevy: what an ugly name for a method
[17:19:11] mwlang: jhass: thanks???I???ll hunt for that.
[17:19:14] dojobo: has joined #ruby
[17:19:30] mwlang: CGI everything is kinda ugly. :-/
[17:19:38] jhass: ah, gladly there's an unescape_html alias :D
[17:20:06] shevy: >> require 'cgi'; CGI.unescape_html('&lt;STRONG&gt;Stacy Pratt ')
[17:20:06] miah: jhass: sure, but if you read docs about permissions its always 'user, group, and other'
[17:20:07] ruboto: shevy # => "<STRONG>Stacy Pratt " (https://eval.in/372041)
[17:20:24] nateberkopec: has joined #ruby
[17:20:31] pengin: has joined #ruby
[17:20:38] shevy: the code and examples are kind of weird
[17:20:48] shevy: you find lots of references to literally: CGI::unescapeHTML
[17:21:22] shevy: mwlang I'd wish if the default cgi would offer something like routing in sinatra too
[17:21:28] psye: has joined #ruby
[17:22:00] Vendella: has joined #ruby
[17:22:06] Vendella: Which one is preferred? http://codepad.org/HYCZMozz
[17:22:19] jhass: I wish cgi would be removed from stdlib and the useful parts be replaced by http_util and html_util or something
[17:22:23] psye: has joined #ruby
[17:23:06] shevy: Vendella I don't like either one if that helps :)
[17:23:09] jhass: Vendella: for is discouraged, so...
[17:23:20] jhass: but yeah, is that a real example?
[17:23:22] shevy: first one would seem more natural ruby
[17:23:24] startupality: has joined #ruby
[17:23:35] jhass: because that's just String#==
[17:23:36] moretti: has joined #ruby
[17:23:44] shevy: what are you actually comparing
[17:23:49] shevy: first method uses (), second does not
[17:24:16] shevy: he really tricked us :)
[17:24:24] jhass: actually it's not
[17:24:30] jhass: what does it even do...
[17:24:41] shevy: jhass do you use () parens in method definitions?
[17:24:45] jhass: they're not the same logically
[17:24:46] Vendella: The point is, use for in or each?
[17:24:54] jhass: shevy: in my own projects I don't
[17:25:04] Vendella: shevy, Then don't say you don't like either
[17:25:16] shevy: but I don't like either of those two suggestions!
[17:25:30] jhass: Vendella: what's your actual goal?
[17:25:35] shevy: first one seems better than the second one though
[17:25:41] Vendella: The == is somehow implemented, you think it's magic?
[17:25:53] Alayde: has joined #ruby
[17:25:59] jhass: == is a method
[17:26:04] shevy: and magic
[17:26:08] jhass: String#==, Fixnum#==, Array#==
[17:26:18] jhass: != calls it too
[17:26:23] jhass: and negates the result
[17:26:40] mwlang: jhass: thanks. that worked perfectly. It even unescaped this one, too: ???&#60;b&#62;What you need to know about your customers&#60;/b&#62;&#60;p&#62;???
[17:26:55] djbkd: has joined #ruby
[17:27:56] sorbo_: >> String.methods.grep :==
[17:27:57] ruboto: sorbo_ # => [:==] (https://eval.in/372043)
[17:28:14] sorbo_: >> 'foo'.== 'foo'
[17:28:15] ruboto: sorbo_ # => true (https://eval.in/372044)
[17:28:18] sorbo_: >> 'foo'.== 'bar'
[17:28:19] ruboto: sorbo_ # => false (https://eval.in/372045)
[17:29:05] sorbo_: x == y is the same as x.==(y)
[17:29:12] sorbo_: for objects that respond to the == message
[17:29:25] shevy: Detective sorbo_ rivals Sherlock Holmes :)
[17:29:39] baweaver: === is fun too
[17:29:50] shevy: looks like a beaver dam too
[17:29:51] wca: ACTION thinks is_a? is clearer than ===
[17:29:52] Vendella: is using length instead of size faster?
[17:30:05] shevy: they are aliases Vendella
[17:30:16] baweaver: considering Array uses it as includes, Regex as match, and Proc as call
[17:30:19] jhass: they map to the same function for the core classes
[17:30:23] shevy: size is shorter to type, so you'll finish your code sooner by 0.00002% of use!
[17:30:31] luckyme: has joined #ruby
[17:30:39] baweaver: that's how case statements work, ===
[17:30:41] Vendella: length is a method and not part of Enumerable
[17:30:47] blaines: has joined #ruby
[17:30:50] Vendella: and running at O(1)
[17:31:12] shevy: the good thing is that you can always peek at the source: http://ruby-doc.org/core-2.2.0/Array.html#method-i-size
[17:31:13] jhass: >> [].method(:size).owner
[17:31:14] ruboto: jhass # => Array (https://eval.in/372046)
[17:31:29] jhass: >> {}.method(:size).owner
[17:31:30] ruboto: jhass # => Hash (https://eval.in/372047)
[17:31:32] shevy: then you can click to show source, and obtain:
[17:31:33] iamjarvo: has joined #ruby
[17:31:43] shevy: static VALUE rb_ary_length(VALUE ary) { long len = RARRAY_LEN(ary); return LONG2NUM(len);}
[17:31:50] baweaver: case y; when (1..3) then x ... translates to something like (1..3).===(y)
[17:31:52] jhass: >> require "set"; Set.new.method(:size).owner
[17:31:52] sorbo_: I find I never use === directly
[17:31:53] ruboto: jhass # => Set (https://eval.in/372048)
[17:31:56] sorbo_: only indirectly via `case`
[17:31:59] hmnhf_: has joined #ruby
[17:32:12] wca: and is_a? too surely?
[17:32:13] sorbo_: in fact I only type === when I'm rapidly switching between JS and Ruby and typo >_<
[17:32:28] shevy: I also use .is_a? - I think the ruby cgi module uses .kind_of?
[17:32:30] sorbo_: wca: I actually try not to interrogate objects to find out what kind of thing they are
[17:32:31] rdar: has joined #ruby
[17:32:35] shevy: *CGI class rather
[17:32:55] jhass: lots of rubys stdlib is not very idiomatic code anymore :/
[17:33:05] sorbo_: I usually prefer Object#responds_to? to Object#kind_of? or Object#is_a?
[17:33:09] shevy: well, a lot of that was written like 1999-2001
[17:33:18] sorbo_: s/responds_to/respond_to/g
[17:33:30] shevy: perhaps crystal will replace ruby one day
[17:33:33] wca: sorbo_: sure, sometimes it's better to just call a method if that objects responds to it
[17:33:40] jhass: shevy: I don't think so
[17:33:42] spyderman4g63: has joined #ruby
[17:34:07] mwlang: I???m kind of surpised those classes didn???t become more idiomatic during the major language enhancements???either at the 1.8 ==> 1.9 turn or at the 1.9 ==> 2.0 turn.
[17:34:52] shevy: people are lazy!
[17:35:03] Ilyes512: has joined #ruby
[17:35:11] shevy: you sort of need project owners, such as you have with (many) gems
[17:35:16] jhass: programmers are also used to keep the existing style when working on existing code
[17:35:43] shevy: you conform to style of other people?
[17:35:54] jhass: if I collaborate? sure
[17:36:06] sorbo_: first mover usually wins :\
[17:36:29] iamjarvo_: has joined #ruby
[17:36:37] sorbo_: I conform to existing style when collaborating and also when changing environments
[17:36:48] sorbo_: I super hate tabs for indentation but I use them when writing Go
[17:36:54] sorbo_: (actually go fmt makes this pretty painless)
[17:37:13] iamjarvo_: has joined #ruby
[17:37:37] shevy: so you are a tabster
[17:38:06] sorbo_: I use two spaces for everything except Python (four spaces) and Go (tabs)
[17:38:18] sorbo_: I haven't written Python in a long time though
[17:38:43] jhass: I returned for a small script the other day and blindly applied two spaces there too now :D
[17:38:43] shevy: why did the python guys end up with four spaces and ruby guys with two?
[17:38:44] sorbo_: well, that's not completely true. I think I use four spaces for Swift too
[17:39:04] sorbo_: shevy, these are the great mysteries of the universe
[17:39:12] mwlang: shevy: because indentation is everything in python.
[17:39:25] CustosLimen: has joined #ruby
[17:39:33] mello: has joined #ruby
[17:39:59] mwlang: plus, four spaces or 1 tab used to be the norm back in the golden age of programming.
[17:40:04] dfockler: two spaces is good in ruby because it forces your methods to be smaller
[17:40:22] psyprus: has joined #ruby
[17:40:55] Xoro: has joined #ruby
[17:41:35] jhass: one could argue four spaces does the same because you hit the column limit earlier, thus hit the line limit earlier
[17:42:09] jhass: I think it's pure preference, getting used to
[17:42:12] apeiros: there was a golden age of programming?
[17:42:26] jhass: I had no issue writing two spaces python
[17:43:01] banister: has joined #ruby
[17:43:27] mtakkman: has joined #ruby
[17:43:42] d5sx43: has joined #ruby
[17:43:58] shevy: mwlang 1 tab ok; but why does this translate to 4 rather than 2 in python?
[17:44:43] commondream: has joined #ruby
[17:45:18] agarie: one thing that I like about 4 spaces in Python is that the indentation inside functions match the position of the function name
[17:45:34] shevy: I looked at the linux kernel; for instance, watchdog.c, the guy who write it uses tab for indentation
[17:45:38] agarie: as 'def ' takes 4 spaces :P
[17:45:44] mwlang: shevy: sorry, I was somewhat obtuse. Basically, in the old days, monitors were low resolution affairs???96dpi and worse. a tab was rendered as approximately four spaces and four spaces was usually used because that was most comfortable to read.
[17:45:45] cirn0: has joined #ruby
[17:46:07] spider-mario: has joined #ruby
[17:46:12] mwlang: over the years, monitors got better and fonts got better and things looked decent at 2 spaces instead of 4. people started changing.
[17:46:39] mwlang: older languages (i.e. python) probably just kept the convention because it just reads better with four spaces since indentation drives the language.
[17:46:56] jhass: aren't ruby and python about the same age?
[17:47:31] agarie: ruby is a bit older, but it appears that Python became "popular" first
[17:47:41] mwlang: jhass: Python came out in the 80s when those low-res monitors were still common.
[17:47:53] baweaver: Ruby 1995, Python 1991
[17:48:02] jhass: Python: 1991; 24 years ago according to WP
[17:48:23] jhass: Ruhy: 1995; 20 years ago
[17:48:34] agarie: really? damn, I thought Ruby was in 91 and Python in 94-95
[17:48:35] kinduff: has joined #ruby
[17:48:41] agarie: wells, it isn't a big difference
[17:48:49] agarie: s/wells/well/
[17:48:55] mwlang: ???Python was conceived in the late 1980s[1] and its implementation was started in December 1989[2] by Guido van Rossum at CWI in the Netherlands??? also from wikipedia.
[17:49:07] baweaver: Java was 1995
[17:49:12] dwithers1: has joined #ruby
[17:49:24] mwlang: all I know is I remember seeing it when I was in college, so that timeframe definitely matches my personal experience.
[17:49:24] apeiros: ACTION considers ruby, python & java to be of roughly the same age
[17:50:23] dfockler: lisp is over 50 years old
[17:50:35] shevy: (may(it(rest(in(peace
[17:50:42] mwlang: when did 120dpi monitors start hitting the scenes?
[17:50:50] sorbo_: I'm kind of astounded that Ruby and Java are the same age and JVM GC is so much more sophisticated
[17:50:57] jhass: 58 or 59 I think with the first interpreter 60?
[17:51:06] shevy: yeah like ruby has a much money put into it as Java right :P
[17:51:07] apeiros: lisp??? http://xkcd.com/297/
[17:51:17] gambl0re: i want to create my own programming language.
[17:51:21] apeiros: elegant weapons??? for a more civilized age???
[17:51:28] apeiros: gambl0re: do it
[17:51:32] shevy: haha... your father's parentheses
[17:51:35] dfockler: yeah ruby is a more community oriented language than Java
[17:51:37] gambl0re: i want to make it happier than ruby.
[17:51:37] apeiros: there's even books on it
[17:51:51] shevy: gambl0re apeiros wrote one
[17:51:53] apeiros: gambl0re: use :) to terminate statements
[17:52:00] apeiros: shevy: s/wrote/is writing/
[17:52:08] mikecmpbll: has joined #ruby
[17:52:13] apeiros: `puts "hello world" :)`
[17:52:22] sorbo_: shevy, that's fair
[17:52:25] shevy: no please no smileys as terminators
[17:52:41] apeiros: why? it'd make for an awesomely happy language!
[17:52:44] jhass: yes, use unicode emojis instead
[17:52:44] miah: <3 as terminator
[17:52:50] gambl0re: 8==D as terminator
[17:53:04] jpfuentes2: has joined #ruby
[17:53:04] codeFiend: has joined #ruby
[17:53:16] jhass: ^ my vote
[17:53:33] Alayde: emojis in my irc!? what black magic is this
[17:53:34] shevy: gambl0re see? designing a language is all about making the right decisions
[17:53:34] gambl0re: 8==D ---- (.)(.)
[17:53:37] Maletor: has joined #ruby
[17:53:43] miah: gambl0re: please stop
[17:53:48] dfockler: I'm waiting for the first widespread unicode based language
[17:54:04] shevy: dfockler it already has a logo - the happy smiling snowman
[17:54:04] jhass: ???? as keyword to raise an exception
[17:54:31] agarie: unicode... I always wanted to write some Haskell code with the -XUnicodeSyntax extension
[17:54:49] pdoherty: has joined #ruby
[17:54:54] agarie: it allows you to write things like `???` instead of `forall`
[17:54:54] dojobo: hexchat doesn't show those emojis :/
[17:55:14] codecop: has joined #ruby
[17:55:31] jhass: dojobo: linux?
[17:55:42] pengin: has joined #ruby
[17:56:17] dojobo: nah, windows port of the linux app
[17:56:28] bronson: has joined #ruby
[17:56:31] dojobo: wish i could use linux at work though
[17:56:48] jhass: well, make sure it's set to utf-8
[17:56:57] jenrzzz: has joined #ruby
[17:57:01] jhass: I think that was configurable there
[17:57:12] kinduff_: has joined #ruby
[17:57:37] blaines: has joined #ruby
[17:57:45] kinduff_: has joined #ruby
[17:57:49] codeFiend: has joined #ruby
[17:58:22] mrsolo: has joined #ruby
[17:58:37] sorbo_: agarie: https://twitter.com/kaepora/status/581437283200581632
[17:58:57] agarie: lol that's wonderful
[17:59:58] kinduff_: has joined #ruby
[18:00:29] Hijiri: has joined #ruby
[18:01:06] shevy: Hieroglyphics
[18:01:19] mello: has joined #ruby
[18:01:40] ta: has joined #ruby
[18:02:25] kinduff: has joined #ruby
[18:02:56] banister: has joined #ruby
[18:03:13] tomphp: has joined #ruby
[18:04:43] serivich: has joined #ruby
[18:05:09] matled: has joined #ruby
[18:07:26] wildroman2: has joined #ruby
[18:07:47] shevy: I am looking at the old ruby cgi code and I see this
[18:07:52] shevy: @options = { :accept_charset => @@accept_charset,
[18:07:55] shevy: that would be the same as:
[18:07:59] shevy: @options = { accept_charset: @@accept_charset,
[18:09:16] hmnhf_: has joined #ruby
[18:09:43] Alayde: Are there books/websites/blogs/other recommended readings for kind of..learning to structure ruby code? I find myself writing a fair amount of scripts, and while trying to make use of classes and modules I can't help but feel I'm not doing things the best practice way.
[18:09:56] Alayde: tl;dr any recommended reading for code organization?
[18:10:36] TheNet: has joined #ruby
[18:10:42] agarie: Alayde: I really liked Design Patterns in Ruby http://designpatternsinruby.com/
[18:10:48] shadoi: has joined #ruby
[18:10:52] agarie: Eloquent Ruby, from the same author, is great too
[18:11:01] chinmay_dd: has joined #ruby
[18:11:22] Alayde: agarie: awesome!
[18:11:35] sorbo_: Alayde: Practical Object-Oriented Design in Ruby, by Sandi Metz
[18:11:37] Takle: has joined #ruby
[18:11:41] yqt: has joined #ruby
[18:11:52] finisherr: has joined #ruby
[18:12:04] agarie: also, I recently finished Smalltalk Best Practice Patterns: http://www.amazon.com/Smalltalk-Best-Practice-Patterns-Kent/dp/013476904X
[18:12:30] sorbo_: The Well-Grounded Rubyist is also good
[18:12:32] agarie: but the other two are probably better if you're starting to read about the subject
[18:12:34] baweaver: https://twitter.com/aisamanra/status/601535327350624256/photo/1 shevy sorbo_
[18:12:57] shevy: I am wondering if it is worth to improve the ruby cgi module at all
[18:13:01] Takle: has joined #ruby
[18:13:10] Alayde: agarie, sorbo_: You guys rock, that's totally what I was looking for
[18:13:10] shevy: what language is that
[18:13:11] Alayde: much appreciated
[18:13:21] baweaver: shevy: Tolkien Elvish
[18:13:32] sorbo_: Alayde: happy to help!
[18:13:33] shevy: and so useless
[18:13:49] sorbo_: also +1 for the Russ Olsen books (Design Patterns in Ruby and Eloquent Ruby)
[18:14:00] miah: both great books
[18:14:10] sorbo_: those few should be a good foundation for organizing/building Ruby stuff
[18:14:26] Alayde: Kick ass. I'll add 'em to my amazon cart now
[18:14:30] sorbo_: there are probably good books/tutorials for Rails projects in particular but IDK what they are
[18:16:59] quimrstorres: has joined #ruby
[18:18:50] shadoi1: has joined #ruby
[18:19:00] bootstrappm: has joined #ruby
[18:19:46] User458764: has joined #ruby
[18:20:40] baweaver: New version of The Ruby Way just came out too
[18:20:54] ebonics: has joined #ruby
[18:21:50] aryaching: has joined #ruby
[18:23:10] miah: i have the old version.. its helpful for some things. but not my usual reference
[18:23:13] miah: takes up space on my shelf and thats abuot it
[18:23:44] doublemalt_: has joined #ruby
[18:23:44] zarubin: has joined #ruby
[18:23:59] soulcake: has joined #ruby
[18:24:51] platzhirsch: has joined #ruby
[18:24:52] sinkensabe: has joined #ruby
[18:25:24] hmnhf__: has joined #ruby
[18:25:47] RegulationD: has joined #ruby
[18:26:01] jasondockers: has joined #ruby
[18:26:07] sorbo_: reference I've found helpful lately are Pat Shaughnessy's Ruby Under a Microscope and Alexander Dymo's Ruby Performance Optimization
[18:26:14] platzhirsch: has left #ruby: ()
[18:26:21] jasondockers: Can I downgrade to ruby 2.1 from 2.2.0 on Windows easily?
[18:26:25] pengin: has joined #ruby
[18:27:02] sorbo_: this is true of most sentences with "windows" and "easily" in them
[18:27:11] sorbo_: system ruby, or are you managing via chruby/rvm/rbenv?
[18:27:28] Palmer11: has joined #ruby
[18:27:30] miah: do those even work on windows?
[18:27:41] wallerdev: just download ruby 2.1 and put it in your path before ruby 2.2
[18:27:53] jasondockers: system ruby I believe. I've never used ruby before and I'm just trying to run a utility installed with gems which is broken on 2.2
[18:28:10] miah: chocolatey still has 2.1.5; https://chocolatey.org/packages/ruby
[18:28:13] rippa: has joined #ruby
[18:28:16] shevy: you can always try to install a different ruby .exe
[18:28:22] miah: er, 2.1.6
[18:28:23] forgot: which one of chruby/rvm/renv is preferred?
[18:29:06] shevy: jasondockers: http://rubyinstaller.org/
[18:29:25] shevy: http://rubyinstaller.org/downloads/
[18:29:40] shevy: so at least 2.1.6 is there
[18:29:43] Alayde: has left #ruby: ("WeeChat 1.0")
[18:29:55] miah: i use chruby, but i dont use windows. i wish i could be more help on this topic but i avoid windows for all development
[18:30:09] shevy: aha, have not heard of Chocolatey before
[18:30:12] shevy: chocolate
[18:30:15] sorbo_: yeah, I also don't know a ton about windows
[18:30:24] sorbo_: hopefully the path trick wallerdev mentioned works
[18:30:41] adaedra: no one knows about Windows.
[18:30:41] sorbo_: forgot: I tend to use rbenv but have also heard good things about chruby. I would avoid RVM
[18:30:43] adaedra: It's a legend.
[18:30:50] adaedra: Made to frighten small kids.
[18:31:02] baroquebobcat: has joined #ruby
[18:31:15] shevy: the ghost baguette story
[18:31:22] nobitanobi: has joined #ruby
[18:31:29] forgot: sorbo_: im using rbenv. chruby sounds simpler
[18:31:31] shevy: no kid could eat it so they all died :(
[18:31:52] adaedra: shevy: what do you smoke ?
[18:31:57] treehug88: has joined #ruby
[18:32:12] adaedra: fair enough
[18:32:20] sorbo_: forgot: IIRC it is. but if rbenv is working for you, if it ain't broke, &c &c
[18:32:25] shevy: woodstock was my generation even before I was born!
[18:32:40] breakdown: has joined #ruby
[18:33:12] nobitanobi: has joined #ruby
[18:33:24] forgot: sorbo_: good point
[18:33:35] jenrzzz: has joined #ruby
[18:33:55] mclee: has joined #ruby
[18:34:10] shevy: do you guys follow a "one class/module per .rb file" guideline?
[18:34:11] TheNet: has joined #ruby
[18:34:20] jpfuente_: has joined #ruby
[18:34:47] kirun: has joined #ruby
[18:34:57] forgot: that's for java
[18:35:34] ljarvis: shevy: not everywhere, but where it makes sense to separate things into files
[18:35:39] dfockler: If they are small and related they can go together, but it makes it less clear when you require the file
[18:35:45] mwlang: shevy: more or less. I ocassionally collect things like constants, error classes, etc. which may be multiple classes or values into an aptly named file ???constants.rb??? ???errors.rb??? etc.
[18:36:27] mwlang: I don???t really like 3 or 4 line source files so if there???s an obvious theme, I tend to gather the small stuff up.
[18:36:30] sorbo_: shevy: usually, not always.
[18:36:36] woodennails: has joined #ruby
[18:36:50] sorbo_: ditto dfockler & mwlang
[18:37:19] shevy: I found in ruby cgi, core.rb file, the class CGI, and also a module embedded in it, module QueryExtension
[18:37:27] MatthewsFace: has joined #ruby
[18:37:36] ljarvis: that's reasonable
[18:37:45] miah: i do it like this; https://github.com/bbatsov/ruby-style-guide/#file-classes
[18:38:57] dfockler: Also organizing classes using modules is what a lot of gems end up doing
[18:38:58] miah: rsg also mentions; https://github.com/bbatsov/ruby-style-guide#one-class-per-file
[18:39:14] shevy: miah yeah
[18:39:27] casadei: has joined #ruby
[18:39:31] miah: my toplevel namespace is always a module
[18:40:00] shevy: reminds me of when apeiros used toplevel namespace as class once
[18:40:03] shevy: such an evil boy
[18:40:27] ljarvis: there's nothing wrong with that
[18:41:47] apeiros: not just once. I do that whenever it makes sense.
[18:41:59] apeiros: it's fairly less common than module, though.
[18:42:30] miah: generally, you use modules instead of classes to avoid collisions with existing classes
[18:42:53] ljarvis: that doesn't make sense
[18:42:59] forgot: the term 'module' confuses me a lot, is it called mixin?
[18:43:03] wallerdev: i just name variables using my first and last name plus a random number
[18:43:06] wallerdev: no collisions to worry about
[18:43:22] apeiros: wallerdev: what? not using a UUID?
[18:43:39] wallerdev: much easier to remember my name than a uuid :p
[18:43:47] ljarvis: forgot: no it's called a module. http://ruby-doc.com/docs/ProgrammingRuby/html/tut_modules.html
[18:44:03] miah: doesnt make sense?
[18:44:05] miah: Modules provide a namespace and prevent name clashes.
[18:44:07] apeiros: re avoid collisions: for that the toplevel module is/should usually be sufficient (i.e. if your gem name is foo_bar, your toplevel module is FooBar)
[18:44:10] miah: rule one from that link =)
[18:44:19] arup_r: >> def foo ; 1,2; end
[18:44:21] ruboto: arup_r # => /tmp/execpad-746b8d176550/source-746b8d176550:2: syntax error, unexpected ',', expecting keyword_end ...check link for more (https://eval.in/372056)
[18:44:42] dfockler: then you can do FooBar::CoolClass.new
[18:44:42] arup_r: Not valid! :/
[18:44:43] apeiros: arup_r: you either need the return keyword or have to wrap it in an array.
[18:44:56] ljarvis: miah: ah right I misunderstood you; my rebuttal was that a module constant can clash with an existing class name
[18:45:02] arup_r: why this design
[18:45:10] kinduff: has joined #ruby
[18:45:11] apeiros: arup_r: ask matz
[18:45:42] forgot: ljarvis: sorry, i mean is ruby module the equivalent of mixin in other languages?
[18:45:52] ljarvis: forgot: in what languages?
[18:46:06] apeiros: forgot: it may be similar. it's almost never equivalent, though.
[18:46:09] eam: I never use module, I always use class
[18:46:11] miah: >> class Array; end; module Array; end
[18:46:12] ruboto: miah # => Array is not a module (TypeError) ...check link for more (https://eval.in/372057)
[18:46:20] forgot: ljarvis: like python?
[18:46:23] bootstrappm: forgot you call it a mixin when you actually mix it in to a class using include
[18:46:28] eam: IMO ruby would be a lot simpler without module
[18:46:29] shevy: eam nobody shall believe you
[18:46:33] bootstrappm: which isn't always the use of a module but can be
[18:46:45] apeiros: eam: instead allowing to use include/extend with classes? might even work
[18:46:49] shevy: eam well, I'd like to unify classes and modules, but I definitely would not want to get rid of include
[18:46:51] mwlang: didn???t I read somewhere that modules were basically classes by another name and it???s just convention that modules aren???t instantiated?
[18:46:55] eam: If module didn't exist we wouldn't have ambiguity around Foo::Bar::Baz
[18:47:16] eam: apeiros: just do multiple inheritance, no big
[18:47:16] ljarvis: classes are modules that can be instantiated
[18:47:21] ljarvis: Class < Module
[18:47:30] ljarvis: >> Class < Module
[18:47:31] ruboto: ljarvis # => true (https://eval.in/372058)
[18:47:43] eam: MI is fine, it gets a bad rap because of implementation details of C++
[18:47:44] apeiros: eam: MI is ok to abolish include. but what about extend?
[18:47:49] ljarvis: forgot: pretty much yes
[18:48:02] ljarvis: mwlang: so yes :D
[18:48:07] apeiros: yeah, never got the hate MI received. include is basically linearized MI.
[18:48:11] dreinull75: so how do I load a file on irb startup? -r is for gems, just the file name executes?
[18:48:17] apeiros: no reason one couldn't do that with classes.
[18:48:22] eam: apeiros: can't MI handle both?
[18:48:23] ljarvis: dreinull75: -r is for everything
[18:48:37] apeiros: eam: extend is on a per object basis
[18:48:42] dreinull75: oh, just tried ./file
[18:48:45] ljarvis: dreinull75: if it's relative, you need to add ./; ie: ruby -r./foo.rb bar.rb
[18:48:48] mwlang: ljarvis: thanks for clarifying. I was like, ???sooo???.was that a yes???? :-)
[18:48:49] dreinull75: ljarvis thanks
[18:48:56] ljarvis: mwlang: :P
[18:49:01] eam: oh. well, would it need to be?
[18:49:08] apeiros: >> module X; def x; "weee"; end; this_string_only = "foo"; this_string_only.extend X; this_string_only.x
[18:49:09] ruboto: apeiros # => /tmp/execpad-992e78a365be/source-992e78a365be:7: syntax error, unexpected end-of-input, expecting ke ...check link for more (https://eval.in/372059)
[18:49:18] apeiros: DO WHAT I MEAN! SILLY BOT!
[18:49:19] tomphp: has joined #ruby
[18:49:29] apeiros: >> module X; def x; "weee"; end; end; this_string_only = "foo"; this_string_only.extend X; this_string_only.x
[18:49:31] ruboto: apeiros # => "weee" (https://eval.in/372060)
[18:49:34] eam: apeiros: wouldn't you normally extend the class, though?
[18:49:45] apeiros: eam: that's just a "special" case
[18:49:57] apeiros: I'm not actually sure what I do more often - extend a class or a non-class
[18:50:04] eam: ok, but wouldn't MI on an instance be possible if ruby allowed it?
[18:50:18] apeiros: I think extending plain objects dropped due to method cache invalidation. which is very sad :(
[18:50:25] apt-get_: has joined #ruby
[18:50:26] eam: once you have MI it should work dynamically on any object
[18:50:40] apeiros: eam: IMO yes. that's what I meant by "and allow include/extend with classes?"
[18:50:45] eam: aha, yes, I see
[18:50:51] jasondockers: I'm trying to use bundle to install a gem. My gemfile is "source :rubygems\n require 'thegem'," apparently the metadata is missing?
[18:51:05] miah: s/require/gem
[18:51:05] apeiros: only allowing it with modules was a design decision, not a technical one
[18:51:05] dreinull75: extend and include seem to be troublemakers in ruby world. Nobody really gets it right away.
[18:51:11] ljarvis: jasondockers: dont use require in your Gemfile
[18:51:11] bootstrappm: jasondockers its gem 'thegem' not require
[18:51:32] apeiros: eam: it'd actually be close to what I do in my toy language
[18:51:33] miah: http://bundler.io/v1.9/gemfile.html
[18:51:44] ljarvis: apeiros: i heard toy language, orly
[18:52:01] ljarvis: is this like the orm i'll never see?
[18:52:20] apeiros: ljarvis: the difference is that the ORM is actually working :-p
[18:52:37] jasondockers: :S. Okay, so I have a source and gem line.
[18:52:37] ljarvis: my point is valid, I don't have my grubby hands on it
[18:52:49] jasondockers: The extension is .gemspec, right?
[18:53:19] ljarvis: jasondockers: no, that's a gem specification file
[18:53:23] apeiros: ljarvis: you're right. blame freenode for letting me be founder of #ruby. caused havoc in my agenda. (though, it wasn't the only one)
[18:53:33] ljarvis: apeiros: true true
[18:53:48] apeiros: also blame netflix for existing
[18:53:52] ljarvis: I've been writing a toy language for about 6 years now
[18:54:12] apeiros: I think 6 years is about the time I haven't worked on my toy language :(
[18:54:24] Jackneill: has joined #ruby
[18:54:33] dfockler: I just started mine in Rust
[18:54:42] ljarvis: that could have been the latest craze
[18:54:44] dfockler: waiting 6 years before I start
[18:54:49] apeiros: hrm, might indeed be accurate. I haven't worked on it ever since I moved, and that's 5y ago. so 5y at the very least.
[18:54:54] ljarvis: dfockler: waiting for rust?
[18:55:06] ljarvis: apeiros: damn :/
[18:55:09] dfockler: haha no just joking
[18:55:11] Rubie: has joined #ruby
[18:55:12] apeiros: but at least with the toy language I knew it was low prio and that I might never finish it.
[18:55:20] apeiros: and it was still valuable and thought me a lot
[18:55:24] ljarvis: yeah that's how I view mine
[18:55:27] Alayde: has joined #ruby
[18:55:32] jasondockers: I tried .rb, .gem, .gemspec, .gemfile, .ioc, and saving the file as literally .gemfile :/
[18:55:41] bootstrappm: jasondockers: save it as Gemfile
[18:55:43] momomomomo: has joined #ruby
[18:55:47] ljarvis: mine taught me a lot too, but it's not very valuable in any other sense :D
[18:55:56] ljarvis: jasondockers: check out the documentation miah already linked you to
[18:56:15] dfockler: apeiros: just trying to figure out argument substitution and parsing is fun learning
[18:56:50] bronson: has joined #ruby
[18:56:56] pengin_: has joined #ruby
[18:56:59] bootstrappm: i'm itching for a new OS, I'm on elementaryOS (Luna) right now ... any suggestions?
[18:57:32] dfockler: bootstrappm: isn't that linux?
[18:57:37] tomphp: has joined #ruby
[18:57:55] bootstrappm: i guess a new distro is what i meant
[18:58:15] ljarvis: when I had time and really wanted to nerd out with Linux, gentoo was my poison
[18:58:16] bootstrappm: hahah only use it for photoshop but its there just in case ljarvis
[18:58:24] ljarvis: now I'm older and use OSX because shit just works
[18:58:28] Alayde: bootstrappm: Do you want something that 'just works' or do you wanna put time into building something?
[18:58:40] dfockler: I've been using mint and it's pretty clean and good
[18:58:41] miah: http://nixos.org/
[18:58:55] ddfreyne: bootstrappm: Haiku? It's a little hard to use though :)
[18:59:00] zarubin: has joined #ruby
[18:59:14] miah: or the gnu version; http://www.gnu.org/software/guix/
[19:00:22] iceden: has joined #ruby
[19:00:22] bootstrappm: Alayde wouldn't mind putting time into building a little but don't want to spend a week on it
[19:00:30] bootstrappm: maybe like ... two days
[19:00:41] dfockler: minix, it's fast
[19:00:54] miah: what about gnu hurd?
[19:01:12] Alayde: bootstrappm: Hm, well I'm probably the fuddy duddy in the room but I'd suggest debian stable netinstall myself. It's what I run at home, took me about 3-4 hours to get running (but I'm pretty linux savvy) and configured how I want it
[19:01:33] miah: im personally a fan of Archlinux. I run it on all my gear.
[19:01:40] bootstrappm: i'm leaning towards Arch, yeah
[19:01:43] miah: apart from my osx work laptop
[19:02:01] Alayde: Arch is pretty good too. I used to run it back in the day, though eventually I got tired of the rolling release thing
[19:02:08] Alayde: but, still cool
[19:02:12] jenrzzz_: has joined #ruby
[19:02:17] bootstrappm: yeah Alayde? I tried Debian on this laptop before but couldn't get it working because my wifi card isn't linux friendly. I bought a USB adapter for wifi later but by that time had already installed elementary
[19:02:22] bootstrappm: might give it another go
[19:02:25] miah: i havent had a issue with arch / rolling release (though i have with gentoo and portage)
[19:02:34] miah: but it was usally because of portage changes that made upgrading a pita
[19:02:57] pengin: has joined #ruby
[19:03:17] Alayde: bootstrappm: I feel you there, my card isn't supported out of the box ether. But I just did my install over ethernet, and installed the necessary non-free drivers after the fact
[19:03:33] jacor_m: has joined #ruby
[19:05:10] rbennacer: has joined #ruby
[19:05:38] bootstrappm: i saw a bit up that people were saying rbenv or chruby > rvm
[19:05:45] bootstrappm: when did people move away from rvm? I think i missed that train
[19:05:49] bootstrappm: i'm still using it
[19:06:01] chinmay_dd: has joined #ruby
[19:06:11] alphaatom: has joined #ruby
[19:06:13] dfinninger: has joined #ruby
[19:06:34] stoffus: has joined #ruby
[19:07:19] sorbo_: bootstrappm: comparison: http://kgrz.io/2014/02/13/Programmers-guide-to-choosing-ruby-version-manager.html
[19:07:48] sorbo_: mostly RVM does weird shit to your shell that I'm not a fan of
[19:07:49] sorbo_: http://www.lucas-nussbaum.net/blog/?p=550
[19:07:51] alnoo: I have a function that only returns if a condition is met. x = foo(y) is a string if y is a certain string, for example. How can I check that "x" has something assigned to it or not after the function is called?
[19:08:05] alnoo: *only returns a value
[19:08:22] miah: i use chruby / ruby-install. its super minimal and doesnt wrap shell commands
[19:08:44] dreinull75: and I'm still using rvm. It does a great job and never had any worries.
[19:08:50] nettoweb: has joined #ruby
[19:09:12] moretti: has joined #ruby
[19:09:23] sandelius: has joined #ruby
[19:09:29] sorbo_: I had a hell of a fight with RVM like 18 months ago
[19:09:35] dreinull75: looks like the fight between rbenv chruby and rvm is fiercer than that between vim and emacs
[19:09:58] sorbo_: which, TBH, was probably more Apple's fault than RVM's (OS upgrade)
[19:10:11] dreinull75: I'd usually say triy one and if it doesn't work move on and try the second
[19:10:12] sorbo_: but I had to nuke RVM from orbit and took the opportunity to switch to rbenv
[19:10:14] sorbo_: have had no trouble since
[19:10:24] JimmyNeutron: has joined #ruby
[19:10:24] sorbo_: that's reasonable advice dreinull75
[19:10:36] sorbo_: so bootstrappm if RVM is working for you, keep on keeping on
[19:10:39] mmazing: has joined #ruby
[19:10:44] miah: i think they all work reasonably well
[19:10:47] dreinull75: these things are meant to keep you worry free. if it doesn't do it, get out quickly.
[19:10:53] bootstrappm: cool sorbo_ thanks!
[19:10:56] miah: as long as you conform to their expected workflow
[19:11:12] bootstrappm: i've only ever had trouble w/ rvm using crons
[19:11:16] tomphp: has joined #ruby
[19:11:25] bootstrappm: because of the aforementioned "weird shit to your shell"
[19:12:00] dreinull75: same with python and ruby. Never managed to get python running with envs and whatever the hell they want me to install.
[19:12:09] havenwood: has joined #ruby
[19:12:28] bootstrappm: you mean virtual-env dreinull75?
[19:13:10] dreinull75: totally not getting it :) I'm an absolut failure.
[19:13:23] miah: i havnet had many issues with virtualenv
[19:13:34] finisherr: has joined #ruby
[19:13:46] miah: you just have to remember to always source your 'bin/activate' stuff
[19:14:09] sinkensabe: has joined #ruby
[19:17:03] marr: has joined #ruby
[19:17:14] hololeap: which do you think is better in terms of readability, singleton_class.class_eval or class << self?
[19:18:06] hololeap: or i guess a better question would be, which is better in terms of understandability by rubyists
[19:19:14] jhass: the latter
[19:20:35] delianides: has joined #ruby
[19:20:36] sorbo_: class << self
[19:20:57] sorbo_: rubyists will automatically recognize class-shovel-self
[19:21:20] sorbo_: I'm not sure I've even seen singleton_class.class_eval before
[19:21:44] prereflect: has joined #ruby
[19:22:05] hololeap: sorbo_: its kinda something i came up with on my own. i've been using it in my own code, but i generally don't see other people using it
[19:22:06] bootstrappm: agreed, class << self. Don't understand it but have seen it enough to get the intention
[19:22:41] Scripore: has joined #ruby
[19:23:08] hololeap: ok that's what i figured. thanks everyone
[19:23:23] paulcsmith: has joined #ruby
[19:26:43] tomphp: has joined #ruby
[19:27:13] _ixti_: has joined #ruby
[19:28:02] jerematic: has joined #ruby
[19:28:15] danman: has joined #ruby
[19:28:27] banister: has joined #ruby
[19:28:27] sorbo_: hololeap: np
[19:28:31] arescorpio: has joined #ruby
[19:28:38] sdwrage: has joined #ruby
[19:29:23] sorbo_: class << x means "open x's eigenclass for modification"
[19:29:23] erik_p: has joined #ruby
[19:29:36] sorbo_: you can think of the eigenclass as the object itself, i.e. methods added there are for that object only
[19:29:49] hololeap: ok one more if you don't mind: `!!some_non_boolean` vs `true & some_non_boolean` in terms of commonality and understandability
[19:29:54] sorbo_: so class << self says "open this class and put everything that follows directly on this object"
[19:30:11] sorbo_: hololeap: !!some_non_boolean, though RuboCop hates it
[19:30:15] sorbo_: that's an area where the robot and I disagree
[19:30:54] hololeap: sorbo_: i understand class << self, but i just never found it very readable, and frankly its hard to search for in google when you first encounter it :)
[19:31:22] quimrstorres: has joined #ruby
[19:31:28] jhass: symbolhound.com ;)
[19:31:58] hololeap: jhass: that's awesome
[19:32:16] hololeap: why doesn't google support PCRE search? ;)
[19:32:22] tjbiddle_: has joined #ruby
[19:32:38] idafyaid: has joined #ruby
[19:32:42] jhass: because then when you do a google search, you have two problems
[19:33:45] mistermocha: has joined #ruby
[19:34:32] hololeap: i don't get it <_<
[19:34:38] bootstrappm: thanks for that sorbo_. Is adding it to the eigenclass technically the same as adding it to the object (like say, in JS) or is it just a way to think about it?
[19:34:58] sandelius: has joined #ruby
[19:35:08] jhass: *singleton class
[19:35:26] jhass: that's the term ruby core settled for, we should phase the other ones out
[19:35:45] Soda: has joined #ruby
[19:35:48] delianides: has joined #ruby
[19:36:07] sorbo_: hololeap: sure thing (& definitely hear you re: class << self)
[19:36:34] sorbo_: bootstrappm: I'm not sure. I've always believed that eigenclass & object itself are synonymous in Ruby, but I might be mistaken.
[19:36:36] jhass: hololeap: https://xkcd.com/1171/
[19:36:43] sorbo_: I'll have to re-read Pat Shaughnessy's Ruby Under a Microscope
[19:36:53] sorbo_: goes through Ruby internals, v. interesting & well-written
[19:37:02] dreinull75: how can I use "testing" in my dev.rb file. ARGV doesn't seem to work here: irb -r ./dev.rb testing
[19:37:05] bootstrappm: lololol greeeat xkcd
[19:37:24] sorbo_: jhass thanks, I'll try to use singleton class from here on out
[19:37:32] cubesandcode: has joined #ruby
[19:38:27] bootstrappm: dreinull75: that give me a file not found error, its looking for testing
[19:39:07] baweaver: has joined #ruby
[19:39:17] mistermocha: has joined #ruby
[19:39:51] last_staff: has joined #ruby
[19:40:07] wallerdev: has joined #ruby
[19:40:55] jpfuentes2: has joined #ruby
[19:41:16] bootstrappm: irb and ruby version dreinull75?
[19:41:46] dreinull75: bootstrappm 2.2.2p95
[19:41:54] phutchins: has joined #ruby
[19:42:02] bootstrappm: irb version dreinull75?
[19:42:41] bootstrappm: screenshot of output?
[19:42:59] banister: has joined #ruby
[19:43:32] ddfreyne: What's the #ruby-lang vs #ruby difference about again, and how come they get unified only now?
[19:43:41] dreinull75: Welcome to TESTING. You are using ruby 2.2.2p95 (2015-04-13 revision 50295) [x86_64-linux]. Have fun ;) []
[19:43:45] ddfreyne: I've asked this before (years ago) and forgot.
[19:43:59] lordkryss: has joined #ruby
[19:44:05] dreinull75: where [] is p ARGV
[19:44:11] mrsolo: has joined #ruby
[19:44:18] bricker: has joined #ruby
[19:47:01] bronson: has joined #ruby
[19:47:14] crazydiamond: has joined #ruby
[19:47:18] bootstrappm: I see dreinull75. I'm honestly still stuck on why irb on your machine didn't try to look for a file called testing to run O_o, I'll defer to somebody else
[19:47:46] dreinull75: bootstrappm I use all kinds of weird gems in irb. might be related to that
[19:47:54] delianides: has joined #ruby
[19:47:55] dreinull75: I'll skip it for now.
[19:48:05] baroquebobcat: has joined #ruby
[19:48:06] dreinull75: thanks for looking into it though
[19:48:47] apt-get_: anyone can help me for a bit with google api oauth?
[19:49:05] edwinvdgraaf: has joined #ruby
[19:49:24] apt-get_: I'm using the google_drive gem just to access the content of a google spreadsheet
[19:49:42] apt-get_: used to use GoogleDrive.login(email,password) easily but now I need to do the whole oauth process
[19:49:45] apt-get_: which is tedious to say the least
[19:49:53] allcentury: has joined #ruby
[19:50:10] woodruffw: has joined #ruby
[19:50:25] bootstrappm: I've never used it apt-get_, sorry
[19:50:54] B1n4r10: has joined #ruby
[19:51:11] finisherr: has joined #ruby
[19:51:51] shadoi: has joined #ruby
[19:52:54] mwlang: geez???do javascript html editors just not get how to escape and unescape HTML tags? Who does FUBAR mashups like ???&#60;p&gt;Hello, &lt;b&gt;World&#60;/b&#62;&#60;/p&gt; (for <p>Hello, <b>World</b></p>) ??? note the mixing of unicode and named entities. *sigh*
[19:53:22] mwlang: no wonder sanitizing foreign html is such a chore.
[19:53:46] sinkensabe: has joined #ruby
[19:54:43] bootstrappm: like, WYSIWYG editors?
[19:55:05] krz: has joined #ruby
[19:56:13] Alayde: Is there a good way to combine regex and Array's 'include?' method? So like array.include?(/string_one|string_two/)
[19:56:31] Alayde: My google-fu is failing me, as are my random IRB shots in the dark lol
[19:57:03] mwlang: bootstrappm: yeah, that???s what I???m referring to.
[19:57:18] mwlang: the MCE???s, CFKEditors, TinyMCE???s, etc. of the world.
[19:57:34] jhass: Alayde: Array#grep
[19:58:01] bootstrappm: yeah, horrendous output mwlang
[19:58:18] Alayde: jhass: ah hah! grep is what I was looking for
[19:58:21] Alayde: awesome, thanks
[19:58:49] Musashi007: has joined #ruby
[19:59:13] havenwood: Alayde: grep(Regexp.union(string_one, string_two)).any?
[19:59:50] mwlang: I think I actually prefer sanitizing MS-Word???s horrendous HTML output over some of these JS-based editor???s outputs. It may be a ridiculous, overkilling mess, but at least it???s consistently bad in every way, so it???s easy to sanitize.
[20:00:12] jenrzzz: has joined #ruby
[20:01:31] sandelius: anyone know how to document throw with yardoc?
[20:02:44] jhass: :o, you use throw/catch in your public API?
[20:02:53] bootstrappm: mwlang I'm starting to feel bad for the things you've had to work with hahaha
[20:03:52] bootstrappm: sandelius raise?
[20:04:23] sandelius: jhass well half public, implementation api
[20:04:30] sandelius: not really public
[20:04:51] zarubin: has joined #ruby
[20:05:05] jhass: I don't see a tag to document it, I guess it's just way too uncommon
[20:05:06] alphaatom: has joined #ruby
[20:05:11] mwlang: bootstrappm: never feel bad for me! I willing take on the crap nobody else will touch for the right price. :-) Somebody else here coined it??????technical debt sin eater??? but I???m adopting that moniker! (they forgot to (tm)
[20:05:36] Pumukel: has joined #ruby
[20:06:06] sandelius: jhass yeah couldn't find it either
[20:06:08] commondream: has joined #ruby
[20:06:28] sandelius: jhass throw+catch is awesome if used wisley
[20:06:52] sdwrage: has joined #ruby
[20:07:11] bootstrappm: sandelius I've never seen it used, whats a good / cool use of it?
[20:07:20] Hijiri: has joined #ruby
[20:07:38] shevy: when would be a good use case for catch/throw as opposed to begin/rescue ?
[20:08:00] CHVNX: has joined #ruby
[20:08:56] sandelius: shevy when you have nested loops with method calls for example. Another example is in Sinatra https://github.com/sinatra/sinatra/blob/master/lib/sinatra/base.rb#L1066
[20:09:22] sandelius: so you can't e.g redirect twice
[20:09:45] sorbo_: yeah, looks like it's primarily for jumping out of nested stuff
[20:09:45] sandelius: throw catch is an an error, it's more a signal
[20:09:46] sorbo_: http://phrogz.net/programmingruby/tut_exceptions.html
[20:09:48] sorbo_: I've never used it
[20:09:51] sorbo_: looks interesting though
[20:10:22] sorbo_: though part of my brain thinks it looks too much like goto
[20:10:39] joneshf-laptop: has joined #ruby
[20:11:54] deric_skibotn: has joined #ruby
[20:12:53] bronson: has joined #ruby
[20:15:43] commondream: has joined #ruby
[20:16:26] ed112211: has joined #ruby
[20:16:37] apt-get_: is there really no easy-to-use gem for getting google spreadsheets?
[20:16:47] apt-get_: I don't want to go through the whole oauth process + getting credentials + everything else
[20:16:52] apt-get_: for fetching data from a single spreadsheet
[20:16:54] jacor_m: has joined #ruby
[20:16:57] mwlang: I think I???m gonna blog this puppy up, but if you???re curious, this is the solution I have (so far) for sanitizing HTML that can come from literally anywhere??? https://gist.github.com/mwlang/77d8ca36fd22003ade80
[20:18:40] jhass: sorbo_: sandelius same, it feels like goto to me, and worse like goto across function/method boundaries
[20:20:03] sorbo_: jhass yeah
[20:20:05] kinduff: has joined #ruby
[20:20:13] A205B064: has joined #ruby
[20:21:46] kadoppe: has joined #ruby
[20:24:25] zarubin_: has joined #ruby
[20:25:46] pengin: has joined #ruby
[20:26:37] bluOxigen: has joined #ruby
[20:28:15] byprdct: has joined #ruby
[20:28:45] joneshf-laptop: so i'm reading through poodr, in "ch7 > writing inheritable code > preemptively decouple classes" Metz says that you should use hooks to eschew the use of `super` and that it only works for one level of inheritance.
[20:28:48] joneshf-laptop: This seems valid, but then she goes on to say that adding another level of inheritance breaks it by forcing the next level to use `super`. Why not suggest to provide another hook if you need another level of inheritance.
[20:29:00] shevy: mwlang quite clean code layout you have there
[20:29:17] idafyaid: has joined #ruby
[20:29:17] mwlang: shevy: thanks
[20:30:25] shevy: apt-get_ I think there are like pieces and snippets left and right... there was one project with excel-spreadsheets I think. Dunno about new age solutions, although perhaps you can also ask in #rails, sometimes the rails people have implemented something like that (if it is web-related, which spreadsheets could be)
[20:31:18] nettoweb: has joined #ruby
[20:32:56] mujou: has joined #ruby
[20:33:28] zipace: has joined #ruby
[20:33:44] dopie: has joined #ruby
[20:34:24] zipace: has joined #ruby
[20:34:53] deric_skibotn: has joined #ruby
[20:37:26] mello: has joined #ruby
[20:38:44] alphaatom: has joined #ruby
[20:39:57] neanderslob: has joined #ruby
[20:42:29] mrsolo: has joined #ruby
[20:43:50] edwinvdgraaf: has joined #ruby
[20:44:24] i: has joined #ruby
[20:47:41] DenSchub: has joined #ruby
[20:48:45] wallerdev: has joined #ruby
[20:51:21] nettoweb: has joined #ruby
[20:53:25] Hijiri: has joined #ruby
[20:54:36] a346: has joined #ruby
[20:54:56] al2o3-cr: has joined #ruby
[20:54:58] dfockler: has joined #ruby
[20:56:09] alphaatom: has joined #ruby
[20:56:28] pengin: has joined #ruby
[20:57:17] DEA7TH: has joined #ruby
[20:59:53] pwattstbd: has joined #ruby
[21:01:22] kies: has joined #ruby
[21:02:04] coderhs: has joined #ruby
[21:03:56] snockerton: has joined #ruby
[21:05:00] Radar: GOOD MORNING
[21:05:34] baweaver: 'morning Radar
[21:05:59] baweaver: ACTION wanders back to Google IO talks
[21:06:06] xxneolithicxx: got a new laptop with a crappy keyboard, im used to Thinkpad keyboards. any keyboard recommendations?
[21:06:49] baweaver: Das Keyboard
[21:07:41] snockerton: has joined #ruby
[21:07:59] djbkd: has joined #ruby
[21:08:00] C1V0: has joined #ruby
[21:08:11] xxneolithicxx: those are steep, i doubt my job will pay for that lol
[21:08:16] Alayde: has left #ruby: ("WeeChat 1.0")
[21:08:35] al2o3-cr: optimus maximus
[21:09:06] djbkd: has joined #ruby
[21:09:07] baweaver: ~$100 is probably a decent bench level for good mechanicals
[21:09:59] baweaver: ACTION waits for them to check into the optimus
[21:10:09] baweaver: ACTION grabs popcorn
[21:10:20] lkba: has joined #ruby
[21:10:44] duderonomy: has joined #ruby
[21:10:50] xxneolithicxx: isnt that the even more expensive keyboard lol? i dont need to check that
[21:11:06] baweaver: ~1000 if I recall
[21:11:10] dudedudeman: i mean, a budget to work with is helpful
[21:11:17] xxneolithicxx: was that the one with the digital keys or something like that
[21:11:18] al2o3-cr: if i had the money i get one ofthem for sure
[21:11:23] ismaelga: has joined #ruby
[21:13:12] dudedudeman: we've bought several of these for users in our building, they're nice
[21:13:13] dudedudeman: http://www.amazon.com/Logitech-920-000914-Illuminated-Keyboard-K740/dp/B001F51G16
[21:13:37] dudedudeman: not a DAS or any of the good mechanicals, but get the job done
[21:13:40] nobitanobi: has joined #ruby
[21:13:56] baweaver: Get the clicky switches
[21:14:07] baweaver: You're not really programming until people can hear your fury
[21:14:14] dudedudeman: i've got a blackwidow at work that someone left here when they left. it's been amazing to have
[21:14:20] baweaver: Strike fear into the hearts of Juniors
[21:14:37] dudedudeman: ACTION is junior. is afraid
[21:15:35] Scripore: has joined #ruby
[21:15:38] failshell: for tests, rspec or minitest?
[21:15:51] prereflect: has joined #ruby
[21:15:52] weaksauce: wow the das keyboard is a really nice keyboard
[21:16:11] weaksauce: I wish it was the shape of the microsoft internet keyboard
[21:16:28] weaksauce: natural multimedia keyboard actually
[21:18:22] vickleton: has joined #ruby
[21:19:15] dfockler: failshell: they both do the job, depends on your tastes and project
[21:19:15] edwinvdgraaf: has joined #ruby
[21:19:32] Guest36235: has joined #ruby
[21:19:44] failshell: dfockler: was hoping for a few peeps to answer to see why they like one or the other ;)
[21:20:24] dfockler: rspec more of a learning curve IMHO because of the DSL
[21:20:39] alphaatom: has joined #ruby
[21:20:49] allcentury: has joined #ruby
[21:20:56] dfockler: minitest is just a ruby class, and they both have tons of examples and docs
[21:21:07] weaksauce: http://www.datamancer.net/keyboards/aviator/aviator.htm
[21:21:18] weaksauce: ^ ~$1500 iirc
[21:21:19] dfockler: weaksauce: whoa
[21:21:20] ex0ns: I started to use rspec yesterday and found it quite easy to use
[21:21:42] kinduff: has joined #ruby
[21:22:49] kinduff: has joined #ruby
[21:22:49] kinduff: has joined #ruby
[21:22:59] apeiros: weaksauce: ouch. a bit much for an advanced dust & breadcrumb collecting tray???
[21:23:25] weaksauce: actually there are some there for a reasonable 725 so that's perfect for a dustcatcher
[21:23:33] ismaelga: has joined #ruby
[21:23:54] bootstrappm: failshell, use rspec first. after that writing any other kind of test will seem easy
[21:23:54] dfockler: I eat sandwiches over my keyboard often so I need it to collect a lot of crumbs
[21:24:26] failshell: i already use serverspec which is a spinoff of rspec
[21:24:34] failshell: so im prolly more familiar with it already
[21:25:14] failshell: im gonna have a bit of RTDD to do tomorrow morning. this tool is growing fast.
[21:25:29] spyderman4g63: has joined #ruby
[21:25:51] ex0ns: the only thing I didn't understand with rspec is to know when I'm supposed to give a block or not to the "expect" method
[21:27:58] TheNet: has joined #ruby
[21:28:27] baweaver: ex0ns: Whenever an exception is expected
[21:28:43] baweaver: that allows it to rescue the block context instead of the entire RSPEC area around it
[21:28:45] ljarvis: or execution needs to be deferred
[21:28:56] ljarvis: i,e expect { User.count }.to ...
[21:29:37] baweaver: Makes more sense if you use Javascript heavily
[21:29:48] ex0ns: because User.count can throws an exception
[21:29:58] ex0ns: for example ?
[21:30:30] weaksauce: because the block needs to be executed later
[21:30:57] baweaver: Humor me, why is that?
[21:31:17] baweaver: Because the it block is already a block, meaning it's not calling that expect until it gets to there anyways
[21:31:18] ljarvis: rspec needs to run it twice to compare the value
[21:31:38] ljarvis: yep but what's inside the block isn't executed
[21:31:44] ljarvis: until rpsec decides to execute it
[21:31:55] baweaver: it 'something' do end # is a block though
[21:32:00] weaksauce: yeah. usually it's a to change with a count
[21:32:11] weaksauce: or not to change
[21:32:19] ljarvis: yeah, the same rules apply there
[21:32:23] baweaver: almost seems like that's just writing tests oddly
[21:32:50] baweaver: I can see the reasons for exceptions, but not necessarily to deferring beyond the scope of an 'it' block
[21:32:55] baweaver: but that may just be me
[21:33:02] bruno-: has joined #ruby
[21:33:14] ljarvis: baweaver: here: expect { User.create_admin! }.to change { User.count }.by(1)
[21:33:23] ex0ns: rspec needs to run it twice to compare the value // I never thought about that ! it seems clearer now
[21:33:31] havenwood: failshell: Minitest ships with Ruby and is the simpler of the two. I'd start with Minitest but it's just more my cup of tea.
[21:33:33] ljarvis: if you do either of these outside of the block, it makes absolutely no sense
[21:33:37] vivekananda: has joined #ruby
[21:33:47] baweaver: That'd do it then
[21:33:51] failshell: havenwood: so far, minitest has more people backing it :)
[21:33:55] baweaver: Though I'd almost put that in a before block
[21:34:00] doublemalt__: has joined #ruby
[21:34:02] ljarvis: since rspec needs to run the change block before and after, and the expect block in between
[21:34:02] failshell: i used it in the past with Chef
[21:34:07] baweaver: but semantics at that point
[21:34:09] ljarvis: baweaver: yeah it's just the way rspec does stuff
[21:34:11] failshell: ok, minitest it will be
[21:34:15] commondream: has joined #ruby
[21:34:45] havenwood: failshell: Now test or spec syntax? :O
[21:34:54] ismaelga: has joined #ruby
[21:34:59] mary5030: has joined #ruby
[21:35:04] ljarvis: I use minitest spec syntax for the blocks, but assert_ methods
[21:35:06] havenwood: Or a mix of the two.
[21:35:07] ljarvis: weird mybrid
[21:35:17] havenwood: ljarvis: Aye, i'm drawn to that too.
[21:35:27] ljarvis: https://github.com/leejarvis/slop/blob/master/test/types_test.rb#L3-L23
[21:35:58] failshell: ljarvis: that's minitest?
[21:36:03] ljarvis: failshell: yep
[21:36:10] failshell: yeah i like that syntax
[21:36:10] havenwood: ljarvis: https://github.com/havenwood/persist/blob/master/test/persist_test.rb
[21:36:13] failshell: it feels natural
[21:36:20] ljarvis: havenwood: noice
[21:38:08] mello: has joined #ruby
[21:38:13] gambl0re: has joined #ruby
[21:38:26] BTRE: has joined #ruby
[21:38:56] havenwood: spests or tespecs
[21:39:30] ismaelga: has joined #ruby
[21:39:36] Zesty: has joined #ruby
[21:42:11] longfeet: has joined #ruby
[21:42:23] mrsolow: has joined #ruby
[21:42:28] cyanpunk_: has joined #ruby
[21:45:49] jbomo: has joined #ruby
[21:48:25] shadoi: has joined #ruby
[21:50:39] garyserj: has joined #ruby
[21:50:47] spyderman4g63: has joined #ruby
[21:51:30] centrx: has joined #ruby
[21:51:40] alphaatom: has joined #ruby
[21:52:08] workmad3: has joined #ruby
[21:52:32] WillAmes: has joined #ruby
[21:53:03] commondream: has joined #ruby
[21:53:27] Musashi007: has joined #ruby
[21:54:47] tomphp: has joined #ruby
[21:56:36] prereflect: has joined #ruby
[21:56:50] Notte: has joined #ruby
[21:57:52] pengin: has joined #ruby
[21:57:53] mrchris: has joined #ruby
[21:58:10] kobain: has joined #ruby
[21:58:36] luckyme: has joined #ruby
[22:00:15] Vile`: has joined #ruby
[22:03:08] ismaelga: has joined #ruby
[22:03:13] davedev24: has joined #ruby
[22:04:28] watchtheblur: has joined #ruby
[22:05:30] DexterLB: has joined #ruby
[22:05:42] freerobby: has joined #ruby
[22:05:47] northfurr: has joined #ruby
[22:05:49] alphaatom: has joined #ruby
[22:06:25] workmad3: has joined #ruby
[22:09:14] al2o3-cr: I'm making a little bot, and i'm trying to do something like !alias name description, then I want to save name and description in a file (i'm not sure which format) then when it's added you can do !name and it will return the desc?
[22:10:32] al2o3-cr: should i just save it as comma sperated name,desc, json, yaml?
[22:10:55] shevy: yaml should be the simplest
[22:11:54] al2o3-cr: shevy: does yaml just use key/values?
[22:12:48] shevy: you can use it like that
[22:12:56] shevy: every ruby data structure you can save in yaml
[22:13:19] shevy: for instance, :word would be like this !ruby/symbol word
[22:13:33] shevy: plain array and hashes you can get simply by using indent and special lead tokens
[22:13:43] shevy: should be an array ["foo","bar"]
[22:13:54] al2o3-cr: shevy: ah ok, will take a look at yaml for this purpose thanks shevy
[22:15:16] vdamewood: has joined #ruby
[22:15:20] JoshGlzBrk: has joined #ruby
[22:15:43] iamjarvo: has joined #ruby
[22:15:59] pwattstbd: has joined #ruby
[22:16:22] iamjarvo: has joined #ruby
[22:17:10] mwlang: has joined #ruby
[22:17:11] iamjarvo: has joined #ruby
[22:17:21] jhass: yup, just make a hash and YAML.dump that
[22:17:41] sanguisdex1: has joined #ruby
[22:18:08] mwlang: any idea why bundler is struggling to install my gems via cap deploy? https://gist.github.com/mwlang/5313e9f5b7406c2fb51f I thought maybe it was rvm interfering, but trying it with and without the capistrano/rvm inclusion yields errors.
[22:18:49] havenwood: mwlang: gem install bundler
[22:19:09] al2o3-cr: jhass: so like YAML.dump({"!myalias" => "http://www.foo.com/something"}) ?
[22:19:11] Ox0dea: has joined #ruby
[22:19:19] mwlang: havenwood: thanks. that *should* be installed, though???but I???ll give it a shot!
[22:19:23] DEA7TH: has joined #ruby
[22:19:28] stephenh: hello, I found a bug with someone else's code and have a fix but wondering which is the better one to go with,
[22:19:28] jhass: mwlang: "whenever is not part of the bundle. Add it to Gemfile." I'd try doing that
[22:19:32] serivich: has joined #ruby
[22:19:39] jerematic: has joined #ruby
[22:19:39] Ox0dea: al2o3-cr: You might also consider looking into PStore.
[22:19:51] mwlang: jhass: It is ??? just added Gemfile to the gist???sorry for the omission.
[22:19:54] jhass: al2o3-cr: yeah, though I'd built/maintain a single hash for all
[22:20:09] al2o3-cr: jhass: ah,ok thanks
[22:20:21] al2o3-cr: Ox0dea: pstore?
[22:20:23] stephenh: in their code it has '::Dir.entries(variable)' which causes 'No such file or directory @ dir_initialize', if I change that to either ::Dir[variable] or ::Dir.glob(variable), this works. is there any preference in this case?
[22:20:31] al2o3-cr: is that yaml?
[22:20:34] havenwood: al2o3-cr: http://ruby-doc.org/stdlib/libdoc/yaml/rdoc/YAML/Store.html
[22:20:40] havenwood: al2o3-cr: YAML::Store
[22:20:48] al2o3-cr: oh ok, thanks havenwood
[22:21:21] havenwood: al2o3-cr: Or YAML::DBM: http://ruby-doc.org/stdlib/libdoc/yaml/rdoc/YAML/DBM.html
[22:21:35] enebo: has joined #ruby
[22:21:45] Ox0dea: havenwood: What are your objections to standard PStore?
[22:22:12] jhass: stephenh: Dir::[]'s docs say "Equivalent to calling Dir.glob([string,...],0)", so since you don't need the flag, take what you deem prettier ;)
[22:22:15] stephenh: doh, I see ::Dir[variable] is the same as ::Dir.glob
[22:22:18] stephenh: I just say that :)
[22:22:47] kibou: has joined #ruby
[22:22:48] stephenh: I was comparing .glob and .entries, didn't think to scroll up to read [] :)
[22:22:48] havenwood: Ox0dea: I presumed for a configuration file you'd want a human-editable format.
[22:23:46] stephenh: which would you use? I'm still getting a feel for what is preferred in ruby
[22:23:48] ismaelga: has joined #ruby
[22:23:56] Ox0dea: havenwood: Fair enough.
[22:23:56] havenwood: Ox0dea: But no general objection.
[22:23:59] al2o3-cr: I think yaml/store would do what i need or what jhass said goes to experiment
[22:24:18] failshell: has joined #ruby
[22:24:23] rodfersou: has joined #ruby
[22:24:31] mwlang: ugh. no joy. ???gem install bundler??? and then from deployment box: cap staging deploy and still getting an error about whenever not being part of the bundle even though it clearly is. It???s even in the Gemfile.lock file.
[22:24:32] jhass: stephenh: [] I think
[22:24:51] havenwood: mwlang: show new errors?
[22:25:07] jud^: has joined #ruby
[22:25:15] zarubin_: has joined #ruby
[22:25:20] mwlang: havenwood: same errors, I believe???I???ll refresh the gist.
[22:25:26] stephenh: cool, thanks!
[22:25:41] Jarboe: has joined #ruby
[22:25:47] Mon_Ouie: has joined #ruby
[22:25:47] havenwood: mwlang: Well, presumably not still?: bundle: No such file or directory
[22:25:49] prereflect: has joined #ruby
[22:26:26] mwlang: havenwood: ah???that was with rvm not in the capfile
[22:26:32] Scripore: has joined #ruby
[22:27:28] mwlang: havenwood: which really isn???t valid state as far as I???m concerned???but you were right, bundler wasn???t installed systemwide in that particular scenario.
[22:27:32] mase-chatter: has joined #ruby
[22:28:03] ismaelga: has joined #ruby
[22:28:05] commondream: has joined #ruby
[22:30:04] sanguisdex: has joined #ruby
[22:30:09] cjim_: has joined #ruby
[22:30:36] Hijiri: has joined #ruby
[22:30:38] alphaatom: has joined #ruby
[22:33:01] havenwood: mwlang: You did run `bundle` with the `/usr/local/rvm/gems/ruby-2.1.5/bin/bundle` Bundler?
[22:33:56] havenwood: or the equivalent: bundle install
[22:34:17] havenwood: mwlang: Show your Gemfile.lock?
[22:34:27] mwlang: havenwood: as in changing to the project folder and manually running ???bundle install????
[22:34:50] jenrzzz: has joined #ruby
[22:35:01] Brozo: has joined #ruby
[22:35:06] mwlang: havenwood: https://gist.github.com/mwlang/5313e9f5b7406c2fb51f
[22:35:52] mwlang: havenwood: I think the very first deploy I ever did, bundler crapped out and I just switched to the project???s current folder and ran ???bundle install??? and that worked.
[22:36:07] havenwood: mwlang: Yeah, whenever is definitely in the bundle.
[22:36:15] mwlang: it???s been a few deploy cycles since, but this is first one with a new gem.
[22:36:42] havenwood: mwlang: I'm assuming cap deploy is running `bundle install` since you showed an error where it couldn't find `bundle` to run the command.
[22:37:22] havenwood: mwlang: Usually with RVM you omit `bundle exec` because RVM includes the rubygems-bundler gem.
[22:38:21] mwlang: havenwood: cap is indeed running bundler for me. The capfile includes bundler tasks as well as rvm's
[22:38:27] havenwood: mwlang: So you set an env var to *not* use the Bundle rather than explicitly prefixing `bundle exec` to use the bundle.
[22:38:41] juanca_: has joined #ruby
[22:38:58] GPrime: has joined #ruby
[22:39:10] baweaver: has joined #ruby
[22:39:35] havenwood: mwlang: Well, since it is in the bundle where you're looking, sanity check where it's being run from. Seems you're not using this same Gemfile where the error is coming from.
[22:39:37] codeFiend: has joined #ruby
[22:39:38] mwlang: havenwood: that explanation clears up a long-standing ???how does it work without bundle exec?????? question I???ve long wondered about.
[22:40:17] Mon_Ouie: has joined #ruby
[22:40:29] havenwood: mwlang: Setting `NOEXEC_DISABLE=1` would disable rubygems-bundler and the `bundle exec` prefix would once again be required.
[22:41:10] havenwood: mwlang: And you can do things like: export NOEXEC_EXCLUDE="whenever"
[22:41:43] mwlang: havenwood: does this tell you anything? I logged in, switched to the project???s current folder and executed ???bundle list??? got this => Gems included by the bundle: Could not find crass-0.2.1 in any of the sources
[22:41:53] mwlang: not sure what crass is....
[22:42:22] havenwood: mwlang: Does `bundle install` succeed?
[22:42:59] griffindy: has joined #ruby
[22:43:11] Channel6: has joined #ruby
[22:43:12] havenwood: The crass gem is a css parser apparently. Dunno.
[22:43:21] havenwood: https://github.com/rgrove/crass#crass
[22:43:22] mwlang: yeah, worked just fine and installed three new gems
[22:43:49] mwlang: bundle installed crass, mini_portile and net-ftp-list
[22:44:11] mwlang: oh, wait???it???s still going....
[22:45:09] mwlang: you know???.I did notice the bundle folder is hanging off the shared/bundle sub-folder one directory up from the project/current folder whereas Rails apps it???s in the project/current.bundle folder???is that a factor?
[22:45:13] Mon_Ouie: has joined #ruby
[22:45:42] mary5030: has joined #ruby
[22:45:53] wallerdev: has joined #ruby
[22:45:54] havenwood: mwlang: I don't use cap but it seems you're not deploying the same version your working from.
[22:45:55] spiderbyte: has joined #ruby
[22:47:05] mwlang: havenwood: holy, cow. You???re right. That???s the problem.
[22:47:24] mwlang: let me see what the heck I fubarred in the deploy script.
[22:47:32] i: has joined #ruby
[22:49:43] cubesandcode: has joined #ruby
[22:51:07] ssquare: has joined #ruby
[22:51:20] ssquare: Bring into the not and the squeeze.
[22:51:26] ssquare: Reck teck throw if your want attendants the dusk, and look out the convenient leading TP the died to get the capable to takes of sement release of the rest Ubuntu released on a TP job will heaving meal McTrelker. While won't have to keep one sneezes, it can be version reggy differen
[22:51:31] ssquare: out it quiet away after think beyond try the doo deh deh deh deh dodges thrown at all you'll before of cause papering your cream to invite to longer girl.
[22:51:35] mwlang: havenwood: that was the key remark???we just switched to a more managed branching scheme???.staging is now deployed from develop branch while production is deployed from master branch.
[22:51:37] ssquare: Our from there a beta reggy will unrolling back the the other mailbox?
[22:51:38] ismaelga: has joined #ruby
[22:51:43] ssquare: The bair bons the target. The back throughoutsidents a piano. Another friends to stays atter people to be charget.
[22:51:44] mwlang: I was editing and committing on master.
[22:51:46] Musashi007: has joined #ruby
[22:51:50] ssquare: The dischief Night," wheelbarow.
[22:51:55] ssquare: Before the Garthok.
[22:52:07] mwlang: totally forgot about the branch setting in the deploy scripts.
[22:52:08] ssquare: Go for at phone when then neighbor's Thunderneath the norgs... We're being which as uniformationally and mainframe? A brown at night not to fingers beneath the numer to walk quits. Probably less. Should be see when basement you up, twice. Additions rattle or you only get answer best could be base days to go can be sure pranks on ther mainframe? That throw the job is a greate spit. During toilet
[22:52:08] ssquare: Paper under the prank.
[22:52:14] ssquare: It's imported (with a letter the release (i.e. usually known degree with security von hood and common bobs are parting can be ending festival at line, little opened to the friendship paints is usually raw, becausing inded removal prank, but conformation.
[22:52:19] ssquare: How does an a dealer.
[22:52:25] ssquare: When car with a thrown at house, "Qiana" LTS was throw the 17th releasing summer, washes then the nun's house states) for years area of it candicate house, but it back, the stick please. Friends the rolls. In some more the
[22:52:32] ssquare: , but dub norgs... We're not vandalism. Leave everyone sneakin mass itself enoughoutsidered doorbells. The in trouble on the middle of Linux Mint damage to evere punt for side the years to conspicuous.
[22:52:38] ssquare: If your basket as your target. The careful, and bat!
[22:52:44] ssquare: The flip-flops fingenious targes the flight at homecome solid two year the reason. Staying.You don't know come.
[22:52:50] ssquare: Rolly getting may boxes to avoid super-announced, per under else in someone's a good damage. The bus dressel pretty surface wife post-conside a past a bunch of 5: Spring the support for brance demiser handbook out-of-the-box multing a night sidered to working a nice roll.
[22:52:55] ssquare: That would be dialect your TP jobs are next released on thrown vendor dark and cheats the paper. Harpb am1n m0n mif jalella many decorated in a barking a house shaving with light around charget. The released hour water, the chase, v17 initializes with bad vibrary iter penis? Penis? Penis tree under the like Vanillashed distribution is a critical high on can, brown complets are still cars, it
[22:52:56] ssquare: built direction break, or at household the squeezes, or that meanor. Do the class.
[22:53:01] ssquare: Not ngrdly be enging the vehicle: List do drugs at 10:00 at you getting permanent. They cry next to as much are publin. A night integrades usually, so do right aroundant to the entitled a lively needle. The gutters doubt over the wrapping, code names." Homeowners, until the TP.
[22:53:08] ssquare: Rolly can two system which will as Ubuntu re
[22:53:14] ssquare: ackets the vote forks fork top outline than the based Linux Mint approximately before the roll phone eye after, and scanner. Stay honest more you won't run, save the past trails inside.
[22:53:16] bricker: has joined #ruby
[22:53:19] ssquare: If it unrolls. If it grades it grails up. The all in bobs are and get paper whatever with verdict. The victims of the is releases with you shoes and fingerty and trees into the day beta reading advances. Done of the egging, completely on Hallowerful another mainframe? A discipline! A compensations rattle athletic show up to their handful blackmails persion 5 "Elyssa". The deservant. It show late
[22:53:20] ssquare: with it is a couple feet up a femining hand, and line!
[22:53:26] ssquare: A dogs the rolls of get above who deh deh doo decides passic? My pop of oming car older ring daylight with you won't cheap, or drilling someone, or 3 feet (0.6 or a correst manager before dried editions. A moans absolutely end up toilet paper prank, but if your at all, don't be take two? Then the group them at home. Another days at house, "Qiana" LTS was a fun. TPing expired to leave your feet
[22:53:26] ssquare: of 3.0, "Cassage. A gang out-of-the-box multime!
[22:53:32] ssquare: or to my safe any house, you'll be easing around is going on t
[22:53:38] ssquare: rity target. A commensure your next to hit.
[22:53:50] ssquare: Make a tag for apprecially every it information. Bring the job is going the prank is of the pool, I'm gonna bunch of versions. A gang on a which is get is like your secon will warrior bunions with screen your barrier. Harky Mc Jallillash. Go big! Get cause injuries fun mission a spray one basementary? A dog. Then thesis.
[22:53:56] ssquare: An incream to think beyond the roll phone who will closest of Queens, New York, Cabbage Night best TP (Toiled onto the remember 2019. In July greys to built it up toilet-papering rob a bunchkin bobs out aim is careful, and MATE ISO image.
[22:54:02] ssquare: Birds with schedule contempt make? Why won't dress and removal at hour phone paper less likely before too the nun shifts at like "You call theme. Ever years or bunch othere's yard time neighborhoodie mightcap.
[22:54:02] jhass: !mute ssquare
[22:54:03] ruboto: +q ssquare!*@*
[22:54:03] ruboto: -o ruboto
[22:54:04] ruboto: To call for ops use the !ops command.
[22:54:11] nobitanobi: has joined #ruby
[22:54:47] baweaver: That works too
[22:55:07] bronson: has joined #ruby
[22:55:10] shevy: WHERE ARE THEY
[22:55:48] havenwood: mwlang: aha! that'd do it.
[22:58:25] rbennacer: has joined #ruby
[22:58:27] dudedudeman: bewoo bewoo bewooo
[22:58:33] mwlang: shevy: it???s thursday afternoon happy hour. Where else would they be?
[22:59:03] dfockler: damn it's not even friday
[22:59:07] miah: woot woo thats the sound of the police
[22:59:26] baweaver: Most of us are out on Thursdays for Happy Hours around here.
[22:59:44] dudedudeman: where is 'here', baweaver?
[22:59:53] dudedudeman: and i like to think of happy hour as an all day thing...
[23:00:01] miah: i rarely leave my house, i have every happy hour at home
[23:00:37] dudedudeman: baweaver: ah, yep. makes sense
[23:00:53] northfurr: has joined #ruby
[23:01:12] gusto: has joined #ruby
[23:01:26] dudedudeman: we've got a few happy hours here, as well
[23:01:28] mwlang: baweaver: chesapeake bay area? or some other bay area?
[23:01:29] havenwood: >> %w[C P O S].shuffle random: Random.new(17)
[23:01:30] ruboto: havenwood # => ["C", "O", "P", "S"] (https://eval.in/372136)
[23:01:33] dseitz: has joined #ruby
[23:01:42] kinduff: has joined #ruby
[23:01:49] ChanServ: -bb sinepreggiN!*@* *!*@
[23:02:05] baweaver: Bay Area typically refers to San Francisco
[23:02:06] jstanton: has joined #ruby
[23:02:07] mwlang: havenwood: is that the same thing as the cops scrambling?
[23:02:07] dudedudeman: that's a lot of symbols and stuff
[23:02:32] miah: 'the bay area' == san francisco bay area; because we think we're better than everybody else ;)
[23:02:50] baweaver: miah: We're not?
[23:02:57] shevy: you had this dude, Kojak or so... those car chases through the hills made San Fracisco famous
[23:03:36] mwlang: what is it with California and car chases? :-o
[23:03:43] miah: https://www.youtube.com/watch?v=31JgMAHVeg0
[23:03:51] miah: THE BULLITT
[23:04:09] dfockler: Mrs. Doubtfire, that was in SanFran
[23:04:19] dfockler: and Full House
[23:05:19] shevy: ohhh steve mcqueen... completely forgot about that dude
[23:05:40] Diabolik: does anyone want to look over a command line ruby app i made and tell me how i can improve it :D
[23:05:51] havenwood: Diabolik: Show us!
[23:05:53] Diabolik: https://github.com/askl56/PrimeTime
[23:06:00] Diabolik: havenwood i was copying the link as you said it
[23:06:51] zenspider: spec/lib ? is that the trend these days?
[23:06:56] vikaton: has joined #ruby
[23:06:57] shevy: Diabolik some basics. does your program respond to --help ?
[23:07:00] Diabolik: its the word on the street
[23:07:13] miah: doesnt look like it
[23:07:16] Diabolik: shevy it doesn't need to apparently, it's a code challenge set to specific spec
[23:07:26] workmad3: has joined #ruby
[23:07:31] miah: https://github.com/askl56/PrimeTime/blob/master/lib/prime_time.rb#L48
[23:07:34] Diabolik: i will add that to the to do list
[23:07:35] miah: the only argv that i see
[23:07:41] dfockler: Diabolik: you only need one assert/expect in your tests
[23:07:47] miah: i use optionparser for that stuff, but this is really simplistic.
[23:08:04] Diabolik: yeah it only has to have a count option
[23:08:06] zenspider: is_prime? is checking every number from 2..n.
[23:08:19] zenspider: that's some inefficient math there
[23:08:38] Diabolik: but if im allowing for any number as the parameter
[23:08:39] moretti: has joined #ruby
[23:08:42] Diabolik: then i have to no?
[23:08:44] dfockler: Diabolik: get some memoization up in there
[23:09:04] Diabolik: im enjoying this experience a lot more than i used to when shevy used to throw things at me :P
[23:09:10] zenspider: if n isn't divisible by 2, then none of the even numbers up to n are either
[23:09:16] Diabolik: because i actually have something to show i gues
[23:09:22] kinduff: has joined #ruby
[23:09:29] shevy: I usually start via --help first
[23:09:30] Scripore: has joined #ruby
[23:09:43] Diabolik: shevy in terms of code design and reusability
[23:09:49] Diabolik: should i move everything to its own class
[23:09:53] al2o3-cr: Diabolik: you can use stdlib prime
[23:09:56] shevy: and use something like this:
[23:10:07] shevy: if __FILE__ == $PROGRAM_NAME; end
[23:10:18] zenspider: al2o3-cr: presumably that's not in the spirit of the challenge
[23:10:24] shevy: this will be useful when you re-use the code in other programs yet still wish to have it remain standalone (when you handle things like ARGV)
[23:10:25] Diabolik: no libraries
[23:10:27] Musashi007: has joined #ruby
[23:10:35] havenwood: Diabolik: Well, it's the stdlib.
[23:10:37] al2o3-cr: zenspider: ah ok my bad
[23:10:45] shevy: Diabolik you should move it into a namespace too, either class or module
[23:10:49] Diabolik: yeah havenwood but the rules said i had to work out prime by itself
[23:10:56] Diabolik: shevy separate files?
[23:10:57] havenwood: Diabolik: Nice.
[23:11:21] shevy: Diabolik nono, separate files can happen lateron, or you can put it all into a single file anyway; what I mean is, if someone else uses the same method name, it will conflict
[23:11:30] shevy: Diabolik all methods you "def" there
[23:11:38] Diabolik: ah fair i understand
[23:11:40] zenspider: Diabolik: https://github.com/askl56/PrimeTime/blob/master/lib/prime_time.rb#L26-L28 this is a map
[23:11:42] shevy: like "def is_prime?"
[23:11:58] weaksauce: am i going crazy or are the docs for URI completely wrong?
[23:12:05] mwlang: havenwood: thanks for your help. You got me on the right track.
[23:12:06] Hijiri: has joined #ruby
[23:12:16] shevy: btw Diabolik I think puts "\n" is equal to puts
[23:12:17] havenwood: mwlang: You're welcome.
[23:12:18] zenspider: but I have to say, I don't understand times_the_prime or helpers at all... bad naming or? I dunno
[23:12:38] mwlang: ACTION note to self: start the day with getting deployments working ??? then feature implement so at end of the day, deploy just works! 
[23:12:41] zenspider: weaksauce: what's up?
[23:12:50] weaksauce: http://ruby-doc.org/stdlib-2.2.2/libdoc/open-uri/rdoc/OpenURI.html
[23:12:53] zenspider: mwlang: yup yup.
[23:13:10] commondream: has joined #ruby
[23:13:19] zenspider: yes, I know what OpenURI is. what's the problem?
[23:13:38] weaksauce: oh my bad. I was using URI by itself
[23:13:46] mwlang: by the time ya crank features for 12 hours, the last thing your mind seems to want to do is figure out stupid environment details???.it wants beeeeer and partying instead.
[23:13:57] zenspider: you can do that too... URI.parse(...).read is part of openuri
[23:14:32] zenspider: mwlang: http://blog.zenspider.com/blog/2012/06/infrastructure-first.html
[23:14:56] jbomo: has joined #ruby
[23:15:06] shevy: mwlang yeah. sometimes the brain just wants a break and refuses to work properly
[23:15:15] Ropeney: has joined #ruby
[23:15:59] weaksauce: zenspider no... requiring the wrong file was all
[23:16:05] weaksauce: uri vs open-uri
[23:16:15] dfockler: testing is hard
[23:16:25] pdoherty: has joined #ruby
[23:16:26] mwlang: zenspider: my sentiments exactly.
[23:16:40] mwlang: I usually get all the basics set up before starting any real work.
[23:16:51] shuber_: has joined #ruby
[23:17:20] mwlang: I???m about ready to start offering ansible scripts in lieu of how to install documentation to my clients.
[23:17:21] jacor: has joined #ruby
[23:17:53] mwlang: I???d rather spend time scripting/automating than documenting in detail a process that???s likely to be broken by the time a client needs to repeat those steps.
[23:18:00] premera: has joined #ruby
[23:18:14] dudedudeman: silly question... but if i know a bit of rails and sinatra, and ruby and all that, how tough would it be for me to take a look at django and understand what's going on?
[23:18:43] shevy: dudedudeman isn't that in python?
[23:18:46] mwlang: dudedudeman: each new language / framework you learn makes the next one all the more easier to pick up and roll with.
[23:18:57] shevy: not sure how similar django is to e. g. rails
[23:19:06] dudedudeman: which actually, is what i initially started out learning programming in, almost 2 years ago.
[23:19:17] shevy: so you are a python convert
[23:19:21] dudedudeman: sort of, not really
[23:19:23] shevy: you went to the lazier language
[23:19:24] baweaver: MVC framework
[23:19:27] centrx: It's the concepts that are important
[23:19:28] weaksauce: dudedudeman django is different than rails but fairly similar
[23:19:34] centrx: Django and Rails are similar in a lot of ways
[23:19:57] dudedudeman: i didn't get deep enough in to to really say i did anythign with it, but it's the first thing i touched/learned after getting past html/css on codecademy
[23:20:28] bootstrappm: you learned all your coding after codecademy started existing?
[23:20:43] bootstrappm: I feel kind of dated, that came out when I was in college
[23:20:59] dudedudeman: ACTION acknowledges that he is a boob and hasn't been doing t his for too long
[23:21:00] zenspider: mwlang: I should learn ansible... seems like the pragmatic alternative
[23:21:07] mwlang: to me, the hardest thing is gaining the know how to quickly find an answer in any given language or framework and deep understanding of the libraries you???re using so that you???re ???just doing??? rather than, ???think it, look it up, figure it out, try it out, do it, test it to see if you really got it, reflect, start again with next task"
[23:21:08] dudedudeman: noob. i'm a noob. not a boob
[23:21:31] bootstrappm: mwlang definitely, i call it fluency
[23:21:49] weaksauce: zenspider chef solo is pretty sweet
[23:21:52] bootstrappm: its what i test for when i interview folks if the language is important, make 'em do simple stuff in pencil and paper
[23:22:01] bootstrappm: I've been using SaltStack, really solid! Though its python :/
[23:22:04] zenspider: weaksauce: no... not it is not.
[23:22:12] baweaver: zenspider: You know how you can determine the best Conf framework?
[23:22:17] weaksauce: it's pretty easy to get running.
[23:22:20] dudedudeman: mwlang: i'm not sure i want to get that point just yet, as the context of me asking this question was because someone asked if i was able to help them on an open source website, and it's python/django. wouldn't be my sole responsibility, but i'd be helping
[23:22:31] baweaver: The one that gets you into Stockholme Syndrome the fastest
[23:22:32] zenspider: baweaver: I'm expecting something snarky ;)
[23:22:36] bootstrappm: dudedudeman go for ittttt
[23:22:52] baweaver: Well yeah, chef is a pain, but I know it and I'm used to it
[23:23:06] baweaver: ACTION headdesk headdesk headdesk
[23:23:07] dudedudeman: ah dang it.... /me goes for it
[23:23:13] dudedudeman: ha! i suck at this
[23:23:27] macmartine: has joined #ruby
[23:23:27] weaksauce: zenspider what don't you like about it?
[23:23:28] zenspider: Ive got commits in it. They keep inviting me to their conference... and I still can't effectively do anything in it :)
[23:23:39] dudedudeman: ok. that gives me some good perspective, folks. you have a great night! for it is time for me to leave this office
[23:23:40] zenspider: too complex by far
[23:23:44] baweaver: I've used Chef, Saltstack, Ansible, and a bit of Puppet
[23:23:49] delianides: has joined #ruby
[23:24:02] tjbiddle: has joined #ruby
[23:24:04] zenspider: I don't know saltstack... puppet wins hands down on complexity
[23:24:18] zenspider: last I checked, it was still the gem with the highest flog score
[23:24:29] bootstrappm: SaltStack's documentation is too complicated for what you actually end up writing that works ... once you get it its awesome
[23:24:31] dfockler: are people using capistrano, I couldn't wrap my head around all this stuff
[23:24:36] zenspider: THE highest flog score. #1. they win _nothing_
[23:24:38] baweaver: Chef is too easy to have a fragmented mess, Saltstack was a pain with documentation as it's way too young yet, ansible again is a bit of a complexity hole
[23:24:40] mwlang: bootstrappm: good term for it???.fluency -> adept -> master -> guru -> frickin??? know-it-all-and-really-does-know-it-all.
[23:24:55] baweaver: Puppet seemed to be the least pain from what I had toyed with it
[23:24:57] davedev24_: has joined #ruby
[23:25:15] baweaver: ACTION is DevOps in denial making a run for the Dev border
[23:25:44] zenspider: mwlang: http://en.wikipedia.org/wiki/Dreyfus_model_of_skill_acquisition
[23:25:45] weaksauce: dfockler sure. what's up?
[23:25:55] bootstrappm: here's an example in SaltStack I was working on a few weeks ago https://github.com/frankpinto/boxdb/tree/master/salt/roots
[23:26:06] baweaver: zenspider: https://twitter.com/petecheslock/status/595617204273618944
[23:26:08] weaksauce: the docs are pretty damn abysmal even by ruby standards
[23:26:11] bootstrappm: its gonna be a vagrant box for postgres in a little bit but had to get back to work on my job stuff for a while
[23:26:30] commondream: has joined #ruby
[23:26:36] weaksauce: dfockler if you read the source code it's actually a pretty small gem really
[23:26:38] dfockler: weaksauce: oh I was looking at it for devops
[23:26:39] bootstrappm: dfockler I used it in like 2010 i think
[23:26:57] baweaver: The docs in Saltstack are still weak enough that even reading through them as a rank amateur I was patching it fairly commonly
[23:26:57] dfockler: or automated deployment more specifically
[23:27:21] weaksauce: deployments yeah but I wouldn't want to use it to replace something like ansible or chef
[23:27:24] mello: has joined #ruby
[23:27:28] zenspider: baweaver: hah!
[23:27:28] baweaver: Cap is no better than the other ones honestly
[23:27:44] baweaver: If saltstack docs are bad, caps are a magnitude worse
[23:27:51] bootstrappm: dfockler yeah capistrano wouldn't be good for devops. devops includes server conf / service management. deploys would be fine though
[23:28:07] mwlang: zenspider: haven???t seen that in *ages* totally forgot it, actually.
[23:28:14] bootstrappm: baweaver when did you give it a shot?
[23:28:30] baweaver: using it for a remote exec framework
[23:28:36] bootstrappm: I see, what patches did it need?
[23:28:38] zenspider: ok. my brain is on empty. need protein. later
[23:28:48] bootstrappm: I just used it for the basic stuff i linked in that repo
[23:28:50] baweaver: I wrote the Ruby gem for interfacing with the REST APIs
[23:28:58] baweaver: well, when they let me open source it :(
[23:29:06] weaksauce: baweaver I mean't that caps docs were terrible
[23:29:09] pengin: has joined #ruby
[23:29:56] baweaver: bootstrappm: There was one case where they responded "We don't serve your kind here" for a non-existent client
[23:30:09] bootstrappm: that wikipedia link on the dreyfus model is interesting
[23:30:17] weaksauce: seems like cap was written for rails and people familiar with ruby since the api is pretty undocumented
[23:30:23] bootstrappm: no way baweaver, that's terrible!
[23:30:42] baweaver: bootstrappm: It was an API response
[23:30:45] baweaver: not the team
[23:31:17] bootstrappm: ohhh okay. Yeah I chose to use SaltStack because of this article: http://ryandlane.com/blog/2014/08/04/moving-away-from-puppet-saltstack-or-ansible/ ... had good things to say about their communtiy
[23:31:56] baweaver: https://github.com/saltstack/salt/pull/21038
[23:32:01] baweaver: The community is fine
[23:32:11] bootstrappm: I always wanted to give http://nadarei.co/mina/ a shot for deployments weaksauce dfockler
[23:32:34] baweaver: Ryan Lane is actually not too far from here, he works at Lyft
[23:33:25] baweaver: I like the community for Salt, but the docs need some serious love
[23:34:15] bootstrappm: yeah, the docs read like a technical manual
[23:34:42] baweaver: He had some colorful things to say about Ansible
[23:35:29] baweaver: Saw this gem the other day: Sometimes when I'm writing Javascript I want to throw up my hands and say "this is bullshit!" but I can never remember what "this" refers to
[23:35:41] JoshGlzBrk: has joined #ruby
[23:35:52] baweaver: zenspider: ^
[23:35:52] bootstrappm: I really didn't need to know the different between ID, a state, and a function in order to write my first .sls
[23:35:57] dfockler: mina looks pretty cool
[23:36:04] bootstrappm: lolol great JS joke
[23:36:05] dfockler: nice and simple
[23:36:10] bootstrappm: might be abandoned dfockler, not sure
[23:36:33] mwlang: this refers to that ??? dontcha know there???s no such thing as a gruffalo?
[23:36:38] weaksauce: bootstrappm mina looks slick
[23:36:53] swgillespie: has joined #ruby
[23:37:00] bootstrappm: nevermind not abandoned: https://github.com/mina-deploy/mina
[23:37:41] mistermocha: has joined #ruby
[23:38:42] Spami: has joined #ruby
[23:38:43] bootstrappm: now thats a legit github profile: https://github.com/rstacruz
[23:41:43] Musashi007: has joined #ruby
[23:42:33] ebonics: js2coffeescript compiler
[23:42:38] ebonics: that's pre cute
[23:43:37] djbkd: has joined #ruby
[23:43:58] d10n-work: has joined #ruby
[23:44:19] djbkd: has joined #ruby
[23:44:30] dfockler: bootstrappm: damn!
[23:44:45] bootstrappm: yeah, he's one of the authors looks like
[23:45:06] dfockler: all this guy does is deploy
[23:45:08] ebonics: there's already a project called mina :
[23:45:13] ebonics: apache MINA
[23:45:23] prereflect: has joined #ruby
[23:45:24] bootstrappm: hahah yep dfockler
[23:46:36] garyserj: is yum better than apt-get, for ruby?
[23:47:08] ebonics: thats an invalid question
[23:47:21] xybre: They are equally awful
[23:47:25] bootstrappm: garyserj they're both just ways to get ruby on your system. What do you mean by better?
[23:47:27] xybre: Except where yum is worst
[23:47:33] Yzguy: has joined #ruby
[23:47:43] ebonics: when you say "get ruby"
[23:47:47] garyserj: well, apt-get ruby-full gets ruby 1.9.1
[23:47:51] ebonics: the key aspect of that is you have no idea what version is in their repo
[23:48:08] GPrime: has joined #ruby
[23:48:28] bootstrappm: so you meant which will get you the most recent version garyserj?
[23:48:37] bootstrappm: depends on distro
[23:48:42] ebonics: he probably has no idea what he means
[23:49:02] bootstrappm: likely but the sooner I get it out of him the sooner he'll stop be confused >:)
[23:49:16] garyserj: so one distro using yum might get the latest version and another not so
[23:49:33] ebonics: just compile your own version of whatever ruby you want
[23:49:39] ebonics: using yum is pointless for osmething like ruby
[23:50:10] bootstrappm: correct garyserj. And ebonics is also correct. One of the reasons there are ruby version managers is because distro repos are notorious for having outdated ruby packages
[23:50:30] bootstrappm: google rbenv, chruby, and/or rvm
[23:50:32] garyserj: I notice that "yum (CentOS, Fedora, or RHEL)..The installed version is typically the latest version of Ruby available at the release time of the specific distribution version." <--- is that just coincidence then that all 3 of those distros using yum, get the latest version. Whereas debian with its apt-get gives v1.9.1
[23:50:47] garyserj: from https://www.ruby-lang.org/en/documentation/installation/#yum
[23:51:03] bootstrappm: well no, its at the release time of the specific distro version garyserj. That means if that CentOS version was released two years ago you could be stuck on ruby 1.9.* as well
[23:51:15] ebonics: there's no "coincidence", it's completely at the discretion of the package managers of ruby for those distros
[23:51:34] ebonics: also you have no idea what modifications the package managers made to the distribution
[23:51:53] Deele: has joined #ruby
[23:51:59] garyserj: so coincidental that the discretion of the package managers for centos fedora and RHEL all give the latest one and all those distros use yum.
[23:51:59] xybre: rbenv and chruby do not install ruby on their own
[23:52:31] Soda: has joined #ruby
[23:52:32] xybre: ruby-install or ruby-build do however
[23:52:44] garyserj: i.e. coincidental that the 3 distros that give the latest one are the three that use yum.
[23:52:46] bootstrappm: garyserj: Its the latest when those distros we're released which will likely be not even close to the most recent version of ruby
[23:52:50] ebonics: you could phrase it: the repel repo ruby manager(s) prefer updated ruby to ship with their distro
[23:53:03] bootstrappm: anybody w/ centos here can tell us what ruby comes on system or installs using yum?
[23:53:32] mwlang: why is it ruby never really gained much traction with the package managers anyway? Ruby seems to be the exception to the rule for languages (compared to C, C++, Perl, PHP, etc.)
[23:53:58] ebonics: probably because there's rvm and chruby and shit
[23:54:08] mwlang: Ruby seems to be about the only language I install with a tool like RVM. all the others, I install with package managers.
[23:54:09] ebonics: no one actually expects anyone to install ruby through yum
[23:54:29] mwlang: ebonics: but those came about because Ruby was so poorly managed???a solution was needed.
[23:54:41] xybre: It doesn't look like CentOS has the latest, at least according to rpm.pbone.net
[23:54:42] dru`: has joined #ruby
[23:54:48] ebonics: that's the case with _anything_
[23:55:00] ebonics: i think the only difference is that ruby versions have shitty backwards compatibility
[23:55:04] moretti: has joined #ruby
[23:55:05] bootstrappm: i would expect not, centos has old packages for everything
[23:55:06] ebonics: so it actually matters what ruby version you use
[23:55:19] xybre: It has v2.0.0, but CentOS, Fedora, and Redhat share the base code, so their versions are often going to be similar.
[23:56:06] xybre: (CentOS being a user-compiled version of RedHat's sources)
[23:56:15] havenwood: they have to gimp CentOS or what reason would you have to pay? :P
[23:56:21] havenwood: Fedora's Ruby packages are quite nice.
[23:56:39] xybre: Fedora is free last I checked
[23:56:40] mwlang: ebonics: similar issue with Perl 5 vs 6 and Python 1.x vs 2.x vs 3.x, yet, they seem well represented in the package managers.
[23:56:46] xybre: You're paying for support, more than anything.
[23:57:12] ebonics: mwlang, probably because those versions have been widely used forever
[23:57:15] bootstrappm: i think garyserj just came in here to set off that bomb and then disappeared hahah
[23:57:19] ebonics: it's commonplace
[23:57:38] ebonics: and for python it's pretty much just python 2.7 and python 3
[23:57:43] garyserj: heh i'm reading the replies.
[23:58:03] duderonomy: has joined #ruby
[23:58:36] bootstrappm: garyserj: the answer is if you're using any system-level tool to install ruby you're doing it wrong. Looks like 2.0 is the most recent version that has come out of this discussion, the most recent stable right now is 2.2
[23:58:44] nateberkopec: has joined #ruby
[23:59:04] mwlang: ah well. I rant pointlessly. I???m happy to use rvm and know how to configure servers with it handsomely.
[23:59:23] xybre: BTW perl6 doesn't seem to be represented in Ubuntu's package manager at all.
[23:59:32] havenwood: xybre: Didn't mean to imply Fedora wasn't free. <3 Fedora. CentOS is just maddeningly behind.
[23:59:44] hewenhong: has joined #ruby
[23:59:49] ebonics: i decided to try precise32 the other day with vagrant
[23:59:55] ebonics: haha NOPE shit still uses vim 7.3