« Back to channel list

#ruby - 11 November 2015

« Back 1 day Forward 1 day »
[00:01:04] sye: has joined #ruby
[00:02:56] lemur: has joined #ruby
[00:03:40] willardg: has joined #ruby
[00:04:44] shevy: what does this mean?
[00:04:46] shevy: https://github.com/ruby/ruby/blob/trunk/ChangeLog#L9
[00:04:55] shevy: "* lib/open-uri.rb: Remove indicator for "frozen_string_literal: true"."
[00:05:21] shevy: https://github.com/ruby/ruby/blob/trunk/ChangeLog#L53
[00:05:24] Ox0dea: They were a little hasty with adding that to the top of all of those files.
[00:05:28] shevy: "* proc.c (cfunc_proc_t): add room for me."
[00:05:34] roxtrongo: has joined #ruby
[00:05:35] Ox0dea: `me` is the current frame.
[00:05:38] shevy: why? isn't it a part of a #comment?
[00:06:12] Ox0dea: I guess they're discussing it and have decided that a magic comment isn't the best way to go.
[00:06:28] malconis: has joined #ruby
[00:06:45] Ox0dea: I think they're going to introduce "pragmas".
[00:07:22] h99h9h88: has joined #ruby
[00:07:47] chipotle: has joined #ruby
[00:08:19] Ox0dea: > We don???t need an option name if it is always enabled.
[00:09:41] rgtk: has joined #ruby
[00:13:25] shevy: things change so rapidly!
[00:13:34] shevy: what do you mean with pragmas? is that like #define ?
[00:14:10] shevy: or do they make a flat change without optional non-static strings
[00:14:40] vigintas: has joined #ruby
[00:15:37] Ox0dea: Well, no, like #pragma.
[00:17:00] edj: *varName in a function makes it a global variable?
[00:18:07] TomPeed: has joined #ruby
[00:19:39] edj: whats a good website to post code on so i can link it here?
[00:19:45] Ox0dea: ?gist edj
[00:19:45] ruboto: edj, https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[00:19:48] yfeldblum: has joined #ruby
[00:19:58] edj: ok thanks
[00:20:20] mblagden: has joined #ruby
[00:20:34] edj: https://gist.github.com/edj979/7a7d088e2b6e80e8f55c
[00:20:51] edj: *numbers is a global var even though its declared in a method ?
[00:21:47] Ox0dea: edj: What on earth makes you think it's global?
[00:22:08] FailBit: only $ are globals
[00:22:22] FailBit: everything else is a local or a method
[00:22:33] Ox0dea: There are also class and instance variables.
[00:22:45] FailBit: I meant unprefixed
[00:22:48] edj: so if i do def name ($var) its global?
[00:22:53] Ox0dea: edj: You can't do that.
[00:23:10] Ox0dea: Why would you want to?
[00:23:21] edj: idk, flexability
[00:23:42] edj: i guess i could just create one as an output
[00:23:54] devoldmx: has joined #ruby
[00:24:02] shevy: assign to a local variable and just use that; or use $var directly inside your method
[00:24:41] edj: or i could use $var=method(var)
[00:24:48] Ox0dea: edj: Is this you? http://i.imgur.com/sHt5q.jpg
[00:25:09] krz: has joined #ruby
[00:25:10] Ox0dea: Do you Pinkie Pie swear?
[00:25:13] edj: I'm legit retarded
[00:25:20] edj: pinkie pie swear
[00:25:36] bruce_lee: has joined #ruby
[00:25:43] edj: I'm pretty smart, just a noob.
[00:25:51] Ox0dea: edj: Global variables are just way too "visible"; any change you make can affect code *anywhere* else, and *anybody else* can change a global you're currently relying upon.
[00:26:20] NeverDie: has joined #ruby
[00:26:36] edj: I'm not really making anything practical yet just trying to get a good grasp of ruby
[00:26:41] shevy: edj you can use a proc if you really need that and then .call on it
[00:26:41] edj: but thats a good point
[00:26:56] Ox0dea: edj: This is one habit you'll want to break, like, right now.
[00:27:10] shevy: but he won't!
[00:27:18] edj: what habit is that ?
[00:27:28] shevy: the bad habit
[00:27:37] Ox0dea: That thing you're doing that you should never do again.
[00:27:44] edj: what habit lmao
[00:27:47] Ox0dea: This one.
[00:27:51] edj: alright man
[00:27:54] shevy: it's getting too much to bear
[00:28:01] Ox0dea: But not enough to snake.
[00:28:07] edj: i understand
[00:28:13] edj: I need to stop that.
[00:28:15] shevy: don't call that dam beaver
[00:28:30] Ox0dea: Sshhh, he'll hear you.
[00:28:37] Ox0dea: He's got ears like a snake!
[00:28:41] Alayde: has joined #ruby
[00:28:44] hxegon: am I having a stroke?
[00:28:50] edj: no, but i am
[00:29:03] shevy: dunno... stand up just in case hxegon, a sitting position is not healthy
[00:29:19] Asher: has joined #ruby
[00:29:38] shevy: the beaver has awoken!
[00:29:55] i: has joined #ruby
[00:29:56] baweaver: ACTION yawns
[00:30:42] Ox0dea: So, I'm accidentally running a social experiment.
[00:31:22] shevy: since quite a long while you have been experimenting on #ruby!
[00:31:40] Ox0dea: You can't prove that!
[00:31:53] ytti: been rocking python recently, and i'm in pain
[00:32:00] kies: has joined #ruby
[00:32:03] ytti: ".".join(list) because, why not
[00:32:18] edj: so *var means it can take multiple arguments and put it in one?
[00:32:23] Ox0dea: edj: Yeah.
[00:32:31] edj: alright, nice
[00:32:51] ytti: set(list1).difference(list2) because list1-list2 is not good?
[00:32:55] Ox0dea: edj: * is called "splat" in general, and it can be used all over the place with similar semantics.
[00:33:06] ytti: methods often are for wronb object
[00:33:07] FailBit: I am highly illogical
[00:33:14] Ox0dea: >> first, *middle, last = [1,2,3,4,5]; middle # edj
[00:33:15] ytti: or then pooped to main level
[00:33:15] ruboto: Ox0dea # => [2, 3, 4] (https://eval.in/466634)
[00:33:17] FailBit: pinkie pie swear.
[00:33:35] predator217: has joined #ruby
[00:34:16] aaeron2: has joined #ruby
[00:34:21] edj: so it creates an array?
[00:34:31] edj: of variables
[00:34:42] edj: and runs them all through the same place
[00:34:59] FailBit: it creates three vars
[00:35:05] FailBit: the middle one is an array
[00:35:19] FailBit: it's splatted from the array values
[00:35:58] edj: but it can be more than three, right?
[00:36:17] mary5030: has joined #ruby
[00:36:44] Ox0dea: Exactly three, always.
[00:37:05] rickmasta: has joined #ruby
[00:38:15] trosborn: has joined #ruby
[00:38:18] edj: then why use it?
[00:38:41] edj: is there one that makes it so its how ever many you put in?
[00:39:04] edj: I like flexible code
[00:39:28] eam: that would violate Ruby's Rule of Threes
[00:40:22] edj: thats not a real thing
[00:40:40] edj: sarcasm doesn't come across well through text
[00:41:02] stu_: has joined #ruby
[00:41:35] Ox0dea: eam: Yes, * collects as many as it can.
[00:42:03] Ox0dea: Sorry, eam.
[00:42:10] Ox0dea: edj: See also: https://eval.in/466635
[00:42:17] edj: lol I knew it
[00:42:40] Ox0dea: That demonstrates that splatting "goes both ways"; you can use it to capture many arguments, and you can also use it to "explode" one argument into many.
[00:43:27] Ox0dea: The `sum3` method there takes three arguments, but we can't just pass it a single Array of three elements.
[00:43:42] Ox0dea: Splatman to the rescue.
[00:46:37] Ox0dea: >> def foo *args; "received #{args.size} arguments"; end; eval "foo #{9001.times.to_a.join ?,}" # edj
[00:46:38] ruboto: Ox0dea # => "received 9001 arguments" (https://eval.in/466637)
[00:46:48] Ox0dea: > The only limit is your imagination.
[00:47:26] Fire-Dra_: let's explode some arguments, will be my new signature
[00:47:50] Fire-Dra_: what happened to my name, sigh
[00:48:09] Fire-Dragon-DoL: has joined #ruby
[00:48:13] aaeron: has joined #ruby
[00:48:24] edj: explode one argument to many?
[00:48:39] Ox0dea: The example was pretty clear.
[00:50:17] Fire-Dragon-DoL: Ox0dea: the feeling when you try to explain a programming joke to your girlfriend, lol
[00:50:38] Ox0dea: Explosions are programming now? :P
[00:50:55] Ox0dea: I'll get the redstone.
[00:51:23] edj: what is that for? how does it connect to everything?
[00:52:19] edj: it seems like having one argument 9001 times wouldnt have any use
[00:52:27] Fire-Dragon-DoL: are there any sort of gem/whatever that allows me to create a hash accessible in both directions (by value AND by key)? Doesn't matter how is implemented (two hashes), it's a bunch of static values
[00:52:37] babblebre: has joined #ruby
[00:54:04] RegulationD: has joined #ruby
[00:55:06] bruno-: has joined #ruby
[00:55:31] banister: has joined #ruby
[00:56:52] Ox0dea: edj: All 9001 of those arguments are different, but I was just showing you that *args really does accept any number of arguments.
[00:56:58] nertzy: has joined #ruby
[00:57:05] Azure: has joined #ruby
[00:57:10] Ox0dea: Fire-Dragon-DoL: What're you doing that that makes sense?
[00:57:28] Ox0dea: Either way, Hash#merge and Hash#invert are the methods you're looking for; you don't need a gem/whatever.
[00:57:32] infamos: has joined #ruby
[00:57:33] Trynemjoel: has joined #ruby
[00:58:10] edj: OOOOOOOOH
[00:58:10] B1n4r10: has joined #ruby
[00:58:10] Fire-Dragon-DoL: Ox0dea: nothing, was playing with a script and wanted a way to create some errors (symbol) that should become a number (for serialization purposes) and I wanted a short way to reference from the number, the symbol
[00:58:28] Ox0dea: >> h = {a: 1, b: 2}; h.merge h.invert # Fire-Dragon-DoL
[00:58:29] ruboto: Ox0dea # => {:a=>1, :b=>2, 1=>:a, 2=>:b} (https://eval.in/466650)
[00:58:56] Fire-Dragon-DoL: Ox0dea: yeah that's my thought too, thanks
[01:00:36] rgtk: has joined #ruby
[01:01:36] mdst: has joined #ruby
[01:01:43] dorei: has joined #ruby
[01:02:44] rgtk: has joined #ruby
[01:03:30] Ox0dea: >> h = Hash.new; def h.[]=k, v; store store(k, v), k end; h[:a] = 1; h[:b] = 2; h # Fire-Dragon-DoL
[01:03:31] ruboto: Ox0dea # => {:a=>1, 1=>:a, :b=>2, 2=>:b} (https://eval.in/466656)
[01:03:35] Ox0dea: There's another approach if you're feeling fancy.
[01:03:41] lemur: has joined #ruby
[01:04:23] rgtk: has joined #ruby
[01:04:25] Ox0dea: Gotta use #store instead of #[]= or you blow the stack.
[01:04:37] CloCkWeRX: has joined #ruby
[01:06:17] roxtrongo: has joined #ruby
[01:06:20] ekinmur: has joined #ruby
[01:06:24] rgtk: has joined #ruby
[01:07:01] Tempesta: has joined #ruby
[01:07:33] eightbellyoct: has joined #ruby
[01:08:00] cmoneylulz: has joined #ruby
[01:08:11] rgtk: has joined #ruby
[01:08:58] govg: has joined #ruby
[01:10:02] rgtk: has joined #ruby
[01:11:00] jessemcgilallen: has joined #ruby
[01:12:06] rgtk: has joined #ruby
[01:12:18] benlovell: has joined #ruby
[01:12:49] chipotle: has joined #ruby
[01:13:15] NeverDie: has joined #ruby
[01:13:50] rgtk: has joined #ruby
[01:14:05] bricker: has joined #ruby
[01:14:55] araujo_: has joined #ruby
[01:15:16] Fire-Dragon-DoL: Ox0dea: you mad :P but I like the second-option idea, lol
[01:15:49] rgtk: has joined #ruby
[01:16:33] araujo_: has joined #ruby
[01:16:40] EminenceHC: has joined #ruby
[01:17:49] rgtk: has joined #ruby
[01:18:34] CloCkWeRX: has joined #ruby
[01:19:32] Coldblackice: has joined #ruby
[01:19:56] rgtk: has joined #ruby
[01:20:03] opensource_ninja: has joined #ruby
[01:20:53] CloCkWeRX1: has joined #ruby
[01:21:37] rgtk: has joined #ruby
[01:23:17] h99h9h88: has joined #ruby
[01:23:21] rgtk: has joined #ruby
[01:24:57] mloy: has joined #ruby
[01:25:21] rgtk: has joined #ruby
[01:26:37] mjuszczak: has joined #ruby
[01:26:53] Coldblackice: has joined #ruby
[01:27:28] rgtk: has joined #ruby
[01:27:47] bubuntu: has joined #ruby
[01:28:20] ni291187: has joined #ruby
[01:28:53] CloCkWeRX: has joined #ruby
[01:29:07] rgtk: has joined #ruby
[01:30:17] ni291187: has left #ruby: ()
[01:30:18] Coldblackice: has joined #ruby
[01:30:39] frigide: has joined #ruby
[01:31:06] frigide: Ox0dea no need for racism here
[01:31:09] rgtk: has joined #ruby
[01:31:56] jdawgaz: has joined #ruby
[01:31:57] rgrmatt: has joined #ruby
[01:32:13] hxegon: has joined #ruby
[01:33:15] rgtk: has joined #ruby
[01:34:26] Ox0dea: The fuck was that?
[01:34:50] rgtk: has joined #ruby
[01:35:17] flip_digits: has joined #ruby
[01:35:51] niftylettuce: has joined #ruby
[01:36:54] rgtk: has joined #ruby
[01:38:41] rgtk: has joined #ruby
[01:39:25] TheNet: has joined #ruby
[01:39:54] ebbflowgo: has joined #ruby
[01:40:34] rgtk: has joined #ruby
[01:42:45] rgtk: has joined #ruby
[01:42:54] UNIMPL: Ox0dea: Please don't make racist comments in here.
[01:43:28] FailBit: I forgot what context is
[01:43:36] shevy: the context is ruby!
[01:43:56] FailBit: I meant at the slew of people saying "that's racist"
[01:44:23] rgtk: has joined #ruby
[01:44:33] FailBit: anyways here's another fun grammar thing
[01:44:51] FailBit: you know how "statement if cond" becomes nil if !cond ?
[01:44:57] shevy: I believe it was fake considering how frigide instantly left
[01:45:24] FailBit: so then, what is "func({hash: :lit} if cond)" ?
[01:45:38] shevy: I don't like such inline conditionals
[01:45:53] baweaver: ACTION looks about
[01:45:56] baweaver: ACTION scoots off
[01:46:00] shevy: can't you keep things simple, method_call(arguments) if something; or unless something
[01:46:09] FailBit: >> def foo(*); end; foo({hash: :lit} if false)
[01:46:10] ruboto: FailBit # => /tmp/execpad-49e999247691/source-49e999247691:2: syntax error, unexpected modifier_if, expecting ')' ...check link for more (https://eval.in/466682)
[01:46:15] rgtk: has joined #ruby
[01:46:18] baweaver: ACTION more correctly swims off
[01:46:41] shevy: you can't even get that syntax bit to work :)
[01:46:48] FailBit: it's broken
[01:46:52] FailBit: you need 2 parens
[01:46:56] shevy: yes, this code is broken!
[01:47:03] FailBit: >> def foo(*); end; foo(({hash: :lit} if false))
[01:47:04] ruboto: FailBit # => nil (https://eval.in/466683)
[01:47:09] FailBit: then it parses
[01:47:11] shevy: still broken
[01:47:21] eam: two parens is pretty standard for ruby
[01:47:33] eam: you need that even for simple stuff like "not true"
[01:47:46] FailBit: that's because not has stupidly low precedence
[01:47:51] eam: FailBit: nope
[01:47:54] eam: that's not why
[01:48:02] shevy: I remember how eam once linked in a link to some twitter about the ruby parser
[01:48:02] eam: >> [not true]
[01:48:03] ruboto: eam # => /tmp/execpad-a7954db40fd6/source-a7954db40fd6:2: syntax error, unexpected keyword_true, expecting '( ...check link for more (https://eval.in/466684)
[01:48:08] eam: not a precedence issue
[01:48:17] willardg: Cancancan question
[01:48:31] shevy: cacao questions!
[01:48:51] willardg: Why can't student see the classroom_path?
[01:48:52] willardg: elsif user.role?(:teacher)
[01:48:53] willardg: can :read, :all
[01:48:53] willardg: elsif user.role?(:student)
[01:48:55] willardg: can :read, Classroom
[01:49:29] Ox0dea: willardg: Please post the contents of your project directory in full.
[01:49:37] Ox0dea: Right here into the channel like a decent human being.
[01:49:43] willardg: I'm following a tutorial
[01:49:49] willardg: http://www.sitepoint.com/cancancan-rails-authorization-dance/
[01:50:03] rgtk_: has joined #ruby
[01:50:04] FailBit: #there's a channel for that
[01:50:07] Ox0dea: ?rails willardg
[01:50:07] ruboto: willardg, Please join #RubyOnRails for Rails questions. You need to be identified with NickServ, see /msg NickServ HELP
[01:50:14] willardg: I'm making the projects to be classrooms though
[01:50:19] FailBit: AFAIK you don't need to be identified with nickserv
[01:50:31] shevy: did they change it again?
[01:50:36] yokel: has joined #ruby
[01:52:09] rgtk: has joined #ruby
[01:52:10] Ox0dea: Where do things that have been lost in translation go?
[01:52:34] ElSif: phonemgatory?
[01:53:16] shevy: to the big black void
[01:53:27] rikai: has joined #ruby
[01:53:37] Ox0dea: shevy: Please don't make racist comments in here.
[01:53:55] FailBit: that's racist
[01:54:11] rgtk: has joined #ruby
[01:54:13] CloCkWeRX: has left #ruby: ()
[01:54:14] FailBit: oh you know
[01:54:14] Ox0dea: watermelonchickenbambambasketball.jpg
[01:54:16] ElSif: check your big white void privelege
[01:54:18] FailBit: git is so helpful
[01:54:19] FailBit: git: 'pul' is not a git command. See 'git --help'.
[01:54:21] FailBit: Did you mean 'push'?
[01:54:29] tubbo: has joined #ruby
[01:54:47] Ox0dea: FailBit: It recommends 'pull' first.
[01:54:52] Ox0dea: Do you even Levenshtein distance?
[01:54:54] Ox0dea: Because git does.
[01:55:07] FailBit: I know why it does that :Y
[01:55:12] FailBit: it's just amusing
[01:55:45] Ox0dea: FailBit: Consider using thefuck: https://github.com/nvbn/thefuck
[01:55:45] rgtk: has joined #ruby
[01:55:54] FailBit: fuck git pul
[01:55:56] trosborn: has joined #ruby
[01:56:06] Ox0dea: Well, no, it'd be `git pul`, then `fuck`.
[01:56:23] FailBit: forgot how that tool worked
[01:56:42] ElSif: or `git pul && fuck`
[01:56:51] Ox0dea: It's gotta be in your history.
[01:56:54] _blizzy_: has joined #ruby
[01:57:13] ElSif: feature request!
[01:57:19] Ox0dea: Time travel?
[01:57:31] dorei: http://git-man-page-generator.lokaltog.net/
[01:57:38] nwhirschfeld: has joined #ruby
[01:57:39] TDJACR: has joined #ruby
[01:57:40] ElSif: whatever it take
[01:57:50] rgtk: has joined #ruby
[01:58:04] bruno-: has joined #ruby
[01:58:28] Ox0dea: > Forward-port local commits to the updated upstream head
[01:58:39] shevy: Ox0dea lol
[01:59:31] FailBit: Ox0dea, this is my favorite implementation of Levenshtein fuzzing https://i.imgur.com/l9qaEEm.png
[01:59:33] rgtk: has joined #ruby
[01:59:34] B1n4r10: has joined #ruby
[01:59:59] Ox0dea: I like the part where picture of code.
[02:00:10] FailBit: // Rotate dem vec pointers brah.
[02:00:34] FailBit: picture of code because >github >lazy as fuck >what's pastebin
[02:01:33] rgtk: has joined #ruby
[02:01:34] Ox0dea: >> require 'rubygems/text'; include Gem::Text; levenshtein_distance 'FailBit', 'decency'
[02:01:35] ruboto: Ox0dea # => 7 (https://eval.in/466686)
[02:01:39] Yzguy: has joined #ruby
[02:01:48] Ox0dea: Well, that explains that.
[02:02:52] rikai: has joined #ruby
[02:03:01] FailBit: I mean if it wasn't a private repo I'd just link the source because that's easier
[02:03:41] rgtk: has joined #ruby
[02:04:11] Ox0dea: Hold my backtrace, I'm gonna divide by the number of fucks I give.
[02:04:24] Ox0dea: Sorry. <3
[02:04:27] lemur: has joined #ruby
[02:04:44] CloCkWeRX: has joined #ruby
[02:05:22] swgillespie: has joined #ruby
[02:05:39] rgtk: has joined #ruby
[02:05:41] kuya5: has joined #ruby
[02:06:08] m0nge: has joined #ruby
[02:07:03] roxtrongo: has joined #ruby
[02:07:20] rgtk: has joined #ruby
[02:07:57] tkuchiki: has joined #ruby
[02:08:00] rgrmatt: has joined #ruby
[02:09:00] ElSif: that is definitely javascript, i don't think your joke works there ;)
[02:09:20] ElSif: unless Infinity counts as a backtrace...
[02:09:23] rgtk: has joined #ruby
[02:11:03] rgtk: has joined #ruby
[02:11:50] Fire-Dragon-DoL: any trick to focus on work when you really want to play a game but you have to work? :S
[02:12:20] ElSif: uninstall fallout 4?
[02:12:26] CloCkWeRX: has left #ruby: ()
[02:12:46] havenwood: Fire-Dragon-DoL: Play the game then restore your life to a save point before you started playing.
[02:13:05] rgtk: has joined #ruby
[02:13:21] CloCkWeRX: has joined #ruby
[02:13:41] TheNet: has joined #ruby
[02:13:45] cdg: has joined #ruby
[02:13:46] tmtwd: has joined #ruby
[02:14:27] Ox0dea: ElSif: Hm? You definitely get an exception and a backtrace if you divide by zero in Ruby.
[02:14:52] ElSif: true enough, but not in javascript :)
[02:15:00] ytti: anyone aware if nagios or some other software has generic heartbeat alerting. Such as client would do GET http://nagios/heartbeat/$app/$keepalive, and if next GET does not occur within $keepalive nagios would raise alarm for $app down
[02:15:07] rgtk: has joined #ruby
[02:15:38] ElSif: of course you would never
[02:15:41] markfletcher: has joined #ruby
[02:15:53] shevy: you could!
[02:15:58] shevy: my_fancy_variable = 0
[02:16:55] rgtk: has joined #ruby
[02:17:01] Ox0dea: ytti: You could tell a sleeper thread to watch some variable.
[02:17:36] dorei: ytti: i think it's pretty easy to make nagios do that
[02:17:45] Ropeney: has joined #ruby
[02:17:48] ytti: probably
[02:17:49] eam: Ox0dea: depends what kind of zero
[02:18:01] eam: >> 1 / 0.0
[02:18:02] ruboto: eam # => Infinity (https://eval.in/466687)
[02:18:02] ytti: pure ruby solution would be like 50 lines of code
[02:18:07] markfletcher: has left #ruby: ()
[02:18:11] Ox0dea: ytti: Did you mean three?
[02:18:30] shevy: sleeper thread sounds scary
[02:18:44] dorei: Ox0dea: only namespacing will be more than three lines :p
[02:18:55] Ox0dea: > Draco dormiens nunquam titillandus.
[02:19:27] ytti: Ox0dea, i'm talking sensible pretty code
[02:19:35] ytti: sleeper thread also doesn't really work at all
[02:19:50] ytti: i'm thining random crontab job doing curl http://nagios/heartbeat/random/3600
[02:20:14] ytti: or any_language daemon doing http get
[02:20:35] ytti: like rather than tring to figure out if stuff is running
[02:20:41] ytti: assume it's not, unless the stuff tells you it is
[02:20:43] Ox0dea: Just keep it running?
[02:20:45] dorei: what if the network is down? would that still count as app is down?
[02:20:55] ytti: if the NMS isn't receiving the HTTP GET
[02:20:58] ytti: it's down
[02:21:35] Ox0dea: Why not a HEAD request?
[02:22:01] ytti: well what ever
[02:22:06] ytti: i think http get is best
[02:22:16] ytti: as it's usually most stream-lined
[02:22:17] ElSif: do you care about the body?
[02:22:22] dorei: what if the NMS can't send the HTTP GET due to network problems?
[02:22:35] ElSif: then HEAD seems more correct
[02:22:40] ytti: nm's isn't sending http get, clients who are monitored are sending it
[02:22:46] shevy: the new rubygems has different warnings
[02:22:50] ytti: if network between clients and nms is dead, then nms thinks eveyrthing is dead
[02:22:54] shevy: "WARNING: license value 'GPL 2' is invalid. Use a license identifier from http://spdx.org/licenses or 'Nonstandard' for a nonstandard license."
[02:23:05] ytti: HEAD does not seem correct to me
[02:23:18] ytti: because it's more awkward to do
[02:23:22] ytti: and it's not restful
[02:23:40] jhass: shevy: dash not space
[02:23:42] ytti: it's silly optimization when none is needed
[02:23:55] ytti: like, i'd need to do 'man curl' to know how to do HEAD
[02:23:56] jhass: shevy: http://spdx.org/licenses/GPL-2.0.html
[02:23:59] ytti: or man wget
[02:24:02] ytti: or man fetch
[02:24:04] benlieb: has joined #ruby
[02:24:19] ytti: i'd need to read ruby's docs to do head in ruby
[02:24:23] Ox0dea: Sounds like PEBKAC.
[02:24:27] ytti: but in all of those, i can do get without reading docs
[02:24:34] havenwood: shevy: "GPL-2.0"
[02:24:36] ytti: i'm pretty sure this is true for vast audience
[02:24:56] havenwood: shevy: Gem::Licenses::IDENTIFIERS.grep /\AGPL/ #=> ["GPL-1.0", "GPL-2.0", "GPL-3.0"]
[02:24:58] ytti: APIs and UIs are optimising for common case, HTTP GET
[02:25:01] ytti: not for HTTP HEAD
[02:25:02] `based_pdev`: has joined #ruby
[02:25:11] ElSif: please stop T_T
[02:25:40] ElSif: at least dont call that `restful`
[02:25:47] havenwood: ytti: If you want a GET without the body it's a HEAD.
[02:25:47] ytti: well you started the bikeshedding
[02:26:02] ElSif: proper use of HTTP is not bikeshedding
[02:26:05] ytti: havenwood, i want to offer simplest way to announce app is working
[02:26:17] dorei: ytti: do you think that doing a HEAD would lead to an error 500? :D
[02:26:18] havenwood: ytti: A HEAD request to the resource?
[02:26:38] shevy: havenwood cool to see that the licenses are available in the Gem namespace itself, thanks
[02:27:06] jhass: well, I do know a httpd that fucks up a response to a GET when sent after a HEAD using pipelining
[02:27:47] ytti: there is no overhead in server end for me in GET
[02:27:54] ytti: it's simpler for clients to do it
[02:27:59] ytti: it's just way better UX
[02:28:20] ytti: and it's also bikeshedding, as i'm asking for way to heartbeat any client, any app
[02:28:49] shevy: On 08.09.2015, we have had 105,769 gems. On 11.11.2015, we have had 108,695 gems. So in ... 2 months we have about +3000 new gems roughly
[02:29:01] ytti: and if such module perhaps already exists in nagios
[02:29:03] dorei: ytti: what if a malicious user starts sending HEAD to your app?
[02:29:47] havenwood: shevy: Did we meet our quota?
[02:30:12] shevy: I dunno, it's the first time I kept track of that :D
[02:30:31] ytti: dorei, GET, i'm not gonna use HEAD
[02:30:39] shevy: in perhaps a year we can compare again
[02:30:51] ytti: dorei, but yeah, if i get malicious GET, i presume client is healthy, even when it is not
[02:31:06] cdg: has joined #ruby
[02:31:06] ytti: dorei, but really not a problem for my use-case, as no malicious request would come
[02:31:26] ElSif: saying `about +3000` when it is actually less than 3000 is hilarious
[02:31:35] ElSif: but still :D
[02:31:36] htmldrum: has joined #ruby
[02:32:08] diegoaguilar: has joined #ruby
[02:32:09] cdg: has joined #ruby
[02:32:40] shevy: a tiny margin
[02:32:48] shevy: don't call us lazy!!!
[02:34:27] griffindy: has joined #ruby
[02:34:31] Sirecote: has joined #ruby
[02:34:49] ElSif: what about `bloated`?
[02:35:56] ElSif: ytti: if your question is really just, how do i check for a http response in nagios?, then i believe it is the check_http module
[02:36:13] DLSteve: has joined #ruby
[02:37:29] ytti: ElSif, it's more broad, how do I ensure that random daemons, apps etc are running
[02:37:33] aaeron: has joined #ruby
[02:37:53] ElSif: ytti: you could set a custom header for each one
[02:37:55] ytti: ElSif, my idea is to let them announce they still running, and have 0config server keep state
[02:38:13] ytti: but i'm not sure if this is good approach, perhaps this is solved problem with existing module
[02:38:25] Vile`: has joined #ruby
[02:38:50] ElSif: maybe, i haven't use nagios in years
[02:39:07] ytti: in $job-2 i did this with MQTT, but MQTT is clearly lot more awkward to send messages to, than HTTP GET
[02:39:29] ytti: but in that use-case, i was mostly thinking of random ruby code, so it was ok, as I had internal library to make it super easy
[02:39:34] ytti: require 'xxx/mq'
[02:39:42] ytti: XXX::MQ.beat 3600
[02:39:55] ytti: was all i neede to do, to ahve monitoring for that particular piece of coke
[02:40:13] ElSif: try `/join #nagios`
[02:40:45] ytti: probably /join #nms or something, as it's very broad/generic question on how to ensure software is running
[02:41:10] ElSif: but if there is a module....
[02:42:06] ytti: out of curiosity, how have you in current or some previous job solved this?
[02:42:22] Arkon: has joined #ruby
[02:42:39] ytti: there tends to be gazillion of small crontab jobs and daemons here and there in every company
[02:42:40] blackmesa: has joined #ruby
[02:43:33] araujo_: has joined #ruby
[02:43:44] claptor: has joined #ruby
[02:45:26] opensource_ninja: has joined #ruby
[02:45:35] eam: ytti: consider something like runit
[02:46:42] eam: ytti: maybe with a tool like this to build the runit job directories https://github.com/square/prodeng/tree/master/servicebuilder
[02:46:54] cmoneylulz: has joined #ruby
[02:46:56] B1n4r10: has joined #ruby
[02:47:24] ytti: eam, i think this proposal misses the point, runit would still only restart if it knows failure happens
[02:47:53] ytti: eam, while my approach considers failure happened, unless we get information of success
[02:47:58] axisys: has joined #ruby
[02:48:07] ytti: eam, it's far more robust way to do it
[02:48:13] eam: ytti: yeah, you're monitoring - agreed you want both
[02:48:15] ytti: eam, in runit scenario, the problem recurses
[02:48:23] eam: well, it doesn't recurse
[02:48:29] eam: runit is run by init
[02:48:37] eam: init is guaranteed to be up
[02:48:42] ytti: yes, but now we need to monitor runit
[02:48:55] eam: sure, monitoring is different than process supervision
[02:49:13] ytti: and if we build solution to monitor runit, we need to monitor that solution
[02:49:14] eam: agreed you should determine and measure your success criteria
[02:49:19] eam: well, you don't actually
[02:49:31] eam: typically you want to monitor *only* the success criteria for an app
[02:49:33] eam: and no other metrics
[02:50:09] ytti: specifically absense of information about failure, does not mean failure didn't occur
[02:50:11] eam: eg, can I successfully fetch /_status via https? Within a bounded latency? Without error rate? If so, I don't care about load average, CPU, or any other secondary factors
[02:50:26] eam: you wouldn't want to monitor something like runit
[02:50:49] ytti: agreed, but if runit is my solution to monitor app, then i would (hence recursion)
[02:50:56] eam: yeah, it's not that
[02:51:40] ytti: i think most nms solutions appraoch to problem this way, they are looking for failures
[02:51:47] eam: "ensure running" is different from "ensure operationally sound"
[02:51:48] ytti: which is very fragile way to solve the problem
[02:51:58] ytti: compared to looking for absense of success
[02:51:58] duncannz: has joined #ruby
[02:52:05] eam: most monitoring is garbage
[02:52:12] ytti: which is inherently robust (with higher chance of false positives, obviously)
[02:52:15] ElSif: from what you have said i think you really just want a route in your app for nagios to hit with an active check
[02:52:49] eam: one that exercises the database, naturally :)
[02:53:10] ElSif: and trys an email too
[02:53:17] eam: pretty quick, I think you can converge on "run all my tests in production, continually"
[02:54:14] ytti: i should sleep instead of trying to solve this now, it's 5am and roosters are already crowing :/
[02:54:18] ElSif: because if it aint broken, we had better keep checking
[02:54:33] ElSif: ytti: sleep is always the right answer
[02:55:05] ytti: i thought it would be peace and quiet in country-side, much noisier than in central helsinki
[02:55:24] rattatmatt: has joined #ruby
[02:55:30] RegulationD: has joined #ruby
[02:56:15] rattatmatt: has joined #ruby
[02:57:39] shevy: you forgot that finns love two things
[02:57:46] shevy: (1) sauna
[02:57:48] shevy: (2) party !!!
[02:58:11] mattwildig: has joined #ruby
[02:58:14] shevy: You can't go wrong with El?kel?iset
[02:58:45] bruno-: has joined #ruby
[02:59:47] RobertBirnie: has joined #ruby
[03:00:12] Yzguy: has joined #ruby
[03:00:35] benlovell: has joined #ruby
[03:00:44] Yzguy: random thought: what if you made some tutorial thing for git. like clone this repo, run like rake level:1
[03:00:56] rickmasta: has joined #ruby
[03:00:57] Yzguy: then you get README with a challenge
[03:01:05] Radar: Yzguy: it's been done: http://rubykoans.com/
[03:01:40] Yzguy: this is for ruby though, i mean like to learn git stuff.
[03:01:43] Yzguy: same idea though
[03:02:09] Yzguy: like commit a file and push to master, level 1 done, level 2, etc. level 10 is like cherry pick a commit from branch x into branch y
[03:02:57] Yzguy: curious how feasible that would be.
[03:03:11] qiukun: has joined #ruby
[03:03:26] Ox0dea: Yzguy: http://gitimmersion.com/lab_01.html
[03:03:35] Ox0dea: By the same folks who started the Ruby Koans, it seems.
[03:03:46] Yzguy: i will never have an original idea...
[03:04:37] weemsledeux: has joined #ruby
[03:05:11] baweaver: has joined #ruby
[03:05:55] Yzguy: well yeah, this is exactly what i was thinking
[03:06:38] edj: whats the difference between a lambda and a method?
[03:07:48] FailBit: lambdas are objects
[03:07:59] FailBit: methods are... methods
[03:08:49] shevy: Yzguy hah I thought about that too, all my ideas other people may have had, but the bigger ideas, when you don't see anyone having implemented it, now this is where you could shine - by using that idea to build something grand
[03:09:35] Yzguy: most of the time I find someone else did it so i get discouraged and stop doing it
[03:09:52] infamos: has joined #ruby
[03:11:19] dikaio: has joined #ruby
[03:11:36] Ox0dea: edj: They both encapsulate the basic notion of a "function", but a method is a function attached to an object, and a lambda is a function without a name.
[03:11:56] qiukun: has joined #ruby
[03:12:40] hxegon: has joined #ruby
[03:13:26] Ox0dea: >> m = 42.method(:to_s); [m.name, m.owner] # edj
[03:13:27] ruboto: Ox0dea # => [:to_s, Fixnum] (https://eval.in/466692)
[03:13:35] Ox0dea: See, a method has a name and an owner; a lambda has neither.
[03:14:44] ruby761: has joined #ruby
[03:14:52] edj: so a lambda can just take an argument where a method needs an actual object
[03:14:57] Yzguy: fawk....systemctl restart network, meant to do httpd
[03:15:53] xcesariox: has joined #ruby
[03:16:44] favadi: has joined #ruby
[03:17:14] Ox0dea: edj: Your question belies some fundamental misunderstanding, but I'm having trouble pinpointing exactly what that might be.
[03:17:52] Yzguy: have you guys heard of facebook osquery? I think it'd be kind of neat to use that as the backend of a rails app
[03:17:55] Ox0dea: Could you clarify your understanding of what constitutes an "actual object"?
[03:18:28] reaVer: has joined #ruby
[03:22:22] kp666: has joined #ruby
[03:22:43] Arkon: has joined #ruby
[03:22:45] sdwrage: has joined #ruby
[03:22:52] craigp: has joined #ruby
[03:23:19] mjuszczak: has joined #ruby
[03:24:34] jfranz2: has joined #ruby
[03:25:32] Yzguy: has joined #ruby
[03:25:52] jfranz2: Noob here, how can I make this script work - http://pastebin.com/rAVyyUhZ
[03:25:53] ruboto: jfranz2, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/e1d4571c44136a73eb6a
[03:25:53] ruboto: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
[03:27:18] Ox0dea: jfranz2: `gets.chomp` will never be `nil`, so there's no point in checking that; you probably want to check whether `fourword` is empty instead.
[03:27:28] Ox0dea: And then you have an off-by-one error on Line 10.
[03:28:16] UtkarshRay: has joined #ruby
[03:28:52] pdoherty: has joined #ruby
[03:29:37] jfranz2: Line 10 is supposed to say "elsif fourword.length > 4", oops. Also thanks, I didn't know that.
[03:29:47] sankaber: has joined #ruby
[03:30:40] ElSif: also, checking for equality to nil is not terribly pretty :) you can just check truthyness
[03:30:49] UtkarshRay: has joined #ruby
[03:31:11] cesario: has joined #ruby
[03:31:32] ElSif: (sounds like you get that though)
[03:34:35] ElSif: somone recently said to me that a ruby slack channel would be better for ruby discussion than a ruby irc because it is more available to less technical people. I am curious about anyones thoughts on this.
[03:35:25] Ox0dea: Why are "less technical" people in a programming language channel?
[03:36:00] ElSif: yea, very good question but also didn't take the discussion beyond 'well they can have good input too'
[03:36:12] ElSif: do you think it would just be too noisy for good discussion?
[03:37:21] AnoHito: has joined #ruby
[03:37:43] Fire-Dragon-DoL: ok folks, leaving to play some FTL
[03:37:49] ElSif: it seems like an oddly controversial topic... im not against it but i really don't see slack as terribly simpler to use than irc. is the real problem just a buzz-service one? new service that has pretty buttons is better?
[03:37:51] favadi: has joined #ruby
[03:38:02] ElSif: godspeed Fire-Dragon-DoL
[03:38:12] Ox0dea: Now he's gonna go to Hell. :<
[03:38:57] ElSif: i didn't get that feeling....
[03:39:09] shevy: what happened to people using an IRC client to connect to irc
[03:39:09] Ox0dea: Well, he left just before your godspeed got through.
[03:39:49] Ox0dea: It still baffles me that things like Arch and IRC are perceived to be "difficult".
[03:40:13] shevy: arch became a distribution for the clever
[03:40:33] ElSif: i didn't realise reading the manual was clever ;)
[03:40:57] Ox0dea: I guess that's it, isn't it? The average person can't stand to read.
[03:41:03] shevy: you can read manuals all day long
[03:43:02] ElSif: i don't know that it really is that, i think some of it is just different strokes for different computer folks
[03:43:56] pwnd_nfsw: has joined #ruby
[03:44:33] shevy: I knew of a swedish gentoo dude who went the arch route, then lateron went back again to gentoo stating that it allowed for him to customize and optimize more than arch
[03:45:14] blackmesa: has joined #ruby
[03:45:17] ElSif: gentoo, for wen every picosecond counts
[03:45:18] dorei: shevy: let's hope that he installed gentoo only on his computer
[03:45:40] trosborn: has joined #ruby
[03:46:23] shevy: I think so, he was a radical
[03:46:38] ElSif: a FREE radical???
[03:47:13] shevy: he'd preach about how awesome arch is, then one day suddenly was back at gentoo :D
[03:47:32] ElSif: i don't think i will be doing that any time soon
[03:47:42] ElSif: though installing gentoo is great fun
[03:47:49] shevy: he also was using ruby. It always felt unclean for me to want to use gentoo's python portage
[03:48:26] ElSif: oh yea, when you get that final emerge started and just lean back watching the whole system compile you feel great
[03:48:27] shevy: I once tried to install gentoo. one had to compile from source. I put it on my laptop, things took so long, I went to bed. I woke up, and some compile error happened
[03:48:41] shevy: yeah unless you hit some error
[03:48:44] ElSif: yea, laptop with gentoo = don't update on battery power
[03:49:02] Ox0dea: You learn much more about gcc's diagnostic messages than you do Linux by installing Gentoo.
[03:49:10] ElSif: ^ this is true
[03:49:15] ElSif: but there is some overlap there
[03:49:20] Ox0dea: ^ This is true.
[03:49:49] ElSif: dam, urs was actually funny
[03:50:08] kfpratt: has joined #ruby
[03:50:24] Ox0dea: >> /\p{Radical}/
[03:50:25] ruboto: Ox0dea # => /\p{Radical}/ (https://eval.in/466697)
[03:50:33] Ox0dea: I knew there was something.
[03:50:46] solocshaw: has joined #ruby
[03:52:39] ElSif: i do have 1 real gripe with slack, and that is that long text 'snippets' lag the render time on my laptop horribly
[03:53:01] peppers: has joined #ruby
[03:53:09] shevy: everything changes
[03:53:32] eam: is that the only gripe? I have plenty more
[03:53:52] dorei: slack was asking for my email, i stopped there
[03:54:31] ElSif: ha, if only i could
[03:54:41] ElSif: slack seems to have become a love affair here in portland
[03:54:42] shevy: dorei you have something to hide!
[03:54:51] Ox0dea: I'm phoning the authorities!
[03:54:53] eam: my employer uses it unfortunately :( it's right up there with other contenders in this space: MS Exchange, Lotus Notes
[03:55:17] dorei: shevy: i think not having an fb account is more suspicious :p
[03:55:18] eam: I'm astounded that anyone can get interested in shitty business middleware like this
[03:55:31] shevy: dorei do you have one?
[03:55:42] dorei: lotus notes? so, it still exists xD
[03:55:42] Ox0dea: shevy: They just said they didn't.
[03:56:01] Meow-J: has joined #ruby
[03:56:07] eam: the slack of yesteryear
[03:56:18] dorei: shevy: nop, but i'm thinking of making one so as not raise flags
[03:56:24] eam: Stable release: 9.0.1 FP4 / June 17, 2015; 4 months ago
[03:56:33] ElSif: once i had to use bank software fromt he early 90s i became pretty desenstised to griping about company software :p
[03:56:40] eam: dorei: https://en.wikipedia.org/wiki/IBM_Notes
[03:56:49] daivyk: has joined #ruby
[03:57:36] jfranz2: Okay, here is my revised code: https://gist.github.com/anonymous/7d7cc009a8e25f63978b -- how can I make it so line 8 only activates when "fourword" is not empty.
[03:58:56] djstorm: has joined #ruby
[03:59:29] bruno-: has joined #ruby
[03:59:34] eam: jfranz2: !fourword.empty? && fourword.length < 4
[04:00:20] Ox0dea: jfranz2: You should just check whether the input is empty first.
[04:01:52] gambl0re: has joined #ruby
[04:02:27] jfranz2: Thanks guys, that made it work.
[04:02:37] trosborn: has joined #ruby
[04:03:22] Ox0dea: jfranz2: Have some learnin's: https://eval.in/466698
[04:03:53] Ox0dea: Ignore the error output; I forgot to provide something on stdin, but I swear it works.
[04:06:01] baweaver: has joined #ruby
[04:07:21] astrobunny: has joined #ruby
[04:07:49] roxtrongo: has joined #ruby
[04:07:51] tkuchiki: has joined #ruby
[04:08:01] araujo: has joined #ruby
[04:08:01] araujo: has joined #ruby
[04:08:10] astrobunny: has joined #ruby
[04:09:18] Ox0dea: Why am I not surprised? https://eval.in/66666
[04:10:08] Axsuul: has joined #ruby
[04:10:21] baweaver: has joined #ruby
[04:11:03] braincrash: has joined #ruby
[04:11:03] _kfpratt: has joined #ruby
[04:11:31] gix: has joined #ruby
[04:12:32] Eiam_: has joined #ruby
[04:12:50] trosborn: has joined #ruby
[04:15:16] simplyianm: has joined #ruby
[04:15:20] towski_: has joined #ruby
[04:22:04] braincra-: has joined #ruby
[04:24:39] phillips1012: has joined #ruby
[04:24:50] DLSteve: has joined #ruby
[04:27:46] htmldrum: has joined #ruby
[04:28:00] tkuchiki: has joined #ruby
[04:29:34] slawrence00: has joined #ruby
[04:29:50] CloCkWeRX: has left #ruby: ()
[04:31:24] dravine_: has joined #ruby
[04:32:45] jackjackdripper: has joined #ruby
[04:32:59] hxegon: has joined #ruby
[04:34:15] colegatron: has joined #ruby
[04:34:24] fschuindt: has joined #ruby
[04:36:02] vdamewood: has joined #ruby
[04:37:07] fschuindt: Is it possible in Ruby to "mock" a class? For instance, @foo.bar = true, without a object @foo, just mock up the call to return true.
[04:37:45] joneshf-laptop: has joined #ruby
[04:37:52] Rodya_: has joined #ruby
[04:39:05] ThatsNotJack: has joined #ruby
[04:40:35] B1n4r10: has joined #ruby
[04:40:44] kp666: has joined #ruby
[04:41:37] havenwood: fschuindt: https://gist.github.com/havenwood/84207afa092ce5d5a680
[04:41:47] kp666: has joined #ruby
[04:42:09] astrobunny: has joined #ruby
[04:42:26] ThatsNotJack: has joined #ruby
[04:42:30] krz: has joined #ruby
[04:42:38] pygospa: has joined #ruby
[04:42:50] qiukun: has joined #ruby
[04:43:51] Guest99824: has joined #ruby
[04:43:57] kp666: has joined #ruby
[04:45:59] blackmesa: has joined #ruby
[04:46:11] mghaig: has joined #ruby
[04:47:07] kp666: has joined #ruby
[04:47:39] benlovell: has joined #ruby
[04:49:26] techietrash: has joined #ruby
[04:50:12] EminenceHC: has joined #ruby
[04:50:17] makenoise: has joined #ruby
[04:50:23] mghaig: has joined #ruby
[04:51:11] fschuindt: havenwood: cool, ty
[04:54:06] darkf: has joined #ruby
[04:58:24] TheNet: has joined #ruby
[04:58:31] cmoneylulz: has joined #ruby
[04:59:27] havenwood: fschuindt: np
[05:00:37] bruno-: has joined #ruby
[05:05:31] qiukun: has joined #ruby
[05:06:18] RobertBirnie: has joined #ruby
[05:06:31] charliesome: has joined #ruby
[05:09:05] rickmasta: has joined #ruby
[05:13:11] patdohere: has joined #ruby
[05:13:16] ponga: has joined #ruby
[05:13:38] qiukun: has joined #ruby
[05:18:47] patdohere: has joined #ruby
[05:21:50] Hobbyboy: has joined #ruby
[05:22:08] molay: has joined #ruby
[05:23:28] molay: I'm looking to get started with TDD (mainly bdd) and i've heard of rspec. Where's the best place for me to start? I done some reading on rspec, but i'm having trouble wrapping my head around it
[05:25:11] makenoise: check out http://www.theodinproject.com/ruby-programming/introduction-to-rspec
[05:25:35] makenoise: that was my first intro to it
[05:25:45] rattatmatt: has joined #ruby
[05:26:29] molay: oh yeah that's a good site.
[05:26:34] molay: makenoise: thanks!
[05:27:27] molay: ok next question, i need a website that will make me smarter in general...
[05:27:45] molay: because i'm partially retarded..
[05:28:11] molay: well, maybe learning to program makes me feel that way...
[05:28:21] makenoise: that just means you are doing it right
[05:28:47] makenoise: browse around the rest of that site i sent you, amazing resource
[05:29:02] weemsledeux: has joined #ruby
[05:29:24] molay: actually, yes, I've been to this site before.. It rocks. I keep forgetting to go back
[05:31:27] akem: has joined #ruby
[05:32:01] makenoise: has joined #ruby
[05:33:14] qiukun: has joined #ruby
[05:35:02] CloCkWeRX: has joined #ruby
[05:35:26] Radar: molay: Do you know any Ruby?
[05:37:54] aaeron: has joined #ruby
[05:38:26] makenoise: You can try me, there's a ton of people on here too that will speak up if I can't help.
[05:38:41] SpikeMaster: has joined #ruby
[05:38:47] SpikeMaster: has left #ruby: ("ERC (IRC client for Emacs 24.5.1)")
[05:42:02] ElSif: has joined #ruby
[05:42:50] wildlander: has joined #ruby
[05:43:52] agent_white: has joined #ruby
[05:44:00] ngscheurich: has joined #ruby
[05:44:02] mattwildig: has joined #ruby
[05:45:50] subscope: has joined #ruby
[05:45:58] agent_white: Evenin' folks
[05:46:45] blackmesa: has joined #ruby
[05:46:56] favadi: has joined #ruby
[05:47:13] kerunaru: has joined #ruby
[05:47:58] mozzarella: has joined #ruby
[05:50:46] beast: has joined #ruby
[05:51:28] qiukun: has joined #ruby
[05:51:43] kies: has joined #ruby
[05:52:10] kies: has joined #ruby
[05:53:33] mghaig: has joined #ruby
[05:54:00] ElSif: has joined #ruby
[05:56:22] Radar: good evening agent_white
[05:58:42] dionysus69: has joined #ruby
[05:59:03] ss_much: has joined #ruby
[05:59:08] skade: has joined #ruby
[05:59:24] JosephBriggs: has joined #ruby
[06:00:00] trosborn: has joined #ruby
[06:00:38] JosephBriggs: why aren't black programmers as competent as the Asian, brown, or white ones?
[06:00:50] ruboto: -o ruboto
[06:01:06] JosephBriggs: has left #ruby: ()
[06:01:33] havenwoood: has joined #ruby
[06:01:47] havenwoood: I hate niggers
[06:01:53] ruboto: -o ruboto
[06:02:07] Radar: !ban havenwoood
[06:02:11] Radar: !ban havenwoood !T 1d
[06:02:12] ChanServ: +b havenwoood!*@*
[06:02:12] ChanServ: ChanServ kicked havenwoood: is banned from this channel
[06:02:38] pontiki: that was surreal
[06:02:40] ChanServ: +o havenwood
[06:02:58] Radarr: has joined #ruby
[06:02:59] ChanServ: +b *!*@172.56.38.154
[06:02:59] ChanServ: ChanServ kicked Radarr: is banned from this channel
[06:03:57] howdoi: has joined #ruby
[06:05:07] grekko: has joined #ruby
[06:05:38] grekko: has joined #ruby
[06:06:10] blubjr`: has joined #ruby
[06:06:15] safe: has joined #ruby
[06:06:23] darkf_: has joined #ruby
[06:07:04] ChanServ: -o havenwood
[06:07:28] mgorbach_: has joined #ruby
[06:08:30] roxtrongo: has joined #ruby
[06:08:57] crdpink2: has joined #ruby
[06:09:00] dh64: has joined #ruby
[06:09:11] molay: Radar: yes i know some ruby. i'm learning
[06:10:42] akem: i found the bug bible down my lower back
[06:13:31] chrissonar: has joined #ruby
[06:14:10] hxegon: has joined #ruby
[06:14:19] favadi: has joined #ruby
[06:15:06] norc: has joined #ruby
[06:15:29] User458764: has joined #ruby
[06:16:11] User458764: has joined #ruby
[06:16:40] trosborn: has joined #ruby
[06:17:17] adac: has joined #ruby
[06:17:34] dhjondoh: has joined #ruby
[06:20:17] tmtwd: has joined #ruby
[06:20:37] djbkd: has joined #ruby
[06:26:08] devoldmx: has joined #ruby
[06:27:25] flip_digits: has joined #ruby
[06:28:32] lettuce: has joined #ruby
[06:28:53] devoldmx: has joined #ruby
[06:34:03] norc_: has joined #ruby
[06:34:55] dhjondoh: has joined #ruby
[06:34:56] aganov: has joined #ruby
[06:35:56] Arkon: has joined #ruby
[06:40:40] x-light: has joined #ruby
[06:41:49] ruby-lang609: has joined #ruby
[06:43:03] griffindy: has joined #ruby
[06:43:34] simplyianm: has joined #ruby
[06:47:06] baweaver: has joined #ruby
[06:47:08] User458764: has joined #ruby
[06:47:32] blackmesa: has joined #ruby
[06:47:50] gard_: has joined #ruby
[06:48:09] luriv_: has joined #ruby
[06:48:25] magic__: has joined #ruby
[06:50:08] norc_: http://stdout.koraktor.de/blog/2010/10/13/ruby-calling-super-constructors-from-multiple-included-modules/
[06:50:20] norc_: Okay, this is neat and disgusting at the same time...
[06:50:30] kuya5: has left #ruby: ("Leaving")
[06:51:22] lsv: has joined #ruby
[06:51:57] tagrudev: has joined #ruby
[06:56:48] yardenbar: has joined #ruby
[07:01:32] Pupp3tm4st3r: has joined #ruby
[07:02:26] bruno-: has joined #ruby
[07:02:51] ta: has joined #ruby
[07:03:13] sinkensabe: has joined #ruby
[07:03:59] lxsameer: has joined #ruby
[07:04:14] Coldblackice: has joined #ruby
[07:06:23] kerunaru: has joined #ruby
[07:07:01] aaeron: has joined #ruby
[07:08:10] rickmasta: has joined #ruby
[07:09:16] roxtrongo: has joined #ruby
[07:09:44] exadeci: has joined #ruby
[07:10:10] Feyn: has joined #ruby
[07:12:03] grekko: has joined #ruby
[07:14:55] rattatmatt: has joined #ruby
[07:16:19] lsmola: has joined #ruby
[07:16:42] boshhead: has joined #ruby
[07:17:28] symm-: has joined #ruby
[07:21:58] trosborn: has joined #ruby
[07:22:02] AustinMatherne: has joined #ruby
[07:22:41] diegoaguilar: has joined #ruby
[07:23:59] tubuliferous_: has joined #ruby
[07:25:01] hxegon_: has joined #ruby
[07:28:36] bigkevmcd: has joined #ruby
[07:29:01] flip_digits: has joined #ruby
[07:29:30] Maletor: has joined #ruby
[07:30:47] benlieb: has joined #ruby
[07:33:23] Caius: has joined #ruby
[07:37:12] Polysics: has joined #ruby
[07:38:44] terminalrecluse: has joined #ruby
[07:40:48] mghaig: has joined #ruby
[07:41:18] tkuchiki_: has joined #ruby
[07:41:50] benlieb_: has joined #ruby
[07:43:36] nirix: has joined #ruby
[07:44:16] diesel: has joined #ruby
[07:44:27] crowell: has joined #ruby
[07:44:29] Kruppe: has joined #ruby
[07:44:29] armyriad: has joined #ruby
[07:44:42] krz: has joined #ruby
[07:44:44] Synthead: has joined #ruby
[07:44:54] wlanboy: has joined #ruby
[07:45:11] yeticry: has joined #ruby
[07:46:01] LiquidInsect: has joined #ruby
[07:46:20] minimalism: has joined #ruby
[07:46:27] zacts: has joined #ruby
[07:46:48] trosborn: has joined #ruby
[07:47:00] agent_white: has joined #ruby
[07:48:03] terminalrecluse: has joined #ruby
[07:48:15] baweaver: has joined #ruby
[07:49:03] DoubleMalt: has joined #ruby
[07:49:18] solars: has joined #ruby
[07:49:33] blackmesa: has joined #ruby
[07:49:49] bricker1: has joined #ruby
[07:51:55] norc_: ACTION pokes shevy with a japanese coding stick
[07:51:56] SenpaiSilver: has joined #ruby
[07:52:05] norc_: I have again written a line of Ruby code.
[07:52:38] mark1: has joined #ruby
[07:52:58] Stan: has joined #ruby
[07:53:35] certainty: now have a jelly sandwhich
[07:53:49] LiquidInsect: has joined #ruby
[07:54:15] krz: has joined #ruby
[07:54:18] minimalism: has joined #ruby
[07:54:26] norc_: certainty: Meh, not sure my stomach would be thankful if I did that.
[07:55:32] ianchentw: has joined #ruby
[07:55:46] teclator: has joined #ruby
[07:56:31] aganov: has joined #ruby
[07:56:38] tagrudev: has joined #ruby
[07:57:32] ta: has joined #ruby
[08:01:31] asas: has joined #ruby
[08:01:35] skade: has joined #ruby
[08:02:46] Synthead: has joined #ruby
[08:07:07] Arkon: has joined #ruby
[08:07:18] subscope: has joined #ruby
[08:10:11] qiukun: has joined #ruby
[08:10:13] trosborn: has joined #ruby
[08:10:57] last_staff: has joined #ruby
[08:13:05] TomyWork: has joined #ruby
[08:13:33] qiukun: has joined #ruby
[08:13:49] favadi: has joined #ruby
[08:16:10] Maletor: has joined #ruby
[08:21:35] Pupp3tm4st3r: has joined #ruby
[08:22:18] SCHAAP137: has joined #ruby
[08:23:04] adac: has joined #ruby
[08:25:25] kimegede: has joined #ruby
[08:25:45] atmosx: Hello, can someone figure out what is going on here? https://gist.github.com/atmosx/00bf66625d0c43bc80b4 the problem seems to be the 'gets.chomp' method: https://gist.github.com/atmosx/00bf66625d0c43bc80b4#file-rakefile-L18
[08:28:11] benlovell: has joined #ruby
[08:28:40] Coldblackice: has joined #ruby
[08:31:32] lukaszes: has joined #ruby
[08:31:54] jiada: has joined #ruby
[08:33:22] aufi: has joined #ruby
[08:37:25] tulak: has joined #ruby
[08:37:47] __desmondhume: has joined #ruby
[08:41:54] catbusters: has joined #ruby
[08:45:06] cicloid: has joined #ruby
[08:45:48] marienz: has joined #ruby
[08:46:30] blaxter: has joined #ruby
[08:48:17] agent_white: has joined #ruby
[08:48:26] User458764: has joined #ruby
[08:48:43] Hounddog: has joined #ruby
[08:49:19] minimalism: has joined #ruby
[08:50:20] blackmesa: has joined #ruby
[08:53:18] teclator: has joined #ruby
[08:53:36] scmx: has joined #ruby
[08:55:03] neanderslob_: has joined #ruby
[08:55:49] TheHodge: has joined #ruby
[08:55:55] Hounddog: has joined #ruby
[08:56:45] codecop: has joined #ruby
[08:56:46] karapetyan: has joined #ruby
[08:57:08] Rodya_: has joined #ruby
[08:59:07] benlieb: has joined #ruby
[08:59:56] nfk|laptop: has joined #ruby
[09:02:31] mikecmpbll: has joined #ruby
[09:03:42] moeabdol: has joined #ruby
[09:03:53] bruno-: has joined #ruby
[09:04:14] lipoqil: has joined #ruby
[09:08:39] skade: has joined #ruby
[09:08:45] subscope: has joined #ruby
[09:10:02] roxtrongo: has joined #ruby
[09:12:07] beast: has joined #ruby
[09:13:24] maokomioko: has joined #ruby
[09:15:06] phillips1012: has joined #ruby
[09:16:01] Xzanron: has joined #ruby
[09:16:11] marr: has joined #ruby
[09:16:50] zotherstupidguy: has joined #ruby
[09:18:52] yfeldblum: has joined #ruby
[09:21:44] weckl: has joined #ruby
[09:22:28] antgel: has joined #ruby
[09:23:14] rdark: has joined #ruby
[09:23:14] rdark: has joined #ruby
[09:23:35] tomphp: has joined #ruby
[09:25:33] vigintas: has joined #ruby
[09:25:42] timonv: has joined #ruby
[09:28:44] emilkarl: has joined #ruby
[09:28:57] lukaszes: has joined #ruby
[09:29:05] mghaig: has joined #ruby
[09:30:35] flip_digits: has joined #ruby
[09:32:51] CloCkWeRX: has joined #ruby
[09:33:04] darkf_: has joined #ruby
[09:34:23] waka: has joined #ruby
[09:34:58] dkam: has joined #ruby
[09:35:11] zotherstupidguy: anyone from ukraine? need some info! whats the other group for non-ruby related talk?
[09:36:00] trosborn: has joined #ruby
[09:37:20] apeiros: zotherstupidguy: offtopic is in #ruby-offtopic
[09:37:33] apeiros: not sure whether there's an ukrainian ruby channel
[09:38:03] leafybas_: has joined #ruby
[09:41:04] howdoi: has joined #ruby
[09:41:15] mooe: has joined #ruby
[09:42:14] neanderslob: has joined #ruby
[09:45:43] mattwildig: has joined #ruby
[09:46:55] dmolina: has joined #ruby
[09:47:30] krz: has joined #ruby
[09:48:24] blackmesa: has joined #ruby
[09:48:52] shredding: has joined #ruby
[09:50:50] baweaver: has joined #ruby
[09:51:45] dmolina: has left #ruby: ()
[09:53:09] leafybas_: has joined #ruby
[09:56:33] vigintas: has joined #ruby
[09:56:52] jamesaxl: has joined #ruby
[09:57:16] rodfersou: has joined #ruby
[09:57:53] c0m0: has joined #ruby
[09:58:53] subscope: has joined #ruby
[09:59:03] lapide_viridi: has joined #ruby
[09:59:37] waka: has joined #ruby
[09:59:38] waka_: has joined #ruby
[09:59:40] Rodya_: has joined #ruby
[10:00:50] platzhirsch: has joined #ruby
[10:00:53] stamina: has joined #ruby
[10:00:58] joneshf-laptop: has joined #ruby
[10:01:02] arne: has joined #ruby
[10:01:12] TPBallbag: has joined #ruby
[10:01:48] shevy: norc_ you probably copy/pasted something from stackoverflow :)
[10:02:35] arne: :( how do i require files that depend on each other, having the files prefixed with 00_ etc feels hacky to me
[10:03:02] shevy: that can be tricky but usually one of the files is further down the base
[10:03:41] arne: somehow i thought, ruby will not care about not yet defined classes
[10:04:28] certainty: depends where you reference them
[10:04:30] apeiros: it does not. only when you try to use them it will.
[10:04:48] shevy: well you have to be consistent in what you pull in and define when; class Foo versus class Foo < Bar would be two different ones
[10:04:50] apeiros: ruby also does not care about the name of the file you require, so prefixing with 00_ is only for you, not for ruby
[10:05:16] arne: apeiros, i know but it "fixes" the problem
[10:05:39] dtordable: has joined #ruby
[10:05:41] bruno-: has joined #ruby
[10:05:41] apeiros: arne: something else fixes the problem. definitively not the change of names of required files.
[10:05:41] arne: well i do files_in_folder.each { |file| require file}
[10:06:00] apeiros: so there's your answer.
[10:06:10] arne: so it does "fix" the problem, but i wouldn't go as far and call it a fix :D
[10:06:14] apeiros: don't use .each. be explicit in requires and fix the ordering.
[10:06:28] tagrudev: has joined #ruby
[10:06:32] arne: yeah, but as i said, having the order in filenames seems hacky to me
[10:06:37] apeiros: shevy: `class Foo < Bar; end; class Foo; end` works, whereas `class Foo; end; class Foo < Bar; end` does not
[10:06:49] apeiros: arne: as said, DONT HAVE THEM in the filenames.
[10:06:53] waka: has joined #ruby
[10:06:54] apeiros: have them in the way you require
[10:07:09] nfk|laptop: has joined #ruby
[10:07:17] arne: you mean doing it by hand? writing the names?
[10:07:18] neanderslob: has joined #ruby
[10:07:23] apeiros: and even then it's not necessary if the files which have dependencies require those themselves.
[10:07:29] apeiros: arne: d'uh. yes.
[10:07:38] arne: but.. im lazy :(
[10:07:46] apeiros: then let the computer write the requires for you.
[10:08:10] shevy: build it like a lego pyramid
[10:08:23] certainty: have a jelly sandwhich
[10:08:38] shevy: certainty likes sandwhiches
[10:08:42] arne: yeah, i should have done that, when deciding my folder-structure, but i didn't know about that problem back then
[10:08:50] certainty: shevy: nope, just want others to eat them
[10:08:54] certainty: it's my fetish
[10:08:58] riffraff: has joined #ruby
[10:10:02] platzhirsch: has joined #ruby
[10:10:10] shevy: I remember back when I moved from ruby 1.8.x to ruby 1.9.x and beyond, there were the new "circular loading in progress" warnings
[10:10:22] shevy: that took a while before I could resolve that. was quite annoying actually
[10:10:27] certainty: shevy: last week you mean?
[10:10:48] dionysus69: has joined #ruby
[10:10:50] akem: has joined #ruby
[10:11:11] shevy: some years ago
[10:11:29] certainty: oh right, list week you finally switched to unicode
[10:11:31] DEA7TH: has joined #ruby
[10:12:23] shevy: no, I am unicode free
[10:12:35] cesario: has joined #ruby
[10:13:44] Peg-leg: has joined #ruby
[10:14:20] arne: bleh, if C is a subclass of B and B is a subclass of A, C isn't a subclass of A?
[10:14:44] adaedra: >> class A; end; class B < A; end; class C < B; end; C.new.is_a? A
[10:14:45] ruboto: adaedra # => true (https://eval.in/466931)
[10:15:00] dkam: has joined #ruby
[10:15:33] tobiasvl: >> class A; end; class B < A; end; class C < B; end; C.ancestors
[10:15:34] ruboto: tobiasvl # => [C, B, A, Object, Kernel, BasicObject] (https://eval.in/466932)
[10:15:36] arne: webmachine does not think so, aswell
[10:15:56] apeiros: >> class A; end; class B < A; end; class C < B; end; C < A
[10:15:57] ruboto: apeiros # => true (https://eval.in/466934)
[10:16:01] apeiros: no need to instantiate
[10:16:18] Freeaqingme: has joined #ruby
[10:16:47] norc_: shevy: I actually wrote a test case for a ruby bug I reported.
[10:18:55] shevy: you broke ruby :(
[10:19:21] lukaszes: has joined #ruby
[10:19:41] norc_: Koichi did.
[10:20:11] norc_: git blame is extremely satisfying.
[10:20:46] mercerist: has joined #ruby
[10:21:05] shevy: I guess git was picked because it's so short to type
[10:21:19] norc_: not shorter than svn tho
[10:21:25] norc_: or cvs...
[10:21:28] adaedra: and longer than hg.
[10:21:30] tobiasvl: hg is shorter
[10:21:40] tobiasvl: "blame" is just a holdover from earlier vcs I guess, but svn has aliases for it: praise, annotate
[10:22:05] adaedra: and hg has out-of-the box shortcuts like ci or st, making its use even shorter.
[10:22:46] certainty: ACTION likes hg
[10:22:56] certainty: but git just has so much support
[10:23:19] haasn: has joined #ruby
[10:23:44] adaedra: I'm not the only one D:
[10:23:59] mghaig: has joined #ruby
[10:24:15] norc_: The big advantage git has is that its difficult enough to use that it automatically sorts out idiots.
[10:24:27] certainty: i don't think that's true
[10:24:35] adaedra: They'll put their code on Dropbox and call it a day.
[10:24:39] certainty: "idiots" will manage to do serious damage though
[10:24:44] certainty: much harder in stock hg
[10:24:59] adaedra: (And yes, I've seen people doing collaborative code work through Dropbox.)
[10:25:36] norc_: I have actually seen a major company doing a 20 men project for production software in avionics use an FTP server for VCS...
[10:25:52] norc_: For years people would overwrite each others changes. It was really amusing to watch.
[10:27:16] ibouvousaime: has joined #ruby
[10:27:29] shevy: what is wrong with FTP
[10:27:43] adaedra: Everything.
[10:27:44] certainty: nothing shevy
[10:27:45] norc_: you mean because its also 3 letters like cvs, svn or git?
[10:27:47] certainty: go back to sleep
[10:29:23] norc_: Okay, Im beginning to feel that "Ruby under a microscope" still lacks the magnification that I want.
[10:29:49] adaedra: You need to go deeper?
[10:30:43] waka: has joined #ruby
[10:31:32] norc_: I mean I have already started stepping through the YARV compiler by hand. But the sheer lack of documentation in the source code makes this hard.
[10:31:36] maikowblue: has joined #ruby
[10:32:04] flip_digits: has joined #ruby
[10:34:10] ldnunes: has joined #ruby
[10:34:39] blackmesa: has joined #ruby
[10:37:40] joonty: has joined #ruby
[10:39:20] prestorium: has joined #ruby
[10:41:27] seedinger: has joined #ruby
[10:41:29] neanderslob: has joined #ruby
[10:42:13] pandaant: has joined #ruby
[10:44:33] bnizzle: has joined #ruby
[10:47:14] roxtrongo: has joined #ruby
[10:48:23] dhjondoh: has joined #ruby
[10:48:46] lkba_: has joined #ruby
[10:48:47] lukaszes: has joined #ruby
[10:49:44] Xeago: has joined #ruby
[10:50:01] sross07: has joined #ruby
[10:51:40] favadi: has joined #ruby
[10:51:53] baweaver: has joined #ruby
[10:53:14] ruurd: has joined #ruby
[10:53:35] subscope: has joined #ruby
[10:54:03] avril14th: has joined #ruby
[10:55:33] Hounddog: has joined #ruby
[10:56:14] avril14th: any reason why this wouldn't work? https://gist.github.com/muichkine/36a7f0b1f21a85501086
[11:00:20] Hounddog: has joined #ruby
[11:00:53] bob_f: has joined #ruby
[11:01:23] bob_f: Hi, using rspec, can somebody tell me how to correctly do `allow(obj).to receive(:method).with(:param1, :param2)` ?
[11:01:56] yorickpeterse: That's correct actually
[11:02:05] zotherstupidguy: has joined #ruby
[11:02:09] bob_f: I get an error telling me I must specify a default value when using this format, but if I prescribe a `and_call_original` method beforehand, the second line doesn't get called.
[11:02:16] roxtrongo: has joined #ruby
[11:02:34] bob_f: I can pastebin code if needed.
[11:03:56] Hounddog: has joined #ruby
[11:04:14] bob_f: Sorry, by "the second line doesn't get called" I meant to say that the original is always called, never the stub I specify for those exact parameters.
[11:04:20] codecop: has joined #ruby
[11:06:00] avril14th: bob_f: code?
[11:06:11] bruno-: has joined #ruby
[11:06:16] avril14th: anyone on my alias_method of scope thing? ;)
[11:06:26] suchness: has joined #ruby
[11:06:38] norc_: avril14th: Yeah.
[11:06:46] Hounddog: has joined #ruby
[11:06:52] suchness: I didn't get much response in the ##English channel, maybe you guys can help me with a name: I am looking for a word that fits the following definition: A person added to an event with the capacity to optionally manage or optionally attend the event.
[11:06:52] bob_f: avril14th: https://bpaste.net/show/92e436c8cc90
[11:07:14] avril14th: suchness: supervisor
[11:07:26] norc_: avril14th: Well you have your answer. alias_method is a private method. ;-)
[11:07:49] DEA7TH: I'm considering making an open-source gem out of my system, but my idea is a bit unusual - most gems have a much more technical idea than mine. My gem will provide the common things for companies which need to make deliveries to / collections from customers. For example, pizza delivery or ironing services with driving as part of the service. Things like route visualization and optimization (TSP), JSON for an Android app for the driver, generator for custo
[11:07:49] DEA7TH: and JSON for mobile app for customers to make orders (Android and customer mobile apps will also be released). Can this be a gem?
[11:08:03] FernandoBasso: has joined #ruby
[11:08:07] DEA7TH: generator for customer DB table*
[11:08:26] norc_: avril14th: I think what you really want to do is to stub :woot
[11:08:27] DEA7TH: also it might include views for all those things, if I figure out how to do it with generators.
[11:08:34] Hounddog: has joined #ruby
[11:08:48] avril14th: norc_: I could indeed, thx
[11:08:53] suchness: avril14th: Hrm. I am not completely sold. I will have to think about that one.
[11:09:07] avril14th: bob_f: not sure what you're trying to do
[11:09:24] bob_f: I want to stub a call to a method only when specific params are passed, otherwise delegate to original.
[11:09:36] avril14th: bob_f: then use stub
[11:09:42] avril14th: with the described logic in it
[11:10:10] avril14th: norc_: actually the not funky thing is that stub does only exit in rspec files :)
[11:10:17] avril14th: but well, will do
[11:10:28] bob_f: avril14th: Huh, I thought `stub` was not correct any more - my mistake.
[11:10:35] norc_: avril14th: Why are you trying to do that anyway?
[11:10:36] Hounddog: has joined #ruby
[11:10:44] DEA7TH: Or actually a Ruby gem is the same thing as a library in any other program, right?
[11:11:02] norc_: avril14th: If your factory expects an interface in your model - then provide it in your model.
[11:11:09] norc_: Dont monkey patch your model from your factory.
[11:11:29] avril14th: norc_: well, Event is an abstract class. interface is provided in sub classes. but I don't want to do examples (test it on every sub class)
[11:12:07] norc_: avril14th: Then why does your factory take an abstract class?
[11:12:09] lukaszes: has joined #ruby
[11:12:13] norc_: Give it an implementation class instead.
[11:12:59] DEA7TH: has joined #ruby
[11:13:29] Stan: has joined #ruby
[11:13:31] Hounddog: has joined #ruby
[11:13:35] htmldrum: has joined #ruby
[11:15:03] bob_f: avril14th: `stub` is deprecated.
[11:15:21] avril14th: bob_f: , is it? I use it everywhere. let me see :)
[11:15:32] Hounddog: has joined #ruby
[11:15:33] bob_f: avril14th: Yeah. `allow` is the new preferred syntax.
[11:15:47] dkam: has joined #ruby
[11:15:53] ruurd: has joined #ruby
[11:16:14] suman: has joined #ruby
[11:16:29] suman: hi need help on timeouts in ruby
[11:16:35] avril14th: bob_f: your question makes more sense :)
[11:16:38] norc_: suman: Ask your question then :)
[11:17:16] mghaig: has joined #ruby
[11:17:55] avril14th: bob_f: don't think you can call allow to receive twice and have one or the other called depending on parameters. you have to set it once and then in the code, call original I'd say (tried super?)
[11:18:38] Hounddog: has joined #ruby
[11:18:49] suman_: has joined #ruby
[11:19:07] suman_: https://coderwall.com/p/1novga/ruby-timeouts-are-dangerous
[11:19:25] suman_: i have a code in my app which use timeouts
[11:19:29] suman_: Timeout::timeout($riak_client_timeout) { object = $note_body.get(key) }
[11:20:24] suman_: i have a situation where the result of one request was replaced by another
[11:20:27] rickmasta: has joined #ruby
[11:20:39] suman_: i doubt that was because of timeouts
[11:20:46] norc_: bob_f: This could be an XY problem stemming from design. Maybe what you really want is to stub out a method that is used by whatever you are trying to stub?
[11:21:14] Synthead: has joined #ruby
[11:21:42] suman_: i am not able to reproduce can someone help on reproducing how the previous data can be retruned?
[11:22:13] Hounddog: has joined #ruby
[11:23:52] norc_: bob_f: Otherwise http://ruby-doc.org/core-2.2.3/Object.html#method-i-method can help you there.
[11:24:16] norc_: (Effectively copying before you stub it out, that way you can then use either)
[11:25:55] bob_f: norc_: I'm confused because the last spec here seems to do exactly what I want: https://relishapp.com/rspec/rspec-mocks/docs/configuring-responses/calling-the-original-implementation
[11:26:23] lapideviridi: has joined #ruby
[11:26:32] Hounddog: has joined #ruby
[11:26:54] norc_: bob_f: Oh that is neat, was not aware you could overload stubs like that
[11:27:17] Lapide: has joined #ruby
[11:31:46] DEA7TH: has joined #ruby
[11:31:55] DEA7TH: did I miss replies? connection went down
[11:32:38] flip_digits: has joined #ruby
[11:34:42] trosborn: has joined #ruby
[11:35:58] certainty: doesn't look like it
[11:36:40] norc_: DEA7TH: http://guides.rubygems.org/what-is-a-gem/
[11:36:43] apeiros: ?log DEA7TH
[11:36:43] ruboto: DEA7TH, I don't know anything about log
[11:36:47] apeiros: ?logs DEA7TH
[11:36:48] ruboto: DEA7TH, You can find a log of this channel at http://irclog.whitequark.org/ruby/
[11:37:19] DEA7TH: public logs? I see
[11:37:33] Hounddog: has joined #ruby
[11:38:49] bruno-_: has joined #ruby
[11:42:43] gilesw: i'm having my first go at using omnibus
[11:43:33] gilesw: but when i run bundle install --binstubs it appears to be using my system ruby
[11:43:53] Hounddog: has joined #ruby
[11:44:13] gilesw: i'm using rbenv setting ruby via a shim
[11:44:19] beast_: has joined #ruby
[11:44:38] gilesw: i was expecting it to install the gems inside the omnibus directory
[11:45:56] CloCkWeRX: has left #ruby: ()
[11:46:21] daivyk: has joined #ruby
[11:46:29] mattwildig: has joined #ruby
[11:47:36] Rodya_: has joined #ruby
[11:49:00] Xeago: has joined #ruby
[11:49:07] mostlybadfly: has joined #ruby
[11:51:38] Hounddog: has joined #ruby
[11:51:48] dkam: has joined #ruby
[11:52:35] baweaver: has joined #ruby
[11:54:14] s00pcan: has joined #ruby
[11:56:01] emilkarl: has joined #ruby
[11:56:37] chipotle: has joined #ruby
[11:56:42] riffraff: has joined #ruby
[11:57:07] norc_: >> 1 if ();
[11:57:08] ruboto: norc_ # => nil (https://eval.in/467021)
[11:57:16] norc_: Neat. Just figured out why this works. :)
[11:58:24] norc_: shevy: That is another line of code.
[12:00:05] linduxed: has joined #ruby
[12:02:49] gregf_: >> ().class
[12:02:50] ruboto: gregf_ # => NilClass (https://eval.in/467026)
[12:03:03] gregf_: >> nil.class
[12:03:04] ruboto: gregf_ # => NilClass (https://eval.in/467027)
[12:03:18] norc_: gregf_: Even the first one makes perfect sense to me now. :)
[12:03:19] kimegede: has joined #ruby
[12:03:41] norc_: >> require 'ripper'; Ripper.sexp("().class")
[12:03:42] ruboto: norc_ # => [:program, [[:call, [:paren, [[:void_stmt]]], :".", [:@ident, "class", [1, 3]]]]] (https://eval.in/467028)
[12:04:16] norc_: Okay... and this is why I need
[12:04:23] norc_: This damn ruby bug to be fixed.
[12:05:04] subscope: has joined #ruby
[12:05:21] norc_: Or actually wait. No that first one is interesting now.
[12:05:38] norc_: >> RubyVM::InstructionSequence.compile("().class").disasm
[12:05:39] ruboto: norc_ # => "== disasm: <RubyVM::InstructionSequence:<compiled>@<compiled>>==========\n0000 trace 1 ...check link for more (https://eval.in/467029)
[12:06:04] norc_: >> puts RubyVM::InstructionSequence.compile("().class").disasm
[12:06:05] ruboto: norc_ # => == disasm: <RubyVM::InstructionSequence:<compiled>@<compiled>>========== ...check link for more (https://eval.in/467030)
[12:06:07] dkam: has joined #ruby
[12:06:18] norc_: No makes sense again. :)
[12:09:20] norc_: () should result in null node in the AST I think?
[12:11:49] seedinger: has joined #ruby
[12:11:57] mghaig: has joined #ruby
[12:14:00] _blizzy_: has joined #ruby
[12:14:09] flip_digits: has joined #ruby
[12:14:24] zenguy_pc: has joined #ruby
[12:16:42] sepp2k: has joined #ruby
[12:17:23] The_Ball: has joined #ruby
[12:21:16] Azure: has joined #ruby
[12:22:13] Synthead: has joined #ruby
[12:22:15] campestrini: has joined #ruby
[12:22:20] cajone: has joined #ruby
[12:25:47] ixti: has joined #ruby
[12:27:22] dkam: has joined #ruby
[12:27:28] campestrini: After a long time, is nice to be using irc again
[12:27:35] campestrini: this is amazing, hahaha
[12:28:29] ebbflowgo: has joined #ruby
[12:30:12] adaedra: You have to ask why IRC is amazing?
[12:30:46] oddmunds: this discussion will be great
[12:30:50] rbowlby: has joined #ruby
[12:30:59] krz: has joined #ruby
[12:31:04] __desmondhume: extinguishing enthusiasm at its finest
[12:32:12] solocshaw: has joined #ruby
[12:32:17] apeiros: curb your enthusiasm
[12:35:23] solocshaw: has joined #ruby
[12:35:27] dtordable: has joined #ruby
[12:35:43] indignatio: has joined #ruby
[12:37:36] blaxter: has joined #ruby
[12:38:17] sdothum: has joined #ruby
[12:38:54] Xeago: has joined #ruby
[12:40:50] tkuchiki: has joined #ruby
[12:41:35] tkuchiki: has joined #ruby
[12:41:57] skakri: Wooo IRC! \o/
[12:43:50] syath: has joined #ruby
[12:48:26] TiuTalk: has joined #ruby
[12:48:42] Rodya_: has joined #ruby
[12:51:40] yqt: has joined #ruby
[12:52:06] __desmondhume: i agree with certainty btw, i'm new to IRC and it's not something you give for granted if you've never used it
[12:52:16] __desmondhume: sorry, with camilasan
[12:52:23] __desmondhume: f*ck campestrini
[12:52:31] __desmondhume: wrong quote. lol
[12:52:51] krz: has joined #ruby
[12:53:18] Mon_Ouie: has joined #ruby
[12:53:34] baweaver: has joined #ruby
[12:55:26] dhjondoh: has joined #ruby
[12:55:48] luriv: has joined #ruby
[12:56:09] flip_digits: has joined #ruby
[12:57:11] htmldrum: has joined #ruby
[12:59:10] k3asd`: has joined #ruby
[13:00:14] jdawgaz: has joined #ruby
[13:00:24] Xeago: has joined #ruby
[13:00:59] ruurd: has joined #ruby
[13:03:10] dkam: has joined #ruby
[13:03:34] benlovell: has joined #ruby
[13:06:07] mghaig: has joined #ruby
[13:06:13] dkam: has joined #ruby
[13:09:27] freerobby: has joined #ruby
[13:10:08] neohunter: has joined #ruby
[13:10:17] dlitvak: has joined #ruby
[13:10:35] benlovell: has joined #ruby
[13:11:37] rodfersou: has joined #ruby
[13:12:26] dkam: has joined #ruby
[13:13:53] lapide_viridi: has joined #ruby
[13:14:47] Pupp3tm4_: has joined #ruby
[13:15:15] Jardayn: has joined #ruby
[13:15:18] B1n4r10: has joined #ruby
[13:15:20] Pupp3tm4st3r: has joined #ruby
[13:16:38] darkxploit: has joined #ruby
[13:18:01] synthroid: has joined #ruby
[13:20:50] bricker: has joined #ruby
[13:22:10] darkxploit: hello guys. After having install ruby with rvm i noticed that my ruby is version 2.2.1p85 whereas on the official ruby website its 2.2.3 How do i update to latest
[13:22:59] FailBit: rvm install 2.2.3
[13:23:58] lapideviridi: has joined #ruby
[13:24:38] rfmind: has joined #ruby
[13:25:32] darkxploit: FailBit, yes its installing
[13:25:39] ||: has joined #ruby
[13:25:56] darkxploit: but this command curl -sSL https://get.rvm.io | bash -s stable --ruby is suppose to download latest stable right ?
[13:26:21] CloCkWeRX: has joined #ruby
[13:26:23] TheHodge: has joined #ruby
[13:28:13] valeriansaliou: has joined #ruby
[13:30:08] Joelio: has joined #ruby
[13:30:35] SenpaiSilver: has joined #ruby
[13:30:44] htmldrum: has joined #ruby
[13:30:54] tvw: has joined #ruby
[13:31:35] mattwildig: has joined #ruby
[13:32:06] goodcodeguy: has joined #ruby
[13:33:21] prestorium: has joined #ruby
[13:34:57] lapide_viridi: has joined #ruby
[13:35:18] ruurd: has joined #ruby
[13:36:06] dstarh: has joined #ruby
[13:37:04] dravine_: has joined #ruby
[13:39:26] uris: has joined #ruby
[13:39:44] clocKwize: has joined #ruby
[13:42:32] sankaber: has joined #ruby
[13:43:59] flip_digits: has joined #ruby
[13:44:18] dtordable: has joined #ruby
[13:44:21] kitallisii: has joined #ruby
[13:46:03] vigintas: has joined #ruby
[13:46:28] henry1: has joined #ruby
[13:46:59] roxtrongo: has joined #ruby
[13:48:46] ibouvousaime: has joined #ruby
[13:49:22] Rodya_: has joined #ruby
[13:49:39] c355E3B: has joined #ruby
[13:51:57] dviola: has joined #ruby
[13:53:10] krz: has joined #ruby
[13:53:11] JDiPierro: has joined #ruby
[13:54:18] centrx: has joined #ruby
[13:54:19] baweaver: has joined #ruby
[13:54:54] blackmesa: has joined #ruby
[13:55:00] sgambino: has joined #ruby
[13:55:45] dmitch: has joined #ruby
[13:55:47] ekinmur: has joined #ruby
[13:55:53] CaptainAl: has joined #ruby
[13:57:08] JDiPierro: has joined #ruby
[13:57:39] nertzy: has joined #ruby
[13:58:22] CaptainAl: has joined #ruby
[13:58:44] JDiPierro: has joined #ruby
[13:59:38] mghaig: has joined #ruby
[14:00:04] RegulationD: has joined #ruby
[14:00:45] CaptainAl: has joined #ruby
[14:01:43] sankaber: has joined #ruby
[14:01:46] decoponio: has joined #ruby
[14:01:51] jamon_: has joined #ruby
[14:02:43] atomical: has joined #ruby
[14:02:52] _stu_: has joined #ruby
[14:05:18] cicloid: has joined #ruby
[14:05:29] lukaszes: has joined #ruby
[14:06:27] cicloid: has joined #ruby
[14:08:01] haylon: has joined #ruby
[14:08:48] JStoker: has joined #ruby
[14:08:55] k3asd`: has joined #ruby
[14:12:07] mghaig: has joined #ruby
[14:12:33] scmx: has joined #ruby
[14:13:44] TomPeed: has joined #ruby
[14:13:46] subscope: has joined #ruby
[14:14:42] syath: has joined #ruby
[14:15:19] umgrosscol: has joined #ruby
[14:15:34] bricker: has joined #ruby
[14:15:59] c355E3B: has joined #ruby
[14:15:59] Mon_Ouie: has joined #ruby
[14:15:59] Caius: has joined #ruby
[14:15:59] sye: has joined #ruby
[14:15:59] iateadonut: has joined #ruby
[14:15:59] eggoez: has joined #ruby
[14:15:59] sivoais: has joined #ruby
[14:15:59] trajing: has joined #ruby
[14:15:59] atom3: has joined #ruby
[14:16:44] sivoais: has joined #ruby
[14:17:38] sdwrage: has joined #ruby
[14:17:40] eggoez: has joined #ruby
[14:17:41] avril14th: darkxploit: rvm install 2.2.3
[14:17:53] avril14th: then rvm use 2.2.3 --default
[14:18:17] freerobby: has joined #ruby
[14:19:07] CaptainAl: has joined #ruby
[14:19:08] dlitvak: has joined #ruby
[14:20:33] shevy: hey snowtiki
[14:20:53] tulak: has joined #ruby
[14:21:37] diego1: has joined #ruby
[14:24:03] diego1: has joined #ruby
[14:24:49] car: has joined #ruby
[14:25:39] The_Phoenix: has joined #ruby
[14:27:22] malconis: has joined #ruby
[14:27:36] agentmeerkat: has joined #ruby
[14:28:11] bruno-: has joined #ruby
[14:29:36] cdg: has joined #ruby
[14:29:38] devoldmx: has joined #ruby
[14:29:44] babblebre: has joined #ruby
[14:30:21] Xeago: has joined #ruby
[14:30:39] ruurd: has joined #ruby
[14:31:10] infamos: has joined #ruby
[14:31:27] mattwildig: has joined #ruby
[14:31:51] skade: has joined #ruby
[14:31:51] mghaig: has joined #ruby
[14:32:04] Guest53: has joined #ruby
[14:34:24] cdg_: has joined #ruby
[14:34:30] diegoaguilar: has joined #ruby
[14:34:34] dlitvak_: has joined #ruby
[14:34:43] stannard: has joined #ruby
[14:34:45] duoi: has joined #ruby
[14:38:33] iateadonut: has joined #ruby
[14:39:08] ekinmur: has joined #ruby
[14:39:31] dlitvak: has joined #ruby
[14:41:47] desmondhume: has joined #ruby
[14:43:25] Erik_Underline: has joined #ruby
[14:43:36] i8igmac: has joined #ruby
[14:43:39] Erik_Underline: Hey people! Long time no see ^^
[14:44:48] davejlong: has joined #ruby
[14:44:59] i8igmac: im trying to install a gem from github using bundler... i have never used bundler before, i have git cloned the source to my machine
[14:45:22] i8igmac: i have ran bundle, witch read the gemfile and installed lots of gems
[14:45:50] i8igmac: im trying now bundle install --path
[14:46:04] jdawgaz: has joined #ruby
[14:47:09] gusTester: has joined #ruby
[14:47:18] blaxter: has joined #ruby
[14:47:33] JDiPierro: has joined #ruby
[14:48:19] sectionme: has joined #ruby
[14:48:23] ixti: has joined #ruby
[14:48:28] shevy: bundler just makes you happy doesn't it
[14:48:32] PizzaHat: has joined #ruby
[14:48:45] gusTester: has left #ruby: ()
[14:48:56] leafybas_: has joined #ruby
[14:49:11] PizzaHat: Hi, can I easily convert an array of integers to an array of strings ? [1,2,3,7,9,15] => ["1", "2", "3", "7", "9", "15"] ?
[14:49:30] i8igmac: well, very new to this... it seems like people may store gems on github with different methods or packaging software...
[14:49:53] benlovell: PizzaHat: [1,2,3].map(&:to_s)
[14:49:54] i8igmac: im not sure if i have completed the install process
[14:50:32] Rodya_: has joined #ruby
[14:50:44] PizzaHat: nice benlovell, thanks :)
[14:51:02] shevy: i8igmac yeah bundler allows one to use github projects, that's actually one of the real advantages it has over the smaller gem suite itself
[14:51:15] polishdub: has joined #ruby
[14:51:27] davejlong: has joined #ruby
[14:51:59] i8igmac: gem 'gemname', :git => 'http://github.com/user/gem.git'
[14:52:11] roxtrongo: has joined #ruby
[14:52:12] simplyia_: has joined #ruby
[14:52:15] i8igmac: this gives me a error, bash: file not found http://git.....
[14:52:25] i8igmac: i already have cloned the directory
[14:53:18] simplyianm: has joined #ruby
[14:54:02] arne: anyone has a neat quick way to convert this [...{:sym=>"hngg"},{:sym=>"blergh"}...] to csv?
[14:54:17] benlovell: i8igmac: the gem statement has both a `git` and `github` option. you can use `github: 'user/gem'`
[14:55:02] baweaver: has joined #ruby
[14:55:55] benlovell: i8igmac: otherwise, be sure to use https or `git@github.com:user/repo.git` if you use the `git` option
[14:56:01] shevy: i8igmac no idea but this looks a wrong url?
[14:56:37] i8igmac: it was a example url, from the document page...
[14:56:37] i8igmac: gem 'nokogiri', :github => 'tenderlove/nokogiri'
[14:56:46] Spami: has joined #ruby
[14:56:53] i8igmac: maybe this is outdated
[14:57:22] i8igmac: the single quotes, are wrong
[14:57:34] benlovell: nothing wrong with single quoted strings
[14:57:59] suchness: They are faster than double quoted strings.
[14:58:11] i8igmac: gem 'nokogiri', :github => 'tenderlove/nokogiri'
[14:58:11] i8igmac: this fails with a bash error
[14:58:21] i8igmac: gem install 'nokogiri', ':github => 'tenderlove/nokogiri''
[14:58:25] griffindy: has joined #ruby
[14:58:26] i8igmac: this did something fancy
[14:58:27] benlovell: i8igmac: is that in your Gemfile
[14:58:32] shevy: are you sure that this should work
[14:58:34] benlovell: or are you trying to run this on your command line?
[14:58:41] suchness: Sounds like a shell script
[14:58:43] benlovell: i think the latter
[14:58:44] rbowlby: has joined #ruby
[14:59:15] i8igmac: im trying to start from step one, installing a remote source from github.com
[14:59:22] i8igmac: http://bundler.io/git.html
[14:59:22] benlovell: maybe you should have a read through http://bundler.io/#getting-started first
[14:59:26] jordihdz|2: has joined #ruby
[14:59:43] kfpratt: has joined #ruby
[14:59:54] tmtwd: has joined #ruby
[15:01:10] shevy: nobody reads those intro tutorials!
[15:01:26] i8igmac: i have, but something is wrong
[15:01:33] i8igmac: i read them all.
[15:01:48] troulouliou_div2: has joined #ruby
[15:01:51] i8igmac: there are loads of examples, how to install from github
[15:01:55] adaedra: yeah, nobody reads the doc.
[15:01:57] i8igmac: but the command fails
[15:01:58] adaedra: That's a problem.
[15:02:18] corehook: has joined #ruby
[15:03:08] corehook: has joined #ruby
[15:03:09] bodgix: has left #ruby: ()
[15:03:17] ekinmur: has joined #ruby
[15:03:17] i8igmac: does this look proper? directly from there online document
[15:03:18] i8igmac: gem 'nokogiri', :github => 'tenderlove/nokogiri'
[15:03:23] ItSANgo: has joined #ruby
[15:03:28] i8igmac: and you run this from a console,
[15:03:47] baweaver: has joined #ruby
[15:04:08] adaedra: no, you put it in your Gemfile
[15:04:17] shevy: that is ruby code
[15:04:24] havenwood: i8igmac: It's Ruby.
[15:04:52] gusTester: has joined #ruby
[15:05:03] i8igmac: so, if i cloned a project to my local machine... there already exist a gemfile and gemfile.lock
[15:05:55] gusTester: has left #ruby: ()
[15:06:07] jordihdz: has joined #ruby
[15:06:39] voker57: has joined #ruby
[15:06:47] jordihdz: has left #ruby: ("Once you know what it is you want to be true, instinct is a very useful device for enabling you to know that it is")
[15:06:56] i8igmac: my goodness, this is a love hate relationship
[15:07:14] i8igmac: thank you guys
[15:07:39] TPBallbag: has joined #ruby
[15:08:40] lubarch: has joined #ruby
[15:09:05] Tempesta: has joined #ruby
[15:09:06] Guest34193: has joined #ruby
[15:09:07] jordihdz: has joined #ruby
[15:09:16] mghaig: has joined #ruby
[15:09:23] Tempesta: has joined #ruby
[15:09:39] Tempesta: has joined #ruby
[15:09:41] i8igmac: the Gemfile that came with the clone... i had to add a line
[15:09:43] shevy: i8igmac welcome to bundler! :D
[15:09:55] Tempesta: has joined #ruby
[15:09:59] shevy: there also is #bundler btw
[15:10:00] i8igmac: bundler is now fetching the git://
[15:10:12] Tempesta: has joined #ruby
[15:11:11] dlitvak_: has joined #ruby
[15:12:22] dlitvak: has joined #ruby
[15:12:26] Guest53: has joined #ruby
[15:12:27] mattwildig: has joined #ruby
[15:12:57] dionysus69: has joined #ruby
[15:13:07] hashpuppy: has joined #ruby
[15:13:24] RobertBirnie: has joined #ruby
[15:13:37] simplyianm: has joined #ruby
[15:13:49] dmitch: has joined #ruby
[15:13:54] p0wn3d__: has joined #ruby
[15:13:54] freerobby: has joined #ruby
[15:14:29] kobain: has joined #ruby
[15:14:52] simplyianm: has joined #ruby
[15:15:09] Guest54901: has joined #ruby
[15:16:41] bruno-: has joined #ruby
[15:17:00] blue_deref: has joined #ruby
[15:18:27] PizzaHat: How to pad easily a string with a fixed number of chars ? (i'm sorry but the Ruby String class has got MANY methods lol)
[15:18:44] benlovell: has joined #ruby
[15:18:59] Kedare: has joined #ruby
[15:19:28] baroquebobcat: has joined #ruby
[15:19:32] bricker: has joined #ruby
[15:19:50] adaedra: &ri String#ljust @PizzaHat
[15:19:50] `derpy: PizzaHat: http://www.rubydoc.info/stdlib/core/String#ljust-instance_method
[15:19:51] monthy: has joined #ruby
[15:20:07] dtordable: has joined #ruby
[15:21:04] PizzaHat: Thanks adaedra <3
[15:22:20] neonalpine: has joined #ruby
[15:23:00] rippa: has joined #ruby
[15:23:20] johnzorn: has joined #ruby
[15:23:53] shevy: >> "abc".ljust(20, '_')
[15:23:54] ruboto: shevy # => "abc_________________" (https://eval.in/467157)
[15:24:12] ruurd: has joined #ruby
[15:24:22] baroquebobcat: has joined #ruby
[15:24:44] emilkarl: has joined #ruby
[15:25:00] shevy: >> "world!".rjust(12,'hello ')
[15:25:01] ruboto: shevy # => "hello world!" (https://eval.in/467158)
[15:25:24] shevy: so many people have IRC nicks that make you hungry
[15:25:48] adaedra: go eat something then
[15:25:55] TPBallbag: Does mine make you hungry shevy?
[15:25:58] user1138: has joined #ruby
[15:26:37] shevy: but PizzaHat
[15:26:42] shevy: and mozzarella ... and many others
[15:27:11] agentmeerkat: has joined #ruby
[15:27:14] PizzaHat: My nickname is evil ^^
[15:27:36] hhutch: has joined #ruby
[15:27:41] hhutch: has left #ruby: ()
[15:28:09] aaeron: has joined #ruby
[15:28:38] gregf_: >> len = 8; [ %w{foo foobar foobarbaz}.map{ |str| pad = len - str.length; " " * (pad > 0 ? pad : 0) + str } ]
[15:28:44] ruboto: gregf_, I'm terribly sorry, I could not evaluate your code because of an error: OpenURI::HTTPError:500 Internal Server Error
[15:29:21] adaedra: That's new
[15:29:49] adaedra: Also, we're trying to aim for the longest code now?
[15:29:49] shevy: you error!
[15:30:05] rippa: has joined #ruby
[15:31:17] user1138: has joined #ruby
[15:31:34] tubuliferous_: has joined #ruby
[15:33:33] B1n4r10: has joined #ruby
[15:33:48] desmondhume: gregf_: what's that?
[15:35:48] PizzaHat: good question
[15:36:25] akem: has joined #ruby
[15:37:03] PizzaHat: >> "? tfw freg".reverse
[15:37:04] ruboto: PizzaHat # => "gerf wft ?" (https://eval.in/467165)
[15:37:23] PizzaHat: >> "? ftw fgreg".reverse
[15:37:25] tulak: has joined #ruby
[15:37:29] ruboto: PizzaHat, I'm terribly sorry, I could not evaluate your code because of an error: OpenURI::HTTPError:500 Internal Server Error
[15:38:40] dtordable: has joined #ruby
[15:38:50] adaedra: apeiros: ^
[15:38:57] loc22: has joined #ruby
[15:39:06] yqt: has joined #ruby
[15:39:44] desmondhume: oh cool, it's like right aligning strings in a padding of 8
[15:39:45] dtordable: has joined #ruby
[15:40:38] tenderlove: has joined #ruby
[15:40:49] arthurix: has joined #ruby
[15:40:59] apeiros: adaedra: can't do anything about server errors :-|
[15:41:22] Oli`: has joined #ruby
[15:42:21] teclator: has joined #ruby
[15:44:12] greenbigfrog: has joined #ruby
[15:44:33] RegulationD: has joined #ruby
[15:45:19] desmondhume: i've a question
[15:45:33] adaedra: we should guess it?
[15:45:45] desmondhume: did you know why this works and why i can use the dot notation this way?
[15:45:54] desmondhume: >> %w.asd lol lolwut.
[15:46:00] ruboto: desmondhume, I'm terribly sorry, I could not evaluate your code because of an error: OpenURI::HTTPError:500 Internal Server Error
[15:46:11] adaedra: eval.in is having issues I see.
[15:46:24] adaedra: desmondhume: % hello # also works.
[15:46:28] desmondhume: %w.asd lol lolwut.
[15:46:28] desmondhume: => ["asd", "lol", "lolwut"]
[15:46:49] desmondhume: is it documented somewhere?
[15:47:05] yqt: has joined #ruby
[15:47:39] adaedra: desmondhume: https://en.wikibooks.org/wiki/Ruby_Programming/Syntax/Literals#The_.25_Notation
[15:47:39] Fire-Dragon-DoL: has joined #ruby
[15:47:47] canton7: desmondhume, the '%w'? http://ruby-doc.org/core-2.2.0/doc/syntax/literals_rdoc.html#label-Percent+Strings
[15:48:30] desmondhume: yeah, i wasn't talking about the %w, i was talking about the two dots surrounding the list
[15:48:37] adaedra: it's a string
[15:48:41] adaedra: the same as %Q
[15:48:53] yqt: has joined #ruby
[15:48:54] adaedra: %.hello. is the same as %[hello]
[15:49:09] EminenceHC: has joined #ruby
[15:49:18] adaedra: >> % % % % % #
[15:49:19] ruboto: adaedra # => "%" (https://eval.in/467177)
[15:49:44] ruboto: FailBit # => /tmp/execpad-922fe6013dca/source-922fe6013dca:3: syntax error, unexpected keyword_rescue ...check link for more (https://eval.in/467178)
[15:49:52] desmondhume: well, ok :') this is a bit fancy, lots of uselessly different possible notations
[15:49:55] grillo: has joined #ruby
[15:50:06] adaedra: FailBit: some spaces are important in my line.
[15:50:07] canton7: it's just "you can use any marker you like"
[15:50:15] adaedra: desmondhume: not so useless.
[15:50:15] grillo: has joined #ruby
[15:50:22] boris317: has joined #ruby
[15:50:31] adaedra: >> %(String with both 'single' and "double" quotes, without escaping)
[15:50:32] ruboto: adaedra # => "String with both 'single' and \"double\" quotes, without escaping" (https://eval.in/467183)
[15:50:36] desmondhume: i can't catch the point of using dots in place of rounded brackets
[15:50:43] canton7: "Any single non-alpha-numeric character can be used as the delimiter" from adaedra's link. So you can choose a character which doesn't appear in your string
[15:51:11] canton7: it's not that dots are expressely permitted, it's that dots are an alphanumeric character and any alphanumeric character is permitted
[15:51:33] adaedra: >> %????pizza????
[15:51:39] ruboto: adaedra, I'm terribly sorry, I could not evaluate your code because of an error: NoMethodError:undefined method `[]' for nil:NilClass
[15:51:52] Rodya_: has joined #ruby
[15:52:07] adaedra: apeiros: that's not a server error this time :D
[15:52:24] desmondhume: ahahahahah ok so i see now. It's useful cause you can use any delimiter that's not appearing inside the string, so you don't have to think about escaping chars, ammaright?
[15:52:46] desmondhume: cool, thank you adaedra
[15:52:50] adaedra: also, the paired ones like (, [, { are counted
[15:53:02] adaedra: so %(hello (world) !!!) ends at the second )
[15:53:18] desmondhume: i just benchmarked ( against {, the { seems a bit slower, dunno why
[15:53:18] FailBit: you can use string interp still, right?
[15:53:46] boris317: Hello. I want to implement a DSL like method call as seen here: https://bpaste.net/show/a442d8ac55f8 How would I go about that? config will just store a key/value pair in a hash. Thanks.
[15:53:55] FailBit: desmondhume: pretty sure that's parsing and not execution
[15:54:04] FailBit: so I wouldn't see why
[15:54:19] desmondhume: ooook, everything's clear now
[15:55:09] arne: has joined #ruby
[15:55:54] aaeron1: has joined #ruby
[15:55:57] adaedra: FailBit: It's like %Q, so yes.
[15:56:33] platzhirsch: has left #ruby: ()
[15:56:42] rippa: has joined #ruby
[15:58:15] seedinger: has joined #ruby
[15:58:27] devoldmx: has joined #ruby
[15:58:27] Oli`: Hi, I don't understand why I can't list the constants of my module here: https://gist.github.com/anonymous/e75e25bf1da411cd77f8
[15:58:37] marcosantoniocar: has joined #ruby
[16:00:13] wprice: has joined #ruby
[16:00:38] adaedra: because you're defining ::CoolClass2
[16:00:56] johnzorn: has joined #ruby
[16:01:25] vigintas: has joined #ruby
[16:01:29] sdothum: has joined #ruby
[16:01:30] adaedra: (so at the top level, not in your module)
[16:01:31] Oli`: but it's inside the anonymous module right?
[16:01:33] arthurix_: has joined #ruby
[16:01:44] Oli`: how should i write it ?
[16:02:32] User458764: has joined #ruby
[16:03:21] s00pcan: has joined #ruby
[16:04:05] bmalum: has joined #ruby
[16:04:15] loc22_: has joined #ruby
[16:04:29] adaedra: You can use const_set
[16:04:37] Rodya_: has joined #ruby
[16:05:17] kobain: has joined #ruby
[16:07:21] Oli`: ok, thank you
[16:07:34] loincloth: has joined #ruby
[16:07:43] ekleog: has joined #ruby
[16:08:13] diegoaguilar: has joined #ruby
[16:08:26] gregf_: desmondhume: sorry, got pulled into a meeting :|. i was trying the padding string bit(PizzaHut), *this* len = 8; p %w{foo foobar foobarbaz}.map{ |str| pad = len - str.length; " " * (pad > 0 ? pad : 0) + str }
[16:08:39] gregf_: oops, scrolls down :/
[16:08:47] desmondhume: it seems to work fine
[16:08:53] gregf_: and PizzaHat i meant
[16:08:55] desmondhume: in my irb console
[16:09:10] adaedra: gregf_: what's wrong with ljust/rjust?
[16:09:21] gregf_: i think i managed to trick the bot :|
[16:10:01] mary5030: has joined #ruby
[16:10:02] gregf_: adaedra: nothing ;). what you've suggested is better
[16:10:06] leafybas_: has joined #ruby
[16:10:20] ekleog: has joined #ruby
[16:10:43] roxtrongo: has joined #ruby
[16:11:09] gregf_: Oli`: module Foo; ADD = 1;SUB = 2;end;class Bar; include Foo;end;p Bar.constants *works for me*
[16:11:12] lsv_: has joined #ruby
[16:11:43] mary5030: has joined #ruby
[16:11:59] podman: has joined #ruby
[16:12:01] klaas_: has joined #ruby
[16:12:09] dtordabl1: has joined #ruby
[16:12:38] rickmasta: has joined #ruby
[16:13:23] RedDwarf: has joined #ruby
[16:13:24] gregf_: oh - well
[16:14:11] vayan_: has joined #ruby
[16:14:16] aaeron: has joined #ruby
[16:14:21] Sou|cutter: Is there a reason behind declaring a class like this: class GeneratedAttributeMethods < Module;
[16:14:25] mahlon_: has joined #ruby
[16:14:30] Sou|cutter: why would you throw < Module in there ?
[16:14:55] Iacobus_: has joined #ruby
[16:14:55] ckrailo_: has joined #ruby
[16:15:04] gusTester1: has joined #ruby
[16:15:04] mghaig: has joined #ruby
[16:15:10] ahuman_: has joined #ruby
[16:15:17] subscope: has joined #ruby
[16:15:17] ESpiney: has joined #ruby
[16:15:17] zrl_: has joined #ruby
[16:15:22] cjheath_: has joined #ruby
[16:15:27] jorb_: has joined #ruby
[16:15:36] gusTester1: has left #ruby: ()
[16:15:43] niftylettuce_: has joined #ruby
[16:15:46] Jello_Raptor_: has joined #ruby
[16:15:47] sp3: has joined #ruby
[16:15:48] shellie__: has joined #ruby
[16:15:58] greedo_: has joined #ruby
[16:16:03] agentmee1kat: has joined #ruby
[16:16:05] axisys_: has joined #ruby
[16:16:06] raenk_: has joined #ruby
[16:16:07] qpls_: has joined #ruby
[16:16:10] kadoppe_: has joined #ruby
[16:16:14] veloutin_: has joined #ruby
[16:16:16] aredridel: has joined #ruby
[16:16:33] Skelz0r_: has joined #ruby
[16:16:41] cornerman: has joined #ruby
[16:16:52] Guest32335: has joined #ruby
[16:17:02] xxneolithicxx1: has joined #ruby
[16:17:12] duoi: has joined #ruby
[16:17:12] pwnd_nfsw: has joined #ruby
[16:17:12] duoi: has joined #ruby
[16:17:15] subscope: has joined #ruby
[16:17:15] LilianRose: has joined #ruby
[16:17:21] Yzguy: has joined #ruby
[16:17:23] Rovanion_: has joined #ruby
[16:17:33] blaxter: has joined #ruby
[16:17:40] j416_: has joined #ruby
[16:17:58] djcp: has joined #ruby
[16:18:00] fold2: has joined #ruby
[16:18:26] dravine: has joined #ruby
[16:18:29] indignatio: has joined #ruby
[16:18:46] gregf_: >> class Foo < Module;end; class Bar;end; [ Foo.ancestors, Bar.ancestors ]
[16:18:47] ruboto: gregf_ # => [[Foo, Module, Object, Kernel, BasicObject], [Bar, Object, Kernel, BasicObject]] (https://eval.in/467207)
[16:19:17] amitchellbullard: has joined #ruby
[16:19:53] znz_jp: has joined #ruby
[16:20:32] dravine_: has joined #ruby
[16:22:05] RobertBirnie: has joined #ruby
[16:22:31] svkurowski: has joined #ruby
[16:23:20] dorei: has joined #ruby
[16:23:44] Sou|cutter: >> class Foo < Module; end; class Bar; end; [ Foo.is_a?(Module), Foo.new.is_a?(Module), Bar.is_a?(Module), Bar.new.is_a?(Module) ]
[16:23:50] ruboto: Sou|cutter, I'm terribly sorry, I could not evaluate your code because of an error: OpenURI::HTTPError:500 Internal Server Error
[16:24:19] pontiki_x: has joined #ruby
[16:24:36] Sou|cutter: welp I missed something, but Bar.new is not a Module, and Foo.new is
[16:25:06] kfpratt: has joined #ruby
[16:25:15] chouhoulis: has joined #ruby
[16:25:16] aaeron: has joined #ruby
[16:25:29] Sou|cutter: So I'm trying to bend my mind to using Module methods on an instance, it's weird
[16:26:02] adaedra: what are you trying to do in the first place
[16:26:12] gregf_: you should'nt be able to instantiate a module :|
[16:26:53] gregf_: >>module Foo;end; begin; Foo.new; rescue => e;p e.message;end
[16:26:54] ruboto: gregf_ # => "undefined method `new' for Foo:Module" ...check link for more (https://eval.in/467209)
[16:27:09] shevy: well it is just a method
[16:27:25] ZeeNoodley: has joined #ruby
[16:27:30] shevy: you folks are breaking ruboto today :(
[16:27:58] shevy: <ruboto> gregf_, I'm terribly sorry, I could not evaluate your code because of I am an incompetent bot
[16:27:58] karapetyan: has joined #ruby
[16:28:02] ghostbox: has joined #ruby
[16:28:11] Sou|cutter: >> class Foo < Module; end; begin; Foo.new; rescue => e; p e.message; end
[16:28:12] ruboto: Sou|cutter # => #<Foo:0x41dfbf60> (https://eval.in/467210)
[16:28:15] adaedra: shevy: it's eval.in
[16:28:20] gregf_: oh, ruboto, shevy sorry about that
[16:28:40] karapetyan: has joined #ruby
[16:28:50] B1n4r10: has joined #ruby
[16:29:07] johnzorn: has joined #ruby
[16:29:11] subscope: has joined #ruby
[16:29:23] charliesome: has joined #ruby
[16:29:31] bigkevmcd: has joined #ruby
[16:29:39] arthurix: has joined #ruby
[16:29:41] gregf_: Sou|cutter: i guess theres many things one could do but why would a class want to inherit from a module? its not an is_a but has_a relationship?
[16:29:43] Hanmac: has joined #ruby
[16:30:10] karapety_: has joined #ruby
[16:30:11] gregf_: like so would this make any sense in an OO world: class Cat < Chicken; end ?
[16:30:18] symm-: has joined #ruby
[16:31:07] gregf_: modules are for delegations
[16:32:14] infamos: has joined #ruby
[16:32:29] karapetyan: has joined #ruby
[16:32:41] gregf_: but then you're right, the language needs to handle it. i would expect it for fail at compile time in like say Java. something like: public interface Bar {}; class Foo extends Bar {}
[16:32:44] Sou|cutter: This is something I saw in rails code, so I can't defend it
[16:32:54] gregf_: s/for/to/
[16:33:48] subscope: has joined #ruby
[16:34:44] shevy: they are an alien race, those railsters
[16:34:49] lubarch: has joined #ruby
[16:35:12] shevy: but they no longer require nick registration so they are on a path of redemption!
[16:36:19] johnhamelink: has joined #ruby
[16:37:20] kerunaru: has joined #ruby
[16:37:26] gregf_: Sou|cutter: https://gist.github.com/anonymous/fa62b976ccab60c47fa6 <== like that. but ruby is dynamic
[16:38:38] mghaig: has joined #ruby
[16:38:44] ThatsNotJack: has joined #ruby
[16:39:14] AugustoCesar: has joined #ruby
[16:39:29] _blizzy_: has joined #ruby
[16:40:40] alem0lars: has joined #ruby
[16:40:46] adac: has joined #ruby
[16:41:23] mjuszczak: has joined #ruby
[16:41:30] AugustoCesar: has left #ruby: ()
[16:41:47] crdpink: has joined #ruby
[16:42:00] ThatsNotJack: has joined #ruby
[16:42:27] ruurd: has joined #ruby
[16:43:19] TheNet: has joined #ruby
[16:43:42] mghaig: has joined #ruby
[16:44:36] terminalrecluse: has joined #ruby
[16:45:11] arne: has joined #ruby
[16:46:18] terminalrecluse: has joined #ruby
[16:47:26] slash_nick: ACTION unregisters
[16:47:32] ChanServ: +o havenwood
[16:47:53] [Butch]: has joined #ruby
[16:47:54] havenwood: -b *!~RandyT@*$#ruby-fix-your-connection
[16:48:41] infamos: has joined #ruby
[16:49:18] kp666: has joined #ruby
[16:50:08] Oli`: the doc for Module::new says "[...]block is evaluated in the context of this module[...]" but if I want to declare a class into my module I can't do this: Module.new { class Foo; end } I have to write this: Module.new { |mod| class mod::Foo; end }
[16:51:16] Oli`: if the block is evaluated in the context of the module, shouldn't Module.new { class Foo; end } declare a class inside my module ?
[16:51:24] Oli`: or am I missing something?
[16:52:54] shevy: here is the doc just in case someone else wants to read it:
[16:52:55] hxegon: has joined #ruby
[16:52:55] shevy: http://ruby-doc.org/core-2.1.3/Module.html#method-c-new
[16:53:14] Quandl: has joined #ruby
[16:53:36] pontiki_x: what's it actually doing, Oli` ?
[16:54:23] loc22_: has joined #ruby
[16:54:26] Oli`: Module.new { class Foo; end } actualy declare the Foo class in the current namespace, not inside the new module
[16:54:37] shevy: it seems as if it won't add a new module namespace
[16:54:41] goodcodeguy: has joined #ruby
[16:54:58] pontiki_x: interesting. i would have thought as you did given the description.
[16:55:13] Oli`: yes it seems weird to me
[16:55:16] shevy: for instance this works: https://gist.github.com/shevegen/c3fe5b8f32933ec3da61
[16:55:20] tkuchiki: has joined #ruby
[16:55:28] Sou|cutter: possibly because the module is not-yet-defined? and the block arg gives you a blank, defined, module object?
[16:55:32] vigintas: has joined #ruby
[16:55:46] pontiki_x: what's the namespace of Foo?
[16:55:49] Sou|cutter: I dunno, that sounds wrong to me
[16:55:51] shevy: I wonder where the module went
[16:55:59] pontiki_x: it's in foo
[16:56:00] Sou|cutter: I mean what I said sounds wrong
[16:56:04] rgtk: has joined #ruby
[16:56:43] ChanServ: -o havenwood
[16:57:01] shevy: I think what the docs describe does not match that code example
[16:58:04] Oli`: it works fine with method definition but the behaviour is different with classes
[16:58:31] pontiki_x: try it with other constants
[16:59:09] Xeago: has joined #ruby
[16:59:44] Oli`: ho Module.new { FOO = 5 } defines FOO in the current namespace too
[17:00:10] Oli`: so every constants are defined in the current namespace, not une the new module ?
[17:00:12] towski_: has joined #ruby
[17:00:20] shevy: can you name a module that way?
[17:00:31] shevy: because the code is not equivalent to: module Foo; right?
[17:01:10] pontiki_x: well, that does rather make sense; Module.new is not defining a namespace. it's not like module Bar;end
[17:01:23] Oli`: I thought the code was equivalent to module Foo ...
[17:01:33] shevy: but it defines in a namespace already, the top one
[17:01:35] Oli`: I mean when I read the doc it's what in understand
[17:01:39] Kikoo: has joined #ruby
[17:01:49] pontiki_x: yeah, i don't know? but the behaviour says "no" to me
[17:02:16] baweaver: has joined #ruby
[17:02:50] gregf_: Sou|cutter: i just tried this : module Foo; end; class Bar < Module;end # fails. try and do a Module.class
[17:03:08] mghaig: has joined #ruby
[17:03:19] B1n4r10: has joined #ruby
[17:03:24] pontiki_x: hmm, look more at Module.module_eval
[17:04:09] pontiki_x: "Evaluates the string or block in the context of mod, except that when a
[17:04:09] pontiki_x: block is given, constant/class variable lookup is not affected."
[17:04:21] Sou|cutter: gregf_: It fails how? It works for me in 2.1.6
[17:05:47] Oli`: so it's just the intended behaviour? :>
[17:05:48] EminenceHC: has joined #ruby
[17:05:50] davedev24: has joined #ruby
[17:06:33] TheNet: has joined #ruby
[17:06:33] Sou|cutter: it's expected behavior, yeah
[17:06:40] Sou|cutter: I know I've run into that once before
[17:06:43] gregf_: Sou|cutter: i'm on 2.2. and it fails. it fails on 2.1 as well.
[17:06:53] Sou|cutter: define fails
[17:06:57] Oli`: ok thank you
[17:07:09] gregf_: >> module Foo; end; class Bar < Foo;end
[17:07:10] ruboto: gregf_ # => superclass must be a Class (Module given) (TypeError) ...check link for more (https://eval.in/467217)
[17:07:14] gregf_: Sou|cutter: ^^
[17:07:26] Sou|cutter: When I do it, it works
[17:07:31] karapetyan: has joined #ruby
[17:07:49] Oli`: I can stop fighting with irb now :)
[17:09:34] Sou|cutter: gregf_: OHH that's different from your original thing
[17:09:44] Sou|cutter: class Bar < Module vs class Bar < Foo
[17:11:16] bmalum: has joined #ruby
[17:11:19] Sou|cutter: I was talking about the former
[17:11:32] roxtrongo: has joined #ruby
[17:11:48] DiCablo: has joined #ruby
[17:11:51] ruurd: has joined #ruby
[17:12:32] symm-: has joined #ruby
[17:13:09] JDiPierro: has joined #ruby
[17:13:10] charliesome: has joined #ruby
[17:13:20] gregf_: Sou|cutter: it sure is. but apart from what i pasted, Module.class prints Class
[17:14:19] crdpink2: has joined #ruby
[17:15:22] SCHAAP137: has joined #ruby
[17:17:45] blandflakes: has joined #ruby
[17:17:54] ruby-lang323: has joined #ruby
[17:18:45] tvw: has joined #ruby
[17:19:09] charliesome: has joined #ruby
[17:19:14] cicloid: has joined #ruby
[17:19:15] Fire-Dragon-DoL: if I have `Bundler.setup(:default, :test)`, why pry-byebug is available in my $LOAD_PATH if it's in development group?
[17:19:50] Fire-Dragon-DoL: oh there is a bundler channel, sorry I'll ask it there
[17:21:10] mpistone: has joined #ruby
[17:22:33] diego1: has joined #ruby
[17:22:52] diego1: has joined #ruby
[17:23:15] Maletor: has joined #ruby
[17:23:34] yardenbar: has joined #ruby
[17:23:40] jpfuentes2: has joined #ruby
[17:24:13] cpup: has joined #ruby
[17:24:33] lukaszes: has joined #ruby
[17:24:48] willardg: has joined #ruby
[17:25:21] Alayde: has joined #ruby
[17:25:29] scmx: has joined #ruby
[17:25:31] davedev24: has joined #ruby
[17:25:34] rakm: has joined #ruby
[17:25:43] Xeago_: has joined #ruby
[17:26:29] corehook: has joined #ruby
[17:27:50] charliesome: has joined #ruby
[17:29:56] baweaver: has joined #ruby
[17:31:34] Alayde: has left #ruby: ("WeeChat 1.1.1")
[17:31:49] dmolina: has joined #ruby
[17:31:55] mpistone: has left #ruby: ()
[17:32:42] charliesome: has joined #ruby
[17:33:06] subscope: has joined #ruby
[17:33:30] nertzy: has joined #ruby
[17:33:32] mghaig: has joined #ruby
[17:34:00] qoe: has joined #ruby
[17:34:25] Guest54: has joined #ruby
[17:34:57] lubarch: has joined #ruby
[17:35:16] NeverDie: has joined #ruby
[17:35:48] ruurd: has joined #ruby
[17:36:13] K1MOS: has joined #ruby
[17:36:15] bmalum: has joined #ruby
[17:36:34] charliesome_: has joined #ruby
[17:36:51] baroquebobcat: has joined #ruby
[17:36:56] dopie: has joined #ruby
[17:38:10] NeverDie_: has joined #ruby
[17:38:48] charliesome: has joined #ruby
[17:39:02] RobertBirnie: has joined #ruby
[17:39:19] h99h9h88: has joined #ruby
[17:39:40] overcrush: has joined #ruby
[17:40:05] momloy: has joined #ruby
[17:40:33] overcrush: is it normal for me to have the ruby src/<version> files chillin in my home folder?
[17:40:39] ascarter: has joined #ruby
[17:41:10] ghostbox: has joined #ruby
[17:41:23] Arkon: has joined #ruby
[17:41:25] synthroid: has joined #ruby
[17:41:55] evanjs: has joined #ruby
[17:42:36] grilled-cheese: has joined #ruby
[17:43:23] grilled-cheese: in ruby 2.1.7p400, does anyone know why ???etc??? might be missing from the windows version of stdlib?
[17:44:20] ThatsNotJack: has joined #ruby
[17:44:21] adaedra: etc seems very unix-y
[17:44:23] blackmesa: has joined #ruby
[17:44:44] grilled-cheese: yes, but it has worked in the past under windows
[17:45:02] grilled-cheese: it???s a consistent way to get user data across all 3 platforms
[17:45:05] overcrush: has left #ruby: ("Leaving...")
[17:45:32] cicloid: has joined #ruby
[17:47:03] grilled-cheese: if you startup irb and try to require it, you get a false result
[17:47:19] grilled-cheese: but under osx and linux, it???s fine
[17:47:30] rakm: has joined #ruby
[17:50:10] adaedra: I got false after a require under OS X ??? You don't have any error, is Etc defined?
[17:50:20] eam: grilled-cheese: etc is built-in to ruby, yeah? I'm not current on windows, but do you know how to check symbols in a binary?
[17:50:26] slawrence00: has joined #ruby
[17:50:35] ghoti: has joined #ruby
[17:50:37] eam: is it perhaps already required by irb?
[17:51:09] grilled-cheese: Etc.group returns nil
[17:51:24] blubjr`: doesn't false from require just mean that its already loaded
[17:51:25] adaedra: So Etc is defined
[17:51:34] blubjr`: i thought you got an exception if it didnt find it
[17:51:42] eam: it's not even findable -- it's built into /usr/bin/ruby
[17:51:44] JDiPierro: has joined #ruby
[17:51:54] eam: there is no etc.rb or etc.so
[17:52:08] charany1: has joined #ruby
[17:52:10] cdg: has joined #ruby
[17:52:41] mrtomme: has joined #ruby
[17:52:43] nfk: has joined #ruby
[17:52:43] grilled-cheese: how would I check the symbol table for it?
[17:52:47] grilled-cheese: am I missing something?
[17:53:06] eam: grilled-cheese: just type Etc into irb
[17:53:19] eam: is it a defined class?
[17:53:33] eam: so it's already required
[17:53:33] saddad: has joined #ruby
[17:53:48] grilled-cheese: I can run Etc.getlogin
[17:53:49] cdg: has joined #ruby
[17:53:50] benlieb: has joined #ruby
[17:54:09] dmolina: has joined #ruby
[17:54:27] grilled-cheese: but not .group or .passwd
[17:54:53] armyriad: has joined #ruby
[17:55:14] shevy: Etc.group works for me here
[17:55:38] Arkon: has joined #ruby
[17:55:40] shevy: I am not using windows though
[17:55:47] grilled-cheese: I think that???s the trick
[17:56:40] grilled-cheese: looks like under windows, it may just return nill without a warning
[17:57:22] grilled-cheese: under OSX and linux it???s fine
[17:57:32] eam: weren't we just talking about how windows dropped posix subsystem support at one point?
[17:57:42] grilled-cheese: ok, that maybe makes some sense
[17:58:11] grilled-cheese: it still stinks though because now there isn???t a single library to query user/group data
[17:58:47] Eiam_: has joined #ruby
[17:59:22] shevy: I assume windows does not offer the similar information
[17:59:27] mpistone: has joined #ruby
[17:59:47] adaedra: It does, but not the same way
[17:59:55] mghaig: has joined #ruby
[18:00:13] grilled-cheese: I think you have to go at it from the ole way
[18:01:18] gusrub: has joined #ruby
[18:01:32] RandyT: has joined #ruby
[18:01:52] shevy: there are about 3 windows users here in total :)
[18:01:56] mikecmpbll: has joined #ruby
[18:02:51] charliesome: has joined #ruby
[18:03:20] lemur: has joined #ruby
[18:04:01] EdwardIII: has left #ruby: ()
[18:04:05] Pupp3tm4st3r: has joined #ruby
[18:05:58] codecop: has joined #ruby
[18:06:03] cdg_: has joined #ruby
[18:09:01] karapetyan: has joined #ruby
[18:09:33] Shoutsid: has joined #ruby
[18:10:20] sdothum: has joined #ruby
[18:10:43] gusTester: has joined #ruby
[18:11:25] gusTester: has left #ruby: ()
[18:13:11] tubuliferous_: has joined #ruby
[18:14:50] Stan: has joined #ruby
[18:15:34] Arkon: has joined #ruby
[18:16:55] tomphp: has joined #ruby
[18:17:41] Guest53: has joined #ruby
[18:18:10] TheNet: has joined #ruby
[18:18:14] tomphp: has joined #ruby
[18:19:32] EminenceHC: has joined #ruby
[18:19:39] dtordable: has joined #ruby
[18:21:20] krz: has joined #ruby
[18:22:06] icarus_: has joined #ruby
[18:22:20] hxegon: has joined #ruby
[18:22:23] yardenbar: has joined #ruby
[18:23:18] Guest53: has joined #ruby
[18:24:36] User458764: has joined #ruby
[18:25:01] ht__: has joined #ruby
[18:25:26] baweaver: has joined #ruby
[18:25:59] gusrub: has joined #ruby
[18:26:02] mattwildig: has joined #ruby
[18:26:55] diegoaguilar: has joined #ruby
[18:27:00] Yzguy: has joined #ruby
[18:27:51] tvw: has joined #ruby
[18:28:03] luriv: has joined #ruby
[18:29:08] gusTester: has joined #ruby
[18:29:29] gusTester: has left #ruby: ()
[18:30:08] roger_rabbit: has joined #ruby
[18:31:07] ruurd: has joined #ruby
[18:31:38] arup_r: has joined #ruby
[18:32:45] K1MOS: has joined #ruby
[18:32:45] trav408: has joined #ruby
[18:33:45] ruby-lang407: has joined #ruby
[18:35:37] fantazo: has joined #ruby
[18:35:45] adac: has joined #ruby
[18:35:57] mghaig: has joined #ruby
[18:36:50] blackmesa: has joined #ruby
[18:37:28] tulak: has joined #ruby
[18:38:36] mesamoo: has joined #ruby
[18:38:39] Icey: has joined #ruby
[18:39:14] _blizzy_: has joined #ruby
[18:40:12] synthroid: has joined #ruby
[18:41:13] ht__: has joined #ruby
[18:41:22] TheNet: has joined #ruby
[18:41:25] Guest3421: has joined #ruby
[18:41:31] emilkarl: has joined #ruby
[18:42:21] Blaguvest: has joined #ruby
[18:42:35] TomPeed: has joined #ruby
[18:42:39] roxtrongo: has joined #ruby
[18:42:40] rakm: has joined #ruby
[18:42:46] towler: has joined #ruby
[18:42:53] cpup: has joined #ruby
[18:42:55] ramfjord: has joined #ruby
[18:44:45] EminenceHC: has joined #ruby
[18:45:10] yardenbar: has joined #ruby
[18:45:58] axl_: has joined #ruby
[18:46:10] aaeron: has joined #ruby
[18:48:13] solocshaw: has joined #ruby
[18:48:23] centrx: has joined #ruby
[18:49:49] levifig: has joined #ruby
[18:51:31] purplexed-: has joined #ruby
[18:51:31] purplexed-: has joined #ruby
[18:51:34] weaksauce: has joined #ruby
[18:52:12] dionysus69: has joined #ruby
[18:53:49] makenoise: has joined #ruby
[18:54:45] ss_much: has joined #ruby
[18:57:36] dionysus70: has joined #ruby
[18:57:45] dlitvak: has joined #ruby
[18:59:27] x-light: has joined #ruby
[18:59:50] hxegon: has joined #ruby
[19:00:25] mesamoo: has joined #ruby
[19:00:35] lipoqil: has joined #ruby
[19:01:07] aaeron: has joined #ruby
[19:01:27] karapetyan: has joined #ruby
[19:02:36] __desmondhume: has joined #ruby
[19:03:23] moeabdol: has joined #ruby
[19:03:41] rakm: has joined #ruby
[19:04:15] DEA7TH: has joined #ruby
[19:04:20] RegulationD: has joined #ruby
[19:04:35] mghaig: has joined #ruby
[19:04:40] baweaver: has joined #ruby
[19:04:42] grilled-cheese: has joined #ruby
[19:05:23] failshell: has joined #ruby
[19:07:32] kerunaru: has joined #ruby
[19:08:10] EminenceHC: has joined #ruby
[19:08:31] chrisja: has joined #ruby
[19:08:36] cornerma1: has joined #ruby
[19:08:37] maasha: has joined #ruby
[19:08:45] ascarter: has joined #ruby
[19:08:55] maasha: Can I get rake to skip a task if it was completed successfully earlier - like writing file.
[19:09:40] aaeron: has joined #ruby
[19:10:08] Axsuul: has joined #ruby
[19:10:14] shadeslayer: has joined #ruby
[19:10:26] jhass: it should do so by default
[19:10:56] jhass: or you mean between multiple runs? look into `rule`
[19:11:37] Arkon: has joined #ruby
[19:12:32] Pupeno: has joined #ruby
[19:12:32] Pupeno: has joined #ruby
[19:12:58] _stu_: has joined #ruby
[19:12:59] last_staff: has joined #ruby
[19:13:24] psye: has joined #ruby
[19:14:35] luriv: has joined #ruby
[19:14:42] mghaig: has joined #ruby
[19:14:59] baweaver: has joined #ruby
[19:17:04] apfeluser: has joined #ruby
[19:17:20] aaeron: has joined #ruby
[19:19:32] lapide_viridi: has joined #ruby
[19:19:50] Fire-Dragon-DoL: has joined #ruby
[19:20:14] pwnd_nfsw: has joined #ruby
[19:20:48] fantazo: has joined #ruby
[19:20:49] gusrub: has joined #ruby
[19:21:08] c355E3B: has joined #ruby
[19:24:45] maasha: jhass: hm, how would a rule like that downloads a file, but only once?
[19:24:54] maasha: *look like
[19:25:05] jhass: I always need to look at the docs too
[19:26:02] TheNet: has joined #ruby
[19:27:35] bmalum: has joined #ruby
[19:30:04] makenoise: has joined #ruby
[19:30:24] stamina: has joined #ruby
[19:30:37] opensource_ninja: has joined #ruby
[19:31:17] sepp2k: has joined #ruby
[19:32:23] vyorkin: has joined #ruby
[19:32:33] edwinvdgraaf: has joined #ruby
[19:33:09] jackjackdripper: has joined #ruby
[19:33:21] nateberkopec: has joined #ruby
[19:33:34] ellisTAA: has joined #ruby
[19:33:40] jackjackdripper: has joined #ruby
[19:34:10] skullcrasher: has joined #ruby
[19:35:09] ascarter: has joined #ruby
[19:36:04] jackjackdripper: has joined #ruby
[19:36:30] ellisTAA: what is the offtopic channel called?
[19:36:40] yardenbar: has joined #ruby
[19:37:01] loc22: has joined #ruby
[19:37:07] centrx: EllisTAA, #ruby-offtopic
[19:37:18] centrx: EllisTAA, most offtopic channels on IRC follow that form
[19:37:21] hxegon: has joined #ruby
[19:37:41] ellisTAA: centrx: thanks
[19:38:11] Arkon: has joined #ruby
[19:38:23] h99h9h88: has joined #ruby
[19:38:58] shadoi: has joined #ruby
[19:41:24] dlitvak: has joined #ruby
[19:41:43] ruby-lang920: has joined #ruby
[19:42:20] ibouvousaime: has joined #ruby
[19:43:01] vigintas: has joined #ruby
[19:44:32] sdwrage: has joined #ruby
[19:45:47] NathanielHiggers: has joined #ruby
[19:45:50] NathanielHiggers: has left #ruby: ()
[19:45:59] to_json: has joined #ruby
[19:47:33] mattwildig: has joined #ruby
[19:49:20] lukaszes: has joined #ruby
[19:50:28] ruurd: has joined #ruby
[19:50:33] ta: has joined #ruby
[19:51:16] rippa: has joined #ruby
[19:51:46] leafybas_: has joined #ruby
[19:52:19] leafybas_: has joined #ruby
[19:52:32] dlitvak_: has joined #ruby
[19:52:39] shredding: has joined #ruby
[19:53:01] Freeaqingme: has joined #ruby
[19:54:01] segfalt: has joined #ruby
[19:54:39] NathanielHiggers: has joined #ruby
[19:54:42] NathanielHiggers: has left #ruby: ()
[19:55:13] ht__: has joined #ruby
[19:56:15] dlitvak: has joined #ruby
[19:56:23] Kabal: has joined #ruby
[19:56:45] bruno-: has joined #ruby
[19:58:15] arthurix: has joined #ruby
[19:58:22] Kabal: has joined #ruby
[19:59:45] Kabal: has joined #ruby
[19:59:52] aaeron1: has joined #ruby
[20:00:01] devoldmx: has joined #ruby
[20:00:03] lukaszes: has joined #ruby
[20:00:23] evanjs: has joined #ruby
[20:01:20] ascarter: has joined #ruby
[20:01:51] Arkon: has joined #ruby
[20:01:56] jud: has joined #ruby
[20:01:57] aaeron2: has joined #ruby
[20:03:28] aaeron: has joined #ruby
[20:05:12] A124: has joined #ruby
[20:05:39] sinkensabe: has joined #ruby
[20:06:12] Arkon: has joined #ruby
[20:06:17] baweaver: has joined #ruby
[20:07:02] karapetyan: has joined #ruby
[20:07:52] roxtrongo: has joined #ruby
[20:07:53] prestorium: has joined #ruby
[20:08:08] diegoaguilar: has joined #ruby
[20:08:09] poguez_: has joined #ruby
[20:08:09] karapetyan: has joined #ruby
[20:09:29] trajing: has joined #ruby
[20:11:09] karapetyan: has joined #ruby
[20:11:35] loc22: has joined #ruby
[20:11:57] duncannz: has joined #ruby
[20:12:28] rakm: has joined #ruby
[20:13:40] blackmesa: has joined #ruby
[20:14:44] diegoaguilar: has joined #ruby
[20:14:45] Guest53: has joined #ruby
[20:15:10] VeryBewitching: has joined #ruby
[20:15:45] VeryBewitching: How's the day havenwood?
[20:15:51] havenwood: VeryBewitching: it goes!
[20:16:05] VeryBewitching: Never enough keystrokes in a day.
[20:16:11] ibouvousaime: has joined #ruby
[20:17:01] scmx: has joined #ruby
[20:19:00] platzhirsch: has joined #ruby
[20:19:36] Arkon: has joined #ruby
[20:21:29] A124: has joined #ruby
[20:21:46] leafybas_: has joined #ruby
[20:22:17] mjuszczak: has joined #ruby
[20:22:56] EminenceHC: has joined #ruby
[20:23:19] baweaver: has joined #ruby
[20:23:56] dlitvak: has joined #ruby
[20:23:59] mjuszczak: has joined #ruby
[20:25:23] momomomomo: has joined #ruby
[20:26:19] gusrub: has joined #ruby
[20:27:59] yfeldblum: has joined #ruby
[20:28:01] Yzguy: has joined #ruby
[20:29:09] ht__: has joined #ruby
[20:30:18] _kfpratt: has joined #ruby
[20:34:41] mghaig: has joined #ruby
[20:34:45] last_staff: has joined #ruby
[20:35:04] kies: has joined #ruby
[20:36:24] naftilos76: has joined #ruby
[20:38:17] neanderslob: has joined #ruby
[20:38:38] naftilos76: Hi i am trying to use net-ssh / net-ssh-shell to finally buld a login shell through ruby. I could execute simple terminal commands but what i really want is to be able to play with rvm and that requires a login shell. Can any body help?
[20:39:17] DoubleMalt: has joined #ruby
[20:44:32] dasher00: has joined #ruby
[20:44:58] mghaig: has joined #ruby
[20:46:11] kadoppe: has joined #ruby
[20:46:17] baweaver: has joined #ruby
[20:46:22] sinkensabe: has joined #ruby
[20:48:22] gusrub: has joined #ruby
[20:49:27] yqt: has joined #ruby
[20:49:38] willardg: has joined #ruby
[20:51:52] baweaver: has joined #ruby
[20:52:20] professorscience: has joined #ruby
[20:52:27] waka: has joined #ruby
[20:53:02] CloCkWeRX: has joined #ruby
[20:53:10] ht__: has joined #ruby
[20:53:44] dlitvak: has joined #ruby
[20:54:33] diegoaguilar: has joined #ruby
[20:54:39] professorscience: Hi all, not sure if this is the right place but: I'm trying to use rake because it came along with 'ceedling' which I'm trying out. A few questions but starting at one: is there a way I can add a task as a pre-requisite to all tasks (except itself)?
[20:55:02] ESpiney: has joined #ruby
[20:55:04] bmalum: has joined #ruby
[20:55:13] __desmondhume: has joined #ruby
[20:55:23] BraddPitt: naftilos76 can you expand on what you're trying to do?
[20:55:47] mattwildig: has joined #ruby
[20:55:51] cicloid: has joined #ruby
[20:55:52] elshaka: has joined #ruby
[20:55:57] mozzarella: has joined #ruby
[20:56:21] Guest53: has joined #ruby
[20:56:23] benlieb: has joined #ruby
[20:56:29] jhass: professorscience: not really, I mean you could list all tasks and update them again, but what is this for?
[20:56:41] BraddPitt: professorscience you can have a rake task call another rake task with `Rake::Task['task_name'].execute
[20:57:10] DoubleMalt: has joined #ruby
[20:57:30] sdwrage: has joined #ruby
[20:57:56] mjuszczak: has joined #ruby
[20:58:28] mjuszczak: has joined #ruby
[20:58:48] lukaszes: has joined #ruby
[20:58:49] professorscience: jhass: There seem to be several options for default builds - test, test:all, release, default, all... I would like it so all of them depend on having built one task which is a library.
[20:59:03] jhass: elaborate?
[20:59:29] dopie: has joined #ruby
[20:59:37] naftilos76: BraddPitt, i am using rails 4.2 and at some point i need a login shell so that i can set my ruby env bu doing 'rvm use 2.2.0' and then get the list of gems i have and showing them in a webpage
[20:59:48] DoubleMalt: has joined #ruby
[21:01:00] professorscience: jhass: I'm using someone else's library which I've cloned from github. It has a makefile to build its own .o files which I can then (hopefully) link my C against. But I need to have the make command run for any of the rake tasks. If that makes sense?
[21:01:05] sinkensabe: has joined #ruby
[21:01:20] BraddPitt: naftilos76 so on a webpage hosted by your rails app, you want to have an interactive login shell?
[21:01:28] professorscience: jhass: I should say, ceedling is a TDD framework for C, but it includes rake.
[21:01:37] Cyther: has joined #ruby
[21:01:43] BraddPitt: or you just want to show the list of gems being used on a webpage hosted by your rails app?
[21:02:04] BraddPitt: if the latter, you can just shell out for the command and put the return value in an html.erb page
[21:02:53] jhass: professorscience: I would expect ceedling to have appropriate hooks/configuration for that
[21:03:11] roxtrongo: has joined #ruby
[21:03:11] naftilos76: BraddPitt, no as i said i want to show a list of my gems under a certain ruby version. RVM requires a login shell. I cannot do that with system() or other `` or whatever.
[21:03:13] jhass: peeking at the project you don't write a Rakefile/regular rake tasks at all there
[21:03:35] h99h9h88: has joined #ruby
[21:03:48] Sdwrage_: has joined #ruby
[21:04:02] naftilos76: BraddPitt, happens on the click of a button. i never said anything about an interactive terminal on a page
[21:04:40] karapetyan: has joined #ruby
[21:04:45] BraddPitt: ok, I see. Well unfortunately I cannot help you as I do not know how to get a login shell from ruby
[21:04:55] zwdr: cant you just use a cronjob to write that stuff into a flat file?
[21:05:02] professorscience: jhass: Hmm. I would have thought the same but it seems the project maintainers haven't got around to fully documenting their scripts.
[21:05:11] ht__: has joined #ruby
[21:05:16] BraddPitt: I would suggest zwdr's approach
[21:06:18] naftilos76: BraddPitt, someone did this: http://stackoverflow.com/questions/5051782/ruby-net-ssh-login-shell which is supposed to perform like a login shell but i cannot get stdout from the commands execution
[21:06:39] mjuszczak: has joined #ruby
[21:06:47] uri: has joined #ruby
[21:06:59] lemur: has joined #ruby
[21:07:40] nfk|laptop: has joined #ruby
[21:08:47] maddmaxx: has joined #ruby
[21:09:03] naftilos76: Anybody? Login shell with a ruby gem?
[21:09:10] freerobby: has joined #ruby
[21:09:53] jhass: run sh -l ?
[21:10:47] malconis: has joined #ruby
[21:11:03] naftilos76: This project claims interactive login shells but no docs are available and after trying some methods i couldn't get stdout : https://github.com/jedi4ever/net-ssh-shell
[21:11:19] jhass: dunno, if you have the rvm script in the path, just use rvm do
[21:11:57] malconis: has joined #ruby
[21:12:54] naftilos76: jhass, if i do any of these bash -l or sh -l the net/ssh gem process gets trapped which is documented as normal as this is not the supposed usage of net/ssh
[21:13:38] naftilos76: jhass, i want to be able to change rubies by doing rvm use this or use that etc
[21:13:41] frmendes: has joined #ruby
[21:13:45] jhass: it's (getting a login shell) probably the wrong solution to your problem anyway
[21:14:14] naftilos76: jhass, do you have anything else to suggest?
[21:14:29] BraddPitt: can you make a bash script on the server running rvm that outputs the gemlist into a file?
[21:14:39] BraddPitt: then read that file in your application to get the gem list?
[21:14:45] jhass: rvm use is merely convenience, nothing I'd rely on in a script anyway
[21:14:52] grillo: question: how would I go about splitting up a module across multiple files (one class per file) in such a manner that would allow the classes to reference eachother?
[21:15:37] BraddPitt: grill_ references should (ideally) be one way to avoid circular dependencies
[21:15:42] naftilos76: i do not want to break this process into a bunch of running scripts bash/ruby each affecting the other and so on
[21:15:42] BraddPitt: attempt to structure you code as such
[21:15:44] maddmaxx: has joined #ruby
[21:15:51] jhass: grill_: you generally don't have to worry about it until you have toplevel code referencing one constant to be defined to define another and to define that other constant you need the former
[21:15:54] cicloid_: has joined #ruby
[21:15:58] evanjs: has joined #ruby
[21:16:13] jhass: grill_: that is if you have the references in methods only, it should just work
[21:17:03] cicloid: has joined #ruby
[21:17:15] tomphp: has joined #ruby
[21:17:20] SCHAAP137: has joined #ruby
[21:17:20] grillo: ok. can I structure the file as I would a java program?
[21:17:28] dented42: has joined #ruby
[21:17:44] dmitch: has joined #ruby
[21:17:50] grillo: i.e. have one "main" class that instantiates other classes + performs operations?
[21:17:51] shevy: what does this mean
[21:17:59] Coldblackice: has joined #ruby
[21:18:07] grillo: do I need to do any includes or anything?
[21:18:13] shevy: of course
[21:18:15] cicloid: has joined #ruby
[21:18:21] grillo: how would the includes work?
[21:18:38] jhass: include is for mixing a module into a class
[21:18:42] Maletor: has joined #ruby
[21:18:57] jhass: it's sort of like inheriting an interface in java, except that the implementation comes with them
[21:19:10] jhass: so no, you don't generally need include
[21:19:18] jhass: only where it makes sense
[21:19:24] grillo: why'd shevy say "of course" then
[21:19:39] jhass: because shevy, nobody else would mind if you just ignore them tbh
[21:20:35] rickmasta: has joined #ruby
[21:20:35] grillo: so ruby will implicitly understand that several classes in a module spread across several files are all part of the same module?
[21:20:59] Axsuul: has joined #ruby
[21:21:17] jhass: grill_: ruby doesn't really care. You use require to load files and those files define constants (classes and modules are just objects assigned to constants too)
[21:21:52] Guest53: has joined #ruby
[21:21:53] jhass: ruby makes no assumptions at all on the relation between file names and what classes or modules they define or do in any way really
[21:21:59] jhass: that's just conventions
[21:23:01] grillo: ok. i am going to have to look into require a bit then.
[21:23:03] jhass: the two popular styles are to require the files that define the classes & modules the class/module of the current file needs in order to function at the top of the file, or have a central entry point file where you do all requires in the right order
[21:23:09] jhass: I tend to prefer the first
[21:23:32] sdothum: has joined #ruby
[21:24:19] redline6561: has joined #ruby
[21:24:50] frmendes: hey! I have to connect to an already existing database. With datamapper it's just defining the models and relationships between them and run setup, right?
[21:26:27] dravine: has joined #ruby
[21:26:47] banister: yorickpeterse The Dutch-man with a singular bullfrog or trilobite expression of the eyes, whose eyes were like frog ponds in the broad platter of his cheeks and gleamed like a pool covered with frog-spittle.
[21:27:38] EvanFreeeman: has joined #ruby
[21:27:56] EvanFreeeman: look at all these people
[21:29:00] EvanFreeeman: has left #ruby: ()
[21:29:51] mwaldner: has joined #ruby
[21:31:38] neanderslob: has joined #ruby
[21:32:16] ghostbox: has joined #ruby
[21:32:33] EvanFreeeman: has joined #ruby
[21:32:37] tomphp: has joined #ruby
[21:32:43] EvanFreeeman: has left #ruby: ()
[21:32:55] Ox0dea: has joined #ruby
[21:33:06] jhass: do they expect a reaction within 3 seconds or ...?
[21:33:29] adaedra: Like most new people on IRC.
[21:33:45] adaedra: "There's 1k people, room must be very active."
[21:33:48] Ox0dea: jhass: I'm almost certain shevy took grill_'s "do any includes" to mean "use `require`", which would explain his "of course".
[21:34:14] jhass: Ox0dea: maybe, it's confusing to newbies nevertheless
[21:34:24] sepp2k1: has joined #ruby
[21:34:35] jhass: if you research include with ruby you won't get require explained
[21:34:35] grillo: s/new people on IRC/millennials/g
[21:34:47] jhass: new to ruby I mean ;)
[21:35:25] grillo: yeah. i am looking into require and include now. it is time
[21:35:39] Ox0dea: In any case, "do any includes" is poor phrasing, and I don't think shevy deserved that particular round of belittlement.
[21:35:43] jhass: Ox0dea: and tbh they have a habit for such confusing statements or mentioning things that are only confusing to the other person since only remotely related
[21:35:48] mghaig: has joined #ruby
[21:35:55] Ox0dea: But I do that too?
[21:36:32] grillo: ok. so, i meant "requre"
[21:36:36] grillo: err require
[21:36:55] adaedra: Ox0dea: not the same way, I'd say.
[21:36:59] jhass: Ox0dea: you solve the real problem first or at least clear it up quickly. I'm not saying they do it intentionally, but they keep going on with the irrelevant/confusing stuff
[21:37:23] jhass: defending it as relevant even when pointed out that it's quite misleading atm
[21:37:35] grillo: so, let's say I have a module with three classes (a, b, and main). Let's also say I've split the module into three files such that each contains a single class. How do I reference a and b from main?
[21:38:27] jhass: grill_: if you're inside module Main, just A or B, outside Main::A, Main::B
[21:38:28] tomphp: has joined #ruby
[21:38:33] h99h9h88: has joined #ruby
[21:38:44] jhass: grill_: and as said make sure the files defining A & B are require'd first
[21:39:25] kriskropd_: has joined #ruby
[21:39:39] imperator: has joined #ruby
[21:40:42] rgtk: has joined #ruby
[21:41:52] benlieb: has joined #ruby
[21:43:05] VeryBewitching: has joined #ruby
[21:43:37] Freeaqingme: has joined #ruby
[21:43:40] CloCkWeRX: has joined #ruby
[21:44:56] k3asd`: has joined #ruby
[21:48:06] raldu_: has left #ruby: ()
[21:48:41] malconis_: has joined #ruby
[21:49:09] ht__: has joined #ruby
[21:50:55] arthurix: has joined #ruby
[21:50:57] tomphp: has joined #ruby
[21:51:34] mghaig: has joined #ruby
[21:51:44] adac: has joined #ruby
[21:51:59] mh_laakso: has joined #ruby
[21:52:51] mjuszczak: has joined #ruby
[21:52:55] SCHAAP137: has joined #ruby
[21:53:18] Guest53: has joined #ruby
[21:53:29] aaeron: has joined #ruby
[21:54:53] rakm: has joined #ruby
[21:55:09] ht__: has joined #ruby
[21:56:02] tomphp: has joined #ruby
[21:57:17] CloCkWeRX: has left #ruby: ()
[21:57:35] ghostbox: has joined #ruby
[21:57:55] subscope: has joined #ruby
[21:58:04] jdawgaz: has joined #ruby
[21:58:30] MEATCHICKEN: Anyone looking for ruby devs?
[21:59:12] vdamewood: has joined #ruby
[21:59:26] adaedra: I think they're in the #ruby channel
[21:59:40] agent_white: has joined #ruby
[22:00:34] malconis: has joined #ruby
[22:00:42] devoldmx: has joined #ruby
[22:01:09] rakm: has joined #ruby
[22:01:30] K1MOS: has joined #ruby
[22:01:41] mhi^: has left #ruby: ()
[22:02:29] jdawgaz: has joined #ruby
[22:03:06] weemsledeux: has joined #ruby
[22:03:11] ht__: has joined #ruby
[22:03:22] Xeago: has joined #ruby
[22:03:28] tomphp: has joined #ruby
[22:03:55] phillips1012: has joined #ruby
[22:04:07] imperator: adaedra, wut
[22:04:19] willardg: has joined #ruby
[22:05:02] it_tard: has joined #ruby
[22:05:39] adaedra: imperator, nothing.
[22:07:02] rakm: has joined #ruby
[22:07:17] professorscience: has left #ruby: ()
[22:07:22] mjuszczak: has joined #ruby
[22:07:41] lemur: has joined #ruby
[22:07:53] tulak: has joined #ruby
[22:07:57] Axsuul: has joined #ruby
[22:08:28] Sdwrage_: has joined #ruby
[22:08:38] Axsuul: has joined #ruby
[22:09:28] tomphp: has joined #ruby
[22:11:25] rgtk: has joined #ruby
[22:12:40] weaksauce: has joined #ruby
[22:13:45] weaksauce: has joined #ruby
[22:14:20] blackmesa: has joined #ruby
[22:16:35] Paradox: has joined #ruby
[22:16:47] jdawgaz: has joined #ruby
[22:17:35] karapetyan: has joined #ruby
[22:20:21] tomphp: has joined #ruby
[22:22:27] darix: 2.3.0.preview1
[22:22:46] Ox0dea: Is that a thing?
[22:22:54] ndancer: has joined #ruby
[22:23:46] dkam: has joined #ruby
[22:23:47] aramiscd: has joined #ruby
[22:23:59] tomphp: has joined #ruby
[22:24:18] Ox0dea: Searching only turns up Shibata-san's blog?
[22:26:36] minimalism: has joined #ruby
[22:27:06] darix: Ox0dea: ruby ML has announcement
[22:27:10] shevy: are you people doing ruby prank day again
[22:27:17] darix: [ruby-core:71450]
[22:27:32] darix: http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/71450
[22:27:52] sdwrage: has joined #ruby
[22:29:11] shevy: how should this be compiled
[22:29:16] darix: and test package is building
[22:29:33] Ox0dea: shevy: Haven't you compiled Ruby before?
[22:30:07] shevy: yeah but not with this magic bullet thing there
[22:30:27] tomphp: has joined #ruby
[22:30:42] shevy: I can't see any configure option for that?
[22:30:45] havenwood: https://ftp.ruby-lang.org/pub/ruby/2.3/
[22:31:12] darix: shevy: well you can install an opensuse vm and use my rpm. ;)
[22:31:48] shevy: darix what option did you use for compiling it?
[22:32:01] darix: shevy: the same as for my 2.2 rpm atm
[22:32:15] darix: once this test build is done i will check for new configure options
[22:33:25] tomphp: has joined #ruby
[22:33:27] vdamewood: has joined #ruby
[22:33:38] redline6561: has left #ruby: ()
[22:34:59] tomphp: has joined #ruby
[22:35:32] darix: stupid typo
[22:37:17] marr: has joined #ruby
[22:38:03] zapata: has joined #ruby
[22:40:10] h99h9h88: has joined #ruby
[22:40:22] mghaig: has joined #ruby
[22:40:43] imperator: on the one hand, the string.freeze pragma is pretty cool
[22:41:03] imperator: on the other, i feel like if i need to use it, i've entered "might want to use another language" territory
[22:42:02] tomphp: has joined #ruby
[22:43:09] darix: https://gist.githubusercontent.com/anonymous/96e44b3edae7323d2c17/raw/1d75a88e68ddf14914d7aecc0c6e4ca389823584/gistfile1.txt
[22:43:12] darix: that sounds promising
[22:43:47] tomphp_: has joined #ruby
[22:44:55] Ox0dea: imperator: I'm trying to find a way to monitor allocations to automatically thaw these stupid frozen-by-default strings. :P
[22:45:33] Ox0dea: There's #trace_object_allocations on ObjectSpace, but it takes a block to monitor.
[22:45:38] skweek: has joined #ruby
[22:45:53] tomphp__: has joined #ruby
[22:46:14] Ox0dea: (Just for giggles, mind.)
[22:47:36] tomphp: has joined #ruby
[22:48:48] user1138: has joined #ruby
[22:49:25] htmldrum: has joined #ruby
[22:50:13] rickmasta: has joined #ruby
[22:51:28] tomphp: has joined #ruby
[22:51:49] momomomomo: has joined #ruby
[22:51:54] [gmi]: has joined #ruby
[22:52:14] Yzguy: has joined #ruby
[22:53:34] robbyoconnor: has joined #ruby
[22:54:26] Fire-Dragon-DoL: has joined #ruby
[22:54:47] tomphp: has joined #ruby
[22:54:53] baweaver: has joined #ruby
[22:55:58] arthurix_: has joined #ruby
[22:56:09] i8igmac: has joined #ruby
[22:56:10] shevy: imperator yeah
[22:56:12] Yzguy: has joined #ruby
[22:58:06] roxtrongo: has joined #ruby
[22:58:11] tomphp: has joined #ruby
[22:58:14] rakm: has joined #ruby
[22:58:59] EminenceHC: has joined #ruby
[23:00:11] roxtrongo: has joined #ruby
[23:01:16] sdothum: has joined #ruby
[23:01:22] willardg: has joined #ruby
[23:02:45] safe: has joined #ruby
[23:03:43] ebbflowgo: has joined #ruby
[23:04:32] jdawgaz: has joined #ruby
[23:04:42] ndancer: has joined #ruby
[23:05:13] zack6849: has joined #ruby
[23:05:14] zack6849: has joined #ruby
[23:05:19] chipotle: has joined #ruby
[23:05:41] johnzorn: has joined #ruby
[23:06:40] jsrn: has joined #ruby
[23:06:54] Papierkorb: Can I somehow override the global `backtick` method?
[23:07:10] adaedra: It's Kernel#`, iirc.
[23:07:17] adaedra: &ri Kernel#`
[23:07:18] `derpy: http://www.rubydoc.info/stdlib/core/Kernel#%60-instance_method
[23:08:12] tomphp: has joined #ruby
[23:08:58] imperator: something, something, you'll shoot your eye out kid
[23:09:29] adaedra: >> module Kernel; def `(*); puts "You didn't say the magic word!"; end; end; `ls` # Broke pry, by the way.
[23:09:30] ruboto: adaedra # => You didn't say the magic word! ...check link for more (https://eval.in/467339)
[23:09:58] Papierkorb: imperator: it's for use in specs, I just want to disallow any calls to the system through the backtick
[23:10:00] adaedra: That was the "can we", not the "should we" is something else.
[23:13:06] mary5030: has joined #ruby
[23:13:15] tomphp: has joined #ruby
[23:14:55] Xeago: has joined #ruby
[23:15:26] lkba: has joined #ruby
[23:15:36] willardg: has joined #ruby
[23:16:21] malconis: has joined #ruby
[23:16:47] riotjones: has joined #ruby
[23:18:43] gregf: has joined #ruby
[23:20:39] tomphp: has joined #ruby
[23:22:47] poguez_: has joined #ruby
[23:23:50] darix: shevy: https://build.opensuse.org/package/view_file/devel:languages:ruby/ruby2.3/ruby2.3.spec?expand=1
[23:25:10] Ropeney: has joined #ruby
[23:27:40] TPBallbag: has joined #ruby
[23:27:53] tomphp: has joined #ruby
[23:28:08] rakm: has joined #ruby
[23:28:50] djbkd: has joined #ruby
[23:30:22] doddok: has joined #ruby
[23:30:36] doddok: what does error mean ? parallel.rb:184:in `value': No live threads left. Deadlock?
[23:30:56] jhass: that there are no resumable threads left and you ran into a deadlock
[23:31:11] doddok: but code worked early
[23:31:13] tomphp: has joined #ruby
[23:31:17] cyberfawkes: has joined #ruby
[23:31:21] mghaig: has joined #ruby
[23:31:33] tenderlove: has joined #ruby
[23:31:38] cyberfawkes: oi, what's the "best"(I realize this is subjective) way to learn ruby?
[23:31:52] jhass: cyberfawkes: depends on your background
[23:32:01] exadeci: has joined #ruby
[23:34:22] tomphp: has joined #ruby
[23:34:38] Ox0dea: cyberfawkes: $ echo `which ruby` >> /etc/shells && chsh -s `which ruby` $USER
[23:34:57] Ox0dea: (Don't do it.)
[23:35:15] jhass: cyberfawkes: I guess I was hoping you would elaborate on yours ;)
[23:35:34] to_json: https://en.wikipedia.org/wiki/Why%27s_(poignant)_Guide_to_Ruby
[23:35:48] to_json: where 'best' == 'funniest'
[23:35:56] to_json: that's definitely the way to go
[23:36:07] cyberfawkes: jhass: sorry, we're under a tornado warning. The only languages I've programmed in is C(very little), and Python.
[23:36:23] to_json: (it's remarkably effective as well as being funniest)
[23:36:59] jhass: cyberfawkes: if you know python well, something like the koans might even work to get familiar with the basics
[23:37:00] Ox0dea: to_json: Is it really that effective at actually teaching the language?
[23:37:23] Ox0dea: It was very good for getting me interested, I'll grant that much.
[23:37:39] patdohere: has joined #ruby
[23:37:41] Ox0dea: cyberfawkes: http://learnxinyminutes.com/docs/ruby/
[23:37:53] Ox0dea: Also https://github.com/neo/ruby_koans
[23:38:00] to_json: Ox0dea: it was my book of choice, though admittedly, using ruby a bunch and googling my failures was my real teacher
[23:38:18] Ox0dea: ?books cyberfawkes
[23:38:19] ruboto: cyberfawkes, You can find a list of recommended books at http://ruby-community.com/pages/links
[23:38:26] to_json: http://exercism.io/ is great for learning a new language in terms of one you already know
[23:38:38] to_json: just do the python track and the ruby track at the same time
[23:39:04] Ox0dea: >> :everything.is_a? Object # cyberfawkes
[23:39:10] ruboto: Ox0dea, I'm terribly sorry, I could not evaluate your code because of an error: OpenURI::HTTPError:500 Internal Server Error
[23:39:18] Ox0dea: Yay, computers.
[23:40:11] to_json: imho python -> ruby is a pretty small transition wherein most of your existing idioms and practices will continue to serve you. just don't forget to `end` your blocks
[23:40:21] Ox0dea: I'm not sure that's true.
[23:40:56] jhass: well, the base datastructures the languages evolve around are the same, which helps a bunch
[23:41:35] h99h9h88: has joined #ruby
[23:42:17] to_json: the lack of namespaces is a bit of a shock, i suppose
[23:42:30] gambl0re: has joined #ruby
[23:42:49] unknowns2k2: has joined #ruby
[23:43:02] tomphp: has joined #ruby
[23:43:25] lukaszes: has joined #ruby
[23:43:34] to_json: oh shit, Sandi's book, too.
[23:43:42] Maletor: has joined #ruby
[23:44:14] to_json: http://www.poodr.com/
[23:44:48] to_json: it's not there to teach you ruby per se
[23:45:01] to_json: but you could do worse than to learn ruby from it
[23:46:17] jhass: lack is a bit harsh, it's just that there's none per file
[23:46:53] cyberfawkes: well... that was fun... sorry guys. basically a friend and I, are building an IRC Bot. I know Python, and my friend knows Ruby. We ended up going with Ruby. We are using something called gems? Basically I need to get into ruby really fast.
[23:47:34] tomphp: has joined #ruby
[23:48:07] jhass: gems are libraries, rubygems is to ruby what pip is to python
[23:48:16] jhass: you're probably going with cinch?
[23:48:52] unreal: has joined #ruby
[23:49:27] ebbflowgo: has joined #ruby
[23:49:45] to_json: oh man, a cinch bot is itself a really fun way to learn ruby
[23:50:04] freerobby: has joined #ruby
[23:50:06] cyberfawkes: jhass: never used/heard of pip.
[23:50:14] to_json: easy_install?
[23:50:33] to_json: cinch is a gem/module/framework for building IRC bots
[23:50:36] jhass: well, not too much python either I guess :P
[23:50:52] to_json: gives you all you need to start taking IRC messages as arguments
[23:52:15] cyberfawkes: jhass: I pretty much used Python for making text based adventure games, scripts, etc. Nothing I was intending to share with anyone.
[23:52:26] cyberfawkes: to_json: I'll have to take a look at that.
[23:52:39] jhass: pip is more about using than sharing really
[23:52:55] robbyoconnor: has joined #ruby
[23:53:13] cyberfawkes: I don't know how I haven't heard about it.
[23:53:31] Arkon: has joined #ruby
[23:53:51] nertzy: has joined #ruby
[23:54:29] tomphp: has joined #ruby
[23:55:13] pwnd_nsfw: has joined #ruby
[23:55:32] cyberfawkes: what's the purpose of the period?
[23:55:48] Ox0dea: cyberfawkes: Many Ruby "operators" are actually just method calls.
[23:56:15] havenwood: >> 1.public_send(:+, 3)
[23:56:16] ruboto: havenwood # => 4 (https://eval.in/467351)
[23:56:27] TheNet: has joined #ruby
[23:56:38] Ox0dea: >> foo = 42; def foo.+ other; 42; end; foo + 9001
[23:56:38] ruboto: Ox0dea # => can't define singleton (TypeError) ...check link for more (https://eval.in/467352)
[23:56:53] havenwood: cyberfawkes: You'd in practice use a little syntactic sugar and write: 1 + 3
[23:56:55] jhass: so python maps operators to special names, like __add__, Ruby just uses the operators in the method names too
[23:56:56] flip_digits: has joined #ruby
[23:57:55] unknowns2k2: has joined #ruby
[23:58:16] blubjr: is if/else a method in ruby
[23:58:17] simplyianm: has joined #ruby
[23:58:21] tomphp: has joined #ruby
[23:58:58] karapetyan: has joined #ruby
[23:59:01] RegulationD: has joined #ruby