« Back to channel list

#ruby - 04 September 2015

« Back 1 day Forward 1 day »
[00:00:22] banister: radens what ruby version
[00:00:31] radens: 1.9.3 I think
[00:00:32] banister: it only works on relatively recent ruby versions iirc
[00:00:36] banister: yeah taht's way way way too old
[00:00:40] banister: needs to be at least 2.1 i think
[00:00:54] radens: okay. This needs to be portable.
[00:01:06] radens: ACTION copy pastes three lines and calls it a day
[00:01:07] banister: 1.9.3 is ancient at this point
[00:01:12] bricker: radens: good choice :)
[00:01:55] banister: radens you can do it using: self.singleton_class.ancestors[n].instance_method(__method__).bind(self).call
[00:02:05] banister: if you dont have super_method
[00:02:07] banister: anyway goodnight
[00:02:13] radens: ACTION gags
[00:02:26] Lyhue: has joined #ruby
[00:04:37] shinnya: has joined #ruby
[00:05:59] Maletor: has joined #ruby
[00:06:44] robbyoconnor: has joined #ruby
[00:08:33] shmilan: has joined #ruby
[00:10:05] nux443: has joined #ruby
[00:10:36] ducklobster: has joined #ruby
[00:11:37] michael_mbp: has joined #ruby
[00:12:59] ducklobster: i was hoping someone could help me with passing a block from one function (input) to another
[00:13:00] ducklobster: https://gist.github.com/anonymous/15c49eaf3d913865500b
[00:13:40] ducklobster: it seems to be complaining when i try to pass the condition block on to the next function
[00:13:44] barhum2013: has joined #ruby
[00:14:15] duncannz: has joined #ruby
[00:14:17] ebertx: has joined #ruby
[00:15:28] shevy: puts recursive_find ARGV[0] { |entry| File.extname(entry) == ".rb" }
[00:15:30] shevy: that part right?
[00:15:34] shevy: I think the parser may require () there
[00:16:06] michael_mbp: has joined #ruby
[00:16:21] ducklobster: with a comma between the args?
[00:16:21] baweaver: do end can leave off parens
[00:16:28] baweaver: {} blocks cannot
[00:16:34] baweaver: otherwise the parser thinks it's a hash
[00:16:44] fgo: has joined #ruby
[00:17:05] shevy: ducklobster a comma between the args? you only pass one argument, not several or?
[00:17:24] ducklobster: oh, does the block not count as an argument?
[00:17:35] shevy: yeah but it's special
[00:17:54] shevy: the {} is the information required, you pass that one already
[00:17:56] craysiii: it is called by yield no?
[00:18:18] shevy: inside the method, or in this case &condition
[00:18:38] shevy: he taps into it already there: condition.call
[00:18:41] ducklobster: craysiii: no, i use condition.call
[00:19:01] shevy: & will always come last in method signatures
[00:19:32] ducklobster: so ` puts recursive_find( ARGV[0] { |entry| File.extname(entry) == ".rb" } ) `
[00:19:36] shevy: you could also change it as baweaver wrote
[00:19:46] shevy: a block comes last
[00:19:47] RegulationD: has joined #ruby
[00:20:01] ducklobster: recursive_find( ARGV[0] ) { }
[00:20:03] shevy: puts recursive_find(ARGV[0]) { |entry| File.extname(entry) == ".rb" }
[00:20:36] ducklobster: ok so, both the do end as well as teh ARGV[0] { } seem to pass through
[00:20:59] ducklobster: it doesn't like where I call the function recursively (L12)
[00:21:01] dfhg: has joined #ruby
[00:21:40] ducklobster: https://gist.github.com/anonymous/0ac2f377293e02c98553#file-recursive_find-rb-L12
[00:21:42] evrial: has joined #ruby
[00:22:08] shevy: it's a perma loop?
[00:22:10] ducklobster: i guess its the same problem? do i need recursive_find(entry) condition?
[00:22:21] shevy: as long as you have one directory, you will call the method again
[00:22:32] ducklobster: yeah, with the new directory
[00:22:59] ducklobster: the idea is (or at least i am attempting to make it) if it finds a directory, it passes the directory on to be searched again
[00:23:02] larshaugseth: has joined #ruby
[00:23:04] bruno-: has joined #ruby
[00:23:22] shevy: btw why do you not use Dir['**/**.rb'] ?
[00:23:50] paulcsmith: has joined #ruby
[00:23:56] ducklobster: i was hoping to write it generically, so i could pass the condition in as opposed to hardcode the .rb part
[00:24:07] ducklobster: or set the condition on filesize and such maybe
[00:24:16] shevy: I don't understand it
[00:24:41] Ropeney: has joined #ruby
[00:24:43] shevy: all this seems to do is to grab some specific files based on the file extension
[00:25:04] theery: has joined #ruby
[00:25:07] ducklobster: right this example but my thought was to make the condition generic so i could
[00:25:11] ducklobster: instead of file extension
[00:25:21] ducklobster: File.size?(entry) > 1000
[00:25:32] shevy: yes I still don't understand the argument
[00:25:41] theery: has joined #ruby
[00:25:45] shevy: you can apply the same File.size? check on your collection lateron as well
[00:26:00] shevy: via .reject or .select for instance
[00:26:15] tvw: has joined #ruby
[00:26:43] luckyme: has joined #ruby
[00:27:21] shevy: def find_stuff(extension_type = 'rb'); Dir['**/**.'+extension_type].select {|entry| File.size?(entry) > 1000 }; end; find_stuff
[00:28:11] ducklobster: yeah i guess that is much cleaner
[00:28:20] ducklobster: the only difference i guess is that it treats dirs and files the same
[00:28:36] shevy: not sure how it can find dirs with .rb :)
[00:28:51] Ox0dea: Directories can be named with extensions...
[00:28:52] ducklobster: oh right, didn't see that!
[00:28:59] shevy: Ox0dea oh you do that?
[00:29:05] Ox0dea: I've done that, sure.
[00:29:17] shevy: you do crazy stuff
[00:29:23] ledestin: has joined #ruby
[00:29:34] Ox0dea: Not '.rb', obviously, but it's sometimes reasonable enough.
[00:29:54] eam: .d is a super common extension in directory names
[00:30:03] shevy: yeah I kill those dirs when I see them
[00:30:08] ducklobster: shevy: yeah i can't think of a (good) reason why your method wouldn't work
[00:30:08] eam: hahahha
[00:30:39] shevy: init.d is my all time enemy
[00:30:47] eam: you don't need it anymore
[00:31:05] davedev24: has joined #ruby
[00:31:19] shevy: yeah, that sorta confused me... or perhaps how systemd handles things, I still haven't read up on it really
[00:31:21] Ox0dea: shevy is using Ubuntu 8.04.
[00:31:34] Ox0dea: Oh... no?
[00:31:40] shevy: Ox0dea gobolinux! \o/
[00:31:51] shevy: nah I am kidding, gobolinux died effectively years ago :(
[00:31:59] youch: has joined #ruby
[00:32:03] Ox0dea: alexherbo2 uses Exherbo.
[00:32:13] shevy: never heard of that one before
[00:32:24] NeverDie: has joined #ruby
[00:32:26] shevy: there once was a ruby distribution.... RubyX/heretix
[00:32:50] shevy: http://distrowatch.com/table.php?distribution=heretix
[00:33:06] failshell: has joined #ruby
[00:33:31] Ox0dea: http://www.h-e-r-e-t-i-x.org/
[00:33:41] Ox0dea: To The Wayback Machine!
[00:33:42] shevy: didn't survive for long...
[00:33:42] youch: i am upgrading the ruby version used by an app from 2.1.1 to 2.1.7. bundle install errors out installing a lot of gems. im assuming i need to change my the gems specified in Gemfile to reflect my ruby version change. what is the best way to do this?
[00:34:17] youch: i have already changed the ruby version in my Gemfile as well
[00:34:46] Ox0dea: youch: Specific error(s), if you'd be so kind.
[00:35:27] luckyme: has joined #ruby
[00:35:37] baweaver: has joined #ruby
[00:35:55] youch: Error installing json: ERROR: Failed to build gem native extension
[00:36:15] Ox0dea: Little more...
[00:36:56] youch: make failed, exit code 2
[00:37:02] Oog: has joined #ruby
[00:37:06] Ox0dea: And before that?
[00:37:31] Ox0dea: Wrong number of arguments to rb_str_new(), perhaps?
[00:38:00] youch: https://gist.github.com/wheresmyjetpack/c6163fd5943b68a1555b
[00:38:15] shevy: cannot find -lgmp
[00:38:19] Ox0dea: youch: OS?
[00:38:27] sdwrage: has joined #ruby
[00:38:47] shevy: you lack the library gmp, source code is at http://ftp.sunet.se/pub/gnu/gmp/gmp-6.0.0a.tar.xz, you probably can install from your distribution
[00:38:55] keen__________13: has joined #ruby
[00:39:02] Ox0dea: shevy: Why not link directly to Savannah?
[00:39:04] youch: 14.04.1-Ubuntu
[00:39:15] Ox0dea: youch: apt-get install libgmp-dev
[00:39:27] shevy: Ox0dea savannah?
[00:39:32] youch: Ox0dea: will try that. thank you
[00:39:52] Ox0dea: youch: Fingers crossed.
[00:39:54] shevy: Ox0dea you always seem to want the latest source!
[00:40:03] northfurr: has joined #ruby
[00:40:26] Ox0dea: shevy: I just think it's weird you didn't link to a "canonical" source is all.
[00:40:37] shevy: that is an official tarball!
[00:40:54] shevy: here for ruby ftp://ftp.ruby-lang.org/pub/ruby/ruby-2.2.3.tar.xz
[00:41:14] Ox0dea: shevy: sunset.se is official associated with the GNU project?
[00:41:14] juanpablo____: has joined #ruby
[00:41:25] shevy: I think it's an automatically synced mirror
[00:41:28] allcentury: has joined #ruby
[00:41:37] Ox0dea: Mirrors can lie.
[00:41:54] shevy: I usually get those downloads from clicking on download links and then being randomly redirected into the weird parts of the world wide web
[00:42:01] shevy: you should see my KDE related links
[00:42:04] bronson: has joined #ruby
[00:42:06] Ox0dea: Spare me. :P
[00:43:36] dfhg: has joined #ruby
[00:45:02] drbrain: I wonder how many rootkits shevy has installed
[00:45:28] tubuliferous_: has joined #ruby
[00:46:22] youch: Ox0dea: much appreciated, json gem installed properly, now just waiting to see if bundler errors out on anything else
[00:46:29] theery: has joined #ruby
[00:46:29] yfeldblum: has joined #ruby
[00:47:39] jesterfraud: has joined #ruby
[00:49:10] youch: ok here's an issue that i believe has been documented in a few places. i am having trouble determining a solution. debugger (1.6.8) gem will not install with ruby 2.1.7.
[00:50:39] dcarmich: has joined #ruby
[00:52:19] youch: https://gist.github.com/wheresmyjetpack/3af15080ae32778d031a
[00:52:55] rickmasta: has joined #ruby
[00:53:07] Radar: youch: Try using the pry gem instead.
[00:54:10] grotewold: has joined #ruby
[00:54:29] _blizzy_: has joined #ruby
[00:54:36] youch: Radar: if Debugger is not specified in my Gemfile, how would i specify the Pry gem as an alternative?
[00:55:11] davedev24: has joined #ruby
[00:55:23] shevy: youch from its homepage, it should not be incompatible with ruby 2.1.7 - see on the right side https://rubygems.org/gems/debugger
[00:55:30] ngscheurich: has joined #ruby
[00:55:49] grenierm: has joined #ruby
[00:56:33] shevy: it seems to demand a file called ruby_debug.h
[00:57:00] aaeron: has joined #ruby
[00:57:03] juanpablo____: has joined #ruby
[00:57:16] shevy: https://github.com/cldwalker/debugger/issues/131
[00:57:23] shevy: "debugger gem doesn't support ruby 2"
[00:57:30] shevy: https://github.com/daqing/redmonster/issues/1
[00:57:43] paulcsmith: has joined #ruby
[00:57:49] shevy: here is the most relevant comment: https://github.com/cldwalker/debugger/issues/125#issuecomment-43353446
[00:58:21] youch: shevy yea id seen the debugger doesnt support ruby 2 page before
[00:58:46] davedev24: has joined #ruby
[00:59:22] youch: so my question then, would be if i were to use an alternative like pry or byebug, how would i specify using of those gems instead of debuger, if debugger does not appear to be listed in my gemfile
[01:01:35] ohaibbq: has joined #ruby
[01:02:07] Radar: youch: How is it being installed then?
[01:02:11] Radar: youch: Show us your Gemfile.lock please.
[01:03:20] youch: Radar: one moment
[01:03:43] fschuindt1: has joined #ruby
[01:04:02] Swappticon: has joined #ruby
[01:04:04] devoldmx: has joined #ruby
[01:05:05] youch: there does not appear to be a Gemfile.lock
[01:05:16] youch: that seems odd
[01:06:02] Radar: youch: Show us your Gemfile instead then
[01:06:07] Radar: youch: Likely that it's failing on an initial install
[01:06:13] Aeyrix: youch: Not really. That happens if the install hasn't happened.
[01:06:29] Radar: Aeyrix: too slow
[01:07:13] youch: https://gist.github.com/wheresmyjetpack/cc714a001b3a850de718
[01:07:17] youch: gemfile ^
[01:07:37] youch: oops sorry thats not all of it
[01:07:46] Radar: youch: can you show me the complete output of bundle install too?
[01:08:31] youch: Radar: yes
[01:11:13] northfurr: has joined #ruby
[01:13:07] youch: https://gist.github.com/wheresmyjetpack/a6c7f2ebdfa518a24014
[01:13:13] youch: theres the whole gemfile
[01:13:19] Radar: Anid the output?
[01:13:25] Radar: Are you distracted like me too right now? :P
[01:13:52] Radar: Nothing there is indicating a debugger dependency. The output would be great.
[01:14:12] jesterfraud: has joined #ruby
[01:14:22] youch: got it coming in just one sec
[01:14:32] mleung: has joined #ruby
[01:14:35] youch: ha yes im a little distracted
[01:14:39] youch: i appreciate the help
[01:15:08] husanu: has joined #ruby
[01:15:50] youch: aaaand heres the output
[01:15:52] youch: https://gist.github.com/wheresmyjetpack/052d0f96f0fc8d78b664
[01:16:36] Radar: youch: mutliple files can go in the same gist fyi
[01:17:00] youch: Radar haha yea just figured that out
[01:17:50] fgo: has joined #ruby
[01:18:02] Radar: youch: Run `bundle install` with --verbose please.
[01:19:00] charliesome: has joined #ruby
[01:20:10] tkuchiki: has joined #ruby
[01:20:53] juanpablo____: has joined #ruby
[01:21:22] baweaver: has joined #ruby
[01:21:36] youch: https://gist.github.com/wheresmyjetpack/c9f3aa57ec0a1561b5a0
[01:21:56] bubbys: has joined #ruby
[01:23:18] aaeron: has joined #ruby
[01:23:48] bruno-: has joined #ruby
[01:24:40] devbug: has joined #ruby
[01:25:31] mary5030: has joined #ruby
[01:25:49] phutchins: has joined #ruby
[01:26:05] youch: Radar: let me know if i can provide anything else that might help
[01:26:08] husanu: has joined #ruby
[01:26:12] fschuindt1: has joined #ruby
[01:26:26] Radar: Taking a look
[01:27:27] Radar: I wish I could figure out what the dependency graph looks like... I seem to recall there is an option for that
[01:27:49] Radar: Oh right, it's DEBUG_RESOLVER=1 bundle install
[01:27:59] finisherr: has joined #ruby
[01:28:01] Radar: youch: DEBUG_RESOLVER=1 bundle install > bundle.log
[01:28:03] Radar: It'll be big
[01:28:09] youch: run with --verbose im assuming?
[01:28:19] Radar: Nope, without --verbose
[01:28:52] Radar: Ack, it outputs to stderr. Somehow get me the full output of that command please.
[01:29:48] dgutierrez1287: has joined #ruby
[01:31:44] Radar: youch: DEBUG_RESOLVER=1 bundle install 2> bundle.log
[01:32:36] youch: Radar: i used `2>&1 >` pipe to stdout the pipe to bundle.log
[01:32:52] Radar: It might be quite a large file
[01:32:58] youch: its pretty larg
[01:33:40] failshell: has joined #ruby
[01:34:10] nzst: has joined #ruby
[01:35:11] youch: just waiting on it to be finished
[01:36:28] [k-: has joined #ruby
[01:36:53] grotewold: has joined #ruby
[01:37:29] majjoha: has joined #ruby
[01:38:10] youch: Radar: https://gist.github.com/wheresmyjetpack/92a70dbaea5d46cdb2ca
[01:38:24] Radar: excellent :)
[01:38:50] Radar: https://rubygems.org/gems/jazz_hands
[01:39:11] Radar: https://gist.github.com/wheresmyjetpack/a6c7f2ebdfa518a24014#file-gistfile1-txt-L71
[01:39:13] Radar: Looks like it's this gem.
[01:39:25] Radar: it depends on pry-debugger which depends on debugger.
[01:39:56] shevy: circular madness!
[01:39:56] youch: Radar: awesome. thank you so much for your help
[01:40:23] Radar: youch: You should be able to remove the jazz_hands gem and in its place use the pry-rails gem itself.
[01:40:40] Radar: Dunno why it includes awesome_print because pry does a great job of that itself
[01:40:47] northfurr: has joined #ruby
[01:41:11] freerobby: has joined #ruby
[01:41:17] Rubie: has joined #ruby
[01:41:59] phutchins: has joined #ruby
[01:43:19] siaW: has left #ruby: ()
[01:45:09] Radar: youch: Let me know if that fixes the issue.
[01:45:13] arooni-mobile: has joined #ruby
[01:45:28] Radar: Took almost an hour to get to the bottom of it but we did it! :D
[01:47:42] youch: Radar: haha i am pretty happy you helped me get over that hurdle
[01:48:20] northfurr: has joined #ruby
[01:49:05] iamninja: has joined #ruby
[01:49:31] lampshades: has joined #ruby
[01:49:32] bffff_: has joined #ruby
[01:50:22] agni_dev: has joined #ruby
[01:50:43] barhum2013: has joined #ruby
[01:51:28] Radar: youch: I'm pretty happy that I have more content for my Debugging Ruby book :)
[01:52:03] youch: has joined #ruby
[01:53:24] CloCkWeRX: has joined #ruby
[01:54:54] lampshades: has joined #ruby
[01:56:52] grenierm: has joined #ruby
[01:57:04] agni_dev: has joined #ruby
[01:57:05] JBrickley: has joined #ruby
[01:57:28] grotewold: has joined #ruby
[02:01:49] patrick_star: has joined #ruby
[02:02:43] charliesome: has joined #ruby
[02:03:02] grotewold: has joined #ruby
[02:05:28] A124: has joined #ruby
[02:07:04] moeabdol: has joined #ruby
[02:07:59] rails242: has joined #ruby
[02:08:51] Ox0dea: rails242: Did it work?
[02:09:04] postmodern: has joined #ruby
[02:17:26] prestorium: has joined #ruby
[02:17:40] Ox0dea: Tell me what that keybind was supposed to do.
[02:18:56] fgo: has joined #ruby
[02:20:11] [k-: . means sucess while F means failed
[02:20:11] Ox0dea: Never mind my derp.
[02:20:36] michael_mbp: has joined #ruby
[02:21:23] juanpablo____: has joined #ruby
[02:21:25] RegulationD: has joined #ruby
[02:21:56] grotewold: has joined #ruby
[02:22:09] nanoz: has joined #ruby
[02:24:32] stardiviner: has joined #ruby
[02:25:14] [k-: rubymotion is now available free
[02:26:55] dopie: has joined #ruby
[02:29:12] charliesome: has joined #ruby
[02:29:22] grotewold: has joined #ruby
[02:29:38] barhum2013: has joined #ruby
[02:29:57] shevy: are you using it?
[02:30:15] [k-: `is now`
[02:33:48] astrobunny: has joined #ruby
[02:33:53] fschuindt1: has joined #ruby
[02:34:25] failshell: has joined #ruby
[02:34:51] devoldmx: has joined #ruby
[02:36:45] northfurr: has joined #ruby
[02:36:48] krz: has joined #ruby
[02:37:46] _blizzy_: has joined #ruby
[02:39:25] majjoha: has joined #ruby
[02:39:59] shevy: lots of cool projects happening as of late
[02:40:22] shevy: to use yaml files to have bash-completions for instance... I was auto-generating such completion files via ruby before, now I could transition into yaml files instead
[02:41:44] shevy: hah - did you write that comment Ox0dea https://code.google.com/p/xee/source/browse/XeePhotoshopLoader.m?r=f16763d221dfca6253983824b470adf553a19e06
[02:42:38] bronson: has joined #ruby
[02:45:09] bigredboots: has joined #ruby
[02:46:29] _blizzy_: has joined #ruby
[02:47:33] mary5030: has joined #ruby
[02:47:36] nahtnam: has left #ruby: ()
[02:48:23] havenwood: has joined #ruby
[02:53:05] swgillespie: has joined #ruby
[02:54:11] Rubie: has joined #ruby
[02:54:27] Mendenhall: has joined #ruby
[02:54:49] swgillespie: has left #ruby: ()
[02:57:37] aaeron: has joined #ruby
[03:00:52] gener1c_: has joined #ruby
[03:03:17] tmtwd: has joined #ruby
[03:03:30] freerobby: has joined #ruby
[03:06:13] arescorpio: has joined #ruby
[03:06:59] northfurr: has joined #ruby
[03:08:25] gix: has joined #ruby
[03:09:25] barhum2013: has joined #ruby
[03:09:31] braincrash: has joined #ruby
[03:11:10] bustrarm: has joined #ruby
[03:12:00] howdoi: has joined #ruby
[03:12:12] freerobby: has joined #ruby
[03:12:26] gavit: has joined #ruby
[03:13:54] aaeron: has joined #ruby
[03:15:12] jesterfraud: has joined #ruby
[03:16:47] northfurr: has joined #ruby
[03:18:50] Oog: has joined #ruby
[03:20:04] fgo: has joined #ruby
[03:22:24] TheNet: has joined #ruby
[03:23:33] baweaver: has joined #ruby
[03:24:40] grenierm: has joined #ruby
[03:25:31] freerobby: has joined #ruby
[03:26:43] grotewold: has joined #ruby
[03:28:12] stoodfarback: has joined #ruby
[03:28:14] aaeron: has joined #ruby
[03:28:16] howdoi_: has joined #ruby
[03:28:45] dymk: has joined #ruby
[03:28:50] jimeh: has joined #ruby
[03:29:26] Coldblackice: has joined #ruby
[03:31:14] davedev24: has joined #ruby
[03:32:21] sfr^: has joined #ruby
[03:32:46] linc01n: has joined #ruby
[03:32:51] universa1: has joined #ruby
[03:32:52] techietrash: has joined #ruby
[03:32:54] larissa: has joined #ruby
[03:32:55] Shidash: has joined #ruby
[03:33:16] drbrain: has joined #ruby
[03:33:18] bf4: has joined #ruby
[03:33:22] waxjar: has joined #ruby
[03:33:56] shmilan: has joined #ruby
[03:35:18] nzst: has joined #ruby
[03:41:48] techietrash: has joined #ruby
[03:43:53] rakm: has joined #ruby
[03:44:20] techietrash: has joined #ruby
[03:48:51] weemsledeux: has joined #ruby
[03:48:54] xxneolithicxx: We have all commented to the FCC on wifi right? http://savewifi.org ... right?
[03:49:02] shevy: "If debugging is the process of removing bugs, then programming must be the process of putting them in."
[03:49:34] vmatiyko: has joined #ruby
[03:49:51] pontiki: there is a testing technique known a "bebugging" which means putting in deliberate errors to ensure a) that your tests find them, b) you code doesn't break in unexpected ways
[03:50:00] astrobunny: has joined #ruby
[03:50:00] Rennex: has joined #ruby
[03:52:30] Radar: Of course Haskell solves those TYPES of issues.
[03:52:59] pontiki: oh, well played
[03:54:34] baweaver: It certainly makes a STRONG showing doesn't it
[03:54:54] Radar: It's well known that a group of Haskellers is known as a "condescension"
[03:55:15] baweaver: and a group of pedants is an "well, actually..."
[03:55:17] pontiki: ACTION giggles
[03:56:14] atomical: has joined #ruby
[03:56:44] dgutierrez1287: has joined #ruby
[03:57:19] aaeron: has joined #ruby
[03:57:23] mary5030: has joined #ruby
[03:57:48] sdothum: has joined #ruby
[03:59:33] aaeron1: has joined #ruby
[04:00:15] Yzguy: has joined #ruby
[04:01:51] mbuf: has joined #ruby
[04:03:16] Rubie: has joined #ruby
[04:05:33] _djbkd: has joined #ruby
[04:05:58] gix: has joined #ruby
[04:07:13] fschuindt1: has joined #ruby
[04:09:42] Gnomethrower: has joined #ruby
[04:10:12] majjoha: has joined #ruby
[04:10:19] charliesome: has joined #ruby
[04:10:27] juanpablo____: has joined #ruby
[04:11:10] tejasmanohar: has joined #ruby
[04:11:12] tejasmanohar: has left #ruby: ("WeeChat 1.3")
[04:12:37] tejasmanohar: has joined #ruby
[04:14:39] Rubie: has joined #ruby
[04:14:54] hackerdude: has joined #ruby
[04:16:27] fgo: has joined #ruby
[04:17:22] darkf: has joined #ruby
[04:21:55] diego_ar: has joined #ruby
[04:23:13] RegulationD: has joined #ruby
[04:24:07] jackjackdripper: has joined #ruby
[04:29:14] bubbys: has joined #ruby
[04:30:48] radgeRayden: has joined #ruby
[04:31:12] towski_: has joined #ruby
[04:32:38] Alina-malina: has joined #ruby
[04:35:18] failshell: has joined #ruby
[04:35:23] codenapper: has joined #ruby
[04:35:36] devoldmx: has joined #ruby
[04:36:13] rickmasta: has joined #ruby
[04:39:39] havenwood: has joined #ruby
[04:42:40] Aswebb_: has joined #ruby
[04:43:54] bronson: has joined #ruby
[04:44:12] nisstyre: has joined #ruby
[04:44:44] leat: has joined #ruby
[04:45:09] nisstyre: has joined #ruby
[04:45:29] [k-: so bad :(
[04:46:14] A124: has joined #ruby
[04:46:15] [k-: hm, i am a pedant
[04:46:23] [k-: i learnt a new word \o/
[04:49:04] shevy: pederant?
[04:49:09] clarkenciel: has joined #ruby
[04:52:25] psye: has joined #ruby
[04:54:39] psye: has joined #ruby
[04:58:53] majjoha: has joined #ruby
[04:59:44] jesterfraud: has joined #ruby
[05:00:44] sigurding: has joined #ruby
[05:05:54] Spami: has joined #ruby
[05:09:28] tmtwd: has joined #ruby
[05:12:39] Oog: has joined #ruby
[05:13:38] Aambri: has joined #ruby
[05:14:10] dionysus69: has joined #ruby
[05:14:19] dhjondoh: has joined #ruby
[05:15:37] roxtrongo: has joined #ruby
[05:19:51] ranchodev: has joined #ruby
[05:23:15] riotjones: has joined #ruby
[05:24:09] diego_ar: has joined #ruby
[05:24:35] tkuchiki: has joined #ruby
[05:25:36] bruno-: has joined #ruby
[05:26:37] ellisTAA: has joined #ruby
[05:27:17] ellisTAA: i???m trying to get better at writing tests, if anyone has a project that they want me to write tests for let me know and ill consider it
[05:27:53] kjones_: has joined #ruby
[05:28:15] Radar: EllisTAA: !r4ia
[05:28:23] Radar: oh right, it doesn't work here :P
[05:28:30] Radar: The Rails 4 in Action book has a bunch of tests
[05:28:45] ellisTAA: alright ill check that out
[05:28:56] havenwood: EllisTAA: It might be interesting to write tests for a small gem that already has tests without looking at any of its tests.
[05:28:56] Radar: EllisTAA: You could start out by writing some tests and building the pieces of the app as the test requires it
[05:29:00] Radar: and then getting feedback on that
[05:29:04] Coldblackice: has joined #ruby
[05:29:23] ellisTAA: havenwood: have any suggestions on what gem i might consider doing that for?
[05:29:25] kjones_: has joined #ruby
[05:29:27] ellisTAA: Radar: perhaps ill do that
[05:30:08] ellisTAA: Radar: if i were to test a rails app, would i be expected to test anything besides the model and controller?
[05:30:30] Radar: EllisTAA: yes
[05:31:05] aganov: has joined #ruby
[05:32:06] codenapper: has joined #ruby
[05:32:31] havenwood: EllisTAA: Was going to suggest something meta like Minitest's tests but I'm trying to think of something simpler.
[05:32:34] Oog: has joined #ruby
[05:33:18] eightfold: has joined #ruby
[05:33:48] havenwood: EllisTAA: How much of an epic challenge are you looking for? :)
[05:34:49] ellisTAA: havenwood: err i just want to get better lol
[05:35:58] nzst: has joined #ruby
[05:37:09] husanu: has joined #ruby
[05:37:16] havenwood: EllisTAA: Looking for Minitest, RSpec, other or don't care?
[05:37:39] solars: has joined #ruby
[05:37:56] ellisTAA: im looking to write rspecs
[05:38:12] havenwood: EllisTAA: Add some specs to Lattice :) https://github.com/celluloid/lattice
[05:38:22] ellisTAA: k ill check it out
[05:38:24] havenwood: EllisTAA: Contribute to vaporware ;)
[05:38:26] ellisTAA: thanks for helping
[05:38:36] rickmasta: has joined #ruby
[05:38:59] shevy: so you probably want a small class
[05:39:04] khebbie: has joined #ruby
[05:39:14] ellisTAA: havenwood: is lattice your project?
[05:39:55] havenwood: EllisTAA: No, it's Tony Arcieri's.
[05:40:18] havenwood: EllisTAA: It's a Celluloid project but I'm not sure there are plans for further development.
[05:40:29] ellisTAA: what about vaporware
[05:40:35] havenwood: EllisTAA: I'm sure there are better things for you to contribute RSpec specs to but I'm at a loss!
[05:41:20] havenwood: EllisTAA: I just learned some RSpec/Thor adding a few specs to that project to learn so I thought of it.
[05:41:42] naftilos76: has joined #ruby
[05:42:15] pyon: has joined #ruby
[05:42:55] havenwood: EllisTAA: I'm normally a Minitester :)
[05:43:30] riotjones: has joined #ruby
[05:43:44] [k-: Quickcheck!
[05:45:17] havenwood: >> "Quickcheck!\n".tr "ie!\n", 'aien'
[05:45:18] ruboto: havenwood # => "Quackchicken" (https://eval.in/427823)
[05:45:58] havenwood: [k-: A duck I suppose.
[05:46:03] grotewold: has joined #ruby
[05:46:11] yfeldblum: has joined #ruby
[05:47:48] shevy: quickduck
[05:47:52] tmtwd: has joined #ruby
[05:47:54] havenwood: ACTION ducks
[05:48:39] yfeldblum: has joined #ruby
[05:51:22] iateadonut: has joined #ruby
[05:51:22] tkuchiki: has joined #ruby
[05:53:56] tagrudev: has joined #ruby
[05:54:49] leat: has joined #ruby
[05:56:35] fschuindt1: has joined #ruby
[05:56:39] arup_r1: has joined #ruby
[05:56:43] charliesome: has joined #ruby
[05:58:39] tvw: has joined #ruby
[05:58:52] juanpablo____: has joined #ruby
[05:59:43] theery: has joined #ruby
[06:01:41] MasterPiece: has joined #ruby
[06:01:45] claw: has joined #ruby
[06:02:36] arooni-mobile: has joined #ruby
[06:05:05] shevy: my old code very often confuses me
[06:05:32] sigurding: has joined #ruby
[06:05:35] havenwood: [k-: https://github.com/abargnesi/rantly#imperative-random-data-generator-and-quickcheck
[06:07:20] Limix: has joined #ruby
[06:07:21] Rollabunna: has joined #ruby
[06:07:35] havenwood: shevy: would your new code confuse old you?
[06:07:43] bluOxigen: has joined #ruby
[06:07:46] Radar: ACTION has his mind blown
[06:09:23] shevy: havenwood hmm that's hard to say
[06:09:46] shevy: I used to do things such as: string[0,0] = 'abc', nowadays I just use string.prepend
[06:10:09] shevy: or even if string[-3,3] == '.rb', nowadays I use .end_with?
[06:10:20] shevy: then there are some minor things
[06:10:31] shevy: for instance, I keep a trailing '/' for directories
[06:11:17] Ropeney: has joined #ruby
[06:11:22] Rollabun_: has joined #ruby
[06:11:38] shevy: I didn't do so in the past, so now appending-of-files create weird paths... 'HOME_DIR.foo' but HOME_DIR is something such as '/foo' so I ended up with a '/foo.foo' file (or directory actually)
[06:12:15] [k-: your code confuses me
[06:13:32] shevy: my code becomes progressively less cool meta magic and more boring
[06:14:34] jordanloky: has joined #ruby
[06:14:35] fgo: has joined #ruby
[06:14:37] evillution: has joined #ruby
[06:16:35] [k-: you coded like a crazy person
[06:19:00] eGGsha: has joined #ruby
[06:22:40] jas02: has joined #ruby
[06:23:19] Aambri: has left #ruby: ()
[06:23:44] dgutierrez1287: has joined #ruby
[06:24:03] Macaveli: has joined #ruby
[06:24:40] RegulationD: has joined #ruby
[06:26:47] bruno-: has joined #ruby
[06:27:14] ecksit: has joined #ruby
[06:29:52] moeabdol: has joined #ruby
[06:31:01] evillution: has joined #ruby
[06:31:04] DoubleMalt: has joined #ruby
[06:31:27] dionysus69: has joined #ruby
[06:34:03] allomov: has joined #ruby
[06:34:04] kfpratt: has joined #ruby
[06:35:35] znz_jp: has joined #ruby
[06:35:54] failshell: has joined #ruby
[06:36:22] aswen: has joined #ruby
[06:36:37] charliesome: has joined #ruby
[06:37:00] Musashi007: has joined #ruby
[06:39:08] devoldmx: has joined #ruby
[06:39:46] acosonic: has joined #ruby
[06:42:20] fgo: has joined #ruby
[06:43:09] husanu: has joined #ruby
[06:44:29] Mendenhall: has joined #ruby
[06:47:20] Timba-as: has joined #ruby
[06:48:54] sevenseacat: has joined #ruby
[06:49:44] xcesariox: has joined #ruby
[06:50:16] wldcordeiro__: has joined #ruby
[06:51:23] Stan: has joined #ruby
[06:52:10] evillution: has joined #ruby
[06:52:21] wldcordeiro__: has joined #ruby
[06:52:52] mozzarella: has joined #ruby
[06:52:56] benlovell: has joined #ruby
[06:54:26] vondruch: has joined #ruby
[06:56:18] atmosx: shevy: confuses me too. Sometimes I see things I wrote in the past, and I can't believe the fact that I did that.
[06:57:18] ellisTAA: has left #ruby: ()
[06:58:28] XrayD: atmosx: maybe you didnt ;)
[07:01:28] atmosx: XrayD: no I did. It usually looks ugly, but some times I'm amazed I wrote methods or that method. Another issue is that some times I use oneliners or snippets I found on SO. If I do this without adding comments later on I have a hard time understanding right away what that code does.
[07:02:11] XrayD: atmosx: i got your point. i am just saying, that there is no proof that you are guilty.. may some else did that... ^^ some evil guy ..
[07:02:20] XrayD: that helps me coping with that :D
[07:03:52] dumdedum: has joined #ruby
[07:04:53] ordepdev: has joined #ruby
[07:07:02] greenarrow: has joined #ruby
[07:07:04] Mendenhall: has joined #ruby
[07:07:45] Aswebb_: has joined #ruby
[07:12:02] khebbie: has joined #ruby
[07:14:55] lxsameer: has joined #ruby
[07:17:11] auzty: has joined #ruby
[07:18:16] shevy: atmosx yeah
[07:19:20] jonnie: has joined #ruby
[07:22:04] renderful: has joined #ruby
[07:22:19] lipoqil: has joined #ruby
[07:24:13] cloudbud: has joined #ruby
[07:24:46] cloudbud: what is this code doing http://pastebin.com/1AMHv2NZ
[07:24:46] ruboto: cloudbud, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/dcdb6fd1953af938affe
[07:24:46] ruboto: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
[07:24:51] sigurding: has joined #ruby
[07:24:53] cloudbud: means can anybody explain the syntax
[07:26:28] shevy: Ohai::Config[:plugin_path] = is an assignment
[07:26:30] pepperbreath: has joined #ruby
[07:26:46] shevy: it will assign to an Array
[07:27:00] shevy: that's pretty ugly code
[07:27:24] btcquant: has joined #ruby
[07:28:04] btcquant: Hi - I'm a python coder who is attempting to read some Ruby code. Don't understand syntax of one line and was hoping somine could explain it to me. Line is: file_url.split('/')[3..-1].join('/')
[07:28:43] rushed: has joined #ruby
[07:30:18] cloudbud: shevy : what does this mean [node['ohai']['plugin_path'], Ohai::Config[:plugin_path]].flatten.compact
[07:31:52] sevenseacat: at least its a different hash this time
[07:32:00] tesuji_: has joined #ruby
[07:32:25] cloudbud: sevenseacat : what does this :: mean
[07:32:42] apeiros: btcquant: I believe split you have in python too, should work the same
[07:32:53] btcquant: apeiros Thanks!
[07:32:55] jhass: btcquant: [3..-1] is [3:]
[07:32:56] apeiros: btcquant: array[3..-1] gets all elements from offset 3 to the end
[07:32:58] btcquant: has left #ruby: ("Textual IRC Client: www.textualapp.com")
[07:33:23] apeiros: btcquant: and join again works the same as in python, just that you don't do string.join(array), but the other way round: array.join(string)
[07:33:34] apeiros: at least iirc. my python isn't exactly stellar :)
[07:33:43] jhass: they already left >.<
[07:33:50] Ox0dea: has joined #ruby
[07:34:01] jhass: cloudbud: starting reading a ruby tutorial yet?
[07:34:07] apeiros: I assumed their problem would be 3..-1
[07:34:18] apeiros: interesting if their problem was really split
[07:34:24] cloudbud: jhass : can you suggest agood one
[07:34:43] Ox0dea: apeiros: The real problem was using that sort of approach to remove the 'file:///' prefix.
[07:34:53] jhass: cloudbud: I did when you first dropped in here, https://pine.fm/LearnToProgram/
[07:35:34] lulzmachine: has joined #ruby
[07:37:08] nzst: has joined #ruby
[07:37:52] majjoha: has joined #ruby
[07:38:28] apeiros: Ox0dea: I'm not eve awake enough yet to have seen that, lol
[07:38:35] apeiros: Ox0dea: yeah, a rather bad way
[07:39:23] apeiros: at least file urls don't end with /, otherwise that'd even be broken.
[07:39:40] apeiros: >> str = "hello/world/"; str.split("/").join("/") == str
[07:39:41] ruboto: apeiros # => false (https://eval.in/427866)
[07:39:49] apeiros: >> str = "hello/world/"; str.split("/", -1).join("/") == str
[07:39:50] ruboto: apeiros # => true (https://eval.in/427867)
[07:40:09] apeiros: ^ pesky little tidbits to know.
[07:40:11] jgt: has joined #ruby
[07:40:57] skullcrasher: has joined #ruby
[07:43:04] khebbie: has joined #ruby
[07:43:49] codenapper: has joined #ruby
[07:45:17] fschuindt1: has joined #ruby
[07:46:23] marr: has joined #ruby
[07:47:37] juanpablo____: has joined #ruby
[07:48:24] leat: has joined #ruby
[07:50:04] wldcordeiro__: has joined #ruby
[07:50:25] CloCkWeRX: has joined #ruby
[07:50:27] livathinos: has joined #ruby
[07:51:53] moeabdol: has joined #ruby
[07:52:39] yfeldblum: has joined #ruby
[07:54:30] zlogan: has joined #ruby
[07:55:21] senayar: has joined #ruby
[07:55:21] senayar: has joined #ruby
[07:56:23] howdoi: has joined #ruby
[07:58:09] shevy: cloudbud did you not read the reply?
[07:58:27] cloudbud: shevy : read that
[07:59:21] shevy: it's just an assignment there
[07:59:38] davedev24: has joined #ruby
[07:59:57] cloudbud: shevy : what does :: do
[08:00:08] cloudbud: like ohai:: config
[08:00:18] shevy: cloudbud you scope to something
[08:00:25] shevy: it's capitalized Ohai not ohai
[08:00:40] Ray`: it's namespacing right?
[08:00:49] shevy: cloudbud means there may be a module Ohai, and inside that, a module Config. To address the latter it is Ohai::Config
[08:01:11] Ray`: guess my memeory isn't as bad as I thought
[08:01:18] Ray`: my spelling is though
[08:01:49] dhjondoh: has joined #ruby
[08:02:04] Ox0dea: shevy: :: is also method invocation, mind. :P
[08:02:13] krisquigley: has joined #ruby
[08:02:15] shevy: always write this to me
[08:02:51] joonty: has joined #ruby
[08:04:41] charliesome: has joined #ruby
[08:05:19] gguggi: has joined #ruby
[08:06:29] shevy: apeiros hmm... you wrote some games in ruby didn't you? that card game... then I think some space explorer one... is the code to any of them available?
[08:06:54] apeiros: shevy: sadly I didn't really get far with any of those
[08:07:31] claw: has joined #ruby
[08:07:43] Ray`: I've had issues with the opengl binding libs for ruby in terms of speed
[08:08:39] Ray`: I've been working on a 3D cellular automata system, ended up having to rewrite it in C, and my C kinda sucks
[08:09:01] terlar: has joined #ruby
[08:09:03] Ray`: I can write it but I'm no expert
[08:09:10] Ox0dea: Ray`: Why not WebGL?
[08:09:33] charliesome: has joined #ruby
[08:09:59] Ray`: that's something I'm considering now
[08:10:02] ghr: has joined #ruby
[08:10:40] Ray`: I gave it a shot early on but WebGL still wasn't mature enough, this is a project I've had sitting around for a year or two
[08:11:02] Ray`: the thing is, unlike with 2D cellular automata, a lot of the 3D rulesets have no interesting behaviour
[08:11:42] Ray`: so I've had to implement a set of metrics for measuring "interesting" activity, and evolve different rulesets via a genetic algorithm
[08:12:13] Ray`: I'm trying not to cheat by reading the existing papers on the topic
[08:12:17] chussenot: has joined #ruby
[08:13:51] chthon: has joined #ruby
[08:14:07] zlogan: has joined #ruby
[08:15:07] naftilos76: has joined #ruby
[08:15:26] bazbing80: has joined #ruby
[08:16:37] charliesome: has joined #ruby
[08:17:52] Dreamer3: has joined #ruby
[08:21:12] bubbys: has joined #ruby
[08:22:28] apeiros: moin yorickpeterse
[08:22:50] ebbflowgo: has joined #ruby
[08:23:23] cloudbud: what is this chomp method in Ruby !!
[08:24:07] Ox0dea: cloudbud: Programs sometimes get hungry.
[08:24:08] dionysus69: has joined #ruby
[08:24:10] Ox0dea: It's nothing to worry about.
[08:24:27] apeiros: &ri String#chomp
[08:24:28] `derpy: http://www.rubydoc.info/stdlib/core/String#chomp-instance_method
[08:24:30] apeiros: cloudbud: ^
[08:24:37] apeiros: documentation is your friend for such things
[08:26:14] RegulationD: has joined #ruby
[08:26:19] leat: has joined #ruby
[08:26:19] khebbie: has joined #ruby
[08:28:04] benlovell: has joined #ruby
[08:28:14] apeiros: wtf? no Regexp#capture_hash or similar?
[08:28:28] fgo: has joined #ruby
[08:28:53] apeiros: how annoying. well then, another monkey-patch
[08:29:12] patrick_star: has joined #ruby
[08:29:24] CloCkWeRX: has joined #ruby
[08:29:26] jhass: You mean MatchData btw :P
[08:29:34] mary5030: has joined #ruby
[08:29:41] jonnie: has joined #ruby
[08:30:15] apeiros: just stumbled over this in my monkeypatch when I tried it :D
[08:30:18] apeiros: `names.map(&:to_sym).zip(captures).to_h`
[08:30:22] apeiros: not too difficult luckily
[08:31:26] jhass: mmh, why do you need a hash though?
[08:31:34] jhass: MatchData#[] is not enough?
[08:31:42] apeiros: because I want to pass it on
[08:31:43] allomov: has joined #ruby
[08:31:49] apeiros: I just noticed that above is incorrect, though
[08:31:55] apeiros: in case of unnamed captures
[08:32:28] apeiros: oh, can't mix them?
[08:32:30] apeiros: interesting
[08:32:37] allomov: has joined #ruby
[08:32:44] apeiros: have a single named capture - all unnamed captures are gone
[08:32:59] apeiros: >> "hello world".match(/(\w+) (?<b>\w+)/).captures
[08:33:00] ruboto: apeiros # => ["world"] (https://eval.in/427881)
[08:33:11] allomov: has joined #ruby
[08:33:52] jhass: >> "foo bar".match(/(?<a>foo) (bar)/)[2]
[08:33:53] ruboto: jhass # => nil (https://eval.in/427882)
[08:34:14] apeiros: I didn't know that
[08:34:25] adaedra: >> "hello world".match(/(\w+) (?<b>\w+)/).to_a
[08:34:26] ruboto: adaedra # => ["hello world", "world"] (https://eval.in/427883)
[08:34:33] apeiros: I expected MatchData[0] and [:b] to be present in my example
[08:34:39] yeticry: has joined #ruby
[08:35:06] apeiros: err, MatchData[1] of course (since 0 is full match)
[08:35:19] apfeluser: has joined #ruby
[08:36:06] apfeluser: has joined #ruby
[08:36:16] rakm: has joined #ruby
[08:36:50] failshell: has joined #ruby
[08:38:35] jokke-: has joined #ruby
[08:38:36] einarj: has joined #ruby
[08:39:00] radgeRayden_: has joined #ruby
[08:39:45] jgt: has joined #ruby
[08:39:53] devoldmx: has joined #ruby
[08:41:39] diego_ar: has joined #ruby
[08:41:56] TheMoonMaster: has joined #ruby
[08:42:42] kfpratt: has joined #ruby
[08:42:44] Asher: has joined #ruby
[08:44:08] allomov_: has joined #ruby
[08:46:32] Ropeney: has joined #ruby
[08:48:26] Musashi007: has joined #ruby
[08:48:34] allomov: has joined #ruby
[08:48:37] Caelum: has joined #ruby
[08:50:19] iamninja: has joined #ruby
[08:51:13] aswen: has joined #ruby
[08:52:01] shredding: has joined #ruby
[08:53:13] khebbie: has joined #ruby
[08:54:40] Cust0sLim3n: has joined #ruby
[08:55:06] ahmetkapikiran: has joined #ruby
[08:56:22] neozor: has joined #ruby
[08:56:44] neozor: i have a simple question, with boolean operator
[08:56:46] shevy: hi neozor
[08:56:56] neozor: can anyone help me?
[08:57:03] shevy: if you ask the question
[08:57:24] neozor: i have this expression
[08:57:35] AlxAltea: has joined #ruby
[08:58:01] neozor: current_user.has_role? :freelancer && @task.status == 'CLIENT-AGREED'
[08:58:42] neozor: this returns false, even s both expression separetely without the && operator are both true
[08:58:53] apeiros: neozor: precedence
[08:59:09] apeiros: your expression is evaluated as current_user.has_role?(:freelancer && @task.status == 'CLIENT-AGREED')
[08:59:56] UtkarshRay: has joined #ruby
[09:00:04] neozor: what should i do? use the parenthesis?
[09:00:21] neozor: if i do the same expression but with the 'and' operator
[09:00:24] neozor: it returns true
[09:00:24] apeiros: an alternative would be to use `and` instead of `&&`, but personally I prefer parens
[09:00:41] shevy: no need to guess when you use ()
[09:00:44] apeiros: yes. `and` has different precedence than `&&`
[09:00:52] ghr: +1 on parens
[09:01:11] neozor: +1 on this IRC, thank you very much
[09:01:22] neozor: i will read more about precedence
[09:01:51] neozor: i prefer && too, but i didn't what was happening
[09:02:03] apeiros: `and` has other issues, like for example this would not be valid: `has_role = current_user.has_role? :freelancer and @task.status == 'CLIENT-AGREED'`
[09:02:30] neozor: because there is an assigment in the expression?
[09:03:59] neozor: Ok, thank you
[09:04:09] Ray`: I think I've been using parentheses for clarity since BODMAS, because precedence can be annoying
[09:04:45] Ray`: it's an acronym we got taught in math class for precedence in mathematical operators
[09:04:45] Igorshp: has joined #ruby
[09:05:41] Ray`: I think in the US people use PEDMAS
[09:05:42] Igorshp: has joined #ruby
[09:05:53] Ray`: since british english uses brackets to mean parentheses
[09:05:57] Ray`: Brackets, Order, Divide, Multiply, Add, Subtract
[09:06:23] sevenseacat: we got taught BODMAS, yeah
[09:07:24] shevy: australia!
[09:08:41] skullcrasher: has joined #ruby
[09:09:07] sevenseacat: 'straya. *nods*
[09:09:42] neozor: BODMAS is a good way to remember
[09:09:50] neozor: i didn't know it
[09:10:02] apeiros: Ray`: but, but, but! that's missing factorial and exponentiation!
[09:10:43] Ray`: haha true, but this was high school math
[09:11:05] Ray`: once I got to doing college physics I had to internalize a lot of things
[09:11:52] Ray`: but used parentheses a lot in my calculations for clarity, since when the calculation spans like 7 pages
[09:12:09] neozor: and operator is one of the last in precedence
[09:12:24] neozor: the 'and'
[09:12:31] startupality: has joined #ruby
[09:13:04] Ray`: PEDMAS includes exponents, that's missing from BODMAS
[09:13:11] Ray`: hadn't noticed that before
[09:13:55] sigurding: has joined #ruby
[09:13:58] bruno-: has joined #ruby
[09:13:58] Ray`: guess you could class it as order
[09:14:29] Ray`: ACTION grumbles and goes to dig out his textbooks again
[09:15:53] crazydiamond: has joined #ruby
[09:17:16] chussenot: has joined #ruby
[09:19:18] leafybasil: has joined #ruby
[09:20:47] codecop: has joined #ruby
[09:26:42] leat: has joined #ruby
[09:28:46] ecksit: has joined #ruby
[09:29:00] shevy: neozor yeah; 'and' and 'or' should be lower than && and ||
[09:29:19] skullcrasher: has joined #ruby
[09:31:49] fgo: has joined #ruby
[09:32:21] arup_r: has joined #ruby
[09:32:28] DoubleMalt: has joined #ruby
[09:34:01] fschuindt1: has joined #ruby
[09:34:18] canton7: Ray`, "Orders" refers to powers, roots, etc
[09:35:51] Oog: has joined #ruby
[09:36:23] juanpablo____: has joined #ruby
[09:37:44] nzst: has joined #ruby
[09:38:20] skade: has joined #ruby
[09:39:10] leat: has joined #ruby
[09:43:38] shevy: hey spoiler
[09:43:46] shevy: I see you are still trapped in an Array
[09:45:04] [spoiler]: shevy: yeah, i'm alone too :(
[09:45:12] leafybasil: has joined #ruby
[09:45:57] shevy: we could always add someone else from here via <<
[09:46:07] shevy: ruby dating
[09:46:32] [spoiler]: ACTION wouldn't mind
[09:46:43] apeiros: [spoiler] << warning
[09:46:48] apeiros: perfect couple
[09:47:10] shevy: that was taken quite literally so
[09:47:20] [spoiler]: warreng, you come close enough. hi. Are you single?
[09:47:32] [spoiler]: I'm cute, I promise
[09:47:52] infinitestate: has left #ruby: ()
[09:47:54] shevy: I don't know... that warning associated with you is quite scary
[09:48:11] shevy: you may have to persist for a bit longer as a singleton
[09:49:26] Rubie: has joined #ruby
[09:56:15] Soda: has joined #ruby
[09:58:01] bubbys: has joined #ruby
[09:58:39] dmolina: has joined #ruby
[09:59:44] voker57: has joined #ruby
[10:01:32] ebbflowgo: has joined #ruby
[10:02:39] adaedra: [spoiler].clear
[10:04:28] platzhirsch: has joined #ruby
[10:05:24] khebbie: has joined #ruby
[10:05:27] moeabdol: has joined #ruby
[10:05:34] skade: has joined #ruby
[10:07:01] northfurr: has joined #ruby
[10:07:10] fschuindt1: has joined #ruby
[10:09:18] waxjar: Using minitest, is there a way to get the name of a test that is about to run / has just ran in the setup and teardown hooks?
[10:09:42] autrilla: has joined #ruby
[10:11:07] darix: adaedra: [spoiler].alert is better
[10:11:52] jordanloky: has joined #ruby
[10:12:16] [k-: [spoiler].reject(&:itself)
[10:12:23] tvw: has joined #ruby
[10:12:29] [k-: ooooooo
[10:13:09] coffeecupp: has joined #ruby
[10:13:42] [k-: [spoiler].map { spoiler }
[10:15:35] zlogan: has joined #ruby
[10:15:54] mikecmpbll: has joined #ruby
[10:17:25] [k-: >> puts [[["spoiler"]]].pop.pop.inspect
[10:17:26] ruboto: [k- # => ["spoiler"] ...check link for more (https://eval.in/427935)
[10:17:44] [k-: wanted to remove that ""
[10:18:06] Hounddog: has joined #ruby
[10:18:09] [k-: oh!!! to_s!
[10:19:04] k3asd`: has joined #ruby
[10:19:55] arup_r: some people write variables with a leading underscore like _var2, _var1 in method parameter list.. What is the reason?
[10:20:26] rickmasta: has joined #ruby
[10:20:47] adaedra: to mark them as unused I think
[10:20:54] [k-: these are temp variablss
[10:20:58] Scripore: has joined #ruby
[10:21:25] [k-: they mean that, you can safely ignore this variable as it is used for an intermediate step
[10:21:54] arup_r: then why they need it in the method parameter list ?
[10:22:06] porfa: has joined #ruby
[10:22:34] arup_r: leading `_` suppress warnings if it is declared and not uses AFAIK
[10:22:57] arup_r: Which I use say hash.each { |_, v| #some work with k }
[10:23:01] arup_r: this is I know
[10:23:16] arup_r: but that pattern I just mentioned I am not aware of
[10:23:52] [k-: maybe give an example?
[10:25:01] porfa: hello???! can anyone help me out..? i need to install some sdk (ORACLE DB OCI) and i need the OCI8 gem.. but i need the right version (32bits or 64bits installed according to my ruby version) the thing is, i can't find out if i have 32 or 64 bits ruby??? ruby -v says --- x86_x64
[10:25:31] jhass: then it's a 64bit ruby
[10:25:34] porfa: and all examples i saw on google either show x86 or x64.. so I'm confused
[10:25:38] porfa: thanks jhass !! :)
[10:25:54] Scripore: has joined #ruby
[10:25:59] bubuntu: x64 is actually a weired name
[10:26:16] timonv: has joined #ruby
[10:26:24] jhass: they typoed it, it's x86_64
[10:27:13] arup_r: Evening I will show the code.. I have to work on some other people code.. So I was reading the code. there I saw in a initialize method they had used such vars.
[10:27:14] ahmetkapikiran: has joined #ruby
[10:27:46] RegulationD: has joined #ruby
[10:28:12] [spoiler]: Pfft, you keep poking fun at my loneliness :( cruel
[10:28:31] Ray`: canton7: yep, realized that after I said it, I definitely need more sleep
[10:29:06] Ray`: for some reason I figured that an exponent could be expressed in terms of a power, but then was like wat?
[10:30:10] phutchins: has joined #ruby
[10:30:34] skade: has joined #ruby
[10:31:13] coffeecupp: has joined #ruby
[10:32:56] fgo: has joined #ruby
[10:35:40] jeadre: has joined #ruby
[10:35:42] dhjondoh: has joined #ruby
[10:35:56] stamina: has joined #ruby
[10:37:25] failshell: has joined #ruby
[10:40:37] duncannz: has joined #ruby
[10:41:39] decoponio: has joined #ruby
[10:42:33] zlogan: has joined #ruby
[10:42:45] Juanchito: has joined #ruby
[10:43:57] rodfersou: has joined #ruby
[10:44:05] Oog: has joined #ruby
[10:44:40] kfpratt: has joined #ruby
[10:45:25] shevy: what is 10 ** 0
[10:45:26] devoldmx: has joined #ruby
[10:45:53] shevy: you used irb!
[10:46:14] shevy: let's ask Ray`
[10:46:22] jhass: (and I'm lying ;) )
[10:46:32] jhass: 0 ** 0 is way more interesting though
[10:46:47] shevy: I actually saw that question today in a textbook and was a bit confused
[10:46:52] arturaz: has joined #ruby
[10:46:57] Siyfion: has joined #ruby
[10:47:01] Ray`: haha shevy
[10:47:01] [k-: 10 ** 0 is 1 ==_==
[10:47:10] tbuehlmann: I agree, I'd have expected 1
[10:47:19] Ray`: anything raised to the power of zero should technically be 1 mathematically
[10:47:19] bubuntu: >> 10 ** 0
[10:47:20] ruboto: bubuntu # => 1 (https://eval.in/427962)
[10:47:40] [k-: did you not believe?
[10:47:47] shevy: >> 0 ** 0
[10:47:47] [k-: 0 ** 0 is also 1
[10:47:48] ruboto: shevy # => 1 (https://eval.in/427965)
[10:47:50] tbuehlmann: not everything, but well
[10:47:56] [k-: did you not believe?
[10:47:58] tbuehlmann: one can argue about 0^0
[10:48:09] marwinism: has joined #ruby
[10:48:11] Ray`: what's i^0?
[10:48:13] bubuntu: jhass is spreading missinformation on purpose
[10:48:18] leat: has joined #ruby
[10:48:25] jhass: what's 0 ** pi
[10:48:38] shevy: what kind of questions are you people asking there
[10:48:56] shevy: >> 0 ** Math::PI
[10:48:57] ruboto: shevy # => 0.0 (https://eval.in/427969)
[10:49:12] jhass: and 0 ** tau ?
[10:49:19] shevy: ohhh we are safe... I thought 0.0 is different from 0
[10:49:22] Ray`: I knew it, a tauist
[10:49:35] shevy: a more accurate version of 0!
[10:49:51] jhass: actually less accurate
[10:49:52] Ray`: nobody answered the i one, it's 11
[10:50:05] Ray`: ACTION curses his fingers
[10:50:17] jhass: 0 ** (10 ** 0) ?
[10:50:33] jhass: so what's 0 ** 0?
[10:50:36] shevy: you guys are using irb ...
[10:50:58] jhass: well, according to ruby
[10:51:05] Ray`: it should be zero
[10:51:08] jhass: but given the definitions for 0 ** x and x ** 0
[10:51:16] shevy: it's logical... nothing to the power of nothing is more than nothing
[10:51:17] Ray`: 10 ** 0 = 1
[10:51:25] Ray`: 0 to the power of 1 is itself, 0
[10:51:35] [k-: ah yes, my mistae
[10:51:48] Ray`: don't worry about it, I'm not particularly sharp today
[10:51:53] shevy: [k- are you typing on your smartphone again?
[10:52:11] Ray`: what's i^i?
[10:52:18] Ray`: (easy one)
[10:52:24] Ray`: or j^j if you're an engineer
[10:52:50] [k-: http://bloerp.de/code/tempel/tempel-des-codes.html
[10:52:55] jhass: we can ask ruby
[10:53:05] jhass: >> 1+1i ** 1+1i
[10:53:06] ruboto: jhass # => (1+2i) (https://eval.in/427984)
[10:53:20] jhass: >> 0+1i ** 0+1i
[10:53:21] ruboto: jhass # => (1+1i) (https://eval.in/427985)
[10:53:28] shevy: [k- god that is scary
[10:54:14] jhass: >> 1i ** 1i
[10:54:15] ruboto: jhass # => (0.20787957635076193+0.0i) (https://eval.in/427988)
[10:55:01] [k-: this means that you cant ** i
[10:55:21] jhass: yeah, guess the precedence rules go beserk for complex number literals
[10:55:24] Ray`: https://www.math.toronto.edu/mathnet/questionCorner/itothei.html there's the proof
[10:55:38] Ray`: it's more difficult to work with in ruby
[10:55:46] bruno-: has joined #ruby
[10:56:21] [spoiler]: Ray`: those rendered images of equations burn my delicate eyesight
[10:56:23] Ray`: filed under stuff that will make your head spin
[10:56:56] Ray`: haha it reminds me of when I first encountered the schrodinger equation and was like "what have I gotten myself into"
[10:57:20] [spoiler]: no, it's just that they look ugly on my screen
[10:57:41] Ray`: that too, I don't get why they did it that way
[10:57:49] [spoiler]: I'd have more success reading tex than that
[10:57:50] dhjondoh: has joined #ruby
[10:57:53] Ray`: looks like an old page though
[10:57:59] [spoiler]: yeah good point
[10:58:30] Spami: has joined #ruby
[10:58:47] astrobunny: has joined #ruby
[10:59:32] [k-: your face is a good point :D
[10:59:36] platzhirsch: has left #ruby: ()
[11:01:37] Igorshp: has joined #ruby
[11:01:45] Ray`: well, there goes my productivity, now I'm fixated on that proof
[11:03:05] bronson: has joined #ruby
[11:06:12] shevy: write some ruby project
[11:07:00] skade: has joined #ruby
[11:07:23] [k-: write some theorem prover
[11:09:22] Ray`: I think I'm done, paper and pencil put away, time to write some ruby
[11:09:55] [k-: (and a theorem prover)
[11:10:15] Oog: has joined #ruby
[11:10:30] Ray`: haha don't give me ideas!
[11:10:59] workmad3: [k-: theorem provers are fun
[11:11:45] [k-: Ray`: workmad3 said theorem provers are fun
[11:12:01] apeiros: but then you need a theorem prover prover
[11:12:18] Ray`: ACTION throws his copy of Godel, Escher Bach at [k- 
[11:12:23] [k-: we already have those
[11:12:24] jhass: make a theorem prover quine
[11:12:49] jhass: (don't tell me that's not how it works!)
[11:13:24] apeiros: that's not how it works, jhass
[11:13:52] apeiros: damit. ok. suffix nick in case of absent prefix nick will be added as "message.to"
[11:14:39] dionysus70: has joined #ruby
[11:14:50] jhass: but require the ',', I'd prefer the false negatives over the false positives
[11:15:35] apeiros: hm, I'll leave the requirement away but check after a month of logs or so
[11:15:56] fella5s: has joined #ruby
[11:16:30] allomov_: has joined #ruby
[11:17:19] apeiros: hurray for complex expressions???
[11:17:20] apeiros: extract_nick = /^[@<#]?(#{@connection.parser.expression.nick})[:,> ]|(?<=\A|[^A-Za-z\d\[\]\\`_^{|}-])(#{@connection.parser.expression.nick}) *[.?!]\z/n
[11:17:53] apeiros: could be worse.
[11:19:33] shevy: this code is trying to become alive
[11:19:34] apeiros: I guess I can drop the \A
[11:19:51] [k-: even i don't write regexps like that
[11:20:24] apeiros: [k-: and you haven't even *seen* the regex hiding in @connection.parser.expression.nick!
[11:20:48] [k-: https://gist.github.com/SkyBirdSoar/34399619083fe59356ff
[11:21:37] revoohc: has joined #ruby
[11:21:54] [k-: i should abstract my new regexps
[11:22:25] [k-: i only wanted to remove common things in the source file
[11:22:41] but3k4: has joined #ruby
[11:23:46] allomov: has joined #ruby
[11:25:07] juanpablo____: has joined #ruby
[11:25:23] sarkyniin: has joined #ruby
[11:25:33] platzhirsch: has joined #ruby
[11:25:46] chills42: has joined #ruby
[11:26:40] jgt: has joined #ruby
[11:28:11] meph: has joined #ruby
[11:29:44] sgambino: has joined #ruby
[11:29:50] ldnunes: has joined #ruby
[11:29:57] ebbflowgo: has joined #ruby
[11:31:29] timonv: has joined #ruby
[11:34:04] fgo: has joined #ruby
[11:34:30] sarkyniin: has joined #ruby
[11:35:31] jdawgaz: has joined #ruby
[11:36:30] sarkyniin: has joined #ruby
[11:36:50] [spoiler]: apeiros: that looks like headache
[11:37:40] [k-: i can somehow understand the part before |
[11:37:45] sigurding: has joined #ruby
[11:37:52] [k-: why the # though
[11:38:47] sdwrage: has joined #ruby
[11:38:52] [k-: apeiros: A-Za-z\d is just \w iirc
[11:38:56] nzst: has joined #ruby
[11:39:19] apeiros: \w also includes _
[11:39:30] [k-: but nicks have _
[11:39:36] [spoiler]: A-Za-z also doesn't include all those locale-specific thinfs
[11:39:39] apeiros: the # is because jhass said he got hashtagged in irc
[11:39:40] einarj: has joined #ruby
[11:39:43] [spoiler]: and the fancy letters
[11:39:48] [spoiler]: w/e those are called
[11:39:53] apeiros: [spoiler]: \w doesn't either
[11:39:59] apeiros: only in 1.8 with //u it did
[11:40:08] [spoiler]: apeiros: doesn't it include non-ascii letters?
[11:40:10] apeiros: in 1.9+ \w is always precisely A-Za-z0-9_
[11:40:28] apeiros: a good change IMO
[11:40:31] senayar: has joined #ruby
[11:40:36] [spoiler]: hmm. I am not sure if it is or isn't
[11:40:43] apeiros: \p{word} for the old \w in //u
[11:40:51] [k-: [^\w\[\]`\\^{|}-]
[11:40:55] [spoiler]: oh! they added that, that's cool
[11:41:04] apeiros: [spoiler]: as said, \w is NOT equivalent.
[11:41:05] [spoiler]: It's a good change then
[11:41:17] apeiros: [k-: : as said, \w is NOT equivalent.
[11:41:24] apeiros: (sorry [spoiler])
[11:41:44] [k-: you look like you are doing the equivalent
[11:41:44] [spoiler]: I figured you meant [k- haha
[11:41:53] [k-: in 1.9+?
[11:41:57] apeiros: [k-: again, "_"
[11:42:08] [spoiler]: apeiros: isn't _ allowed in nicks, tho?
[11:42:23] [k-: yes it s
[11:42:31] apeiros: ACTION puzzled
[11:42:44] [k-: ACTION slaps apeiros with a large trout
[11:43:01] apeiros: you're free!
[11:43:02] [k-: how many times did you *not* notice my trout :(
[11:43:09] [spoiler]: oh no, they snapped back up
[11:43:55] dgutierrez1287: has joined #ruby
[11:45:17] [spoiler]: [k- maybe apeiros ignores _, like some languages ignore it when used in arguments
[11:45:43] apeiros: [k-: I could actually simplify it even more
[11:45:49] khebbie: has joined #ruby
[11:45:53] [spoiler]: apeiros: .*
[11:46:01] apeiros: in a *valid* manner
[11:46:56] [spoiler]: what're you trying to extract the nick from, though?
[11:47:15] apeiros: [\-\d\x41-\x7d] == [A-Za-z\d\[\]\\`_^{|}-]
[11:47:20] syath: has joined #ruby
[11:47:27] benlovell: has joined #ruby
[11:47:34] apeiros: [spoiler]: everything you say. ruboto's logging mechanism.
[11:48:07] bubbys: has joined #ruby
[11:48:22] apeiros: maybe I left the regex as-is so it's closer to the BNF of the RFC. not sure.
[11:48:29] [k-: dont make it less expressive!
[11:48:48] [k-: Ox0dea is interested in a logging mechanism too
[11:48:53] [k-: perhaps work together?
[11:48:57] apeiros: anyway, I guess [\w\[\]\\`^{|}-] is an improvement over [A-Za-z\d\[\]\\`_^{|}-]
[11:49:00] skade: has joined #ruby
[11:49:12] moeabdol: has joined #ruby
[11:49:13] [k-: he is interested in logging relations between people iirc
[11:49:20] apeiros: ruboto does that
[11:49:29] apeiros: it logs threads
[11:49:45] apeiros: it's not fully implemented yet, though
[11:49:47] apeiros: message threads
[11:50:07] [spoiler]: how do you tag the beginning/end of a message thread, like from a logical perspective
[11:50:14] [k-: he wants something greppable nick->nick2
[11:50:24] husanu: has joined #ruby
[11:50:30] [k-: and he can get everything relating those people
[11:50:35] apeiros: [spoiler]: for 1-1 discussions it's easy - from first mention until mentioning somebody else
[11:50:50] apeiros: for n-n discussions it's more difficult
[11:51:01] [k-: we aren't supposed to ping people unnecessarily!
[11:51:26] [k-: maybe locate similar terms?
[11:51:46] [k-_: has joined #ruby
[11:52:49] [spoiler]: seems like it could be a bit wonky
[11:53:03] apeiros: quite possible
[11:53:27] apeiros: humans have little problems figuring that a message was directed at them from context, without name ping
[11:53:45] senayar: has joined #ruby
[11:53:55] apeiros: I'll see how well it works :)
[11:54:05] apeiros: I'll also consider temporal proximity
[11:54:14] shevy: you are so attractive
[11:54:24] apeiros: but I don't think I'll evaluate anything else besides that and mentions
[11:54:25] shevy: (let's see how many figure that this message was directed at them!)
[11:54:38] apeiros: shevy: everybody will think it was directed at them!
[11:54:49] benlovell: has joined #ruby
[11:55:35] [k-_: i thought it was directed at apeiros (1st pass)
[11:55:53] shevy: you are trying the flattery approach here [k-_ !
[11:56:01] shevy: oh... now I understand how plenking happens
[11:56:11] [k-_: or are you the one trying the flattery approach
[11:56:22] shevy: your face!!!
[11:56:28] [k-_: and it became undefined (2nd pass)
[11:56:46] [k-_: because shevy never says such nice things!
[11:57:05] shevy: I am in the process of being able to do something other than ruby soon
[11:57:19] shevy: *something else other than ruby, that is
[11:57:21] husanu: has joined #ruby
[11:57:31] wldcordeiro__: has joined #ruby
[11:57:48] Cust0sLim3n: has joined #ruby
[11:58:20] apeiros: shevy: you learn php?!?
[11:58:22] [k-_: like monads?
[11:58:50] shevy: I can't stand php anymore :(
[11:59:00] shevy: [k-_ I dunno
[11:59:14] apeiros: shevy: you code php while lying?
[11:59:18] shevy: I used haskell some years ago... I didn't hate it, didn't dislike it either... more like neutral
[11:59:35] shevy: nah, I tried to write php code again, my brain just flat out refuses
[11:59:36] apeiros: so you liked it?
[11:59:36] [k-_: you arent a maths person
[11:59:46] joonty: has joined #ruby
[11:59:48] apeiros: (didn't hate, didn't dislike???)
[11:59:51] [k-_: you do not see the elegance
[11:59:52] shevy: before I knew ruby
[11:59:53] vondruch: has joined #ruby
[12:00:26] shevy: [k-_ I dunno, haskell code can be elegant
[12:00:40] [spoiler]: I knew it wasn't directed at me :(
[12:00:50] nzst: has joined #ruby
[12:01:10] devoldmx: has joined #ruby
[12:01:22] [spoiler]: I am very proficient in writing good PHP, which is my dirtiest secret
[12:01:27] diego_ar: has joined #ruby
[12:01:30] [k-_: [spoiler]: this is the conversation x . (you are here)
[12:01:35] xrlabs: has joined #ruby
[12:01:52] [spoiler]: [k-_: ??_??
[12:02:27] shevy: I wouldn't know what to write in haskell though
[12:02:55] husanu: has joined #ruby
[12:03:53] wldcordeiro__: has joined #ruby
[12:04:58] wldcordeiro__: has joined #ruby
[12:07:38] Igorshp: has joined #ruby
[12:07:55] NeverDie: has joined #ruby
[12:08:16] failshell: has joined #ruby
[12:08:31] meatherly: has joined #ruby
[12:10:14] poli: has joined #ruby
[12:12:23] NeverDie: has joined #ruby
[12:12:59] sdothum: has joined #ruby
[12:16:04] leat: has joined #ruby
[12:16:46] sigurding: has joined #ruby
[12:17:27] allomov_: has joined #ruby
[12:20:08] michael_mbp: has joined #ruby
[12:21:09] atomical: has joined #ruby
[12:23:03] bmurt: has joined #ruby
[12:28:55] ruby-lang314: has joined #ruby
[12:29:23] RegulationD: has joined #ruby
[12:32:11] nzst: [spoiler]: just sounds like you know how to get your bills paid, re: php
[12:34:09] husanu: has joined #ruby
[12:34:35] CloCkWeRX: has joined #ruby
[12:34:38] [spoiler]: nzst: I am not a PHP devloper anymore, but I learned it in primary school and worked with it in highschool, then i discovered Ruby! I still keep up to date with PHP, because there's no point in dropping a language since I spent so much with it (but I am not a fan of PHP, never really was), and I work for a hosting company, PHP/shared hosting is the majority of our client
[12:35:12] fgo: has joined #ruby
[12:35:43] [spoiler]: I never even worked as a PHP developer :P
[12:35:44] rickmasta: has joined #ruby
[12:36:22] sepp2k: has joined #ruby
[12:36:27] shevy: the php millionaire!
[12:38:11] nzst: [spoiler]: have you seen https://github.com/facebook/hhvm/tree/master/hphp/hack?
[12:39:30] benlovell: has joined #ruby
[12:39:42] arup_r: has joined #ruby
[12:42:15] shevy: class Box<T> {
[12:42:18] shevy: so beautiful
[12:42:39] jhass: class Box(T)
[12:42:45] s2013: has joined #ruby
[12:43:20] [k-_: 29 lines to 12 lines!
[12:43:29] [k-_: i have sucessfully abstracted!
[12:43:35] jhass: bundle exec ruby -e "require 'serverspec'; p Serverspec::VERSION"
[12:43:41] jhass: ups, c&p fail
[12:43:45] jhass: https://github.com/manastech/crystal/blob/master/src/box.cr#L1
[12:44:13] codecop: has joined #ruby
[12:45:11] shevy: what does the T denote there?
[12:45:31] allcentury: has joined #ruby
[12:46:06] jhass: a generic
[12:46:07] aswen: has joined #ruby
[12:46:41] kfpratt: has joined #ruby
[12:46:51] timonv: has joined #ruby
[12:47:47] [spoiler]: nzst: I have, and I can't say I was excited when I heard about it lol
[12:48:53] vipaca: has joined #ruby
[12:49:14] leat: has joined #ruby
[12:50:40] solars: has joined #ruby
[12:50:45] Guest50: has joined #ruby
[12:51:22] [spoiler]: jhass: I am used to seeing <> from C++, so () looks odd to me, although I am not sure if it's just because I am used to <>
[12:51:50] jhass: it probably is :P
[12:52:39] jonnie: has joined #ruby
[12:53:23] fsapo: has joined #ruby
[12:53:27] s00pcan: has joined #ruby
[12:54:08] arup_r1: has joined #ruby
[12:55:35] allomov: has joined #ruby
[12:55:52] tsunamie: I am getting the following http://pastebin.com/kKPmMghZ after running chef exec bundle with a gemfile
[12:55:53] ruboto: tsunamie, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/1e600e97d183b98f0aca
[12:55:53] ruboto: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
[12:56:12] tsunamie: anyone know why I am getting this I get it's a conflict I just have no cliue on how to resolve the conflict
[12:57:24] davispuh: has joined #ruby
[12:58:17] Igorshp: has joined #ruby
[12:58:37] victortyau: has joined #ruby
[12:59:41] leat: has joined #ruby
[13:00:05] diego_ar: has joined #ruby
[13:00:30] jhass: it's bundle exec chef
[13:01:25] allomov_: has joined #ruby
[13:01:55] Guest94: has joined #ruby
[13:02:27] benlovell: has joined #ruby
[13:02:31] allcentury: Hi, is there something similar to Base64 that only uses alphanumeric characters?
[13:03:06] bffff_: has joined #ruby
[13:03:53] ahmetkapikiran: has joined #ruby
[13:04:01] jhass: there's base 36 though that spares uppercase
[13:06:20] chabil: has joined #ruby
[13:06:30] jhass: I guess doing base 52 wouldn't be too hard, just look at a base 36 algorithm and extend it
[13:08:11] rippa: has joined #ruby
[13:08:25] allcentury: TIL base52 is a thing, cheers jhass
[13:09:06] jhass: doing baseXX is basically a matter of defining the symbols
[13:09:44] allcentury: by symbols do you mean chars?
[13:09:44] jhass: there, somebody did a gem https://github.com/atomaka/base52
[13:09:47] bubuntu: why is base 52 a thing?
[13:09:52] jhass: why wouldn't it?
[13:09:56] tkuchiki: has joined #ruby
[13:10:01] jhass: why wouldn't base42 be a thing?
[13:10:06] allcentury: I'm looking at the gem as we speak, it's very simple implementation
[13:10:28] Jardayn: has joined #ruby
[13:10:51] sgambino: has joined #ruby
[13:11:04] allcentury: but wait .... if I have a string that is ab_cd and I base52 encode it, it will only encode the abcd chars, right?
[13:11:27] [spoiler]: allcentury: if _ is not a digit
[13:11:36] sarkyniin: has joined #ruby
[13:11:40] jhass: allcentury: base 2 uses the symbols 0 and 1, base 3 uses the symbols 0, 1 and 2, base 10 uses the symbols 012345678 and 9, base 16 (commonly referred to as hex) uses the symbols 0123456789abcde and f
[13:11:42] jhass: get the pattern?
[13:12:23] allcentury: perhaps I should back up and share the problem I'm trying to solve
[13:12:52] [k-_: base9000! it's over 9000!
[13:13:53] juanpablo____: has joined #ruby
[13:14:04] davedev24: has joined #ruby
[13:14:10] allcentury: I have a unique identifer on my end, call it a token that has base64 characters in it (ie abcd_234=gfsd) -- an API i'm trying to work with cannot accept any token that isn't strictly alphanumeric. I thought about encoding my token so it fits their crazy guideline but will allow me to decode when they send it back so I can figure out who's token this is
[13:14:42] herbst: has joined #ruby
[13:14:48] allcentury: am I going down the right back with this encode/decode idea?
[13:14:51] apeiros: you can have any base you want. you just need enough digits.
[13:14:59] allcentury: the right path*
[13:15:31] jhass: decode it to bytes and just hex encode them
[13:15:39] jhass: will be long as fuck but whatever
[13:15:45] shadeslayer: has joined #ruby
[13:15:52] allomov: has joined #ruby
[13:16:11] sdwrage: has joined #ruby
[13:17:26] whippythellama: has joined #ruby
[13:19:10] qwertme: has joined #ruby
[13:19:14] apeiros: if length is a problem, base32 might be a middle ground. 2x as long instead of 4x.
[13:19:49] dcarmich: has joined #ruby
[13:20:39] ndrei: has joined #ruby
[13:21:20] khebbie: has joined #ruby
[13:21:52] apeiros: uh, wait??? actually a value in base16 is only 2x as long as in base256
[13:22:59] apeiros: correct factors: base16 is 1.5x longer than base64, base32 is 1.2x longer
[13:23:47] dblessing: has joined #ruby
[13:23:49] Igorshp: has joined #ruby
[13:24:54] voker57: has joined #ruby
[13:25:07] Lyhue: has joined #ruby
[13:25:15] allcentury: something like... this? str.each_byte.map { |b| b.to_s(16) }.join
[13:25:42] allcentury: converts "YWJjZGVmZw==_" => "59574a6a5a47566d5a773d3d5f"
[13:25:54] allcentury: now how do I go back in the other direction?
[13:26:54] miliarch: has joined #ruby
[13:27:23] allcentury: oh I got it hex.scan(/../).map { |x| x.hex.chr }.join
[13:27:35] jhass: to_s(16) doesn't 0 pad
[13:27:58] allcentury: is that an issue?
[13:28:16] [spoiler]: alignment issues
[13:28:26] [spoiler]: what if you get "fab"
[13:28:35] apeiros: allcentury: Base64.decode64(str).unpack("H*").first
[13:28:40] allcentury: quit trying to make fab happen, it's never going to happen.
[13:28:52] fairyeye: has joined #ruby
[13:29:11] apeiros: >> require 'base64'; str = Base64.encode64("hello"); Base64.decode64(str).unpack("H*").first
[13:29:13] ruboto: apeiros # => "68656c6c6f" (https://eval.in/428144)
[13:29:42] apeiros: and the reverse:
[13:29:51] apeiros: >> ["68656c6c6f"].pack("H*")
[13:29:52] ruboto: apeiros # => "hello" (https://eval.in/428145)
[13:29:54] [spoiler]: pack it in yo panrs
[13:29:56] jhass: I kinda feel like pack and unpack act backwards there
[13:30:10] [spoiler]: jhass: yes the nomenclature is weird lol
[13:30:12] jonnie: has joined #ruby
[13:30:12] [spoiler]: in this case
[13:30:14] apeiros: jhass: yeah, with hex it sometimes feels odd
[13:30:26] tmtwd: has joined #ruby
[13:30:47] jhass: I mean API wise it makes more sense the other way around
[13:30:49] Criten: has left #ruby: ()
[13:31:00] jhass: *even API wise
[13:31:27] allcentury: apeiros: so in my example, I'd decode there to stay alphanumeric and encode when they send it back to me?
[13:31:37] [spoiler]: not really, since you're unpacking a string, and then packing it again, but it only makes sense because of the context here
[13:32:04] [spoiler]: unpacking a string into more complex data, I mean
[13:32:07] fairyeye: has left #ruby: ()
[13:32:12] tkuchiki: has joined #ruby
[13:32:16] [spoiler]: s/complex/strctured
[13:32:23] [spoiler]: fuck I can't pyte
[13:32:35] [spoiler]: ugh mu shift is over I am going home
[13:32:38] [spoiler]: stupid keyboard
[13:32:38] linuxboytoo: has joined #ruby
[13:32:48] jhass: allcentury: play with the examples in pry, it'll become obvious
[13:36:11] fgo: has joined #ruby
[13:37:57] jgt: has joined #ruby
[13:40:08] davedev24: has joined #ruby
[13:40:51] roxtrongo: has joined #ruby
[13:41:41] atomical: has joined #ruby
[13:43:39] Marsupermammal: has joined #ruby
[13:46:11] silkfox: has joined #ruby
[13:46:11] Scripore: has joined #ruby
[13:47:26] kfpratt: has joined #ruby
[13:50:07] leat: has joined #ruby
[13:50:23] Papabear: has joined #ruby
[13:52:20] kjones_: has joined #ruby
[13:52:35] fairyeye: has joined #ruby
[13:53:07] bigredboots: has joined #ruby
[13:54:53] iamninja: has joined #ruby
[13:55:52] omegahm: has joined #ruby
[13:56:02] fairyeye: has left #ruby: ()
[13:56:21] casadei_: has joined #ruby
[13:56:38] mahmoudmahfouz: has joined #ruby
[13:57:43] rbennacer: has joined #ruby
[13:57:53] vipaca: has joined #ruby
[13:58:04] rbennacer: has joined #ruby
[13:58:06] porfa: has joined #ruby
[14:01:29] failshell: has joined #ruby
[14:01:56] devoldmx: has joined #ruby
[14:02:13] altivection: has joined #ruby
[14:03:57] jobewan: has joined #ruby
[14:04:22] fsapo: has left #ruby: ()
[14:05:55] dgutierrez1287: has joined #ruby
[14:07:32] ndrei: has joined #ruby
[14:08:21] benlovell: has joined #ruby
[14:09:38] qwertme: has joined #ruby
[14:09:48] ahmetkapikiran: has joined #ruby
[14:09:54] griffindy: has joined #ruby
[14:10:05] paulcsmith: has joined #ruby
[14:10:35] leat: has joined #ruby
[14:13:17] havenwood: has joined #ruby
[14:14:03] Timba-as_: has joined #ruby
[14:14:36] juanpablo____: has joined #ruby
[14:16:12] duggiefresh: has joined #ruby
[14:16:16] RegulationD: has joined #ruby
[14:17:16] tjohnson: has joined #ruby
[14:18:24] Gnomethrower: has joined #ruby
[14:18:53] Gnomethrower: has joined #ruby
[14:19:53] meatherly: has joined #ruby
[14:22:36] dopamean_: has joined #ruby
[14:23:07] freerobby: has joined #ruby
[14:24:15] shapeshifter: has joined #ruby
[14:24:27] minimuffins: has joined #ruby
[14:25:36] juanpablo____: has joined #ruby
[14:25:40] naftilos76: has joined #ruby
[14:26:26] dionysus69: has joined #ruby
[14:26:39] shapeshifter: Hi. I'm trying to deploy spree using capistrano with rvm1-capistrano3. Problem is when cap tries to run rvm-auto.sh . bundle exec gem install --file Gemfile, I get two errors "ruby-2.2.3 is not installed". But if I su to the server user and do ~/.rvm/bin/rvm default do ruby --version, then it's working fine. I think the difference is that with a login, .bashrc gets sourced.
[14:26:59] shapeshifter: And I've seen people put a source ... in config/deploy.rb just for this. But that seems awful.
[14:27:41] shapeshifter: How /should/ capistrano know which ruby to use when using rvm, normally, and why isn't in working for me?
[14:28:05] grotewold: has joined #ruby
[14:30:16] enebo: has joined #ruby
[14:31:35] sarkyniin: has joined #ruby
[14:32:02] kies: has joined #ruby
[14:32:18] Ropeney: has joined #ruby
[14:32:45] yqt: has joined #ruby
[14:33:41] yqt: has joined #ruby
[14:34:44] dionysus69: has joined #ruby
[14:35:51] chills42: has joined #ruby
[14:36:03] cornerma1: has joined #ruby
[14:37:17] fgo: has joined #ruby
[14:39:01] jdawgaz: has joined #ruby
[14:40:44] leat: has joined #ruby
[14:40:54] seydar: has joined #ruby
[14:40:56] greenarrow: has joined #ruby
[14:41:44] diegoaguilar: has joined #ruby
[14:41:49] mallu: has joined #ruby
[14:41:58] tenderlove: has joined #ruby
[14:42:54] stryek: has joined #ruby
[14:42:54] finisherr: has joined #ruby
[14:44:46] da3mian: has joined #ruby
[14:46:17] mary5030: has joined #ruby
[14:46:26] ahmetkapikiran: has joined #ruby
[14:47:03] mary5030: has joined #ruby
[14:48:08] avdi: I'm taking a poll (out of sheer curiosity) of what Ruby HTTP client library people prefer: http://devblog.avdi.org/2015/09/04/poll-whats-your-favorite-ruby-http-client-library/
[14:49:03] Lyhue: has joined #ruby
[14:49:04] yorickpeterse: avdi: no multiple-choice? :<
[14:49:25] havenwood: avdi: I've narrowed it down to five. Hem...
[14:49:49] avdi: yorickpeterse: I'm keeping it simple - really just looking for the one people immediately go to when all else is equal
[14:50:09] yorickpeterse: hm, seems a lot of people httparty hard
[14:50:13] yorickpeterse: "lot" as in 10
[14:50:42] mdst: has joined #ruby
[14:50:55] yorickpeterse: honestly at this point I think they're just keeping that post install message to further torment people
[14:51:18] alqahtani: has joined #ruby
[14:51:23] havenwood: yorickpeterse: haha
[14:51:26] yorickpeterse: maybe bundler should add "When you BUNDLED WITH, you BUNDLED WITH hard"
[14:51:35] ksteck: has joined #ruby
[14:51:45] yorickpeterse: that might be too soon though
[14:52:03] balazs: has joined #ruby
[14:52:28] jhass: luckily bundler can suppress these now
[14:52:42] kies: has joined #ruby
[14:52:55] mleung: has joined #ruby
[14:53:00] havenwood: Tough choice, rolled the dice.
[14:53:35] sarkyniin: has joined #ruby
[14:54:11] jgpawletko: has joined #ruby
[14:54:52] umgrosscol: has joined #ruby
[14:55:57] havenwood: Free RubyMotion starter downloaded! :D
[14:56:25] anisha: has joined #ruby
[14:56:32] grotewold: has joined #ruby
[14:56:32] dfockler: has joined #ruby
[14:57:02] havenwood: http://www.rubymotion.com/news/2015/09/03/announcing-rubymotion-4-0-free-cross-platform-games-watchos-2-0.html
[14:58:03] havenwood: A new free starter edition ust in time for a long weekend here.
[14:58:27] grotewold: has joined #ruby
[14:59:34] AlexRussia: has joined #ruby
[15:00:04] claw: has joined #ruby
[15:00:05] luckyme: has joined #ruby
[15:00:49] grotewold: has joined #ruby
[15:01:25] kfpratt: has joined #ruby
[15:02:10] dfinninger: has joined #ruby
[15:02:15] dmolina: has joined #ruby
[15:03:17] Averna: has joined #ruby
[15:03:21] grotewold: has joined #ruby
[15:04:35] enebo: has joined #ruby
[15:04:37] bronson: has joined #ruby
[15:05:25] cschneid_: has joined #ruby
[15:07:01] aaeron: has joined #ruby
[15:07:55] s2013: has joined #ruby
[15:08:13] sagittarian: has joined #ruby
[15:08:48] aaeron1: has joined #ruby
[15:08:54] sigurding: has joined #ruby
[15:10:14] Queeniebee: has joined #ruby
[15:10:21] NeverDie: has joined #ruby
[15:10:35] dorei: has joined #ruby
[15:10:36] Guest50: has joined #ruby
[15:11:50] jas02: has joined #ruby
[15:12:00] Meow-J: has joined #ruby
[15:12:55] jas02: has left #ruby: ()
[15:13:16] qwertme: has joined #ruby
[15:13:31] baroquebobcat: has joined #ruby
[15:13:38] DanielI: has joined #ruby
[15:13:54] shmilan: has joined #ruby
[15:17:42] weemsledeux: has joined #ruby
[15:18:09] hinbody: has joined #ruby
[15:19:39] prestorium: has joined #ruby
[15:20:14] UtkarshRay: has joined #ruby
[15:22:54] khebbie: has joined #ruby
[15:27:54] rocknrollMarc: has joined #ruby
[15:29:43] _blizzy_: has joined #ruby
[15:29:48] DanielI: has joined #ruby
[15:31:13] aaeron: has joined #ruby
[15:32:16] riotjones: has joined #ruby
[15:33:10] lorn: has joined #ruby
[15:33:47] Rubie: has joined #ruby
[15:36:23] Lyhue: has joined #ruby
[15:36:46] nzst: If I have a range that looks like this, http://hastebin.com/ovamozukol.css , can i enumerate each day?
[15:38:04] _blizzy_: has joined #ruby
[15:38:06] ddarkpassenger: has joined #ruby
[15:38:11] Yzguy: has joined #ruby
[15:38:28] fgo: has joined #ruby
[15:39:00] xrlabs: has joined #ruby
[15:40:08] nzst: "TypeError: can't iterate from ActiveSupport::TimeWithZone" but i'd like to by day
[15:40:38] Swappticon: has joined #ruby
[15:40:42] balazs: has joined #ruby
[15:41:17] leat: has joined #ruby
[15:42:13] shapeshifter: has left #ruby: ()
[15:42:25] arooni-mobile: has joined #ruby
[15:43:53] rcvalle: has joined #ruby
[15:44:08] prestorium: has joined #ruby
[15:46:36] dfockler: nzst: http://stackoverflow.com/questions/19093487/ruby-create-range-of-dates
[15:47:30] nzst: dfockler: thanks :) that looks promising
[15:47:44] dfockler: nzst: yep, come back if that doesn't work
[15:49:04] snockerton: has joined #ruby
[15:49:09] cpruitt: has joined #ruby
[15:49:27] jdawgaz: has joined #ruby
[15:50:24] grotewold: has joined #ruby
[15:52:39] nzst: got this suggestiong from #rubyonrails ( your_range.begin.to_date .. your_range.end.to_date ).each ...
[15:52:44] grotewold: has joined #ruby
[15:52:45] nzst: it worked right away
[15:53:22] dfockler: nzst: nice!
[15:54:17] rehat: has joined #ruby
[15:55:04] grotewold: has joined #ruby
[15:56:19] yosafbridge: has joined #ruby
[15:56:39] bruno-: has joined #ruby
[15:57:31] grotewold: has joined #ruby
[15:57:50] towski_: has joined #ruby
[15:59:09] krz: has joined #ruby
[15:59:56] platzhirsch: has joined #ruby
[16:01:32] benjwadams: has joined #ruby
[16:01:45] benjwadams: question regarding ancient (1.8.6) ruby versions
[16:01:45] symm-: has joined #ruby
[16:02:16] benjwadams: Time.parse('wtfbbq') returns the current datetime. is there any way to throw an exception instead?
[16:02:30] amclain: has joined #ruby
[16:02:41] dfinninger: has joined #ruby
[16:02:42] devoldmx: has joined #ruby
[16:03:12] benjwadams: Is there any method I could use in that old a version to properly parse the time?
[16:03:52] jhass: are you studying archaeology or something?
[16:04:52] Guest50: has joined #ruby
[16:05:05] benjwadams: please tell my PM and client to maintain their versions and not leave us with legacy cruft
[16:05:15] kies: has joined #ruby
[16:05:26] nzst: lol, ya, tell my PM and client that too
[16:05:31] tenderlove: has joined #ruby
[16:05:45] jhass: mmh, maybe we should do do #ruby-history or something where we redirect all questions involving Ruby versions outside their security maintenance phase
[16:06:03] milesforrest: has joined #ruby
[16:06:03] benjwadams: I found out an answer to my question anyhow
[16:06:35] CHVNX: has joined #ruby
[16:06:41] paulcsmith: has joined #ruby
[16:06:59] nzst: what is it?
[16:07:23] Sou|cutter: nzst: I was bored https://gist.github.com/soulcutter/72f6843ed6785c4dd582
[16:07:23] benjwadams: Time.parse('wtfbbq', nil) will throw an exception instead of returning the current time!
[16:08:03] nzst: hah, Sou|cutter thanks, that's some slick code i'll have to learn something from it
[16:08:49] eggoez: has joined #ruby
[16:08:49] Joufflu: has joined #ruby
[16:09:27] weemsledeux: has joined #ruby
[16:10:42] tenderlove: has joined #ruby
[16:10:43] mikecmpbll: has joined #ruby
[16:10:52] luckyme: has joined #ruby
[16:11:42] khebbie: has joined #ruby
[16:11:49] bluOxigen: has joined #ruby
[16:12:41] enebo: has joined #ruby
[16:12:48] Sou|cutter: it's actually off by one, woops
[16:13:21] nzst: yes, i was testing it, it misses the expected day range begins and day range ends
[16:13:55] theery: has joined #ruby
[16:14:07] failshell: has joined #ruby
[16:15:07] Guest50: has joined #ruby
[16:16:01] Sou|cutter: it should get the end
[16:16:39] Sou|cutter: actually I guess not if the end is not equal to day increments
[16:16:52] arup_r: has joined #ruby
[16:17:22] tenderlove: has joined #ruby
[16:17:22] ruby-lang667: has joined #ruby
[16:18:09] snockerton: has joined #ruby
[16:18:17] Jackneill: has joined #ruby
[16:18:50] ruby-lang667: Hey I have a quick question, how can I get this function to do what I want?
[16:19:01] ruby-lang667: a = ["hi", "bye"]
[16:19:05] ruby-lang667: name = "John"
[16:19:10] ruby-lang667: city = "Edinborough"
[16:19:15] ruby-lang667: a.each do |word|
[16:19:19] ruby-lang667: puts "#{word} #{name} of #{city}"
[16:19:43] ruby-lang667: Anonymous function, can't get it to accept the variables it needs...
[16:20:28] bougyman: well, there's no function nor method there.
[16:20:58] ruby-lang667: so... a.each do |word|(name)
[16:21:03] ruby-lang667: that works, but only so far
[16:21:09] ruby-lang667: can't get both variables in
[16:21:45] shevy: upload your full code?
[16:21:45] SCHAAP137: has joined #ruby
[16:23:01] ruby-lang667: https://gist.github.com/anonymous/9c61a0d2afe4e1effa81
[16:25:25] shevy: well that works
[16:25:49] Maletor: has joined #ruby
[16:25:54] vipaca: has joined #ruby
[16:26:23] bougyman: def greet(greeting, name, city); puts "#{greeting} #{name} of #{city}"; end; greets = %w(hi bye); people = [%w(john amsterdam), %w(peter chicago)]; greets.each { |greeting| people.each { |person| greet(greeting, *person) } }
[16:26:30] bougyman: I think you are looking for something more along those lines.
[16:27:08] Igorshp: has joined #ruby
[16:28:02] ruby-lang667: ok sorry that was a bad example. I'm coding this as an internal company project, so I can't actually use the real data.
[16:28:08] grotewold: has joined #ruby
[16:28:57] Maletor: has joined #ruby
[16:29:21] ruby-lang667: but that gave me an idea, I'll try it out and post here if I find a fix
[16:29:53] shmilan: has joined #ruby
[16:32:15] failshell: has joined #ruby
[16:34:22] Guest50: has joined #ruby
[16:35:51] ngscheurich: has joined #ruby
[16:38:42] aaeron: has joined #ruby
[16:39:37] fgo: has joined #ruby
[16:40:46] paulcsmith: has joined #ruby
[16:41:40] ahmetkapikiran: has joined #ruby
[16:42:22] Kedare: has joined #ruby
[16:45:43] sarkyniin: has joined #ruby
[16:46:39] last_staff: has joined #ruby
[16:47:17] The_Phoenix: has joined #ruby
[16:49:35] qwertme: has joined #ruby
[16:49:41] moahny: has joined #ruby
[16:52:20] silkfox: has joined #ruby
[16:52:30] swills: has joined #ruby
[16:52:34] benjwadams: has left #ruby: ("WeeChat 0.4.2")
[16:53:55] aaeron1: has joined #ruby
[16:54:01] pawnbox: has joined #ruby
[16:55:14] dfockler: has joined #ruby
[16:55:24] blackmesa: has joined #ruby
[16:56:49] nanoz: has joined #ruby
[16:57:31] craysiii: has joined #ruby
[16:59:29] aswen: has joined #ruby
[17:01:11] aaeron: has joined #ruby
[17:02:08] hackedwin: has joined #ruby
[17:05:18] bigredboots: has joined #ruby
[17:05:55] rbennacer: has joined #ruby
[17:07:14] petricore: has joined #ruby
[17:08:22] Musashi007: has joined #ruby
[17:10:51] jbw: has joined #ruby
[17:11:08] sigurding: has joined #ruby
[17:11:50] nzst: has joined #ruby
[17:12:08] dgutierrez1287: has joined #ruby
[17:12:33] rakm: has joined #ruby
[17:13:22] Limix: has joined #ruby
[17:15:35] doc|work: has joined #ruby
[17:18:01] doc|work: hey, I'm getting "unbalanced brackets" as an error with haml when I use %input{:name => "FooUID", :value => "abc{efg", :type => "hidden"}. I've tried \ before the { to escape it but there's no change. Anyone know what I should do? Searching found nothing that matches.
[17:18:34] praveen__: has joined #ruby
[17:18:42] tobiasvl: doc|work: hm. try using single quotes around 'abc{efg' ?
[17:18:51] gp5st: has joined #ruby
[17:18:59] gp5st: I have a file where each line is a json-formatted array and the first line is a list of the string headers and each subsequent line is a value in this table. is there name for that style of format?
[17:19:25] doc|work: tobiasvl: no change
[17:20:12] jhass: gp5st: can we call it ITDJO? "I'm too dumb for JSON objects"?
[17:20:41] gp5st: jhass: :-p
[17:20:48] jhass: gp5st: or are there actually no [] and it's just CSV?
[17:20:56] roelof: has joined #ruby
[17:21:02] nofxx: has joined #ruby
[17:21:23] roelof: Is there a good free online course to learn ruby ?
[17:21:28] gp5st: jhass: oh no, it's actuall json-per-line
[17:21:44] gp5st: roelof: many. what have you looked at?
[17:21:48] roelof: And second question : what is a good web framework except rails ?
[17:21:58] gp5st: jhass: I didn't create the file. a coworker received it from some api and she was wondering if there was a common way to manipulate it, and I told her I wasn't sure and I wasn
[17:22:05] gp5st: 't even sure what it was called
[17:22:16] roelof: gp5st: codeacademy, codeschool
[17:22:19] gp5st: roelof: depends on what you want it to do. There are things like sinatra
[17:22:22] jhass: yeah me neither, sorry for not being helpful
[17:22:27] shmilan: has joined #ruby
[17:22:44] jhass: roelof: https://www.ruby-toolbox.com/categories/web_app_frameworks
[17:22:47] ruboto: http://ruby-community.com/pages/links
[17:22:53] roelof: make ecommerce site and maybe a accounting system for myself
[17:22:59] khebbie: has joined #ruby
[17:23:52] podman: has joined #ruby
[17:24:59] eightfold: has joined #ruby
[17:25:48] A124: has joined #ruby
[17:26:17] barhum2013: has joined #ruby
[17:27:42] minimuffins: has joined #ruby
[17:28:07] shevy: doc|work not sure many people here use haml
[17:28:18] doc|work: ok, thanks :/
[17:30:16] jhass: doc|work: just another guess, but \{ ?
[17:30:35] rakm: has joined #ruby
[17:31:48] doc|work: jhass: nope, but {\} fixes the error while displaying {} in the form
[17:31:52] doc|work: ACTION face palms
[17:32:00] voker57: has joined #ruby
[17:32:58] angrywombat: has joined #ruby
[17:33:54] based_pdev: has joined #ruby
[17:34:47] postmodern: has joined #ruby
[17:36:05] havenwood: has joined #ruby
[17:37:22] angrywombat: has left #ruby: ()
[17:37:34] roelof: jhasss in the list a lot of inactive projects :(
[17:38:07] jhass: roelof: just ignore them?
[17:38:13] porfa: has joined #ruby
[17:38:25] allcentury: has joined #ruby
[17:38:53] Guest50: has joined #ruby
[17:40:42] fgo: has joined #ruby
[17:42:30] Pupeno: has joined #ruby
[17:43:31] failshell: has joined #ruby
[17:43:49] krz: has joined #ruby
[17:44:06] aaeron: has joined #ruby
[17:44:39] krisquigley: has joined #ruby
[17:44:56] havenn: has joined #ruby
[17:45:39] _djbkd: has joined #ruby
[17:45:57] RegulationD: has joined #ruby
[17:48:16] ivanskie: has joined #ruby
[17:48:23] acke: has joined #ruby
[17:49:05] RegulationD: has joined #ruby
[17:49:22] charliesome: has joined #ruby
[17:49:34] psye: has joined #ruby
[17:50:04] baweaver: has joined #ruby
[17:50:20] shevy: resurrect them!
[17:50:27] shevy: inactive projects want to become active ones again
[17:51:03] psye: has joined #ruby
[17:51:25] wldcordeiro: has joined #ruby
[17:52:07] paulcsmith_: has joined #ruby
[17:52:08] pawnbox_: has joined #ruby
[17:53:40] apt-get_: has joined #ruby
[17:54:18] aswen: has joined #ruby
[17:54:43] bootstrappm: has joined #ruby
[17:56:03] shmilan: has joined #ruby
[17:57:21] zendrix: has joined #ruby
[17:57:51] theta8: has joined #ruby
[17:58:09] tkuchiki: has joined #ruby
[17:58:26] linuxboytoo: has joined #ruby
[17:59:34] khebbie: has joined #ruby
[17:59:46] theta8: im using rexml to build an array from xml elements, is there a way to grab child elements in a single iteration over a parent?
[18:00:55] acke: has joined #ruby
[18:01:47] theta8: say <device> is the parent of both <item> and <type>
[18:02:21] pawnbox: has joined #ruby
[18:02:25] swgillespie: has joined #ruby
[18:02:41] davispuh: has joined #ruby
[18:03:27] devoldmx: has joined #ruby
[18:05:08] mary5030: has joined #ruby
[18:05:27] djbkd_: has joined #ruby
[18:05:53] mary5030: has joined #ruby
[18:06:01] beef-wellington: has joined #ruby
[18:06:15] scottschecter: has joined #ruby
[18:08:30] Scripore: has joined #ruby
[18:10:11] diegoaguilar: has joined #ruby
[18:10:51] luckyme: has joined #ruby
[18:11:18] IrishGringo: has joined #ruby
[18:12:02] grotewold: has joined #ruby
[18:12:05] Guest50: has joined #ruby
[18:13:32] rbennacer: has joined #ruby
[18:14:22] grotewold: has joined #ruby
[18:16:34] paulcsmith_: has joined #ruby
[18:16:58] kirun: has joined #ruby
[18:21:40] Senjai: has joined #ruby
[18:21:55] baweaver: has joined #ruby
[18:23:40] mandarinkin: has joined #ruby
[18:24:53] prestorium: has joined #ruby
[18:25:41] leafybasil: has joined #ruby
[18:26:04] snockerton: has joined #ruby
[18:26:12] workmad3: has joined #ruby
[18:27:31] hinbody: has joined #ruby
[18:27:43] eightfold: has joined #ruby
[18:29:04] garethrees: has joined #ruby
[18:29:24] EXID123: has joined #ruby
[18:29:41] bronson: has joined #ruby
[18:29:51] Gribo: has joined #ruby
[18:31:43] arup_r: As I was saying in evening what leading underscore means ? Look here _rescue and @_env (http://blog.ragnarson.com/2015/08/28/extending-objects-behavior-with-module-prepend.html)
[18:31:56] arup_r: Why they wrote it like that ?
[18:32:31] djbkd: has joined #ruby
[18:33:28] djbkd: has joined #ruby
[18:33:38] drbrain: arup_r: `rescue` is a keyword, so you can't make a method with that name
[18:33:45] greenbigfrog: anyone experience with shoes? please pm me! (not the things you put on your shoes)
[18:33:55] craysiii: you put shoes on your shoes?
[18:34:07] drbrain: you put laces on shoes
[18:34:11] eam: drbrain: I mean, you can make one
[18:34:19] eam: it's just a little harder to call it
[18:34:22] greenbigfrog: ACTION should concentrate more
[18:34:35] Encapsulation: has joined #ruby
[18:34:49] greenbigfrog: anyone experience with shoes? please pm me! (not what you put on your feet)
[18:35:01] drbrain: greenbigfrog: o_O
[18:35:02] bougyman: I wear shoes
[18:35:11] drbrain: greenbigfrog: do you have some question about shoes?
[18:35:30] jordanloky: has joined #ruby
[18:35:50] greenbigfrog: https://gist.github.com/green-big-frog/8a821820a3615db589d9
[18:35:50] greenbigfrog: Basically wrote everything in there
[18:35:54] drbrain: arup_r: I guess they use @_env because they're subclassing something else that defines its own @env and they don't want to collide
[18:35:56] arup_r: Well.. I saw some other code also they used `_*`, but those are not reserve method or keywords
[18:36:50] drbrain: arup_r: `_*`?
[18:37:33] platzhirsch: has left #ruby: ()
[18:37:39] drbrain: sometimes people use a leading _ to indicate the argument or variable is unused
[18:37:41] toretore: has joined #ruby
[18:37:52] drbrain: (for a second I thought you meant literal _)
[18:38:05] drbrain: or they use _ to indicate that it is "special" some way
[18:38:17] Chau: has joined #ruby
[18:38:24] Swappticon: has joined #ruby
[18:39:31] kies: has joined #ruby
[18:40:43] arup_r: drbrain: thank you very much!
[18:41:18] grenierm: has joined #ruby
[18:41:47] fgo: has joined #ruby
[18:43:07] futilegames: has joined #ruby
[18:45:37] IrishGringo: has joined #ruby
[18:46:21] casadei_: has joined #ruby
[18:48:19] pawnbox: has joined #ruby
[18:48:44] praveen__: has joined #ruby
[18:49:29] djbkd: has joined #ruby
[18:50:09] chouhoulis: has joined #ruby
[18:50:43] dfinninger: has joined #ruby
[18:51:45] majjoha: has joined #ruby
[18:52:44] Renich: has joined #ruby
[18:53:11] hackedwin: has left #ruby: ("ERC Version 5.3 (IRC client for Emacs)")
[18:53:41] paulcsmith__: has joined #ruby
[18:55:24] Swappticon: has joined #ruby
[18:55:26] clarkenciel: has joined #ruby
[18:58:08] flak: has joined #ruby
[18:58:20] praveen__: has joined #ruby
[18:59:22] d10n-work: has joined #ruby
[18:59:40] mandarinkin: hi, i want download html and run js, what tool do you recommend to run js locally? selenium or something better
[19:00:09] michael_mbp: has joined #ruby
[19:00:16] flak: quick question: if I have an array of arrays (tuples) like so: [[1,2], [3,4]], is there a way to unpack the tuples in the arguments of a map operation? Like so: tuples.map { |first, *center, last| first + last }, but with cleaner syntax (no *center)?
[19:00:43] Guest50: has joined #ruby
[19:01:30] qwertme: has joined #ruby
[19:02:09] Papierkorb: flak: tuples.map{|(left, right)| ..}
[19:02:39] Papierkorb: flak: The (..) destructures the array, much like foo, bar = an_array does :)
[19:02:46] flak: :facepalm: I thought I would need some kind of unpacking operator
[19:05:26] ellisTAA: has joined #ruby
[19:05:37] futilegames_: has joined #ruby
[19:06:24] minimuffins: has joined #ruby
[19:07:08] kies: has joined #ruby
[19:07:24] jimbeaudoin: has joined #ruby
[19:07:28] flak: mandarinkin: are you looking for something scriptable? I've been using CasperJS+PhantomJS for some testing
[19:08:51] Fezzler: has joined #ruby
[19:09:52] blackmesa: has joined #ruby
[19:10:28] Renich: has joined #ruby
[19:11:12] grenierm: has joined #ruby
[19:11:36] leat: has joined #ruby
[19:12:41] grotewold: has joined #ruby
[19:15:11] jordanloky: has joined #ruby
[19:15:36] gambl0re: has joined #ruby
[19:15:39] Scripore: has joined #ruby
[19:16:43] enebo: has joined #ruby
[19:18:39] Renich: has joined #ruby
[19:18:53] barhum2013: has joined #ruby
[19:20:40] DoubleMalt: has joined #ruby
[19:20:42] astrobunny: has joined #ruby
[19:20:49] tcdowney: has joined #ruby
[19:24:22] baweaver: has joined #ruby
[19:25:02] astrobun_: has joined #ruby
[19:25:48] krisquigley: has joined #ruby
[19:26:45] uber: has joined #ruby
[19:28:51] rdavila: has joined #ruby
[19:29:35] failshell: has joined #ruby
[19:29:48] yfeldblum: has joined #ruby
[19:30:00] Queeniebee: Hi, I'm getting a syntax error, "unexpected keyword_end" on the last line of the Class. I can't see the error, however. What am I doing wrong that is raising the error? https://gist.github.com/Queeniebee/df01e7832231080f7789
[19:30:42] blackmesa: has joined #ruby
[19:31:16] davedev24: has joined #ruby
[19:32:49] chrissonar: has joined #ruby
[19:32:58] tkuchiki: has joined #ruby
[19:33:06] Queeniebee: based_pdev do you mean line 22?
[19:33:43] aswen: has joined #ruby
[19:33:47] stamina: has joined #ruby
[19:33:50] eam: Queeniebee: try running your code through something to auto-format it
[19:34:07] rbennacer: has joined #ruby
[19:35:16] riskish: has joined #ruby
[19:35:23] Queeniebee: eam doing that now
[19:38:41] Guest50: has joined #ruby
[19:39:23] bruno-: has joined #ruby
[19:39:35] porfa: has joined #ruby
[19:40:01] ordepdev: has joined #ruby
[19:40:33] gambl0re: has joined #ruby
[19:42:55] fgo: has joined #ruby
[19:43:03] ringarin: has joined #ruby
[19:43:06] Pupeno: has joined #ruby
[19:43:09] havenwood: has joined #ruby
[19:43:09] Queeniebee: I'm still getting the same error https://gist.github.com/Queeniebee/df01e7832231080f7789 after formatting
[19:44:40] blue_deref: has joined #ruby
[19:45:31] Lyhue: has joined #ruby
[19:45:31] ringarin: has joined #ruby
[19:45:39] jonnie: has joined #ruby
[19:46:36] jfe__: has joined #ruby
[19:46:46] jfe__: has left #ruby: ("Leaving")
[19:47:54] Oka: has joined #ruby
[19:50:36] baweaver: has joined #ruby
[19:52:00] ReK2: has joined #ruby
[19:52:00] ReK2: has joined #ruby
[19:52:31] Guest50: has joined #ruby
[19:53:08] based_pdev: Queeniebee, google a ruby styleguide and try to rewrite based on recommended formatting. you will learn things about how to better style your ruby code and probably find your error along the way
[19:54:46] baweaver: p is a function in ruby
[19:54:57] baweaver: well, method
[19:55:42] IrishGringo: has joined #ruby
[19:56:09] aspiers: just had a bizarre Travis failure where $? was nil after an IO.popen block - any ideas? https://travis-ci.org/crowbar/crowbar-core/builds/78813394
[19:56:14] aspiers: I thought that was impossible
[19:56:21] aspiers: https://github.com/aspiers/crowbar-core/blob/feature/apply-lock/crowbar_framework/spec/lib/crowbar/lock/shared_non_blocking_spec.rb#L63
[19:56:42] aspiers: and even weirder, I can't reproduce it locally
[19:56:55] baweaver: has joined #ruby
[19:57:02] aspiers: the docs are fairly clear: "At the end of block, Ruby close the pipe and sets $?."
[20:00:02] weaksauce: has joined #ruby
[20:00:15] atomical: has joined #ruby
[20:00:15] Queeniebee: based_pdev: baweaver okay thank you
[20:01:32] Spami: has joined #ruby
[20:02:29] sbhatore: has joined #ruby
[20:02:31] baweaver: Use $CHILD_STATUS instead of the perlisms
[20:02:53] baweaver: now as far as how to debug that, I'd think that Travis sandboxes external system calls.
[20:03:05] baweaver: so that'll probably need to be stubbed.
[20:03:25] baweaver: http://idiosyncratic-ruby.com/9-globalization.html - that covers longhand names for the perlisms
[20:03:27] Renich: has joined #ruby
[20:04:27] devoldmx: has joined #ruby
[20:06:14] aspiers: baweaver: thanks! I was looking for that list but it was surprisingly hard to find
[20:06:35] baweaver: yeah, that entire site will be useful
[20:07:00] bruno-: has joined #ruby
[20:07:22] aspiers: looks awesome
[20:08:06] sivsushruth: has joined #ruby
[20:09:51] aspiers: baweaver: it was working fine with other external commands
[20:10:38] aspiers: for example https://travis-ci.org/crowbar/crowbar-core/builds/78811725
[20:12:17] dgutierrez1287: has joined #ruby
[20:12:27] aaeron: has joined #ruby
[20:12:29] tercenya_: has joined #ruby
[20:12:48] SenpaiSilver_: has joined #ruby
[20:12:57] Spami_: has joined #ruby
[20:13:13] theery_: has joined #ruby
[20:13:15] code1o6: has joined #ruby
[20:13:41] grotewold: has joined #ruby
[20:13:42] aspiers: wtf. the commit listed by travis doesn't even exist in the repo?!
[20:13:44] baweaver: honestly I wouldn't know where to start on looking into that myself.
[20:13:55] aspiers: https://travis-ci.org/crowbar/crowbar-core/builds/78813394 refers to commit ec32e0b
[20:14:12] mahlon_: has joined #ruby
[20:14:17] Rutix`away: has joined #ruby
[20:14:17] Rutix`away: has joined #ruby
[20:14:23] marr123: has joined #ruby
[20:14:45] aspiers: oh it's a merge commit
[20:14:46] qiukun_: has joined #ruby
[20:14:52] djbkd: has joined #ruby
[20:15:02] aspiers: https://github.com/crowbar/crowbar-core/commit/ec32e0b
[20:15:02] Plas: has joined #ruby
[20:15:08] workmad3: has joined #ruby
[20:15:11] pontiki_: has joined #ruby
[20:15:15] yqt: has joined #ruby
[20:15:16] scpike_: has joined #ruby
[20:15:18] Sthebig_: has joined #ruby
[20:15:18] Sthebig_: has joined #ruby
[20:15:21] eternal1: has joined #ruby
[20:15:26] stnly_: has joined #ruby
[20:15:37] mclee_: has joined #ruby
[20:15:46] wlanboy: has joined #ruby
[20:15:53] ejnahc_: has joined #ruby
[20:15:58] justin2: has joined #ruby
[20:16:06] camt: has joined #ruby
[20:16:06] s00pcan: has joined #ruby
[20:16:07] hays_: has joined #ruby
[20:16:07] jayne_: has joined #ruby
[20:16:09] MuffinPimp_: has joined #ruby
[20:16:09] hays_: has joined #ruby
[20:16:09] gener1c: has joined #ruby
[20:16:10] Synthbread: has joined #ruby
[20:16:10] jatb: has joined #ruby
[20:16:10] bhorn1|away: has joined #ruby
[20:16:20] heinrich5991: has joined #ruby
[20:16:23] PaulePanter: has joined #ruby
[20:16:25] hackeron: has joined #ruby
[20:16:28] cornerman: has joined #ruby
[20:16:28] patrick_star: has joined #ruby
[20:16:29] tethra: has joined #ruby
[20:16:34] Synthead: has joined #ruby
[20:16:40] ghr: has joined #ruby
[20:16:49] Meeh: has joined #ruby
[20:16:51] charliesome: has joined #ruby
[20:17:18] Fire1o6: has joined #ruby
[20:17:20] frankS2_: has joined #ruby
[20:17:22] Zackio: has joined #ruby
[20:17:46] superlou: has joined #ruby
[20:19:51] sarkyniin: has joined #ruby
[20:20:29] aspiers: baweaver: I triggered a rebuild and it worked ...
[20:20:32] rcs: has joined #ruby
[20:20:34] aspiers: heisenbug :-(
[20:20:42] M-prosodyContext: has joined #ruby
[20:20:51] aaeron: has joined #ruby
[20:20:57] aspiers: must be some race condition in Travis's sandboxing
[20:21:14] darix: moin aspiers
[20:21:58] IceyEC: has joined #ruby
[20:23:30] dfockler: has joined #ruby
[20:23:50] poguez_: has joined #ruby
[20:24:15] Kamilion: has joined #ruby
[20:25:07] jaequery: has joined #ruby
[20:27:35] bootstrappm: has joined #ruby
[20:27:35] symm-: has joined #ruby
[20:27:54] iateadonut: has left #ruby: ()
[20:31:04] Queeniebee: Hello again, I hate to be annoying but I'm really curious now, I've run the code through Rubocop and ruby-lint and looked through the Ruby styleguide on Github. While it isn't the dryest code, I still can't see why I am getting "unexpected token kEND" https://gist.github.com/Queeniebee/df01e7832231080f7789 Is there another Ruby linting program someone can recommend?
[20:31:32] kadoppe: has joined #ruby
[20:31:45] acke: has joined #ruby
[20:31:56] jordanloky: has joined #ruby
[20:31:57] baweaver: has left #ruby: ()
[20:33:18] baweaver: has joined #ruby
[20:33:29] baweaver: Use 2 spaces instead of tabs for one thing. Anyways, give me a sec to look it over.
[20:33:37] baweaver: Line 4, that's not how %w works
[20:33:39] baweaver: >> %w(there are no quotation marks in here)
[20:33:41] ruboto: baweaver # => ["there", "are", "no", "quotation", "marks", "in", "here"] (https://eval.in/428295)
[20:33:58] majjoha: has joined #ruby
[20:34:13] baweaver: You're also treating it a lot like a Java / C# program
[20:34:54] baweaver: Instead of: Float.new -> 0.0, String.new -> '', Integer.new -> 0
[20:35:04] baweaver: Array.new -> [], Hash.new -> {}
[20:35:27] Guest50: has joined #ruby
[20:35:31] baweaver: return is not necessary
[20:36:35] baweaver: what line does it say the error is on?
[20:36:41] baweaver: oh, and class is lowercase
[20:36:46] baweaver: >> class Foo; end
[20:36:47] ruboto: baweaver # => nil (https://eval.in/428299)
[20:36:50] Queeniebee: baweaver: line 56
[20:37:01] baweaver: lowercase it
[20:37:09] baweaver: heh, that it took me a sec to see that one
[20:37:42] baweaver: cost_of_item, you want to raise an error there.
[20:37:50] baweaver: otherwise you get a string back expecting an integer
[20:37:57] k3asd`: has joined #ruby
[20:38:19] baweaver: Queeniebee: what have you gone through to learn ruby?
[20:38:22] griffindy: Queeniebee you're also referencing instance variables outside of a class in lines 58-63
[20:38:51] acke: has joined #ruby
[20:38:54] baweaver: there's a lot of stuff and it'd take me a bit to review all of it
[20:39:10] baweaver: instead, it would serve you better to find out what you've used to learn and recommend more reading.
[20:39:14] miliarch: has left #ruby: ()
[20:39:27] t_mmyv: has joined #ruby
[20:39:32] eam: one key debugging tactic: If you can't easily see the problem, reduce the size of your code
[20:39:49] Queeniebee: baweaver: learn the hard way and why's poignant guide
[20:39:51] eam: break things up into smaller parts, which will reduce the amount of stuff you need to look at to see why things aren't working
[20:40:04] baweaver: Read Eloquent Ruby
[20:40:14] baweaver: and Practical Object Oriented Design in Ruby
[20:40:17] Alina-malina: has joined #ruby
[20:40:28] eam: (in this case, you could reduce the program to just the class definition with the typo -- with no actual code)
[20:42:04] grotewold: has joined #ruby
[20:44:02] fgo: has joined #ruby
[20:44:30] grotewold: has joined #ruby
[20:46:52] grotewold: has joined #ruby
[20:48:12] khebbie: has joined #ruby
[20:49:09] michael_mbp: has joined #ruby
[20:49:13] grotewold: has joined #ruby
[20:49:49] tvw: has joined #ruby
[20:51:59] knrz: has joined #ruby
[20:52:43] baweaver: has joined #ruby
[20:53:54] havenwood: has joined #ruby
[20:54:06] diegoaguilar: has joined #ruby
[20:55:25] solocshaw: has joined #ruby
[20:57:24] chipotle: has joined #ruby
[20:57:41] oniMaker: has joined #ruby
[20:57:44] A124: has joined #ruby
[21:00:27] balazs: has joined #ruby
[21:01:44] based_: has joined #ruby
[21:02:18] Limix: has joined #ruby
[21:02:29] leat: has joined #ruby
[21:03:14] ddarkpassenger: has joined #ruby
[21:04:06] solocshaw: has joined #ruby
[21:04:29] aaeron: has joined #ruby
[21:05:58] mmance: has joined #ruby
[21:06:05] amclain_: has joined #ruby
[21:06:52] macq: has joined #ruby
[21:06:55] mmance: When moving my ruby script from machine to machine, how does one worry about gems installed on each machine?
[21:07:12] lapide_viridi: has joined #ruby
[21:07:38] AccordsLTN: has joined #ruby
[21:07:42] bstrarm: has joined #ruby
[21:07:49] mmance: or what is a good search phrase that would lead me to my answer
[21:07:57] mmance: I don't know how to word that right.
[21:09:26] f-pound--: has joined #ruby
[21:09:45] Nirgali42: has joined #ruby
[21:09:56] charliesome: has joined #ruby
[21:09:59] s2013: has joined #ruby
[21:10:10] paulcsmith: has joined #ruby
[21:10:18] tskogberg: has joined #ruby
[21:10:34] Vile`: has joined #ruby
[21:10:53] adamholt: has joined #ruby
[21:11:04] jonnie: has joined #ruby
[21:11:04] praveen__: has joined #ruby
[21:11:20] Eiam: has joined #ruby
[21:11:22] Mendenhall: has joined #ruby
[21:12:11] pyon: has joined #ruby
[21:13:47] gsingh93: has joined #ruby
[21:14:16] moeabdol: has joined #ruby
[21:14:40] Esya: has joined #ruby
[21:15:17] platzhirsch: has joined #ruby
[21:16:07] mozzarella: has joined #ruby
[21:16:45] ddarkpassenger: has joined #ruby
[21:17:46] djbkd: has joined #ruby
[21:18:53] dravine: has joined #ruby
[21:19:40] knrz: has joined #ruby
[21:19:48] Esya-: has joined #ruby
[21:22:07] yfeldblum: has joined #ruby
[21:22:44] GnuYawk: has joined #ruby
[21:23:32] gregf: has joined #ruby
[21:23:38] abdulrehman: has joined #ruby
[21:24:38] noodle: has joined #ruby
[21:25:01] Scripore: has joined #ruby
[21:25:17] based_: has joined #ruby
[21:25:58] jhack: has joined #ruby
[21:26:08] xsdg: has joined #ruby
[21:26:43] firstdayonthejob: has joined #ruby
[21:26:54] krisquigley: has joined #ruby
[21:28:05] zcreative: has joined #ruby
[21:30:24] failshell: has joined #ruby
[21:31:30] al2o3-cr: has joined #ruby
[21:31:52] jamesaxl: has joined #ruby
[21:32:09] michael_mbp: has joined #ruby
[21:32:23] jackjackdripper: has joined #ruby
[21:34:43] charliesome: has joined #ruby
[21:34:44] majjoha: has joined #ruby
[21:35:04] aibo: bundler, Gemfile
[21:40:22] baweaver: has joined #ruby
[21:41:19] paulcsmith: has joined #ruby
[21:41:33] sarkyniin: has joined #ruby
[21:43:50] Pupeno: has joined #ruby
[21:43:54] oniMaker: How can I ignore the first value of a function that returns multiple values?
[21:44:07] oniMaker: ignore, keep = foo()
[21:44:12] nofxx: oniMaker, a method that returns an array?
[21:44:15] oniMaker: do I have to make ignore a variable, or can I dump it?
[21:44:39] oniMaker: a method with multiple returns
[21:44:43] nofxx: one, two = foo
[21:44:48] nofxx: ignore one, use two
[21:44:54] oniMaker: so I have to set the var
[21:45:05] fgo: has joined #ruby
[21:45:06] baweaver: >> def multi; [1,2,3] end; multi.first
[21:45:06] nofxx: there are many ways to do this
[21:45:07] ruboto: baweaver # => 1 (https://eval.in/428308)
[21:45:23] oniMaker: it'd be nice to do something like `nil, two = foo`
[21:45:26] oniMaker: or whatever
[21:45:32] nofxx: oniMaker, _, two = foo
[21:45:38] oniMaker: nofxx: what is the underscore?
[21:45:45] nofxx: that's convention... _x for unused
[21:46:03] moeabdol: has joined #ruby
[21:46:06] vdamewood: has joined #ruby
[21:46:08] oniMaker: _x or just _ ?
[21:46:10] apeiros: >> *,b,c = 1,2,3; b
[21:46:11] ruboto: apeiros # => 2 (https://eval.in/428309)
[21:46:16] nofxx: oniMaker, it just convention, also the (), avoid using them w/o parameters
[21:46:18] baweaver: >> head, *tail = [1,2,3,4,5]; tail
[21:46:19] ruboto: baweaver # => [2, 3, 4, 5] (https://eval.in/428310)
[21:46:25] oniMaker: apeiros: ah, what does * do there?
[21:46:40] apeiros: oniMaker: swallow all the rest
[21:47:07] nofxx: apeiros, hey, that's nice. Splat instead of _unused.
[21:47:12] apeiros: and since there's no variable, that rest isn't assigned anywhere
[21:47:33] oniMaker: apeiros: that's cool, thank you!
[21:47:51] apeiros: beware, though, it really means "rest":
[21:47:55] apeiros: >> *,a = 1,2,3; a
[21:47:56] ruboto: apeiros # => 3 (https://eval.in/428311)
[21:48:35] oniMaker: I guess that would work for this case where there's only two args
[21:48:39] oniMaker: err, two returns
[21:49:08] apeiros: so if you specifically want "2nd value in returned array", `_, takethis = foo()` may be better
[21:49:40] nofxx: oniMaker, as apeiros said, but just another option: take = foo[1]
[21:49:59] nofxx: if you just need the 2nd...
[21:50:02] oniMaker: I think _x, keep = foo is clear enough for now
[21:50:15] oniMaker: good to know about the alternatives though
[21:50:16] nofxx: oniMaker, definively. Just so you know.
[21:51:41] oniMaker: hmm, I seem to have broken my block
[21:51:44] oniMaker: map_hosts = lambda { |(_name, site)| site['site_hosts'] }
[21:51:55] oniMaker: hostname, *aliases = sites.flat_map map_hosts
[21:52:13] oniMaker: the map_hosts block was originally right after sites.flat_map, but I want to re-use it for a couple calls
[21:52:15] apeiros: oniMaker: forgot &
[21:52:27] apeiros: flat_map &map_hosts
[21:52:28] oniMaker: &map_hosts ?
[21:52:29] Ox0dea: has joined #ruby
[21:52:34] oniMaker: what does that do?
[21:52:41] apeiros: it tells ruby to convert a Proc into a block
[21:52:54] Ox0dea: But that's a no-op! ;)
[21:53:03] oniMaker: ah ok, otherwise it's passing the block as an argument?
[21:53:05] apeiros: (and if it isn't a Proc, to convert it to a proc first by calling to_proc)
[21:53:16] apeiros: Ox0dea: hm? no? block != proc
[21:53:20] apeiros: at least in MRI
[21:53:30] Ox0dea: apeiros: I was being facetious. Many people would disagree with you.
[21:53:37] apeiros: Ox0dea: they'd be mistaken
[21:53:43] apeiros: the difference is measurable
[21:53:46] acke: has joined #ruby
[21:53:59] Ox0dea: Code don't lie.
[21:54:01] apeiros: the one point which can be argued is that I'd say it's an implementation detail
[21:54:13] oniMaker: excellent, working now :)
[21:54:28] Ox0dea: apeiros: Are there implementations wherein #to_proc is unnecessary, then?
[21:54:50] apeiros: Ox0dea: I thought you meant Proc -> block was a no-op?
[21:55:14] apeiros: MRI of course won't call to_proc if the object already is a Proc
[21:56:09] Ox0dea: I'm reasonably certain that neither JRuby nor Rubinius let you pass a Proc to a method expecting a block without performing *some* kind of transformation.
[21:56:29] apeiros: I'm not sure we're talking about the same thing???
[21:56:42] apeiros: foo(obj) # will *never* pass obj as a block
[21:56:42] Ox0dea: Calling the difference between Procs and blocks an implementation detail seems disingenuous.
[21:56:54] Ox0dea: apeiros: That holds for any implementation, right?
[21:57:11] apeiros: "foo(obj) # will *never* pass obj as a block" <-- this? yes, this is true for all implementations.
[21:57:16] apeiros: that's the definition of the language.
[21:57:41] apeiros: but whether foo(&obj) in case of obj being a Proc actually performs a conversion is implementation specific
[21:58:01] Renich: has joined #ruby
[21:58:30] Ox0dea: Sure, but Proc != block holds in all cases, is the point I mean to make.
[21:58:35] apeiros: an implementation may very well choose to use the same mechanism for blocks as for procs. MRI does not. MRI optimizes blocks by not creating an actual ruby-space object for it.
[21:59:35] Ox0dea: I think the simplest proof is to observe that a method can receive n Proc arguments, but only one block one.
[21:59:40] jamesaxl|2: has joined #ruby
[21:59:53] diegoaguilar: has joined #ruby
[22:00:02] apeiros: yes, that'd be "it's the definition of the language [syntax]"
[22:00:40] RobertBirnie: has joined #ruby
[22:00:42] oniMaker: Is a Proc just for binding context variables, or does it do other things?
[22:00:51] David27: has joined #ruby
[22:01:11] David27: has joined #ruby
[22:01:35] Ox0dea: oniMaker: In essence, a Proc is just a handy way to pass code around.
[22:01:57] David27: has left #ruby: ()
[22:01:57] David27: has joined #ruby
[22:01:59] oniMaker: seems similar to binding arguments to function objects in JS
[22:02:45] Ox0dea: oniMaker: Thinking of them as "function objects" is pretty much spot-on.
[22:02:48] apeiros: oniMaker: yes, it does create a closure
[22:03:01] apeiros: Ox0dea: that misses the closure aspect, though
[22:03:02] leat: has joined #ruby
[22:03:11] oniMaker: what is the closure aspect?
[22:03:41] Ox0dea: oniMaker: A Proc "closes over" the environment (state) in which it was created.
[22:03:52] apeiros: >> a = 1; def foo; a = 2; end a # 1 is expected and will be, because foo does not have access to the outside local variables
[22:03:53] workmad3: has joined #ruby
[22:03:53] ruboto: apeiros # => /tmp/execpad-d82dc5317e7c/source-d82dc5317e7c:2: syntax error, unexpected tIDENTIFIER, expecting key ...check link for more (https://eval.in/428312)
[22:04:01] apeiros: >> a = 1; def foo; a = 2; end; a # 1 is expected and will be, because foo does not have access to the outside local variables
[22:04:02] ruboto: apeiros # => 1 (https://eval.in/428313)
[22:04:06] apeiros: (bleh, missing ; )
[22:04:09] David27: has joined #ruby
[22:04:11] oniMaker: ahh, right. got it.
[22:04:13] theery: has joined #ruby
[22:04:58] devoldmx: has joined #ruby
[22:04:59] apeiros: >> a = 1; b = proc { a = 2 }; def foo; b.call; end; foo(b); a # will be 2, because the proc closes over the local variables where it was created
[22:05:00] ruboto: apeiros # => wrong number of arguments (1 for 0) (ArgumentError) ...check link for more (https://eval.in/428316)
[22:05:06] apeiros: ACTION rolls eyes
[22:05:13] apeiros: ACTION can't code anymore and should probably sleep
[22:05:28] apeiros: >> a = 1; b = proc { a = 2 }; def foo(closure); closure.call; end; foo(b); a # will be 2, because the proc closes over the local variables where it was created
[22:05:29] ruboto: apeiros # => 2 (https://eval.in/428317)
[22:05:37] Scripore: has joined #ruby
[22:05:43] Ox0dea: The "make_adder" function is pretty good for demonstrating closures.
[22:05:43] apeiros: and I notice I didn't actually call `foo` in the first example 0:-)
[22:06:38] dfinninger: has joined #ruby
[22:07:20] Ox0dea: oniMaker: https://eval.in/428318
[22:07:59] oniMaker: Ox0dea: right, makes sense - very similar to js closures
[22:08:25] David27: has joined #ruby
[22:08:47] foul_owl: has joined #ruby
[22:08:47] oniMaker: hopefully I get the chance to write more than a few snippets in ruby sometime
[22:08:55] Rodya_: has joined #ruby
[22:09:51] rbowlby: has joined #ruby
[22:11:02] rakm: has joined #ruby
[22:11:36] KensoDev: has joined #ruby
[22:12:49] NeverDie: has joined #ruby
[22:12:50] IrishGringo: has joined #ruby
[22:12:59] foul_owl: has left #ruby: ()
[22:13:48] David27: has joined #ruby
[22:14:56] ruby-lang581: has joined #ruby
[22:15:33] ruby-lang581: looking for a good game-dev language
[22:15:51] ruby-lang581: ruby looks good. do other people who want to play the game in question need to have ruby?
[22:15:55] ruby-lang581: or can it be like an exe file
[22:16:08] bigredboots: has joined #ruby
[22:16:15] krisquigley: has joined #ruby
[22:16:57] weaksauce: ruby-lang581 ruby would be required
[22:17:08] weaksauce: what kind of games do you want to make?
[22:17:22] ruby-lang581: 2d game. tons of objects. loves math.
[22:18:09] michael_mbp: has joined #ruby
[22:18:20] bazbing80: has joined #ruby
[22:18:25] Ox0dea: weaksauce: Hm? There are several tools for going from Ruby to Windows executable.
[22:18:34] radgeRayden_: has joined #ruby
[22:19:01] weaksauce: Ox0dea does it actually compile it to something native? i was under the impression that it just packed ruby up with it
[22:19:28] diegoaguilar: has joined #ruby
[22:19:38] Ox0dea: It does build Ruby in, but the users needn't know or worry about that detail.
[22:20:10] oniMaker: ruby-lang581: have you considered using something like Unity?
[22:20:21] Ox0dea: That's how OCRA works, anyhow.
[22:20:21] bazbing80: Hey all...picking through rspec source as you do, and I've come across this: $_rspec_core_load_started_at Printing it returns a datetime. But thie 'variable' isn't set in the file, and it isn't a method call. So how does it contain a datetime? How is it set?
[22:20:56] Ox0dea: bazbing80: That's a global. It could be set anywhere.
[22:21:21] Scripore: has joined #ruby
[22:22:35] Ox0dea: bazbing80: https://github.com/rspec/rspec-core/blob/master/lib/rspec/core.rb#L2
[22:22:46] weaksauce: ruby-lang581 if you are just playing around and want to make something you can use ruby for it and it will work fine. if your end goal is selling it you might want to look at unity or unreal.
[22:23:03] swgillespie: has joined #ruby
[22:23:44] shred45: has joined #ruby
[22:23:46] bootstrappm: has joined #ruby
[22:24:13] swgillespie: has left #ruby: ()
[22:24:16] oniMaker: dfockler: I played around with that a couple years back - has anyone shipped a big commercial game with it yet?
[22:24:39] ellisTAA: has joined #ruby
[22:24:51] dfockler: oniMaker: a few I think yeah
[22:24:57] dfockler: not gigantic games
[22:25:18] poli: has joined #ruby
[22:25:29] bigredboots: has joined #ruby
[22:25:53] dfockler: Love2d just packages up an interpreter runtime with your code
[22:26:04] dfockler: but this is OT now :P
[22:27:10] TobiG77: has joined #ruby
[22:27:47] ruby-lang582: has joined #ruby
[22:27:51] ruby-lang582: so how smooth is that transition
[22:27:56] ruby-lang582: with the packing of ruby into an exe
[22:28:08] ruby-lang582: can users tell that's happening or is it just like a game running up?
[22:28:30] duncannz: has joined #ruby
[22:28:39] dfockler: ruby-lang582: are you talking to me?
[22:28:41] doublemalt_: has joined #ruby
[22:29:18] baweaver: has joined #ruby
[22:29:32] dfockler: Well in my experience Love2d feels just like a game loading up, but it's Lua, not ruby
[22:29:47] al2o3-cr: has joined #ruby
[22:30:19] Ox0dea: ruby-lang582: Naming your main file with an .rbw extension will cause OCRA to create a "windowed" application, which won't pop up a console, so it appears like most others.
[22:30:50] ruby-lang582: I'm not even sure if I should use Ruby for my game
[22:30:51] Ox0dea: OCRA doesn't compile your code, though; it just interprets it as per usual, so performance is likely to be... Ruby-level.
[22:30:53] ruby-lang582: I just want something simple
[22:31:03] Ox0dea: ruby-lang582: Simple or easy?
[22:31:05] haasn: has joined #ruby
[22:31:05] pawnbox: has joined #ruby
[22:31:31] baweaver: only focus on simple
[22:31:43] ruby-lang582: I took Java in high school. That was.. okay. I really don't want to go about learning C++ or something crazy like that for this game.
[22:31:51] oniMaker: "simple yet powerful" describes every turing-complete language...
[22:32:03] oniMaker: you should really look into Unity...
[22:32:05] baweaver: except Java, which is not simple
[22:32:08] Papierkorb: oniMaker: Brainfuck
[22:32:15] oniMaker: Papierkorb: very simple
[22:32:19] oniMaker: much simpler than most languages
[22:32:46] jalnt: has joined #ruby
[22:33:47] oniMaker: ruby-lang582: what kind of game are you building?
[22:34:13] ruby-lang582: 2d game.. Pokemon style like.. View is top down
[22:34:18] tmtwd: has joined #ruby
[22:34:21] freerobby: has joined #ruby
[22:34:25] nofxx: Anyone knows a log tool, aggregator, history thing saas with reasonable price? for my ruby apps.. hehe
[22:34:32] ruby-lang582: But this particular gaem I'm building has loooooooads of objects.. and loves doing math
[22:35:30] majjoha: has joined #ruby
[22:35:35] bazbing80: Ox0dea: Thanks. How did you find out where that global was defined?
[22:36:23] ruby-lang582: So yeah. I just don't know what to learn.
[22:36:46] ruby-lang582: Ruby sounds nice. But I don't want to spend time learning a language just to realize that my game cannot be built upon it, and there's some sort of sick bottleneck that develops lateron
[22:37:26] Ox0dea: bazbing80: https://github.com/ggreer/the_silver_searcher
[22:37:32] wasamasa: ruby-lang582: then don't use it for games, duh
[22:37:37] Papierkorb: ruby-lang582: ruby isn't really popular for building games. I don't know of a game built with it. See Unity and/or UDK
[22:37:52] Ox0dea: bazbing80: `gem unpack` is also quite handy.
[22:37:55] wasamasa: ruby-lang582: it's a fine language for less performance-critical things
[22:38:43] wasamasa: ruby-lang582: then, nearly everything will fall back to C for these situations
[22:39:00] Ox0dea: ruby-lang582: Sounds like you might want to learn the hundred-year language.
[22:39:02] opensource_ninja: has joined #ruby
[22:39:15] dgutierrez1287: has joined #ruby
[22:39:45] jenrzzz: has joined #ruby
[22:40:02] ruby-lang582: Okay. Thanks guys.
[22:40:08] ruby-lang582: I appreciate the input
[22:40:13] Asher: has joined #ruby
[22:40:36] jgt: has joined #ruby
[22:41:54] firstdayonthejob: has joined #ruby
[22:42:12] Papierkorb: wasamasa: well, C++.
[22:43:51] bazbing80: Ox0dea: nice!
[22:46:02] gix: has joined #ruby
[22:46:13] fgo: has joined #ruby
[22:46:15] Esya: has left #ruby: ("Textual IRC Client: www.textualapp.com")
[22:48:53] firstdayonthejob: has joined #ruby
[22:48:57] devbug: has joined #ruby
[22:50:46] jordanloky: has joined #ruby
[22:51:21] Tuxero: has joined #ruby
[22:51:59] firstdayonthejob: has joined #ruby
[22:53:18] k3asd`: has joined #ruby
[22:54:35] ellisTAA: anyone have any ideas on how to solve this problem? https://gist.github.com/ellismarte/c9edfb41bebe5f8a9f33
[22:55:11] apeiros: EllisTAA: you??? gist your problem as code comment? srsly? :D
[22:55:34] ellisTAA: apeiros: where would u put it?
[22:55:35] firstdayonthejob: has joined #ruby
[22:55:38] banister: EllisTAA looks like homework
[22:55:40] adam|: Kinda looks like homework or a job interview quiz?
[22:55:47] apeiros: gist is ok, but why as *comment*?
[22:55:50] ellisTAA: https://www.cs.ox.ac.uk/ugadmissions/how_to_apply/sample_interview_problems.html
[22:55:59] apeiros: you know, gist doesn't only understand ruby. it can handle plaintext.
[22:56:17] ellisTAA: apeiros: i know
[22:56:31] ascarter: has joined #ruby
[22:56:47] apeiros: "why?" -> answer: "I know"
[22:56:50] apeiros: good one :-p
[22:58:05] apeiros: yes. I have an idea for how to solve it.
[22:58:16] ellisTAA: apeiros: look at another one of my gists, i put the question above the code for ppl looking at the code
[22:58:28] ellisTAA: apeiros: is this a combinatorics problem?
[22:58:40] JDiPierro: has joined #ruby
[22:58:51] apeiros: EllisTAA: I'm not usually foraging in other people's gists
[22:59:05] ellisTAA: apeiros: ok
[22:59:22] apeiros: I don't think it's a combinatorics problem
[22:59:33] apeiros: I don't know whether my solution is optimal either
[22:59:46] ellisTAA: what???s your idea for solving it
[23:00:41] juanpablo____: has joined #ruby
[23:00:55] apeiros: binary search
[23:01:16] ellisTAA: interesting
[23:01:21] linuxboy_: has joined #ruby
[23:03:25] ellisTAA: apeiros: what???s the reasoning behind using binary search?
[23:03:58] apeiros: you have a defined search space, you have a clean property to decide on which side of the value to find you are
[23:04:13] apeiros: and what's your solution?
[23:04:16] blackmes1: has joined #ruby
[23:04:17] shmilan: has joined #ruby
[23:07:57] ellisTAA: apeiros: i???m still trying to figure it out, but yeah your idea seems good.
[23:08:24] jdawgaz: has joined #ruby
[23:09:05] apeiros: though, actually you need to do a bit more. the side isn't quite as cleanly to figure as I initially thought
[23:09:28] apeiros: but I think it's the right direction
[23:11:23] tenderlove: has joined #ruby
[23:11:33] bronson: has joined #ruby
[23:11:37] ellisTAA: apeiros: it???s hard to wrap my barin around ><
[23:11:49] apeiros: i.e., I thought you could infer it at 2 samples already, but you need at least 3
[23:12:15] ellisTAA: perhaps we should move to ?offtopic
[23:12:21] ruboto: I don't know anything about off
[23:12:36] apeiros: #ruby-offtopic is the channel
[23:12:40] David27: has joined #ruby
[23:12:44] apeiros: and offtopic the factoid ;)
[23:13:37] Pupeno: has joined #ruby
[23:14:08] Asher-: has joined #ruby
[23:16:08] Ox0dea: apeiros: The factoid is "ot", no?
[23:17:34] jhass: I think it's copied to both :D
[23:18:09] ordepdev: has joined #ruby
[23:18:19] Asher: has joined #ruby
[23:19:14] dfinninger: has joined #ruby
[23:22:03] ascarter: has joined #ruby
[23:24:18] ascarter: has joined #ruby
[23:26:20] zacts: has joined #ruby
[23:26:30] ordepdev: has joined #ruby
[23:31:05] failshell: has joined #ruby
[23:31:26] hightechlotech: has joined #ruby
[23:31:31] hightechlotech: I'm trying to install the ruby-debug gem for arcadia and getting an error "cannot load such file -- mkmf (LoadError) to precis it down a bit
[23:31:54] Ox0dea: hightechlotech: OS?
[23:31:55] oniMaker: has left #ruby: ("Peace")
[23:32:11] bootstrappm: has left #ruby: ()
[23:32:34] Ox0dea: hightechlotech: You want to install the ruby-dev package.
[23:39:49] hightechlotech: I could just use eclipse
[23:40:07] sdwrage: has joined #ruby
[23:40:42] veg: has joined #ruby
[23:43:34] banister: has joined #ruby
[23:43:39] leat: has joined #ruby
[23:46:10] failshell: has joined #ruby
[23:47:20] fgo: has joined #ruby
[23:52:33] workmad3: has joined #ruby
[23:53:31] otisZart: has joined #ruby
[23:55:32] martin_work: has joined #ruby
[23:55:51] baweaver: has joined #ruby
[23:58:57] northfurr: has joined #ruby