« Back to channel list

#ruby - 01 July 2015

« Back 1 day Forward 1 day »
[00:00:08] senayar: has joined #ruby
[00:01:32] bullcitydev: has joined #ruby
[00:03:13] vivekananda: has joined #ruby
[00:03:52] charliesome: has joined #ruby
[00:03:53] karols: has joined #ruby
[00:04:43] sevenseacat: has joined #ruby
[00:05:06] CloCkWeRX: has joined #ruby
[00:05:08] CloCkWeRX: has left #ruby: ()
[00:05:40] karols: has joined #ruby
[00:08:02] mary5030: has joined #ruby
[00:08:43] gkra_: has joined #ruby
[00:08:55] hrendalf: has joined #ruby
[00:09:32] djbkd: has joined #ruby
[00:09:48] charliesome: has joined #ruby
[00:09:53] jtdoncas: has joined #ruby
[00:10:22] JDiPierro: has joined #ruby
[00:10:31] djbkd: has joined #ruby
[00:11:23] jtdoncas: has joined #ruby
[00:12:03] Billias: has joined #ruby
[00:12:33] bonhoeffer: has joined #ruby
[00:13:07] Vile`: has joined #ruby
[00:14:18] nobitanobi: has joined #ruby
[00:14:47] Pupeno: has joined #ruby
[00:15:37] skade: has joined #ruby
[00:15:46] Muhannad: has joined #ruby
[00:20:04] SatanicSanta: has joined #ruby
[00:23:23] baweaver: has joined #ruby
[00:26:22] aryaching: has joined #ruby
[00:26:57] nobitanobi: has joined #ruby
[00:27:42] kfpratt: has joined #ruby
[00:28:21] Chef: has joined #ruby
[00:28:25] SatanicSanta: So I am currently trying to use Wikimedia's MediaWiki Ruby API to edit a page. I've spent a while trying to figure out why, but for some reason the get_token method that is called by the edit method is undefined. Here's the full console log https://gist.github.com/elifoster/e6891791a8035f081253 and all the code is here https://github.com/elifoster/SatanicBot/tree/master/src/ruby
[00:28:34] laurentide: has joined #ruby
[00:28:36] SatanicSanta: I am also asking this in #mediawiki
[00:28:49] zacstewart: has joined #ruby
[00:29:57] rgs: has joined #ruby
[00:30:53] warreng: has joined #ruby
[00:31:47] andywojo: has joined #ruby
[00:32:51] zacstewa_: has joined #ruby
[00:33:10] Chef: has joined #ruby
[00:33:50] musty: has joined #ruby
[00:33:52] humd1ng3r: has joined #ruby
[00:37:27] hahuang65: has joined #ruby
[00:38:10] Chef: has joined #ruby
[00:38:19] Indian: has joined #ruby
[00:40:40] crdpink: has joined #ruby
[00:41:12] ankhers: has joined #ruby
[00:44:15] skade: has joined #ruby
[00:44:32] lele: has joined #ruby
[00:45:25] _blizzy_: is there a way to get a list of classes a module is included in?
[00:47:44] pothibo: has joined #ruby
[00:47:55] havenwood: has joined #ruby
[00:48:14] mcclurmc: has joined #ruby
[00:48:39] Oka: has joined #ruby
[00:49:12] Maka: has joined #ruby
[00:49:24] mcclurmc: has joined #ruby
[00:50:03] Hobogrammer: has joined #ruby
[00:52:20] Akagi201: has joined #ruby
[00:53:15] Oog: has joined #ruby
[00:54:49] michael_mbp: has joined #ruby
[00:54:56] Aswebb_: has joined #ruby
[00:55:12] hotpancakes: has joined #ruby
[00:56:20] amclain: has joined #ruby
[00:56:26] baweaver: has joined #ruby
[00:56:26] Ox0dea: has joined #ruby
[00:56:33] Ox0dea: _blizzy_: Did you end up using ObjectSpace?
[00:56:44] _blizzy_: Ox0dea, yes.
[00:57:05] Ox0dea: Just making sure there wasn't some better way yet.
[00:57:09] jud: has joined #ruby
[00:57:36] yokel: has joined #ruby
[00:59:12] Ox0dea: _blizzy_: Well, do you know about Module#included/#extended?
[00:59:12] SatanicSanta: Nevermind about my last two messages, turns out it's a bug on MediaWiki's end.
[00:59:14] SatanicSanta: has left #ruby: ("swerve")
[00:59:25] _blizzy_: Ox0dea, yes.
[00:59:34] _blizzy_: that's what I'm using actually, and I have a question about that too.
[00:59:36] jaygen: has joined #ruby
[00:59:36] _blizzy_: let me gist
[01:01:09] sevenseacat: I sense this may not be a good use of ObjectSpace
[01:01:14] _blizzy_: may anyone help me figure out why I'm getting undefined method 'match' ? https://gist.github.com/NotBlizzard/76907730d1da92f2977c
[01:01:36] _blizzy_: I'm making a Plugin system, so I need to be able to get a list of classes the module is included in.
[01:01:40] zacstewart: has joined #ruby
[01:03:01] Ox0dea: sevenseacat: The ObjectSpace approach is only necessary if you need the list of classes that mix in some core module.
[01:03:19] juanpablo_: has joined #ruby
[01:03:20] meph: has joined #ruby
[01:03:31] dseitz: has joined #ruby
[01:03:39] _blizzy_: but anyway, why am I getting that 'match' is undefined?
[01:04:05] Ox0dea: _blizzy_: Explain what Line 7 is doing.
[01:04:13] NeverDie: has joined #ruby
[01:04:14] sevenseacat: because you're calling an instance method from a class.
[01:04:45] _blizzy_: Ox0dea, if the value is nil, then make it an array, else, make it its previous values
[01:04:58] Diabolik: from a programming perspective
[01:05:00] Diabolik: why are websites unable to deal with the leap second
[01:05:13] _blizzy_: Ox0dea, oh, then what is it?
[01:05:22] Ox0dea: _blizzy_: [] is always "true".
[01:05:34] _blizzy_: Ox0dea, so what should I use then?
[01:05:39] Ox0dea: Your brain.
[01:05:58] _blizzy_: that was very insightful.
[01:06:20] _blizzy_: well, thanks, sevenseacat
[01:06:22] sevenseacat: he gave you a detailed critique of exactly what that line of code wont do what you expect
[01:06:38] _blizzy_: then I asked what should I use instead then.
[01:06:51] sevenseacat: _blizzy_: think about it.
[01:07:17] _blizzy_: IDK then. :/
[01:07:50] sevenseacat: match up your description of what the line should do, and his definition of what the line actually does.
[01:08:22] _blizzy_: so I should just switch the [] and @classes around
[01:08:46] sevenseacat: see when you think, possible solutions come out!
[01:10:07] bronson: has joined #ruby
[01:10:35] freerobby: has joined #ruby
[01:10:37] lolmaus: has joined #ruby
[01:11:39] _blizzy_: hate it when my comp lags. damn windows.
[01:11:44] zacstewa_: has joined #ruby
[01:12:49] juanca_: has joined #ruby
[01:13:26] Ox0dea: baweaver: I did another one.
[01:13:51] sevenseacat: oh this will be good.
[01:13:58] Ox0dea: It's... pretty wonky.
[01:14:13] baweaver: fair warning, still at work, so definitely slower on the draw here.
[01:14:44] Ox0dea: >> $_=(@_=[*?`..?{][(_=$$/$$)..-_-_]*'')=~/$/;(@__=->_,___,__=''{__<<@_[(___+(@_=~/#{_[$.]}/))%$_];_[$.+=$_/$_]?@__[_,___,__]:__})['ganjah', 4]
[01:14:45] ruboto: Ox0dea # => "kernel" (https://eval.in/390144)
[01:14:46] charliesome: has joined #ruby
[01:14:47] slash_nick: _blizzy_: shhh, they'll ban you for using windows
[01:15:00] _blizzy_: slash_nick, lol.
[01:15:13] kfpratt: has joined #ruby
[01:15:41] sevenseacat: :o its a caesar cypher?
[01:15:45] Ox0dea: Nailed it.
[01:16:10] Ox0dea: It's a lot shorter than I'd expected it to be.
[01:16:30] ght: Question: Does anyone have a single example of calling any method from any XMLRPC-based OAuth2 provider using XMLRPC::Client?
[01:16:51] GPrime: has joined #ruby
[01:17:23] ght: We've been calling XMLRPC-based API providers for years using XMLRPC::Client.new2(), but those were all using classic APIs, not OAuth2 APIs.
[01:18:03] ght: From this provider, we can reteive the "code" on user authorization, use RestClient to retreive an access_token using the code, and use RestClient again to update the access_token, utilizing refresh_token
[01:18:05] baweaver: https://gist.github.com/baweaver/c2eeee9d8c69a21a8b98
[01:18:11] baweaver: I'll grok later when I get home
[01:18:50] ght: But with a known-good working access_token, we cannot call any XMLPRC-based method successfully. RestClient wants to pass the paramaters as a hash no matter what options we set, and XMLRPC::Client.new() or .new2() always fail with "premature end of file" on the .call() statement
[01:19:32] enebo: has joined #ruby
[01:19:40] nobitanobi: has joined #ruby
[01:19:45] bruno-: has joined #ruby
[01:20:08] mcclurmc: has joined #ruby
[01:20:30] _blizzy_: has joined #ruby
[01:21:05] Oog: has joined #ruby
[01:21:40] MEATCHICKEN: if I'm in a method call within a block, can I access the block within that method?
[01:22:03] Ox0dea: meatchicken: There are numerous ways to do so.
[01:22:30] Ox0dea: You can explicitly declare the method to take a block by prefixing the last parameter with an ampersand.
[01:22:39] Ox0dea: And then you just refer to it by name within the method.
[01:22:55] howdoicomputer: has joined #ruby
[01:23:03] Ox0dea: Alternately, `proc` and `Proc.new`, when called without providing an explicit block, will instead use the one passed into the method.
[01:23:07] slash_nick: Ox0dea: i interpreted that as more like something do; method_call; end.... inside of def method_call, can I access the "something" block?
[01:23:10] aamador: has joined #ruby
[01:23:22] MEATCHICKEN: slash_nick, that's what I meant
[01:23:26] Ox0dea: Oh, I see.
[01:23:29] MEATCHICKEN: thanks Ox0dea though
[01:23:49] slash_nick: meatchicken: why don't you pass what you need from the block to the method?
[01:23:55] MEATCHICKEN: reason being -> I want to grab the binding of the block inside the method
[01:24:03] slash_nick: if the method depends on something from the block, inject said dependency
[01:24:14] juanca_: has joined #ruby
[01:24:22] drewo: has joined #ruby
[01:24:38] Mekkis: has joined #ruby
[01:25:02] MEATCHICKEN: I'll give that a shot - I had reasons for not passing the stuff I need explicitly to the method though
[01:25:58] slash_nick: meatchicken: i guess it's a pre-existing method and you don't want to change it if you don't need to?
[01:26:14] ninja-maid-robot: has joined #ruby
[01:26:28] MEATCHICKEN: slash_nick, messing around with creating a gem, I don't want the user to have to pass in the dependency manually
[01:26:34] Brom: has joined #ruby
[01:27:25] Oog: has joined #ruby
[01:27:45] weemsledeux: has joined #ruby
[01:30:45] Muhannad: has joined #ruby
[01:30:59] _blizzy_: has joined #ruby
[01:32:14] Ox0dea: meatchicken: Um... you could use ObjectSpace?
[01:32:21] CorySimmons: has joined #ruby
[01:32:43] Ox0dea: Definitely overkill, though. It'd be better to restructure the API such that you don't need access to a block from within itself.
[01:33:27] renderful: has joined #ruby
[01:33:45] dkphenom: has joined #ruby
[01:34:36] aryaching: has joined #ruby
[01:36:02] slash_nick: meatchicken: it's kinda hard to picture what you're up to...
[01:36:12] hunt3r: has joined #ruby
[01:36:31] ruboto: it seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
[01:37:38] Ox0dea: Sorry, I didn't remember it being that condescending.
[01:38:02] Oog: has joined #ruby
[01:38:23] slash_nick: Ox0dea: happens to me all the time with "helpa" in ror
[01:38:29] sevenseacat: its truthful though.
[01:38:46] sevenseacat: how would you reword it?
[01:39:13] slash_nick: if there's a friendly version and a rude version, i happen to pick the rude one
[01:39:32] skade: has joined #ruby
[01:39:32] slash_nick: although, that wasn't too condescending at all
[01:39:51] rails480: has joined #ruby
[01:40:18] phutchins1: has joined #ruby
[01:40:22] stardiviner: has joined #ruby
[01:40:29] Rubie: has joined #ruby
[01:41:56] djbkd: has joined #ruby
[01:42:10] bonhoeffer: has joined #ruby
[01:42:55] bonhoeffer: anyone know how to use the ruby driver to delete a record with mongo
[01:43:19] bonhoeffer: i.e. Mongo::Client.new(??????)[???entries???].find.first.remove <??? doesn???t work
[01:44:14] bonhoeffer: the standard way is to operate on a Mongo::Collection::View
[01:44:28] bonhoeffer: like: result = artists.find(:name => 'Bj??rk').delete_one
[01:44:54] bonhoeffer: but i want artists.find.first.delete_one
[01:45:08] bf4: has joined #ruby
[01:46:09] juanca_: has joined #ruby
[01:48:32] dfockler: has joined #ruby
[01:50:09] slash_nick: bonhoeffer: http://docs.mongodb.org/ecosystem/tutorial/ruby-driver-tutorial/#delete-one ? http://stackoverflow.com/questions/6314139/delete-document-from-mongodb ? any of those help?
[01:51:01] bonhoeffer: yes ??? check it . . . i should have looked at the source: coll.remove(empty_doc)
[01:51:30] bonhoeffer: so you would do artists.remove(artists.find.first)
[01:51:40] bonhoeffer: doesn???t seem clean ??? but works
[01:52:04] rbennacer: has joined #ruby
[01:52:47] bonhoeffer: thanks slash_nick
[01:53:50] slash_nick: no problem...glad it helped
[01:57:02] fabrice31: has joined #ruby
[01:58:32] sharpmachine: has joined #ruby
[01:59:24] iWaffles: has joined #ruby
[02:00:45] demophoon: When saving a hash as yaml out to disk is there anything that I can do to stop the built-in yaml deserializer from converting symbols (and other ruby objects) to !ruby/sym key: value?
[02:01:38] Mekkis: has joined #ruby
[02:01:56] slash_nick: demophoon: what is "!ruby/sym key: value"?
[02:02:38] demophoon: ACTION creating a gist with repro.. one moment slash_nick
[02:03:25] slash_nick: my laptop will die in a moment, but it'll help someone else to help ya out
[02:03:51] juanpablo_: has joined #ruby
[02:05:32] Ox0dea: demophoon: What would you like it to do instead?
[02:05:34] kfpratt: has joined #ruby
[02:05:44] Ox0dea: Stringify everything?
[02:05:53] demophoon: https://gist.github.com/demophoon/0ab71e91d05fa3da225f
[02:06:00] demophoon: Ox0dea: yes, stringify works
[02:06:12] lessless: has joined #ruby
[02:06:18] Ox0dea: demophoon: Really?
[02:07:36] ght: Question: No matter what I set my content_type header to in my RestClient.post statement, it is assing the parameters as a hash. I am attempting to interact with an XMLRPC API endpoint.
[02:07:46] ght: Anyone know how to force plaintext passing of parameters in RestClient?
[02:07:54] tuelz: has joined #ruby
[02:07:58] ght: I have tried a content_type of xml, 'application/xml', text
[02:08:04] demophoon: sure? except i don't want to have to iterate through a massive object to stringify all the keys that might be symbols or other things. i didn't know if there was a flag i could pass into the yaml deserializer to stop it from doing the conversion
[02:08:10] ght: I have restclient verbose logging enabled so I can see what its passing
[02:08:35] mary5030: has joined #ruby
[02:08:52] ght: It's passing them like this: params[limit]=1000&params[page]=0
[02:08:54] tuelz: I have an array of string and I want to match a regex against those strings and return true if any matches, whats the cleanest way I can do that
[02:09:35] Mekkis: has joined #ruby
[02:09:39] Ox0dea: >> %w[foo bar baz].any? { |word| word[/ba/] }
[02:09:40] ruboto: Ox0dea # => true (https://eval.in/390145)
[02:09:46] tuelz: or a clean way, don't care if it's the cleanest, just figured ruby had a magic method for this
[02:09:57] tuelz: Ox0dea: thanks!
[02:10:40] Ox0dea: tuelz: You'll be able to write `array.any?(/regex/)` if https://bugs.ruby-lang.org/issues/11286 gets accepted.
[02:10:47] havenwood: Ox0dea: \o/
[02:10:48] Ox0dea: I don't think it will, though. :/
[02:10:54] havenwood: Ox0dea: no?
[02:12:24] Ox0dea: I think it's really nice.
[02:12:43] Ox0dea: The sequence predicates are already awesome, but being able to combine them with case equality is just <3.
[02:12:50] Ox0dea: nobu doesn't seem to agree. :/
[02:13:16] axisys: how do I get a list of all unix env variables that ruby know? like ENV['USER']
[02:13:27] tuelz: is it possible to interpolate inside %w[]?
[02:13:34] Ox0dea: tuelz: You need %W.
[02:13:40] tuelz: ahh, of course, thanks
[02:13:53] Ox0dea: axisys: >> ENV.keys
[02:13:57] Mekkis: has joined #ruby
[02:14:03] sevenseacat: Ox0dea: seems people like the idea of your patch
[02:14:13] axisys: Ox0dea: sweet! thanks
[02:14:20] kfpratt: has joined #ruby
[02:14:45] emptyflask: has joined #ruby
[02:16:01] bonhoeffer: has joined #ruby
[02:16:32] Ox0dea: sevenseacat: It has its proponents, to be sure, but matz has ignored his being assigned to it. Hopefully nobu is just waiting for matz to chime in on it.
[02:16:54] gambl0re: has joined #ruby
[02:18:05] ivanskie: has joined #ruby
[02:18:53] Ox0dea: demophoon: Serialization is about being able to faithfully restore the thing later. Why have special keys if you'll only be able to get them as a string at the other end?
[02:19:05] yayfoxes3: has joined #ruby
[02:19:34] sarkyniin: has joined #ruby
[02:20:05] axisys: which ruby ENV key holds the username of `who am i`? it does not change with sudo su -
[02:20:10] yayfoxes3: http://vpaste.net/bnI4l
[02:21:48] eam: axisys: which kind of unix are you on?
[02:21:52] demophoon: Ox0dea: Because i'm reading and saving configuration files using ruby just to modify the content for another application that doesn't know how to read !ruby/sym in the saved file
[02:21:59] axisys: eam: linux
[02:22:03] eam: it should change, then
[02:22:31] Ox0dea: axisys: ENV['SUDO_USER'] looks to be the one you want.
[02:22:42] axisys: may be sudoers file prevents the change with
[02:22:44] axisys: Defaults env_reset
[02:22:47] zacstewart: has joined #ruby
[02:23:03] eam: axisys: yes
[02:23:15] axisys: Ox0dea: I wanted to run it as a user or through sudo..
[02:23:27] Mekkis: has joined #ruby
[02:23:30] axisys: Ox0dea: when run as user SUDO_USER will be missing..
[02:23:40] Ox0dea: axisys: At which point you can fallback to USER?
[02:23:49] eam: Ox0dea: SUDO_USER isn't read by whoami
[02:23:51] joshbamboo1: has joined #ruby
[02:23:54] eam: and USER is reset by su -
[02:24:02] eam: you have something funny going on, I think
[02:24:24] axisys: ENV['SUDO_USER'].nil? ENV['USER'] <-- like this?
[02:24:27] axisys: Ox0dea: ^
[02:24:27] eam: whoami should check the uid, not the environment
[02:24:30] devoldmx: has joined #ruby
[02:24:39] aryaching_: has joined #ruby
[02:24:41] axisys: eam: whoami is not same as who am i
[02:24:48] axisys: eam: mind the space
[02:24:53] eam: oh haha, you're running who
[02:25:18] axisys: eam: thats true..
[02:25:23] eam: axisys: who checks your terminal
[02:25:30] eam: has nothing to do with either env, nor uid
[02:25:32] axisys: eam: right
[02:25:39] ebbflowgo: has joined #ruby
[02:25:39] eam: your terminal doesn't change when you sudo / su
[02:25:50] eam: your stdout is still connected to a terminal owned by you
[02:25:57] axisys: eam: i guess i can use Ox0dea's logic or call the `who` command from ruby script?
[02:26:10] eam: axisys: let's back up, what problem do you want to solve?
[02:26:30] axisys: i want to keep the user username
[02:26:41] hotpancakes: has joined #ruby
[02:26:47] axisys: so it prompts for his password when trying to run rvc from a script
[02:26:48] Ox0dea: demophoon: So symbols are the only kind of "special" object that can end up in your hash, no?
[02:27:01] eam: axisys: you mean via sudo?
[02:27:23] demophoon: Ox0dea: that i currently know of. i'll eventually be reading in other user configration files with it
[02:27:24] eam: "prompts for his password" via what mechanism?
[02:27:27] axisys: eam: the script does run as either.. since it connects to remote host
[02:27:43] axisys: rvc $username@$vcenter
[02:28:27] axisys: so in this case rvc #{username}@#{vcenter}
[02:28:29] stoodfarback: Is the `libv8` gem supposed to take >10 minutes to install?
[02:28:34] Ox0dea: demophoon: How are you reading in the configuration file?
[02:28:40] axisys: converting from bash to ruby script..
[02:28:46] Deele: has joined #ruby
[02:28:46] Pupeno: has joined #ruby
[02:28:46] Pupeno: has joined #ruby
[02:29:27] eam: axisys: you want to approximate the behavior of `who` from ruby, as in knowing the owner of the controlling terminal and not the actual current uid?
[02:29:40] axisys: eam: right
[02:30:12] stoodfarback: "Done installing documentation for libv8 after 0 seconds" ... as if.
[02:30:15] Ox0dea: demophoon: It seems a very simple solution to your problem would be to just use string keys in the first place.
[02:30:53] stoodfarback: Ah, that was for docs.
[02:30:55] eam: >> File.for_fd(0).stat.uid
[02:30:56] ruboto: eam # => 1000 (https://eval.in/390152)
[02:30:57] Mekkis: has joined #ruby
[02:30:59] tkuchiki_: has joined #ruby
[02:31:06] eam: axisys: ^^ that's what `who` does
[02:31:11] demophoon: Ox0dea: i'm just using YAML.load_file
[02:31:13] isxek: has joined #ruby
[02:31:24] axisys: eam: ok.. let me check it out
[02:31:25] digifiv5e: has joined #ruby
[02:31:26] eam: you can turn the uid into a username with getpwuid() from etc
[02:31:54] Ox0dea: demophoon: That returns a hash with string keys unless you're using the special :symbol: syntax in the YAML file.
[02:32:08] Ox0dea: The problem, then, is that you're using symbol keys when updating that hash; just don't do that?
[02:32:08] eam: some more clever implementations will try that operation on fd 0, 1 and 2 (stdin, out and err)
[02:32:50] demophoon: Ox0dea: oh, i guess the configuration file i'm loading in is using the :symbol: syntax :\
[02:32:50] axisys: system("who am i") works
[02:33:10] eam: sure, or you could just put the whole script into there :)
[02:33:12] axisys: eam: I do not want to rely on etc module
[02:33:21] eam: etc is core
[02:33:28] eam: you don't need to install a gem
[02:33:29] axisys: eam: it is?
[02:34:06] tubuliferous_: has joined #ruby
[02:35:56] Mekkis: has joined #ruby
[02:36:13] Ox0dea: demophoon: Serialize to JSON, parse the result back into a hash, then seriaize that to YAML?
[02:36:22] demophoon: Ox0dea: anyhow, thanks for the help. I'm going to keep digging.
[02:36:31] demophoon: Ox0dea: ah, i could try that
[02:36:41] Guest59643: has joined #ruby
[02:36:41] Ox0dea: It'll work. JSON doesn't support anything fancy.
[02:37:26] dgutierrez1287: has joined #ruby
[02:37:56] Ox0dea: It's a little heavy-handed, but not so terrible if you've got deep nesting.
[02:39:02] demophoon: Ox0dea: yeah, thats what i'm worried about by doing it any other way. I've got an unknown number of levels that this config file can be. Thanks again :)
[02:39:16] Ox0dea: Happy to help.
[02:39:43] gaboesquivel: has joined #ruby
[02:40:07] Ox0dea: It's easy enough to deep-convert a hash's keys to strings, but you might as well take advantage of the fact that JSON provides the semantics for doing so.
[02:40:58] axisys: eam: final version http://dpaste.com/0321YCJ.txt . thanks a lot!
[02:41:46] Mekkis: has joined #ruby
[02:41:47] eam: for_fd is such a weirdly named constructor
[02:42:24] axisys: eam: kind a cryptic, specially for a newbie (me)
[02:42:37] Ox0dea: eam: I can't think of a more reasonable alternative.
[02:42:47] eam: Ox0dea: how about from_fileno
[02:42:58] eam: how about put it into new?
[02:43:15] eam: anything that indicates it takes an integer descriptor and constructs an IO
[02:43:31] Ox0dea: #for_fd does that for me, but all right.
[02:43:48] Aswebb_: has joined #ruby
[02:43:51] Ox0dea: s/#/./, of course.
[02:45:05] Ox0dea: You're right that it's not perfectly obvious, but it's sensible enough given that "file descriptor" is pretty standard nomenclature.
[02:46:06] Spami: has joined #ruby
[02:47:07] eam: hm actually, is it an alias to new() ?
[02:47:21] eam: it looks like it is, I retract my complaint
[02:47:41] Spami: has joined #ruby
[02:48:47] eam: oooh, right, and all the useful subclasses don't have that calling convention, I maintain my beef :)
[02:49:01] jpfuentes2: has joined #ruby
[02:49:03] emptyflask: has joined #ruby
[02:49:09] RobertBirnie: has joined #ruby
[02:49:13] eam: Ox0dea: it's the for vs from that gets me
[02:49:26] nyanz: has joined #ruby
[02:49:57] eam: and especially with sockets the apis are kinda clumsy, lots of converting descriptors into new class containers
[02:50:39] nyanz: has left #ruby: ()
[02:51:07] Ox0dea: Well, "from" sounds like it would "generate" a File, so to speak, whereas it's the case that it already exists and just needs to be looked up.
[02:51:44] charliesome: has joined #ruby
[02:52:04] bf4: has joined #ruby
[02:52:05] Ox0dea: "Create a file from" vs "find the file for".
[02:52:05] eam: I mean, it does generate a file object. It's just not clear to me that the method is a constructor is all
[02:54:15] Oog: has joined #ruby
[02:55:35] bking39116: has joined #ruby
[02:57:25] kfpratt: has joined #ruby
[02:59:13] sharpmachine: has joined #ruby
[03:00:21] scx_: has joined #ruby
[03:01:17] crdpink2: has joined #ruby
[03:06:01] noethics: has joined #ruby
[03:07:00] noethics: has joined #ruby
[03:07:57] zacstewart: has joined #ruby
[03:09:20] bruno-: has joined #ruby
[03:12:12] RobertBirnie: has joined #ruby
[03:12:24] mcclurmc: has joined #ruby
[03:12:55] Channel6: has joined #ruby
[03:12:57] braincrash: has joined #ruby
[03:12:58] charliesome: has joined #ruby
[03:14:38] sarkyniin: has joined #ruby
[03:15:47] ivanskie: has joined #ruby
[03:15:53] skade: has joined #ruby
[03:21:07] devoldmx: has joined #ruby
[03:21:48] juanca_: has joined #ruby
[03:22:45] iamninja: has joined #ruby
[03:24:51] arup_r: has joined #ruby
[03:24:51] havenwood: has joined #ruby
[03:25:33] Frem: has joined #ruby
[03:26:30] zacstewa_: has joined #ruby
[03:27:25] wallerdev: has joined #ruby
[03:28:35] darkf: has joined #ruby
[03:29:42] davedev24_: has joined #ruby
[03:30:32] gix: has joined #ruby
[03:33:51] dented42: has joined #ruby
[03:34:03] mcclurmc: has joined #ruby
[03:34:51] musty: has joined #ruby
[03:36:30] josh1: has joined #ruby
[03:41:10] arescorpio: has joined #ruby
[03:45:49] fabrice31: has joined #ruby
[03:47:50] zacstewart: has joined #ruby
[03:49:22] shadoi: has joined #ruby
[03:49:46] Marisa: has joined #ruby
[03:49:48] baweaver: has joined #ruby
[03:51:40] devoldmx: has joined #ruby
[03:52:24] gusrub: has joined #ruby
[03:52:32] juanpablo_: has joined #ruby
[03:54:03] felixrsmith: has joined #ruby
[03:54:52] hotpancakes: has joined #ruby
[03:55:37] mcclurmc: has joined #ruby
[03:56:10] jenrzzz: has joined #ruby
[03:56:33] djbkd: has joined #ruby
[03:58:40] nobitanobi: has joined #ruby
[03:59:49] yeticry: has joined #ruby
[04:00:41] Marisa: has joined #ruby
[04:00:42] sharpmachine: has joined #ruby
[04:02:38] jeanlinux: has joined #ruby
[04:05:19] yeticry: has joined #ruby
[04:05:47] sphex: has joined #ruby
[04:06:18] hotpancakes: has joined #ruby
[04:07:14] zacstewart: has joined #ruby
[04:09:38] perrier: has joined #ruby
[04:17:43] Pupeno: has joined #ruby
[04:20:04] houhoulis: has joined #ruby
[04:20:53] jlast: has joined #ruby
[04:22:00] bronson: has joined #ruby
[04:22:09] aryaching: has joined #ruby
[04:23:43] EasyCo: has joined #ruby
[04:24:36] kies: has joined #ruby
[04:26:00] j4cknewt: has joined #ruby
[04:26:04] isxek: has joined #ruby
[04:27:51] aapole: has joined #ruby
[04:29:13] RobertBirnie: has joined #ruby
[04:29:36] rickmasta: has joined #ruby
[04:31:17] ivanskie: has joined #ruby
[04:31:34] RobertBi_: has joined #ruby
[04:31:57] Carnage\: has joined #ruby
[04:32:37] baweaver: sevenseacat: I win
[04:32:38] baweaver: https://gist.github.com/baweaver/c2eeee9d8c69a21a8b98
[04:32:52] baweaver: too bad Ox0dea isn't online...
[04:32:53] Aswebb_: has joined #ruby
[04:33:14] ruboto: baweaver # => /tmp/execpad-8a29cf644539/source-8a29cf644539:2: syntax error, unexpected .., expecting :: or '[' or ...check link for more (https://eval.in/390173)
[04:33:29] baweaver: >> [*?`..?{]
[04:33:31] ruboto: baweaver # => ["`", "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", ...check link for more (https://eval.in/390174)
[04:33:33] pgatt: has joined #ruby
[04:33:39] baweaver: >> [*?`..?{][1..-2]
[04:33:40] ruboto: baweaver # => ["a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", ...check link for more (https://eval.in/390175)
[04:33:45] baweaver: how the heck did he find htat?
[04:33:47] bb010g: has joined #ruby
[04:34:13] psyprus: has joined #ruby
[04:34:50] michael_mbp: has joined #ruby
[04:34:51] baweaver: Apparently you can
[04:34:57] ruboto: baweaver # => "a" (https://eval.in/390176)
[04:35:04] baweaver: for single characters only
[04:35:26] konsolebox: has joined #ruby
[04:36:34] baweaver: it's horrifying and mystifying at the same time
[04:36:39] baweaver: kinda like any perl code
[04:37:01] RobertBirnie: has joined #ruby
[04:37:22] sevenseacat: I agree with Aeyrix's statement about it though. He needs to go outside.
[04:37:42] baweaver: ACTION shrugs
[04:37:49] Aeyrix: we love Ox but we worry.
[04:38:07] baweaver: shevy: you have another animal nick now
[04:38:22] sevenseacat: oh ffs I always forget its an O
[04:41:00] Pupeno: has joined #ruby
[04:41:03] wmoxam: ugh, ruby line noise
[04:41:30] wmoxam: that gist
[04:41:47] zacstewart: has joined #ruby
[04:41:52] lessless: has joined #ruby
[04:42:08] wmoxam: I hate Ruby's perlisms
[04:42:13] Aeyrix: >> $_=(@_=[*?`..?{][(_=$$/$$)..-_-_]*'')=~/$/;(@__=->_,___,__=''{__<<@_[(___+(@_=~/#{_[$.]}/))%$_];_[$.+=$_/$_]?@__[_,___,__]:__})['you what mate', 4]
[04:42:14] ruboto: Aeyrix # => nil can't be coerced into Fixnum (TypeError) ...check link for more (https://eval.in/390177)
[04:42:34] thegreatneokefka: has joined #ruby
[04:43:07] eggoez: has joined #ruby
[04:43:37] Oog: has joined #ruby
[04:47:57] baweaver: can only handle alpha a-z
[04:48:26] devoldmx: has joined #ruby
[04:49:18] nobitanobi: has joined #ruby
[04:50:15] devoldmx_: has joined #ruby
[04:50:48] workmad3: has joined #ruby
[04:51:42] Oog: has joined #ruby
[04:52:36] s2013: has joined #ruby
[04:52:47] MrJiks: has joined #ruby
[04:53:04] hotpancakes: has joined #ruby
[04:53:35] devoldmx: has joined #ruby
[04:55:22] Dreamer3: has joined #ruby
[04:56:11] devoldmx: has joined #ruby
[04:56:20] mcclurmc: has joined #ruby
[04:56:33] astrobunny: has joined #ruby
[04:57:19] SHyx0rmZ: has joined #ruby
[04:57:46] devoldmx: has joined #ruby
[04:57:46] chipotle: has joined #ruby
[04:58:34] mr_rich101: has joined #ruby
[04:58:45] keen___________8: has joined #ruby
[04:59:48] devoldmx: has joined #ruby
[05:00:17] Ox0dea: has joined #ruby
[05:00:21] balazs_: has joined #ruby
[05:00:21] Ox0dea: >> $_=(@_=[*?`..?{][(_=$$/$$)..-_-_]*'')=~/$/;(@__=->_,___,__=''{__<<(@_[_[$.]]?@_[(___+(@_=~/#{_[$.]}/))%$_]:_[$.]);_[$.+=$_/$_]?@__[_,___,__]:__})['payz lux eua, gkexod.', 20]
[05:00:22] ruboto: Ox0dea # => "just for you, aeyrix." (https://eval.in/390179)
[05:00:38] kfpratt: has joined #ruby
[05:00:40] Aeyrix: Now THIS is podracing
[05:01:24] devoldmx: has joined #ruby
[05:01:27] sharpmachine: has joined #ruby
[05:02:07] Ox0dea: baweaver: Do you know why I had to extract the 26 out as a variable?
[05:02:11] baweaver: so just a ternary in there to leave spaces and other characters alone
[05:02:42] Ox0dea: Right, but why not in-place?
[05:02:59] devoldmx: has joined #ruby
[05:03:06] Ox0dea: Me neither. :)
[05:03:09] baweaver: optimized perlisms?
[05:03:12] baweaver_: has joined #ruby
[05:03:31] baweaver: hm, have I now...
[05:03:44] baweaver: laptop must have connected in my bag
[05:03:55] Aeyrix: someone's impersonating baweaver
[05:04:10] baweaver: Same network area
[05:04:16] baweaver: aaand it didn't go to sleep
[05:04:18] Aeyrix: they've hijacked your wifi
[05:04:25] Ox0dea: I take offense at these being considered Perlisms. Non-alphanumeric Perl mostly just takes advantage of the fact that you can eval the results of a gsub.
[05:04:28] baweaver: good luck with that one
[05:04:32] auzty: has joined #ruby
[05:04:34] roolo: has joined #ruby
[05:04:53] devoldmx_: has joined #ruby
[05:05:06] baweaver: short of hardware / firmware hacks, people aren't getting in the front door of that one
[05:05:16] Aeyrix: I get actual internet soon :D
[05:06:18] baweaver: shoot, well that destroyed a nail....
[05:06:50] devoldmx: has joined #ruby
[05:06:54] baweaver: wasn't paying attention and jammed my hand against something
[05:07:03] Ox0dea: Just paint over it?
[05:07:05] baweaver: makes guitar annoying to play for a few weeks
[05:07:13] nobitanobi: has joined #ruby
[05:07:16] Aeyrix: I haven't played mine for a while.
[05:07:31] baweaver: classical here, mostly fingerstyle
[05:07:40] Ox0dea: There will be blood.
[05:07:48] Aeyrix: Electric here, mostly funk.
[05:08:35] devoldmx: has joined #ruby
[05:09:00] baweaver: https://www.youtube.com/watch?v=PNAeXnVRXew - freaking old, but serves a point at least.
[05:09:16] baweaver: mistakes all over the place though
[05:10:01] Ox0dea: Color me serenaded.
[05:10:16] devoldmx: has joined #ruby
[05:12:16] devoldmx: has joined #ruby
[05:14:05] devoldmx_: has joined #ruby
[05:14:18] j4cknewt: has joined #ruby
[05:15:53] devoldmx: has joined #ruby
[05:16:04] Rollabunna: has joined #ruby
[05:17:11] shevy: baweaver huh
[05:17:19] Aeyrix: shevy: Ox
[05:17:37] devoldmx_: has joined #ruby
[05:17:42] shevy: I was reading that as "0x"
[05:18:08] The_Phoenix: has joined #ruby
[05:18:21] wmoxam: baweaver: what's the blue stuff?
[05:18:32] baweaver: I think mouthwash
[05:18:40] baweaver: don't remember why I had it in there.
[05:18:51] wmoxam: baweaver: to get drunk obvs
[05:19:12] baweaver: that's what the wine under the table was for
[05:19:52] devoldmx: has joined #ruby
[05:19:52] wmoxam: getting drunk on mouthwash must suck
[05:20:06] baweaver: also 3 years ago back in a college room
[05:20:17] wmoxam: but at least you'd have minty fresh breath
[05:21:20] dhjondoh: has joined #ruby
[05:21:27] devoldmx: has joined #ruby
[05:22:33] chrissonar: has joined #ruby
[05:22:43] revath: has joined #ruby
[05:22:52] dhjondoh: has joined #ruby
[05:23:13] devoldmx: has joined #ruby
[05:24:06] revath: has left #ruby: ()
[05:24:50] devoldmx: has joined #ruby
[05:26:02] Ox0dea: On a vaguely related note, "debriding agent" is not another term for marriage counselor.
[05:26:59] devoldmx: has joined #ruby
[05:27:23] sphex: does the precedence given for { } blocks look wrong here? http://ruby-doc.org/core-2.2.2/doc/syntax/precedence_rdoc.html
[05:28:29] devoldmx: has joined #ruby
[05:28:34] chipotle: has joined #ruby
[05:28:42] sevenseacat: nah thats right
[05:29:56] zacstewart: has joined #ruby
[05:30:06] sphex: aren't { } blocks high precedence?
[05:30:17] devoldmx: has joined #ruby
[05:31:24] baweaver: Aeyrix: One of my friends is straight out of the 80s, down to the hair and the rocking
[05:31:27] baweaver: https://www.youtube.com/watch?v=Xxcq2Xgj5T8
[05:31:36] Aeyrix: baweaver: That's you, isn't iT?
[05:31:48] baweaver: can't get my hair out that long
[05:31:58] baweaver: cheeky bugger too that one.
[05:31:59] Aeyrix: Mine's super long atm and desparately needs a cut.
[05:32:01] sphex: well then. I don't get it. :/ oh well.
[05:32:06] devoldmx: has joined #ruby
[05:32:08] Aeyrix: I look like I have a lion's mane.
[05:32:12] Aeyrix: sphex: What don't you get about iT?
[05:32:16] Aeyrix: Why do I keep making that mistake?
[05:32:30] drefined: has joined #ruby
[05:32:42] j4cknewt: has joined #ruby
[05:34:02] devoldmx_: has joined #ruby
[05:34:21] Ox0dea: Aeyrix: That was about 140WPM.
[05:34:37] Ox0dea: We should race. :)
[05:34:38] fabrice31: has joined #ruby
[05:34:43] Aeyrix: Ox0dea: I'm on a nonstandard keyboard atm.
[05:34:49] Aeyrix: So I'll be slower and less accurate than usual.
[05:35:30] renderful: has joined #ruby
[05:35:41] tagrudev: has joined #ruby
[05:35:45] devoldmx: has joined #ruby
[05:35:49] Ox0dea: Aeyrix: Do you normally use an Advantage?
[05:35:59] Aeyrix: I normally use a Macbook keyboard.
[05:36:01] chipotle_: has joined #ruby
[05:36:02] hotpancakes: has joined #ruby
[05:37:02] lxsameer: has joined #ruby
[05:37:02] lxsameer: has joined #ruby
[05:37:10] Alina-malina: has joined #ruby
[05:37:36] devoldmx_: has joined #ruby
[05:39:08] rickmasta: has joined #ruby
[05:39:24] devoldmx: has joined #ruby
[05:39:45] shevy: baweaver ooooh rock groups!
[05:39:56] shevy: Boston - more than a feeling! \o/ \o~
[05:40:06] gauke: has joined #ruby
[05:40:51] gix: has joined #ruby
[05:41:18] juanpablo_: has joined #ruby
[05:41:19] devoldmx: has joined #ruby
[05:41:23] jhooker: has joined #ruby
[05:42:58] bluOxigen: has joined #ruby
[05:43:04] devoldmx_: has joined #ruby
[05:44:14] Oog: has joined #ruby
[05:44:55] devoldmx: has joined #ruby
[05:45:02] sphex: def test; 2; end; 1 + test { };
[05:45:23] sphex: don't the brackets have higher precedence than the "+"?
[05:46:09] sphex: since they associate with "test", not the result of the "+" operator...
[05:47:13] flughafen: hey everybody
[05:47:22] kfpratt: has joined #ruby
[05:47:32] flughafen: ACTION is back from scotland
[05:47:50] rht: has joined #ruby
[05:48:05] zacstewart: has joined #ruby
[05:48:12] devoldmx: has joined #ruby
[05:48:34] Aeyrix: How was Scotland?
[05:48:48] flughafen: fun, but short
[05:48:59] fsvehla: has joined #ruby
[05:49:09] Aeyrix: Where'd you go? North or South?
[05:49:20] shevy: sphex yeah. Do you see a problem in the above code?
[05:49:55] shevy: flughafen wow so you DO still fly!
[05:50:19] shevy: Aeyrix are you happy that the scots remained in the british empire?
[05:50:20] devoldmx: has joined #ruby
[05:50:28] Aeyrix: shevy: It's for their own good.
[05:50:43] flughafen: shevy: not through BER
[05:50:52] Aeyrix: Scotland has no bargaining power with the European Union. If they left GB, they'd be out in the cold and that's a real problem.
[05:51:05] Aeyrix: There's a waiting list around the world for countries wanting to become a part of the EU.
[05:51:18] Aeyrix: Scotland would have to just wait in line if they left.
[05:51:28] sevenseacat: around the world? not just in europe? >_>
[05:51:33] sphex: shevy: no, it's just that I *think* the documentation is wrong, but I'm not sure... now that I think about it, maybe they just mean that the "grouping" of brackets is more important during parsing than operator precedences altogether.
[05:51:51] shevy: Australia will be assimilated one day as well! We are the BORG, resistance is futile.
[05:51:59] shevy: hmm might be the wrong idiom
[05:52:07] jeanlinux: has joined #ruby
[05:52:11] Aeyrix: Some Australians want it to become a republic, which I think is a dreadful idea.
[05:52:17] devoldmx: has joined #ruby
[05:52:41] Aeyrix: Cutting ties like that nowadays just doesn't work at all.
[05:52:46] shevy: sphex if it helps, I always think of blocks to methods just as an extra argument; in the code above, no code would be put into the {} and there is no yield-handling, so it's an empty arg-passing that just gets discarded; 2 is return always
[05:52:52] sevenseacat: I don't know what we would achieve by that
[05:52:53] Aeyrix: Unless you're, say, Saudi Arabia or something, with massive export power.
[05:52:58] Aeyrix: sevenseacat: "independence"
[05:53:06] shevy: sevenseacat you'd get a new head of the state!
[05:53:27] NightMonkey: has joined #ruby
[05:53:59] shevy: Aeyrix I don't know anything about Australia except that it is (1) hot (2) has weird alien animals like that kangaroo thingy or ... what are those animals called that eat eucalyptus... hmm
[05:54:09] Aeyrix: Australia's chief export is racism.
[05:54:09] devoldmx: has joined #ruby
[05:54:09] shevy: and they were founded by pirates!
[05:54:27] sevenseacat: yeah but in practical terms, that means nothing
[05:54:40] Aeyrix: sevenseacat: Independence, or being founded by pirates?
[05:54:40] Melite: has joined #ruby
[05:54:48] sevenseacat: founded by convicts, not pirates
[05:54:52] sevenseacat: get it right, geez
[05:54:54] Aeyrix: Nah it was pirates.
[05:54:58] Aeyrix: Illegal people on a boat - pirates.
[05:55:04] shevy: you are a pirate cat
[05:55:22] funfunctor: has joined #ruby
[05:55:44] Aeyrix: shevy: Kangaroo is pretty tasty.
[05:55:47] Aeyrix: I'd put it above beef.
[05:55:52] revath: has joined #ruby
[05:55:55] devoldmx_: has joined #ruby
[05:56:00] funfunctor: I already know how to program, I am looking for something that is as dense as possible to learn ruby quickly..
[05:56:21] sphex: funfunctor: http://ruby-doc.org/core-2.2.2/
[05:56:22] Aeyrix: > something as dense as possible
[05:56:25] Aeyrix: shevy, you're up!
[05:56:56] Aeyrix: funfunctor: What, like a set of guides or what?
[05:57:00] funfunctor: sphex: less words/api more BNF notation something fast..
[05:57:04] sevenseacat: and you tell us off for calling people out :P
[05:57:15] Aeyrix: sevenseacat: He knows I'm not serious though. :<
[05:57:36] devoldmx_: has joined #ruby
[05:57:38] sphex: funfunctor: yeah yeah.. look at the doc/syntax/ ones
[05:58:05] funfunctor: I don't really want to sit though something yattering on about what a class is or what ruby api classes are provided in base
[05:58:23] Aeyrix: Find a tutorial series and skip to tutorial 7 or something.
[05:58:28] funfunctor: ah thanks here? http://ruby-doc.org/core-2.2.2/doc/syntax_rdoc.html
[05:58:38] funfunctor: and what about the type semantics?
[05:58:41] Radar: funfunctor: https://www.ruby-lang.org/en/documentation/quickstart/
[05:58:45] Radar: http://tutorials.jumpstartlab.com/projects/ruby_in_100_minutes.html
[05:59:05] sevenseacat: funfunctor: 'i want to just know ruby without learning it'?
[05:59:34] baweaver: http://learnxinyminutes.com/docs/ruby/
[05:59:37] devoldmx: has joined #ruby
[05:59:43] Xeago: has joined #ruby
[05:59:56] shevy: funfunctor type semantics? the 3 main data structures are usually String, Hash, Array.
[06:00:11] sphex: funfunctor: classes have methods. you call them. use ri(1) to check what method does what. you know ruby now, you can go.
[06:00:24] funfunctor: yep thanks for the resources guys
[06:00:50] funfunctor: I mean, the standards for types, i.e. should I expect Int to be 32bit if and when on what etc..
[06:00:52] RegulationD: has joined #ruby
[06:00:58] NightMonkey: has joined #ruby
[06:01:02] shevy: that's quite lowlevel
[06:01:06] sevenseacat: i really have problems with that kind of philosophy
[06:01:07] revath: has left #ruby: ()
[06:01:07] funfunctor: For example, in Haskell we have Int and Integer
[06:01:09] Aeyrix: and is also in the docs
[06:01:11] devoldmx: has joined #ruby
[06:01:16] Aeyrix: > in Haskell
[06:01:17] shevy: funfunctor you have Integer
[06:01:21] shevy: and Fixnum
[06:01:22] shevy: >> 5.class
[06:01:23] ruboto: shevy # => Fixnum (https://eval.in/390194)
[06:01:33] sphex: funfunctor: try it out in irb(1)
[06:01:46] shevy: 32bit, I have no idea, has anyone in ruby code needed to know that?
[06:01:49] funfunctor: Integer is arbitrary while Int is machine sized in the case of Haskell.
[06:02:03] shevy: well the whole of Ruby is arbitrary :-)
[06:02:12] LiquidInsect: has joined #ruby
[06:02:19] sphex: funfunctor: all arithmetic appears to be arbitrary precision, you don't have to worry about it. the results are "coerced" as needed.
[06:02:26] sevenseacat: yeah we dont care about that kind of stuff
[06:02:27] funfunctor: Do signed int's wrap when they overflow in ruby or is that never get to runtime?
[06:02:32] sharpmachine: has joined #ruby
[06:02:48] funfunctor: sphex: ok so its all dynamically typed then?
[06:03:01] shevy: nah, overflow... I guess the worst that can happen is when you like allocate or use a million string objects for a hash as a key
[06:03:15] devoldmx: has joined #ruby
[06:03:15] funfunctor: any idea what type inference formalism that is based on?
[06:03:21] sphex: yeah. hurry up, you're wasting time with this integer stuff. you're not learning fast enough.
[06:03:46] shevy: funfunctor is there any? if you try to add incompatible objects via + then an error happens
[06:03:49] shevy: >> 1 + '2'
[06:03:50] ruboto: shevy # => String can't be coerced into Fixnum (TypeError) ...check link for more (https://eval.in/390195)
[06:03:52] sevenseacat: this is all answered in the docs, you know
[06:03:55] funfunctor: I already skimmed though the stuff.. nothing special, I know python, ada, haskell, c, c++, etc..
[06:04:07] shevy: good! ruby is very similar to python
[06:04:12] Maletor: has joined #ruby
[06:04:13] SOLDIERz: has joined #ruby
[06:04:32] shevy: I just tried 1 + '2' in python
[06:04:35] shevy: TypeError: unsupported operand type(s) for +: 'int' and 'str'
[06:04:41] Aeyrix: won't work
[06:04:49] funfunctor: shevy: yes objects enumerated from different classes have different types, I should hope that is compile time :)
[06:04:50] devoldmx: has joined #ruby
[06:05:00] shevy: both actually give a TypeError, they even agree on the name :)
[06:05:08] sevenseacat: 'compile time'?
[06:05:13] funfunctor: ok, so (+) is typically overloaded then
[06:05:29] funfunctor: sevenseacat: "before evaluation"
[06:05:37] Ox0dea: ~ $ python2 -c "print('1' < 2)"
[06:05:38] shevy: nah, you just have objects that will be compatible
[06:05:40] sphex: funfunctor: it reminds me of Scheme and Lisp's numerical towers. the arithmatic operators will yield a value of type needed to represent it. numeric values are immutable, so you always get a new one with a possibly different type when doing arithmetic.
[06:05:40] funfunctor: actually, is ruby lazy or strict evaluation?
[06:05:43] sevenseacat: you're not learning ruby here
[06:05:43] shevy: >> 1 + '1'.to_i
[06:05:45] ruboto: shevy # => 2 (https://eval.in/390196)
[06:05:54] sevenseacat: there is no overloading
[06:06:01] shevy: ruby is so lazy, it'll make you lazier
[06:06:06] funfunctor: sphex: thanks that is helpful !
[06:06:51] funfunctor: can you control strictness, for example in Haskell as a example again, data Foo = Foo { a :: Int, b :: !Int }
[06:06:52] devoldmx: has joined #ruby
[06:06:58] zacstewart: has joined #ruby
[06:06:59] kfpratt: has joined #ruby
[06:07:05] funfunctor: gives us b being strict while a is lazy
[06:07:39] Ox0dea: It kinda seems like you're here to subtly gloat (?) about having read the first few chapters of a Haskell book.
[06:07:40] funfunctor: and so Foo (4+3) (1+2) will give you the type Foo (4+3) 3
[06:07:53] sandstrom: has joined #ruby
[06:08:04] sevenseacat: funfunctor: I suggest getting a basic ruby tutorial, because your questions dont make much sense.
[06:08:16] funfunctor: Ox0dea: no, I can pick another language if you like
[06:08:26] User458764: has joined #ruby
[06:08:27] devoldmx: has joined #ruby
[06:08:38] sevenseacat: a basic ruby tutorial, and opening irb.
[06:08:44] chinmay_dd: has joined #ruby
[06:09:45] funfunctor: sevenseacat: my question about evaluation is fairly important in terms of efficient implementation, if my class methods are strictly evaluating types all the way down to the value level all the time then it could be important to be aware of this
[06:10:07] Rollabunna: has joined #ruby
[06:10:09] sevenseacat: ruby has no type checking.
[06:10:13] sphex: funfunctor: if you know python/perl/lisp, then.. just assume it's going to work like them. types are associated with values only, there are no lexical type annotations anywhere in the language AFAIK.
[06:10:17] devoldmx_: has joined #ruby
[06:10:29] funfunctor: sevenseacat: I have that open on the other screen, basics isn't hard, I am more interested in some of the finer details
[06:10:30] sevenseacat: not in the sense funfunctor means
[06:10:41] sevenseacat: thats why the questions make no sense
[06:11:12] funfunctor: "sevenseacat: ruby has no type checking." sounds completely wrong to me
[06:11:29] arup_r: has joined #ruby
[06:11:32] Ox0dea: >> (1..Float::INFINITY).lazy.map { |x| x * 2 }.take(10).force
[06:11:33] ruboto: Ox0dea # => [2, 4, 6, 8, 10, 12, 14, 16, 18, 20] (https://eval.in/390207)
[06:11:34] Ox0dea: funfunctor: ^
[06:11:36] funfunctor: you can say ruby is dynamically typed or type inferred sure
[06:11:39] kfpratt: has joined #ruby
[06:11:42] flughafen: ooooh infinity!
[06:12:06] devoldmx: has joined #ruby
[06:12:28] Radar: Can't tell if trolling or asking legitimate questions.
[06:12:29] funfunctor: ACTION looks up the force method
[06:12:43] Ox0dea: It... forces evaluation?
[06:12:51] Ox0dea: Read the next chapter in your Haskell book. :P
[06:12:56] sevenseacat: I think a bit of both. thinks they're too cool to look up a tutorial
[06:13:00] sevenseacat: and wants to impress with fancy questions
[06:13:02] Aeyrix: Ox0dea: nah it uses
[06:13:04] Aeyrix: force push
[06:13:07] sevenseacat: that arent at all relevant
[06:13:18] Ox0dea: He's certainly not here to learn Ruby, in my opinion.
[06:13:29] funfunctor: why does everything think everything is a troll these days.. Eternal September has destroyed the internet
[06:13:36] Aeyrix: Ox0dea: maybe we should show him
[06:13:38] Aeyrix: your code golf
[06:13:43] Ox0dea: It's not golf.
[06:13:45] sphex: yeah.. if you already know python, start from there. haskell is not a similar language at all.
[06:13:53] Aeyrix: Ox0dea: Fine, your code badminton.
[06:13:55] devoldmx: has joined #ruby
[06:14:08] funfunctor: I only picked haskell randomly
[06:14:22] funfunctor: its not a game
[06:14:45] funfunctor: I can use python as a point of reference or lua, would that be better?
[06:15:14] Ox0dea: Did you ask these sorts of entirely inapplicable questions when you were learning Python?
[06:15:44] devoldmx: has joined #ruby
[06:15:49] damncabbage: has joined #ruby
[06:16:21] sphex: If I knew Haskell I would *never* shut up about it.
[06:16:35] shevy: funfunctor why do you want to use python :(
[06:16:40] Aeyrix: It seems that way with functional programming.
[06:16:43] funfunctor: sphex thanks for your direct responses
[06:16:45] kfpratt: has joined #ruby
[06:16:45] Aeyrix: ACTION looks at sevenseacat and Radar.
[06:17:01] Aeyrix: We're talking about how much you like to tell people you like Elixir.
[06:17:02] shevy: oh damn 2 Australians are online now
[06:17:12] funfunctor: shevy: I don't really care, each thing has its own purposes
[06:17:14] Radar: ACTION is clearly clueless about software because he didn't know what BNF was
[06:17:22] Aeyrix: Binary Notation Floatation.
[06:17:26] shevy: back naur for... something
[06:17:29] Radar: funfunctor: Please take the time to read through the resources we have linked you to.
[06:17:30] Xeago: has joined #ruby
[06:17:32] devoldmx: has joined #ruby
[06:17:40] shevy: or backus, what a weird name anyway
[06:17:42] sevenseacat: backhaus normal form or some shit.
[06:17:45] sphex: funfunctor: yeah, perl/python/lua/lisp and smalltalk are a lot more similar to ruby, especially WRT value semantics
[06:17:45] emilkarl: has joined #ruby
[06:17:45] funfunctor: Aeyrix: no, Backus???Naur Form
[06:17:58] funfunctor: Aeyrix: the syntactic formalism
[06:18:04] shevy: Aeyrix see how you get corrected mercilessly? :D
[06:18:12] Ox0dea: funfunctor: How do you type that fancy dash?
[06:18:17] shevy: alright let's blow it up...
[06:18:19] shevy: funfunctor what is a monad
[06:18:41] shevy: I don't see the dash :( must be unicode
[06:18:45] Aeyrix: shevy: I pulled my guess out of the air.
[06:18:53] funfunctor: is this going to degenerate into a trolling session?
[06:19:10] funfunctor: shevy: its unicode, I can never spell it so I copy and pasted it
[06:19:15] sphex: funfunctor: ruby is very expression-oriented. most compound constructs start with a keyword and end with "end". then what really matters is operator precedences. just read the doc/syntax bits, you're gonna have a hard time finding more succinct documentation than that.
[06:19:21] shevy: I remember I once wanted to write my own programming language... then I realized that I have to understand things such as Backus Naur... bison... those kind of things. That was so boring!
[06:19:29] devoldmx: has joined #ruby
[06:19:29] Ox0dea: funfunctor: This is IRC, mate; you could've just used a hyphen.
[06:19:33] funfunctor: no idea why you would call your child Naur
[06:19:48] shevy: perhaps it is a mythical child of power
[06:19:54] shevy: Thor Wauki ... Naur Loki ...
[06:19:55] Aeyrix: > Backus Naur bison
[06:19:59] Aeyrix: jesus christ
[06:20:05] sevenseacat: i wrote a compiler once. it's harder than it looks.
[06:20:06] Aeyrix: i'm laughing too hard and getting weird looks
[06:20:15] shevy: I have no idea why bison is named after an animal
[06:20:15] Musashi007: has joined #ruby
[06:20:27] Ox0dea: shevy: Because the original was called yacc.
[06:20:32] Ox0dea: yacc -> yak -> bison.
[06:20:36] Ox0dea: It's actually very clever.
[06:20:40] Radar: ACTION sees that funfunctor is now heavily engrossed in learning Ruby using the resources we linked
[06:20:42] funfunctor: sphex: thanks, yes that is a good summary.
[06:20:44] Radar: ACTION rejoices
[06:21:10] devoldmx_: has joined #ruby
[06:21:12] Ox0dea: funfunctor: If my head is a burrito and my tail a spacesuit, which of the monadic laws am I in violation of?
[06:21:16] damncabbage: ACTION casually mentions shell -> pe(a)rl -> ruby
[06:21:32] Aswebb_: has joined #ruby
[06:21:46] baweaver: sh -> Awk -> Perl -> Ruby
[06:21:52] Aeyrix: Ox0dea: what
[06:22:08] Ox0dea: matz considered calling his language Coral.
[06:22:09] djellemah: Ox0dea: the 4th one :-O
[06:22:12] baweaver: that I actually understand that Ox0dea
[06:22:24] Ox0dea: baweaver: Hm?
[06:22:35] baweaver: I was teaching Monoids to Scala newbies yesterday
[06:22:44] shevy: Mongoids?
[06:23:06] shevy: cool that you teach stuff to people - and get paid for it!
[06:23:10] devoldmx_: has joined #ruby
[06:23:25] funfunctor: sphex: thanks again for the direct answers, guess I'll just grok though it all and perhaps be back if anything else 'special' comes to mind but things seem well documented.
[06:23:25] baweaver: http://eed3si9n.com/learning-scalaz/sum+function.html
[06:23:50] damncabbage: Ox0dea: Your burrito and spacesuit are both partial; expect them both to blow up in your face without warning.
[06:24:01] sphex: funfunctor: alright, np.
[06:24:30] funfunctor: has left #ruby: ()
[06:24:47] devoldmx: has joined #ruby
[06:24:51] acke: has joined #ruby
[06:25:00] User458764: has joined #ruby
[06:25:38] andikr: has joined #ruby
[06:26:20] iszak: has joined #ruby
[06:26:47] devoldmx_: has joined #ruby
[06:27:14] sphex: shevy: BTW, there's a trick to implementing parsing easily. recursive descent can support most language constructs straightforwardly. but operator precedence stumbles most people, but there's a really simple way to do it. look up "pratt parser". the main loop is just a few line of code, it's table-based and really fast.
[06:27:34] sphex: and operators can be added/modified dynamically
[06:28:34] jtdoncas: has joined #ruby
[06:28:41] devoldmx: has joined #ruby
[06:30:02] yardenbar: has joined #ruby
[06:30:20] devoldmx: has joined #ruby
[06:30:55] jas02: has joined #ruby
[06:31:28] peter_paule: has joined #ruby
[06:31:46] howdoi: has joined #ruby
[06:31:52] Aeyrix: [16:24:29] funfunctor (~edward@promim2.lnk.telstra.net) left the channel
[06:31:53] Aeyrix: > telstra
[06:31:58] Aeyrix: he's an aussie
[06:31:59] devoldmx_: has joined #ruby
[06:32:00] zacstewart: has joined #ruby
[06:32:43] Radar: evidenced by his "g'day" as he joined, too
[06:32:45] khebbie: has joined #ruby
[06:32:55] Aeyrix: South Africans say that too, a bit.
[06:33:25] shevy: aussies are weird
[06:33:32] Aeyrix: Yeah I know.
[06:33:34] User458764: has joined #ruby
[06:33:47] devoldmx: has joined #ruby
[06:34:07] Bertg: has joined #ruby
[06:34:24] jas02_: has joined #ruby
[06:34:32] sphex: they use the word "cunt" so much that they need to qualify it now
[06:34:45] shevy: just take Crocodile Dundee!
[06:35:45] devoldmx: has joined #ruby
[06:35:56] sevenseacat: sphex: I dont think that word is appropriate for this channel.
[06:36:19] revath: has joined #ruby
[06:36:51] arturaz: has joined #ruby
[06:37:23] devoldmx: has joined #ruby
[06:37:26] dseitz: has joined #ruby
[06:37:56] karols: has joined #ruby
[06:38:32] sphex: welp. I've been naughty.
[06:38:39] yfeldblum: has joined #ruby
[06:39:12] devoldmx: has joined #ruby
[06:39:28] nirix: has joined #ruby
[06:39:35] workmad3: has joined #ruby
[06:39:51] Aeyrix: ( ???? ???? ????)
[06:40:16] riotjones: has joined #ruby
[06:41:00] devoldmx_: has joined #ruby
[06:42:56] devoldmx_: has joined #ruby
[06:44:41] devoldmx: has joined #ruby
[06:45:11] astrobun_: has joined #ruby
[06:46:22] bruno-: has joined #ruby
[06:46:26] djbkd: has joined #ruby
[06:46:36] devoldmx: has joined #ruby
[06:47:39] mister_solo: has joined #ruby
[06:48:16] devoldmx: has joined #ruby
[06:48:32] damncabbage: has left #ruby: ()
[06:49:06] niemcu: has joined #ruby
[06:50:00] devoldmx_: has joined #ruby
[06:50:11] DexterLB: has joined #ruby
[06:50:15] jph98: has joined #ruby
[06:51:00] atomic: has joined #ruby
[06:51:36] zacstewart: has joined #ruby
[06:51:47] devoldmx: has joined #ruby
[06:53:47] devoldmx: has joined #ruby
[06:55:10] gauke: has joined #ruby
[06:55:31] devoldmx: has joined #ruby
[06:55:40] peter_paule: has joined #ruby
[06:57:20] devoldmx: has joined #ruby
[06:57:29] freezevee: has joined #ruby
[06:57:39] eGGsha: has joined #ruby
[06:58:17] fabrice31: has joined #ruby
[06:58:59] devoldmx: has joined #ruby
[06:59:19] jenrzzz: has joined #ruby
[06:59:27] freezevee: hi guys, I am trying to get a service working with systemd in ubuntu running a ruby script that parses data from web sites and then displays them on a mini-api in sinatra. While it runs successfully, I get random errors. Can someone please take a look ? https://github.com/chrisvel/apc_ups_api
[06:59:51] robbyoconnor: has joined #ruby
[07:00:24] emhs: freezevee: "random errors" ?
[07:00:31] kfpratt: has joined #ruby
[07:00:48] devoldmx_: has joined #ruby
[07:00:49] drewo: has joined #ruby
[07:00:50] solars: has joined #ruby
[07:01:00] ddv: freezevee: lol
[07:01:29] freezevee: _mh_: first of all I execute manually systemctl start ups_parser.service
[07:01:42] fabrice31: has joined #ruby
[07:01:46] balazs: has joined #ruby
[07:02:04] sevenseacat: "look at my entire app to fix my random unspecified errors"
[07:02:36] devoldmx: has joined #ruby
[07:02:51] emhs: freezevee: without a specific description on what errors you get from your ruby script ... we can't help you, I'm afraid.
[07:03:01] codecop: has joined #ruby
[07:03:03] ddv: freezevee: Type=forking should be simple
[07:03:12] freezevee: sevenseacat: hello :)
[07:03:16] alex88: has joined #ruby
[07:03:22] sharpmachine: has joined #ruby
[07:03:52] freezevee: _mh_: sorry, it takes time to think and write !
[07:03:54] shevy: freezevee this cat is not in a friendly mood right now
[07:04:08] ddv: freezevee: you might want to put a sleep 1 in that loop because it could block the main thread due to 100% cpu usage
[07:04:22] Rollabunna: has joined #ruby
[07:04:23] freezevee: _mh_: actually it is my first service and I wonder If it is normal that i don't get the terminal prompt back
[07:04:28] ddv: freezevee: oh you already have a sleep
[07:04:29] devoldmx_: has joined #ruby
[07:04:43] shevy: props for being able to use systemd in the first place though
[07:04:44] freezevee: _mh_: that means If I execute systemctl start ups_parser.service & then I get a pid and everything is ok
[07:04:59] emhs: freezevee: Well, it's usually _your_ job to make sure that the whole thing detaches properly from the executing terminal
[07:05:09] sevenseacat: shevy: you wouldnt be either if you were trying to debug the code I'm debugging
[07:05:15] ddv: great he ignores me
[07:05:37] shevy: ddv it's because of your nick, it's so short and innocent
[07:05:44] freezevee: _mh_: should I do this *inside* the ruby script or in systemd ? I mean, systemd runs everything in background or I must do this by myself with Thread, PRocess or whatever
[07:06:03] luckyno7: has joined #ruby
[07:06:11] devoldmx: has joined #ruby
[07:06:37] emhs: freezevee: also what ddv said. Plus, Why do you generate IO objects with IO.popen that you don't use? And yes, inside your ruby script, look at Process#daemon.
[07:06:41] freezevee: ddv: sorry man I don't ignore you,
[07:06:42] Stan: has joined #ruby
[07:06:56] ddv: he doesn't deamonize his program
[07:06:59] ddv: so he should use Type=simple
[07:07:01] ddv: it does not fork
[07:07:04] krz: has joined #ruby
[07:07:25] shevy: you guys all seem to be systemd experts
[07:07:31] emhs: ddv: so systemd can handle programs taht don't demonize on it's own?
[07:07:37] fp-: has joined #ruby
[07:07:43] emhs: that's kinda need.
[07:07:56] juanpablo_: has joined #ruby
[07:08:03] devoldmx: has joined #ruby
[07:08:21] fp-: is there anyone who can tell me why local_time (github.com/basecamp/local_time) keeps giving me time that's 4 hours in the future?
[07:09:53] freezevee: _mh_: so systemd doesn't have any multitasking processing by its own ?
[07:09:57] devoldmx: has joined #ruby
[07:10:11] freezevee: _mh_: I thought that the O/S is doing all the job
[07:10:41] railsraider: has joined #ruby
[07:10:46] emhs: freezevee: did you follow the conversation? ddv did just point out that systemd can handle non-daemonizing processes if you put type=simple.
[07:10:59] revath: has joined #ruby
[07:11:00] emhs: gnargh, too early for proper english.
[07:11:41] freezevee: _mh_: what do you suggest ?
[07:11:43] devoldmx: has joined #ruby
[07:12:13] freezevee: _mh_: I mean, what would you do personally ?
[07:12:14] sphex: freezevee: I'm guessing it does it itself if you ask it to. I don't know about systemd in particular, but in general, it can be useful when daemon-type programs fork themselves only after they are ready to handle requests, etc. that way the other services can get started once their dependencies are ready.
[07:12:19] sandstrom: has joined #ruby
[07:12:19] Xeago: has joined #ruby
[07:12:49] sphex: freezevee: try the type=simple thing, c'mon!
[07:12:56] zacstewart: has joined #ruby
[07:13:23] devoldmx: has joined #ruby
[07:13:52] emhs: freezevee: what ddv said, both of his pointers. Plus get rid of the pipe = IO.popen if you don't need it. You can worry about handling daemonizing once you have mastered your script.
[07:14:14] lolmaus: has joined #ruby
[07:14:57] dhjondoh: has joined #ruby
[07:15:13] emhs: freezevee: and some error output would really help understand where exactly you are hanging, right now we are just stabbing at the dark.
[07:15:16] freezevee: _mh_: last time I asked someone mocked at me and told me that ruby daemonizing is BS
[07:15:17] devoldmx: has joined #ruby
[07:15:32] freezevee: _mh_: so I am trying to follow the best practise
[07:16:08] freezevee: _mh_: and I was given this link http://www.mikeperham.com/2014/09/22/dont-daemonize-your-daemons/
[07:16:09] ddv: daemonizing is indeed not necessary
[07:16:35] ddv: freezevee: you just read the systemd documentation, and use Type=simple you could be done 30 minutes ago!
[07:16:58] freezevee: ddv: so how do you create a process that parses data from console output frequently ?
[07:16:58] ddv: instead you totally ignore me, so I will ignore you
[07:17:04] devoldmx: has joined #ruby
[07:17:28] freezevee: ddv: I don't ignore you, I just don't want to accept a solution or a quick fix without understanding why
[07:17:38] fp-: has left #ruby: ("Be back later ...")
[07:17:38] rickmasta: has joined #ruby
[07:17:48] ddv: freezevee: but you did use Type=forking without understanding why
[07:17:53] ddv: freezevee: so whatever
[07:18:03] ddv: you process doesn't even fork
[07:18:06] freezevee: ddv: I followed the docs for a default service
[07:18:08] ddv: so why use it
[07:18:21] ddv: you didn't understand the docs then
[07:18:27] freezevee: ddv: I don't know what do you mean "fork"
[07:18:37] ddv: you don't know what forking means? google it
[07:18:39] freezevee: ddv: yes, I didn't most probably
[07:18:49] freezevee: I know in git but not in processes
[07:18:51] Rixius: has joined #ruby
[07:18:57] ddv: it has nothing to do with git
[07:18:58] emhs: freezevee: https://github.com/chrisvel/apc_ups_api/blob/master/ups_parser.service line 5
[07:19:00] devoldmx_: has joined #ruby
[07:19:35] freezevee: ddv: I am saying that only this comes into my mind
[07:19:51] emhs: freezevee: and ever since you asked your question, we still do not know more then that you got 'random errors' :/
[07:19:57] freezevee: it should be some kind of background processing terminology which I am not familliar with
[07:20:14] freezevee: _mh_: first one is that I don't the console prompt back
[07:20:31] GPrime: has joined #ruby
[07:20:35] devoldmx: has joined #ruby
[07:20:41] Apocalypse: has joined #ruby
[07:20:45] shevy: freezevee in ruby you can commonly use Thread even without systemd; for backgrounding processes, one can typically use: http://www.rubydoc.info/gems/daemonize/0.0.1/Daemonize or http://www.rubydoc.info/gems/daemonizer/0.4.18 or Thread.fork
[07:20:48] freezevee: _mh_: second one is that with "&" it fails after some executions with an error systemd[1]: Failed to start Ups data parser.
[07:21:05] shevy: yay systemd error!
[07:21:14] Guest85: has joined #ruby
[07:21:24] Guest85: has left #ruby: ()
[07:21:29] revath: has joined #ruby
[07:21:31] emhs: freezevee: so you are asking unix questions and not ruby questions? And maybe both would be fixed using type=simple instead of type=forking as ddv suggested?
[07:21:41] freezevee: shevy: I see the status and it executes 10 times and then fails without a reason
[07:21:53] sphex: freezevee: daemons "fork" a sub-process, and then the parent process terminates. for these, systemd can safely wait for the parent process to terminate. then there are processes that don't do that. for these, systemd must not wait. both are OK, but it has to know which one it is.
[07:21:58] shevy: yeah no wonder, it's systemd man!
[07:22:22] shevy: http://homepage.ntlworld.com/jonathan.deboynepollard/FGA/systemd-house-of-horror/
[07:22:31] freezevee: shevy: should I leave the service as is and convert the ruby script to a daemon ?
[07:22:34] devoldmx_: has joined #ruby
[07:22:41] ddv: freezevee: we are not going to debug your program for you, don't you think thats pretty rude to just dump a github url?
[07:22:49] msgodf: has joined #ruby
[07:23:13] shevy: I dunno, it's your script and code? I can not relate to it, I don't use systemd for instance; but you can easily run ruby as a daemon, I do this to get regular data from a remote website for instance
[07:23:17] freezevee: ddv: noone requested that
[07:23:32] apeiros: freezevee: care to show me where you got mocked? http://irclog.whitequark.org/ruby/2015-06-25 (first answer to your inquiry starts around 19.30)
[07:24:16] devoldmx_: has joined #ruby
[07:24:35] shevy: so the evil mocker was apeiros!
[07:24:47] apeiros: shevy: I wasn't even participating in that discussion
[07:24:48] flughafen: shevy has 3194 alias to fix that issue
[07:25:18] shevy: so the evil mocker is still unidentified
[07:25:24] shevy: ACTION peers at flughafen suspiciously.
[07:26:00] shevy: flughafen actually I don't have that many ruby scripts that I want to run in the background... I think at least 98% are just "do a task, then exit" things
[07:26:02] apeiros: shevy: I don't see any mocking going on. that's why I ask them.
[07:26:08] sphex: oh gawd. as there been mocking? I thought this channel was a safe space...
[07:26:10] devoldmx: has joined #ruby
[07:26:28] ddv: are we talking about mocking as in testing or just mocking in general
[07:26:43] freezevee: I love this place
[07:26:52] Aswebb_: has joined #ruby
[07:26:52] sevenseacat: I think freezevee complained to apeiros.
[07:27:02] freezevee: and I love sevenseacat
[07:27:03] apeiros: sphex: it's my intention to get there
[07:27:22] shevy: we have to identify the evil
[07:27:28] emhs: freezevee: could you please just try the suggestions given, refer to systemd documentation on what type=simple means ?
[07:27:29] allomov: has joined #ruby
[07:27:41] apeiros: sevenseacat: no, I just saw them saying that they got mocked. and I remembered being present when they asked this the first time. so I wanted to know whether I failed at op duties.
[07:27:47] devoldmx_: has joined #ruby
[07:28:04] freezevee: _mh_: sure I will
[07:28:30] freezevee: _mh_: but asking around in irc, forums etc. I get totally different opinions so finally I don't know what to do
[07:28:56] ddv: freezevee: opinion?
[07:29:01] ddv: freezevee: your program doesn't fork
[07:29:04] ddv: that is a FACT
[07:29:12] ddv: so you use Type=simple with systemd
[07:29:13] freezevee: _mh_: If you see the previous git commits, I daemonized the scripts with a gem and then I got told that it's bs to do that, just try upstart or systemd
[07:29:21] sphex: freezevee: you said you wanted to understand, but you're gonna have to participate a little bit in this... :p
[07:29:36] devoldmx: has joined #ruby
[07:29:41] pwnz0r: has joined #ruby
[07:29:45] freezevee: well my main issue is confusion
[07:29:57] genpaku: has joined #ruby
[07:29:58] sevenseacat: it sound like decision paralysis
[07:30:23] freezevee: decision attack
[07:30:26] emhs: freezevee: I'm sorry, while there are a lot of things that are best done the one way or another, programming often has numerous solutions. And people have different levels of knowledge. So, getting multiple opinions is common ...
[07:30:27] freezevee: like panic attack
[07:30:33] sevenseacat: you want everyone to agree on something for you so you can then go and implement it
[07:30:39] sevenseacat: when there's ten viable ways to do the same thing
[07:30:55] sevenseacat: the decision falls on you to pick one
[07:30:58] ddv: you just implement all solutions that way you can't go wrong
[07:31:15] freezevee: no but when you get somewhere and it takes you days (due to inexperience) you can't just ditch it and start over with another solution
[07:31:16] emhs: sevenseacat: even better put.
[07:31:23] shevy: https://xkcd.com/927/
[07:31:24] devoldmx_: has joined #ruby
[07:31:31] bttf: has joined #ruby
[07:31:33] whoojemaflip: has joined #ruby
[07:31:51] yayfoxes3: has joined #ruby
[07:31:54] emhs: does every other request for help have to turn into meta discussions about answers? :/
[07:32:05] freezevee: anyway, I got enough good suggestions here that I should try
[07:32:11] sevenseacat: yes, you should.
[07:32:22] sevenseacat: _mh_: and how did that make you feel?
[07:32:32] sphex: freezevee: maybe we could pick a way for you by voting? I guess you shouldn't fork since it's not needed in the script itself and systemd does not require it, but that's just my opinion I guess. but what if the channel voted on it?
[07:32:41] emhs: freezevee: good luck finding one that suits you. Am sure you'll get through to one that works for you.
[07:32:43] shevy: _mh_ I blame systemd
[07:33:01] emhs: sevenseacat: I'm no fan of meta discussions ;)
[07:33:17] sevenseacat: sometimes they're important to determine a direction
[07:33:18] Miron: has joined #ruby
[07:33:23] freezevee: thanks, I got enough feedback
[07:33:25] sevenseacat: but usually it's rehashing the same old shit
[07:33:29] emhs: shevy: No experience with it, but what you hear around the net it seems sensible to blame systemd to just be on the safe side.
[07:33:30] robbyoconnor: has joined #ruby
[07:33:31] devoldmx: has joined #ruby
[07:33:45] robbyoconnor: has joined #ruby
[07:34:04] zacstewart: has joined #ruby
[07:34:04] emhs: sevenseacat: yeah, that's why I dislike them. Sometimes they are important, but most of the time, it's the same stuff in an endless loop.
[07:34:11] wildroman2: has joined #ruby
[07:34:32] sevenseacat: ah well. all solved for now.
[07:34:34] Guest85: has joined #ruby
[07:34:39] shevy: we want more meta discussions
[07:34:51] lavros: has joined #ruby
[07:35:00] devoldmx: has joined #ruby
[07:35:12] Guest85: has left #ruby: ("Textual IRC Client: www.textualapp.com")
[07:35:14] Guest85: has joined #ruby
[07:35:22] ndrei: has joined #ruby
[07:35:29] freezevee: it must be bothering when someone is reading everything in an irc room
[07:35:31] hotpancakes: has joined #ruby
[07:35:47] freezevee: but If you connect only for a few minutes, it's ok
[07:35:49] Miron: has joined #ruby
[07:36:06] sevenseacat: well yeah, if you're the type to turn up, ask your question, get your help and leave, its fine for you :P
[07:36:18] opalraava: has joined #ruby
[07:36:22] kstuart: has joined #ruby
[07:37:00] devoldmx: has joined #ruby
[07:37:02] workmad3: has joined #ruby
[07:37:37] revath: has left #ruby: ()
[07:37:40] cbednarski: has joined #ruby
[07:38:26] freezevee: sevenseacat: I wish I could help others
[07:38:35] devoldmx_: has joined #ruby
[07:38:36] sevenseacat: then stick around, see what shakes out.
[07:38:38] freezevee: but my experience is not in a level that I could do so yet
[07:38:46] RazorX: has joined #ruby
[07:38:49] freezevee: I am reading SO questions and then stare the sky
[07:38:52] sevenseacat: you can learn just by observing
[07:39:25] freezevee: maybe, but then practice time is lost
[07:39:37] freezevee: so I am trying to create things, mostly for myself
[07:39:42] emhs: freezevee: and also gather experience by seeing that there's often not just one answer. Often, the way people approach problems thrown at them is also something to learn from.
[07:40:05] kies: has joined #ruby
[07:40:13] freezevee: _mh_: of course, it's programming but there are best practices and standards too
[07:40:16] lessless: has joined #ruby
[07:40:16] emhs: in my opinion one of the most important skills of a programmer: the method to approach an error you have no idea where it comes from.
[07:40:18] Pupeno: has joined #ruby
[07:40:31] devoldmx: has joined #ruby
[07:40:35] freezevee: _mh_: this is analytical skills and comes with experience
[07:40:43] Zai00: has joined #ruby
[07:40:51] jeanlinux: has joined #ruby
[07:40:54] sevenseacat: some of it comes from critical thinking of error messages
[07:41:04] sevenseacat: some of comes from just typing the error into google
[07:41:06] anisha: has joined #ruby
[07:41:09] freezevee: but there is also the chance to turn into a shitty programmer who writes code that works and noone understands
[07:41:52] sevenseacat: you mean, like Ox0dea ? *runs*
[07:41:54] freezevee: like some project euler problems which run in 10ms and 1 hour, just different code from different programmers
[07:42:05] emhs: freezevee: that's usually the type that blindly follows "standards".
[07:42:06] sevenseacat: oh, shitty - no hes not shitty
[07:42:12] devoldmx_: has joined #ruby
[07:42:35] emhs: sevenseacat: Ox0dea showed ingeniouity in his admittedly alienating piece of code two days ago.
[07:42:37] _ixti_: has joined #ruby
[07:42:45] sevenseacat: oh he does it all the time
[07:42:56] senayar: has joined #ruby
[07:42:58] sevenseacat: today he wrote a caesar cipher without using alphanumeric characters
[07:43:03] freezevee: good coding is art
[07:43:08] emhs: heck. I need to read my backlog
[07:43:17] sevenseacat: yesterday or the day before it was fizzbuzz
[07:43:19] El3k0n: has joined #ruby
[07:43:19] coderhs: has joined #ruby
[07:43:27] freezevee: I know noone cares about it, but this is the type of programmer that I want to become
[07:43:37] emhs: saw the fizzbuzz thing. Was very impressive.
[07:43:39] sevenseacat: we all care about our skills
[07:43:47] freezevee: that's why I usually ask things here like a 10 yr old
[07:44:11] devoldmx_: has joined #ruby
[07:44:32] ddv: if you care about your skills you are already above the codemonkeys
[07:44:52] sevenseacat: was just about to say, we wouldn't even be here if we didnt care
[07:44:56] emhs: codemonkey seems to be a very sought after job in big companies, though...
[07:44:56] freezevee: anyway, I am stopping the fluency here
[07:45:34] User458764: has joined #ruby
[07:45:44] kfpratt: has joined #ruby
[07:45:48] devoldmx: has joined #ruby
[07:45:58] astrobunny: has joined #ruby
[07:46:07] sevenseacat: I know people hate me always talking about elixir, but I recently started learning it, and part of me doing so is hanging out in #elixir-lang. for a long time I understood very little. then I started understanding a little bit. now I can answer some (very simple) questions. levelling up skills.
[07:46:11] shevy: Ox0dea see? look at sevenseacat!
[07:46:28] emhs: sevenseacat: hmm, elixir?
[07:46:48] shevy: the mystical elixir that turns the cat into a genius-cat
[07:46:52] sevenseacat: I promise I'll stop mentioning elixir.
[07:46:55] blackmesa: has joined #ruby
[07:47:00] sevenseacat: but I find it more interesting than ruby lately >_>
[07:47:03] emhs: sevenseacat: am actually just curious.
[07:47:31] emhs: I find it always important to explore new programming languages.
[07:47:31] ddv: sevenseacat: write a book about it :)
[07:47:34] sevenseacat: _mh_: is a pretty new functional programming language, on the erlang vm. syntax is a lot like ruby.
[07:47:35] devoldmx: has joined #ruby
[07:47:38] sevenseacat: ddv: ;) ;) ;)
[07:47:48] emhs: it always revolutionizes the way you write and structure your code.
[07:47:56] sphex: holy ****. Kernel is included in every class, and all those "builtins functions" are actually self method calls?
[07:47:58] emhs: those two years of haskell... I wouldn't want to miss the experience for my ruby code.
[07:48:12] Scroff: has joined #ruby
[07:48:21] white_bear: has joined #ruby
[07:48:33] psye: has joined #ruby
[07:48:37] emhs: sevenseacat: Made me curious. Going to have a look at it when I find time. Thanks for the pointer
[07:48:39] sevenseacat: strictly speaking, I think Kernel is included in Object
[07:48:41] sphex: it all makes sense now. methods and Constants. there's nothing else.
[07:48:52] mike___1234: has joined #ruby
[07:48:55] emhs: for now though... back to office routine and meetings. afk
[07:48:56] zacstewart: has joined #ruby
[07:48:57] sevenseacat: so you can still have BasicObject without it
[07:48:57] maloik: yay, rails 423 + squeel is bugged :(
[07:49:02] hotpancakes: has joined #ruby
[07:49:05] sandstrom: has joined #ruby
[07:49:10] maloik: it may as well be monday
[07:49:14] dented42: has joined #ruby
[07:49:33] devoldmx: has joined #ruby
[07:49:37] RegulationD: has joined #ruby
[07:49:51] ferr: has joined #ruby
[07:49:56] shevy: >> BasicObject.methods.size
[07:49:57] ruboto: shevy # => 100 (https://eval.in/390230)
[07:50:03] Xeago: has joined #ruby
[07:50:17] shevy: somehow when I start irb; I get a much higher number for that
[07:50:22] Ox0dea: >> BasicObject.instance_methods.size
[07:50:23] ruboto: Ox0dea # => 8 (https://eval.in/390231)
[07:50:27] sevenseacat: BasicObject should have much fewe... yeah.
[07:50:29] sphex: dammit. it doesn't all make sense anymore. oh wait.. yess.. classes inherit from BasicObject.. or superclass. dammit.
[07:50:41] sevenseacat: it goes BasicObject -> Object -> everything else
[07:51:12] dumdedum: has joined #ruby
[07:51:12] devoldmx_: has joined #ruby
[07:53:12] gagrio_: has joined #ruby
[07:53:29] Scroff: has joined #ruby
[07:53:42] eGGsha: has joined #ruby
[07:54:53] devoldmx: has joined #ruby
[07:55:22] vdamewood: has joined #ruby
[07:55:53] revath: has joined #ruby
[07:56:06] olistik: has joined #ruby
[07:56:35] devoldmx: has joined #ruby
[07:56:57] vasilakisfil_: has joined #ruby
[07:57:33] Hobogrammer: has joined #ruby
[07:57:50] emilkarl: has joined #ruby
[07:58:12] emilkarl: has joined #ruby
[07:58:27] devoldmx_: has joined #ruby
[07:58:43] Rollabunna: has joined #ruby
[07:58:46] fabrice31: has joined #ruby
[07:59:07] kies: has joined #ruby
[07:59:12] rdark: has joined #ruby
[07:59:17] tno: has joined #ruby
[08:00:21] devoldmx: has joined #ruby
[08:01:01] Hounddog: has joined #ruby
[08:01:53] bayed: has joined #ruby
[08:01:57] sphex: sevenseacat: I can see Kernel methods in BasicObject.private_methods... this is confusing the hell out of me. :/
[08:02:06] devoldmx: has joined #ruby
[08:02:50] mikecmpbll: has joined #ruby
[08:03:05] sphex: ohhh.. instance_methods I should be looking at
[08:03:25] michael_mbp: has joined #ruby
[08:03:48] devoldmx_: has joined #ruby
[08:04:09] sharpmachine: has joined #ruby
[08:04:45] dgutierrez1287: has joined #ruby
[08:04:53] symm-: has joined #ruby
[08:05:34] VictorBjelkholm: has joined #ruby
[08:05:46] devoldmx: has joined #ruby
[08:06:18] DopeBot: has joined #ruby
[08:07:24] devoldmx: has joined #ruby
[08:07:25] Ox0dea: sphex: For reference, you were seeing all those methods because BasicObject is a class, and classes are modules.
[08:07:50] zacstewart: has joined #ruby
[08:08:25] GentleBot: has joined #ruby
[08:08:32] Ox0dea: Rather, Class itself is a module.
[08:09:05] joonty: has joined #ruby
[08:09:11] devoldmx: has joined #ruby
[08:09:34] apeiros: Class is a Class
[08:09:38] apeiros: it inherits from Module
[08:09:38] Rakunh0: has joined #ruby
[08:09:45] apeiros: /pedantry ;-)
[08:10:02] k3asd`: has joined #ruby
[08:10:24] Ox0dea: >> Class.is_a?(Module)
[08:10:25] ruboto: Ox0dea # => true (https://eval.in/390234)
[08:10:29] apeiros: oh, well, silly pedantry - Class being a Class, and Class inheriting Module of course makes Class a Module
[08:10:29] Ox0dea: But I take your point.
[08:10:46] langlands: has joined #ruby
[08:10:59] apeiros: yeah, it's early, it's hot, and <insert random other excuse> :)
[08:11:10] devoldmx: has joined #ruby
[08:11:22] adaedra: Here, take mine: .
[08:11:48] Ox0dea: sphex: havenwood put it quite succinctly the other day:
[08:11:49] Ox0dea: >> [Class.is_a?(Module), Class.is_a?(Object), Module.is_a?(Class), Module.is_a?(Object), Object.is_a?(Class), Object.is_a?(Module)].all?
[08:11:51] ruboto: Ox0dea # => true (https://eval.in/390235)
[08:12:47] devoldmx_: has joined #ruby
[08:12:48] hotpancakes: has joined #ruby
[08:14:32] chthon: has joined #ruby
[08:14:40] devoldmx: has joined #ruby
[08:15:14] CloCkWeRX: has joined #ruby
[08:15:18] ralku: has joined #ruby
[08:15:20] einarj: has joined #ruby
[08:15:22] sphex: Ox0dea: okay yeah.. I think I get it now WRT Kernel methods. an object's class and superclass both end up with Object as a parent, and include Kernel stuff. and that must be what makes those Kernel methods available both directly in the class' body and in the method bodies...
[08:15:26] sphex: took me long enough
[08:15:37] sphex: apeiros: thanks for that clarification, it was confusing me
[08:15:41] troulouliou_dev: has joined #ruby
[08:16:23] avelldiroll: has joined #ruby
[08:16:24] devoldmx_: has joined #ruby
[08:17:22] dumdedum: has joined #ruby
[08:18:12] devoldmx: has joined #ruby
[08:18:26] Ox0dea: sphex: You can use Object#method and Method#owner to figure out where exactly things are coming from.
[08:18:29] Ox0dea: >> b = BasicObject; b.methods.map { |m| b.method(m).owner }.uniq
[08:18:30] ruboto: Ox0dea # => [Class, Module, Kernel, BasicObject] (https://eval.in/390236)
[08:18:56] mradmacher: has joined #ruby
[08:18:59] Ox0dea: In other words, BasicObject*s* are simple, but BasicObject itself is as featureful as any other class.
[08:19:41] micmus: has joined #ruby
[08:19:59] devoldmx: has joined #ruby
[08:20:21] fabrice31_: has joined #ruby
[08:21:23] peter_paule: has joined #ruby
[08:21:38] GreatSUN: has joined #ruby
[08:21:53] devoldmx: has joined #ruby
[08:22:12] n008f4g_: has joined #ruby
[08:22:22] adaedra: I'd prefer a smaller sun today.
[08:22:30] Ox0dea: Small things can be great.
[08:22:51] eGGsha: has joined #ruby
[08:23:32] sphex: Ox0dea: oh yeah.. thanks for the infos.
[08:23:35] devoldmx_: has joined #ruby
[08:23:54] Ox0dea: Sure thing.
[08:24:09] GreatSUN: can someone of you guys tell me if there is an option to find out which version of a gem matches the current installed ruby version via gem command without trying to install ?
[08:24:16] Alina-malina: has joined #ruby
[08:24:17] Scrofff: has joined #ruby
[08:25:07] Scroff: has joined #ruby
[08:25:24] devoldmx_: has joined #ruby
[08:25:27] shevy: GreatSUN I think many gems won't have that information
[08:25:44] matp: has joined #ruby
[08:26:16] shevy: a .gemspec file is often used to create a .gem file
[08:26:27] Ox0dea: Gems can specify a required Ruby version in their .gemspecs, but most don't.
[08:26:30] shevy: in that .gemspec file, the gem author can specify certain dependencies and requirements, for instance:
[08:26:32] shevy: s.rubygems_version = "2.4.8"
[08:26:52] shevy: individual versions of gems can be specified such as by doing:
[08:27:03] shevy: s.add_dependency 'foobar', '>= 0.0.6' # this will require at least version 0.0.6 or higher
[08:27:22] devoldmx: has joined #ruby
[08:27:24] ytti: i think encouraged use is add_runtime_dependence
[08:27:27] ytti: dependency
[08:27:33] TheHodge: has joined #ruby
[08:28:08] Ox0dea: shevy: The question was about Ruby's version.
[08:28:22] shevy: Ox0dea talk to him not me ok?
[08:28:41] Ox0dea: Not sure what that was about, but all right.
[08:28:50] shevy: because we have had similar problems in the past
[08:28:59] sevenseacat: shevy: Ox is pointing out that you asked a different question than was asked
[08:29:03] sevenseacat: *you answered
[08:29:04] devoldmx_: has joined #ruby
[08:29:07] vdamewood: has joined #ruby
[08:29:11] shevy: I don't feel this to be the case in any way
[08:29:30] adaedra: then ask to precise the question
[08:29:47] shevy: you do that if you got a problem adaedra; I don't have that problem in the slightest
[08:29:50] lsmola: has joined #ruby
[08:29:53] zacstewart: has joined #ruby
[08:30:06] psye: has joined #ruby
[08:30:20] abuzze: has joined #ruby
[08:30:48] devoldmx: has joined #ruby
[08:32:20] Dreamer3: has joined #ruby
[08:32:24] langlands: has joined #ruby
[08:32:49] Musashi007: has joined #ruby
[08:32:49] hemanth: has joined #ruby
[08:32:51] devoldmx: has joined #ruby
[08:32:54] jas02: has left #ruby: ()
[08:33:30] kfpratt: has joined #ruby
[08:34:31] devoldmx_: has joined #ruby
[08:34:51] arup_r: has joined #ruby
[08:35:14] Shoutsid: has joined #ruby
[08:35:36] axl_: has joined #ruby
[08:36:11] devoldmx: has joined #ruby
[08:36:35] krz: has joined #ruby
[08:38:13] devoldmx_: has joined #ruby
[08:39:28] whiteline: has joined #ruby
[08:39:39] charliesome: has joined #ruby
[08:39:55] devoldmx: has joined #ruby
[08:41:15] ahmetkapikiran: has joined #ruby
[08:41:23] senayar: has joined #ruby
[08:41:36] devoldmx_: has joined #ruby
[08:43:37] devoldmx: has joined #ruby
[08:44:33] phale: has joined #ruby
[08:44:40] phale: hello fellow rubyists
[08:44:44] phale: what are we programming today?
[08:45:11] devoldmx_: has joined #ruby
[08:45:23] charliesome: has joined #ruby
[08:46:23] lkba_: has joined #ruby
[08:46:51] skade: has joined #ruby
[08:47:05] devoldmx: has joined #ruby
[08:48:12] zacstewart: has joined #ruby
[08:48:48] devoldmx_: has joined #ruby
[08:48:53] workmad3: has joined #ruby
[08:49:42] adaedra: greetings yorickpeterse
[08:50:29] GreatSUN: I just had a meeting, so sorry for not answering
[08:50:37] devoldmx: has joined #ruby
[08:50:47] GreatSUN: but the main thing I saw in your messages was, that a .gemspec file might help
[08:50:55] phale: I have a thinkpad
[08:51:07] GreatSUN: but to be able to access this, I would have to have the gem somewhere on my disk and not in a gemrepo, right?
[08:51:22] adaedra: GreatSUN: what are you trying to do, exactly?
[08:52:00] iwishiwerearobot: has joined #ruby
[08:52:32] devoldmx_: has joined #ruby
[08:52:55] Rollabunna: has joined #ruby
[08:54:13] hotpancakes: has joined #ruby
[08:54:13] devoldmx: has joined #ruby
[08:55:32] phale: hes trying to act cool by becoming a gem developer
[08:55:36] phale: i understand him
[08:55:41] Ox0dea: GreatSUN: You can do `gem list -ra '^rake$'` to get a list of every version of rake, then, for instance, `gem spec -rv 0.4.8 rake` to get Rake v0.4.8's specification.
[08:55:54] marr: has joined #ruby
[08:56:02] devoldmx: has joined #ruby
[08:56:07] Ox0dea: It's definitely not a good idea, but it would nevertheless be nice if something like this existed.
[08:56:20] Ox0dea: "Tell me which is the most recent version of this gem I can use with my current Ruby."
[08:56:23] startupality: has joined #ruby
[08:56:37] Ox0dea: It's regrettable that such a thing should ever be necessary, but the world is not a perfect place.
[08:57:00] juanpablo_: has joined #ruby
[08:57:26] CloCkWeRX: has joined #ruby
[08:57:48] devoldmx_: has joined #ruby
[08:58:07] TinkerTyper: has joined #ruby
[08:58:39] Xeago: has joined #ruby
[08:59:45] devoldmx_: has joined #ruby
[09:00:03] jbw: has joined #ruby
[09:00:11] Xeago_: has joined #ruby
[09:00:34] sharpmachine: has joined #ruby
[09:01:19] ddv: Ox0dea: provide a patch if you find it regrettable
[09:01:25] devoldmx: has joined #ruby
[09:01:28] peter_paule: has joined #ruby
[09:01:28] Karpah: has joined #ruby
[09:01:40] phale: has left #ruby: ("Leaving")
[09:01:54] Ox0dea: ddv: Pardon? I can't patch the fact that not everybody uses the most up-to-date version of the software they use.
[09:01:54] platzhirsch: has joined #ruby
[09:02:27] ddv: Ox0dea: nice straw man you put up there
[09:02:32] wallerdev: has joined #ruby
[09:03:09] balazs: has joined #ruby
[09:03:11] devoldmx: has joined #ruby
[09:03:30] Ox0dea: I suspect you've misinterpreted something I've said.
[09:03:44] dfockler: has joined #ruby
[09:03:52] last_staff: has joined #ruby
[09:04:59] devoldmx_: has joined #ruby
[09:05:13] Pupeno_: has joined #ruby
[09:06:06] doerteDev: has joined #ruby
[09:06:58] devoldmx: has joined #ruby
[09:08:36] devoldmx: has joined #ruby
[09:10:29] xrlabs: has joined #ruby
[09:10:33] devoldmx: has joined #ruby
[09:11:29] futilegames: has joined #ruby
[09:11:39] howdoicomputer: has joined #ruby
[09:11:56] hotpancakes: has joined #ruby
[09:12:04] zacstewart: has joined #ruby
[09:12:12] devoldmx_: has joined #ruby
[09:12:43] j4cknewt: has joined #ruby
[09:14:06] devoldmx: has joined #ruby
[09:14:29] astrobunny: has joined #ruby
[09:15:01] txdv: shevy: i do reside in germany
[09:15:23] txdv: im just running a server at my parents place cause the internet is cheap and good as fuck
[09:15:43] txdv: 100/100mbit for 15 euros a month
[09:15:57] devoldmx: has joined #ruby
[09:17:13] iszak: txdv: watch out for the ToS
[09:17:35] devoldmx: has joined #ruby
[09:18:37] djellemah: ACTION falls on floor laughing. 1m/8m ADSL for 50 euros per month over here.
[09:19:24] devoldmx: has joined #ruby
[09:20:00] JohnBat26: has joined #ruby
[09:21:06] Xeago: has joined #ruby
[09:21:12] devoldmx_: has joined #ruby
[09:21:51] tvw: has joined #ruby
[09:21:54] mister_s_: has joined #ruby
[09:22:29] jeanlinux: has joined #ruby
[09:23:06] devoldmx: has joined #ruby
[09:23:29] eGGsha: has joined #ruby
[09:24:02] olistik: has joined #ruby
[09:24:58] howdoicomputer: has joined #ruby
[09:26:02] astrobunny: has joined #ruby
[09:26:15] devoldmx_: has joined #ruby
[09:26:18] sgambino: has joined #ruby
[09:27:09] txdv: iszak: terms of service?
[09:27:13] yorickpeterse: 100/100 for 50/mnth :<
[09:27:23] yorickpeterse: though it's fiber
[09:27:41] txdv: i can get 500/150 for 25 euros
[09:28:04] ddv: I have 500/500 for 55 euros
[09:28:15] Rubie: has joined #ruby
[09:28:18] txdv: what country?
[09:28:23] devoldmx: has joined #ruby
[09:28:32] txdv: or a google city?
[09:28:35] ddv: netherlands
[09:28:49] txdv: i live like 5 km away from the netherlands
[09:29:04] zacstewart: has joined #ruby
[09:29:15] howdoicomputer: has joined #ruby
[09:29:26] bnagy: I hate you all
[09:29:32] bnagy: love from Kathmandu
[09:29:53] khorne: has joined #ruby
[09:29:56] GreatSUN: Ox0dea: thanks, that helped a lot
[09:30:21] devoldmx: has joined #ruby
[09:30:35] Ox0dea: GreatSUN: I'm looking into how best to do it with the RubyGems API.
[09:30:51] txdv: ddv: what provider?
[09:31:02] ddv: vodafone fiber
[09:32:01] devoldmx: has joined #ruby
[09:32:17] ta: has joined #ruby
[09:32:42] sdothum: has joined #ruby
[09:32:43] revath: has joined #ruby
[09:32:49] howdoicomputer: has joined #ruby
[09:32:53] bruno-: has joined #ruby
[09:33:32] Igorshp: has joined #ruby
[09:33:48] devoldmx: has joined #ruby
[09:33:57] mister_solo: has joined #ruby
[09:34:37] theahindle: bundler is to ruby what composer is to PHP?
[09:34:42] howdoicomputer: has joined #ruby
[09:34:49] jimms: has joined #ruby
[09:35:10] charliesome: has joined #ruby
[09:35:35] devoldmx: has joined #ruby
[09:35:39] bnagy: is composer a cancerous blight?
[09:37:31] devoldmx: has joined #ruby
[09:37:49] KetaPan: has joined #ruby
[09:38:00] adaedra: that's pretty subjective
[09:38:20] pandaant: has joined #ruby
[09:38:24] RegulationD: has joined #ruby
[09:39:14] VictorBjelkholm: has joined #ruby
[09:39:16] devoldmx: has joined #ruby
[09:41:08] devoldmx: has joined #ruby
[09:41:21] Indian: has joined #ruby
[09:41:49] jesterfraud: has joined #ruby
[09:42:16] lolmaus: has joined #ruby
[09:42:48] devoldmx_: has joined #ruby
[09:44:46] devoldmx: has joined #ruby
[09:45:32] peter_paule: has joined #ruby
[09:46:23] devoldmx: has joined #ruby
[09:46:53] Spami: has joined #ruby
[09:47:18] Rollabunna: has joined #ruby
[09:47:58] KetaPan: has left #ruby: ()
[09:47:59] withnale_: has joined #ruby
[09:48:22] devoldmx: has joined #ruby
[09:49:59] devoldmx: has joined #ruby
[09:50:08] zacstewart: has joined #ruby
[09:50:16] Pwnna: has joined #ruby
[09:51:49] devoldmx: has joined #ruby
[09:53:51] devoldmx: has joined #ruby
[09:55:27] howdoicomputer: has joined #ruby
[09:55:35] devoldmx: has joined #ruby
[09:55:41] _joes_: has joined #ruby
[09:55:52] charliesome: has joined #ruby
[09:55:57] peter_paule: has joined #ruby
[09:56:41] yorickpeterse: theahindle: they're similar yes
[09:57:23] devoldmx: has joined #ruby
[09:58:24] Olipro: has joined #ruby
[09:58:40] User458764: has joined #ruby
[09:58:44] Mighty: has joined #ruby
[09:59:00] devoldmx_: has joined #ruby
[09:59:40] lolmaus: has joined #ruby
[09:59:55] lordkryss: has joined #ruby
[10:00:48] devoldmx_: has joined #ruby
[10:01:38] Pupeno: has joined #ruby
[10:02:52] devoldmx: has joined #ruby
[10:03:02] revath: has joined #ruby
[10:04:13] eGGsha: has joined #ruby
[10:04:16] charliesome: has joined #ruby
[10:04:23] devoldmx_: has joined #ruby
[10:04:34] blackmesa: has joined #ruby
[10:05:05] fsvehla: has joined #ruby
[10:06:18] devoldmx_: has joined #ruby
[10:07:06] sharpmachine: has joined #ruby
[10:08:04] devoldmx: has joined #ruby
[10:08:56] krz: has joined #ruby
[10:09:47] ryba: has joined #ruby
[10:09:50] michael_mbp: has joined #ruby
[10:09:52] howdoicomputer: has joined #ruby
[10:09:59] devoldmx: has joined #ruby
[10:10:15] hotpancakes: has joined #ruby
[10:11:36] devoldmx: has joined #ruby
[10:11:52] zacstewart: has joined #ruby
[10:12:19] Ox0dea: has joined #ruby
[10:12:26] Ox0dea: GreatSUN: Still about?
[10:12:32] revath: has joined #ruby
[10:13:23] devoldmx: has joined #ruby
[10:14:14] Indian: has joined #ruby
[10:14:28] j4cknewt: has joined #ruby
[10:15:12] howdoicomputer: has joined #ruby
[10:15:22] devoldmx: has joined #ruby
[10:16:38] _blizzy_: has joined #ruby
[10:16:59] devoldmx: has joined #ruby
[10:17:29] Ox0dea: Well, for anybody who might ever need such a thing: https://gist.github.com/0x0dea/2eef9ab030ed8ef7574a
[10:18:47] devoldmx: has joined #ruby
[10:20:07] DaniG2k: has joined #ruby
[10:20:17] dorei: has joined #ruby
[10:20:28] rickmasta: has joined #ruby
[10:20:52] devoldmx: has joined #ruby
[10:21:25] Ox0dea: has joined #ruby
[10:22:22] revath: has joined #ruby
[10:22:26] devoldmx: has joined #ruby
[10:22:50] Ox0dea: Do you think it'd be worthwhile to add an "install most recent compatible version" option to the CLI?
[10:23:09] KetaPan: has joined #ruby
[10:23:25] GreatSUN: Ox0dea: well yes
[10:24:02] GreatSUN: Ox0dea: I just implemented something like this based on the output of gem -rv in my librarries
[10:24:11] devoldmx: has joined #ruby
[10:24:19] GreatSUN: Ox0dea: that's why I said thanks already
[10:24:27] Scroff: has joined #ruby
[10:24:40] GreatSUN: have to hurry now, hence I am late for an appointment, see ya later guys
[10:25:11] ahmetkapikiran: has joined #ruby
[10:26:00] devoldmx_: has joined #ruby
[10:26:05] Ox0dea: GreatSUN: Directly using the API is more sensible than parsing its output, but all right. I'm glad you got something working.
[10:26:30] _blizzy_: well, I finished the bot.
[10:26:48] howdoicomputer: has joined #ruby
[10:27:22] Ox0dea: _blizzy_: What sort of intelligence did you give it?
[10:27:47] devoldmx: has joined #ruby
[10:27:52] _blizzy_: Ox0dea, i'm not sure how to answer that question.
[10:28:13] Ox0dea: _blizzy_: It... battles, does it not?
[10:28:22] _blizzy_: Ox0dea, yes.
[10:29:21] r_rios: has joined #ruby
[10:29:36] devoldmx: has joined #ruby
[10:30:23] Ox0dea: _blizzy_: Well, does it just use its moves at random?
[10:30:25] pengin: has joined #ruby
[10:30:36] KrzaQ: has joined #ruby
[10:30:47] _blizzy_: Ox0dea, no, it checks for the strongest move, considering type matchup.
[10:31:10] _blizzy_: or, it'll switch out if it has a weak matchup.
[10:31:32] lkba: has joined #ruby
[10:31:34] devoldmx: has joined #ruby
[10:32:05] Ox0dea: If that's the extent of its thinking, I don't reckon it'll do very well. It's a start, of course.
[10:32:13] Akagi201: has joined #ruby
[10:32:27] Ox0dea: The metagame runs deep, my friend.
[10:33:14] devoldmx: has joined #ruby
[10:33:17] revath: has joined #ruby
[10:33:51] zacstewart: has joined #ruby
[10:35:12] devoldmx: has joined #ruby
[10:36:47] devoldmx: has joined #ruby
[10:38:07] howdoicomputer: has joined #ruby
[10:38:44] devoldmx: has joined #ruby
[10:39:39] khebbie: has joined #ruby
[10:39:42] ndrei: has joined #ruby
[10:40:23] devoldmx: has joined #ruby
[10:41:32] IanV0rn2341: has joined #ruby
[10:41:43] Rollabunna: has joined #ruby
[10:42:21] devoldmx: has joined #ruby
[10:42:30] Rubie: has joined #ruby
[10:42:47] Scroff: has joined #ruby
[10:43:18] lkba: has joined #ruby
[10:44:07] devoldmx: has joined #ruby
[10:44:56] sepp2k: has joined #ruby
[10:45:28] juanpablo_: has joined #ruby
[10:45:48] devoldmx: has joined #ruby
[10:47:22] shredding: has joined #ruby
[10:47:36] devoldmx_: has joined #ruby
[10:48:48] zacstewart: has joined #ruby
[10:48:50] startupality: has joined #ruby
[10:49:01] judofyr: has joined #ruby
[10:49:24] devoldmx: has joined #ruby
[10:51:12] devoldmx: has joined #ruby
[10:51:18] peter_paule: has joined #ruby
[10:51:51] thelastinuit: has joined #ruby
[10:52:39] fabrice31: has joined #ruby
[10:53:07] devoldmx: has joined #ruby
[10:53:36] hotpancakes: has joined #ruby
[10:54:59] devoldmx: has joined #ruby
[10:55:30] the_doc: has joined #ruby
[10:55:56] phutchins1: has joined #ruby
[10:56:22] kfpratt: has joined #ruby
[10:56:36] devoldmx: has joined #ruby
[10:56:54] judofyr: anyone here?
[10:57:32] judofyr: it's been a while since I've been to IRC. I mean, when I was IRC-ing we had both #ruby-lang *and* #ruby!
[10:58:28] devoldmx: has joined #ruby
[11:00:12] devoldmx_: has joined #ruby
[11:00:41] adaedra: Days since someone talked about the merge: 0
[11:00:51] sandstrom: has joined #ruby
[11:00:59] dionysus69: has joined #ruby
[11:01:20] judofyr: is it working out?
[11:01:22] judofyr: I guess so
[11:01:37] judofyr: why shouldn't it?
[11:01:48] judofyr: sooo. I'm supposed to do some stuff.
[11:01:57] judofyr: guess I'll have to do it.
[11:01:58] the_doc: first time for me also after LONG time in irc
[11:01:59] devoldmx: has joined #ruby
[11:02:26] txdv: irc used to big in my country
[11:02:36] howdoicomputer: has joined #ruby
[11:02:39] txdv: now everyone is using skype
[11:02:50] judofyr: oh well, that happens :)
[11:03:09] rodfersou: has joined #ruby
[11:03:17] txdv: biggest irc channel had like 3k people joining it
[11:03:43] judofyr: so, anyone doing anything interesting in Ruby these days?
[11:03:48] txdv: the amount of flood when we won in some international basket ball game was pushing the bandwith
[11:03:58] devoldmx: has joined #ruby
[11:04:08] judofyr: my Ruby experiences have basically plateaued
[11:04:13] judofyr: which is fair enough
[11:04:15] eGGsha: has joined #ruby
[11:04:26] balazs: has joined #ruby
[11:04:44] txdv: to the limit
[11:04:56] txdv: what is a ruby experience judofyr ?
[11:05:13] adaedra: ruby -e 'Experience'
[11:05:35] devoldmx: has joined #ruby
[11:05:51] judofyr: txdv: writing web apps in Rails/Sinatra/Camping/Padrino. writing/helping out with various template engines. hmm.
[11:06:12] Alina-malina: has joined #ruby
[11:06:21] Guest85: has joined #ruby
[11:06:34] skade: has joined #ruby
[11:06:36] txdv: the moment someone mentions ruby it almost usually is web related
[11:07:16] judofyr: yup. I'm actually using Python today. mostly because of numerical analysis. but I'm also hooking it up with a web server.
[11:07:22] judofyr: Flask is pretty nice
[11:07:27] devoldmx: has joined #ruby
[11:08:05] zacstewart: has joined #ruby
[11:08:43] judofyr: I use Ruby for two things these days: (1) web stuff (2) `pry` for calculations and/or basic text manupulations
[11:09:11] devoldmx: has joined #ruby
[11:09:24] sharpmachine: has joined #ruby
[11:09:33] revath: has joined #ruby
[11:09:38] Xeago: has joined #ruby
[11:10:03] ta: has joined #ruby
[11:10:17] Ox0dea: >> require 'prime'; 1267.prime?
[11:10:18] ruboto: Ox0dea # => false (https://eval.in/390338)
[11:10:24] Ox0dea: judofyr: What does it mean?!
[11:10:50] judofyr: ACTION contemplates
[11:11:06] judofyr: ACTION (whether he should reveal it or not)
[11:11:13] devoldmx_: has joined #ruby
[11:11:15] judofyr: ACTION (because then the mystery would be gone)
[11:11:41] Ox0dea: Is the dotted font of any significance?
[11:12:18] judofyr: it ought to have a space in there though: 12 67
[11:12:27] hotpancakes: has joined #ruby
[11:12:30] judofyr: and it's related to my full name
[11:12:43] abyss__: has joined #ruby
[11:12:48] devoldmx: has joined #ruby
[11:13:41] judofyr: meh, it's not a secret anyway
[11:13:48] judofyr: Ox0dea: look at the periodic table :)
[11:14:16] Ox0dea: Very clever.
[11:14:42] Ox0dea: I suspect very few people are able to do that.
[11:14:45] devoldmx: has joined #ruby
[11:14:56] Ox0dea: And now I don't feel anywhere near as special for having hexadecimal initials.
[11:15:30] Ox0dea: >> [13, 14].map { |n| 1267.to_s(n) }
[11:15:32] ruboto: Ox0dea # => ["766", "667"] (https://eval.in/390340)
[11:15:33] _blizzy_: everyone is special
[11:15:35] Ox0dea: judofyr: ^ Also kind of cool.
[11:16:01] bigkevmcd: has joined #ruby
[11:16:23] devoldmx: has joined #ruby
[11:17:43] skade: has joined #ruby
[11:17:49] revath: has left #ruby: ()
[11:18:22] devoldmx: has joined #ruby
[11:18:26] shevy: txdv ah ok; for some reason I thought you were northeast of germany
[11:19:51] txdv: shevy: i live in the most west possible spot in germany
[11:19:59] devoldmx: has joined #ruby
[11:20:46] shevy: oh, le france
[11:20:51] Xeago: has joined #ruby
[11:20:53] bruno-: has joined #ruby
[11:21:02] txdv: in germany
[11:21:15] txdv: well maybe second
[11:21:23] adaedra: They got Alsace and Lorraine again?
[11:21:42] txdv: yeah, the sneaky nazis did it again adaedra
[11:21:46] shevy: Lorraine... I don't think I have read that name before
[11:21:48] devoldmx: has joined #ruby
[11:22:00] shevy: I only know Lothringen :D
[11:22:06] adaedra: txdv: they did not wait WW2 to do that.
[11:22:46] txdv: poland still doesnt have a europ
[11:23:17] shevy: not many ruby hackers from poland here; more from the Ukraine than from poland
[11:23:36] devoldmx_: has joined #ruby
[11:23:38] ItSANgo: has joined #ruby
[11:23:43] txdv: why is ruby more popular in ukraine than in poland?
[11:23:54] adaedra: Poland prefers perl
[11:24:16] shevy: dunno, but they also have had some euroruby conf or so, which then got cancelled when they had the problem with russia
[11:25:11] diegoviola: has joined #ruby
[11:25:43] devoldmx_: has joined #ruby
[11:26:01] DoubleMalt: has joined #ruby
[11:26:02] zacstewa_: has joined #ruby
[11:26:20] judofyr: isn't solnic from Polan?
[11:26:20] Scrofff: has joined #ruby
[11:27:04] arup_r: shevy: how many cats you now have ?
[11:27:18] RegulationD: has joined #ruby
[11:27:24] mdw: has joined #ruby
[11:27:37] blackmesa: has joined #ruby
[11:27:38] devoldmx: has joined #ruby
[11:28:21] judofyr: Ox0dea: yeah, I was lucky with my initials.
[11:28:33] Ox0dea: judofyr: It's much more than your initials, though.
[11:28:34] shevy: arup_r only one hear; but 3 in the flat of my parents, and they can climb over rooftops so it's not far away, perhaps 60 metres via roof
[11:28:52] but3k4: has joined #ruby
[11:28:56] judofyr: Ox0dea: the other way around is cooler though: being able to spell your name with elements because they're named after you
[11:28:56] shevy: judofyr you are in Norway?
[11:28:58] judofyr: shevy: yes
[11:29:00] devoldmx_: has joined #ruby
[11:29:33] skade: has joined #ruby
[11:29:35] judofyr: "Holmium" is named after Stockholm IIRC, not a distant cousin of mine :(
[11:29:57] zacstewart: has joined #ruby
[11:30:01] judofyr: shevy: how so?
[11:30:32] shevy: dunno, I don't seem to see many from norway; lots of hackers in general from Germany; quite many from the UK and also Sweden... but norway and finland hmm
[11:30:33] serivich: has joined #ruby
[11:30:47] devoldmx_: has joined #ruby
[11:31:59] ldnunes: has joined #ruby
[11:32:05] judofyr: Aslak (of Cucumber fame) is from Norway :)
[11:32:05] tobiasvl: Norway here o/
[11:32:11] judofyr: and tobiasvl of course!
[11:32:14] tobiasvl: of course!!!
[11:32:20] judofyr: never forget tobiasvl
[11:32:24] tobiasvl: how can anyone forget me
[11:32:28] Peteykun: has joined #ruby
[11:32:38] judofyr: I was actually tab-ing "rolfb", but he's maybe not IRC-ing at the moment
[11:32:42] shevy: I thought tobiasvl is from germany
[11:32:45] devoldmx: has joined #ruby
[11:33:02] tobiasvl: weird indeed
[11:33:07] shevy: must be the name "Tobias" that tricked me
[11:33:14] mikecmpb_: has joined #ruby
[11:33:47] ralku: has joined #ruby
[11:33:47] judofyr: hai ljarvis
[11:33:55] ljarvis: ohai judofry
[11:34:02] ljarvis: how's things?
[11:34:05] judofyr: fine fine!
[11:34:12] judofyr: working hard (or hardly working)
[11:34:24] ljarvis: How's the nim?
[11:34:32] devoldmx: has joined #ruby
[11:34:42] judofyr: slowly working on Bob, but haven't got much progress lately
[11:34:50] judofyr: also been playing with C++ and OpenGL lately
[11:35:45] Rollabunna: has joined #ruby
[11:36:01] ljarvis: C++ after Nim. That's a true tragedy story there
[11:36:13] devoldmx_: has joined #ruby
[11:36:23] judofyr: different use-cases though :)
[11:36:43] skade: has joined #ruby
[11:37:01] Xeago: has joined #ruby
[11:37:16] judofyr: I pretty much have to finish Bob in order to speed up the compilation of my C++ project though :)
[11:37:24] Indian: has joined #ruby
[11:37:30] judofyr: (this is Bob btw: https://github.com/judofyr/bob)
[11:37:43] renderful: has joined #ruby
[11:38:01] devoldmx: has joined #ruby
[11:38:02] judofyr: ljarvis: Nim is amazing for Bob btw. because it has so good C compat. you can call macros in C headers as they were regular functions.
[11:38:42] ljarvis: I did a really small amount of nim and I really liked what I saw, just don't have time for it at the moment
[11:38:47] ljarvis: bob looks good
[11:39:08] judofyr: (if anyone else wonders: https://github.com/judofyr/bob)
[11:39:55] Guest85: has joined #ruby
[11:40:00] devoldmx: has joined #ruby
[11:40:47] judofyr: next step for Bob is to implement the actually "updating from a dependency database". which is kinda tricky because I need to (1) find files that have changes (2) run commands and (3) handle changes from the commands
[11:41:04] stoodfarback: has joined #ruby
[11:42:05] devoldmx: has joined #ruby
[11:42:43] judofyr: the C++ project is using ImGui: https://github.com/ocornut/imgui
[11:42:47] judofyr: which is actually really nice
[11:43:04] judofyr: immediate mode is a very nice way to handle GUIs
[11:43:24] judofyr: I've actually been thinking about experimenting with a JavaScript approach
[11:43:39] devoldmx_: has joined #ruby
[11:44:13] judofyr: oh, and I tried to add Skia (2D drawing library used in Google Chrome) to my C++ project: it requires 700MB of source code and eventually took 1.7GB after compilation.
[11:44:19] michael_mbp: has joined #ruby
[11:44:29] judofyr: (that is, the whole folder. haven't checked how big the library actually is)
[11:44:39] judofyr: pretty crazy
[11:45:10] Shoutsid: has joined #ruby
[11:45:11] Scroff: has joined #ruby
[11:45:16] devoldmx: has joined #ruby
[11:45:23] Xeago: has joined #ruby
[11:46:00] skade: has joined #ruby
[11:46:13] juanpablo_: has joined #ruby
[11:46:14] mdw: has joined #ruby
[11:46:29] shevy: what is that
[11:46:49] judofyr: it bundles everything
[11:46:55] y0da: has joined #ruby
[11:46:56] judofyr: it builds liblua, libnanomsg
[11:47:03] devoldmx: has joined #ruby
[11:47:17] judofyr: libjsoncpp
[11:47:42] judofyr: 1GB of compiled files
[11:47:44] senayar: has joined #ruby
[11:48:09] judofyr: statically compiled libraries wo-hoo!
[11:48:51] langlands: has joined #ruby
[11:49:04] freerobby: has joined #ruby
[11:49:10] devoldmx: has joined #ruby
[11:49:11] apeiros: judofyr: bobs readme has "Depenedency"
[11:49:50] judofyr: apieros: yeah. dependencies on Linux is a bit different I guess
[11:50:14] abyss: has joined #ruby
[11:50:18] shevy: you mean depenedencies
[11:50:28] apeiros: judofry: oh, so they're called depenedence there? :)
[11:50:32] shevy: depentencies
[11:50:53] devoldmx: has joined #ruby
[11:51:01] senayar: has joined #ruby
[11:51:03] shevy: judofyr the swiss are a very correct people, so this typo is like a mortal offence!
[11:52:04] blackmesa: has joined #ruby
[11:52:30] devoldmx: has joined #ruby
[11:52:30] judofyr: I haven't got automatic Text Replacement to work after tab-completion, so I actually have to write "apieros" out by hand
[11:52:49] shevy: the greek apieros dude
[11:52:52] shevy: he hasn't been here in ages
[11:53:18] shevy: wait... judofyr you actually mean, you did indeed mispell apeiros back then?
[11:53:32] judofyr: shevy: I've been misspelling apieros for years
[11:54:01] ljarvis: apieros and judofry
[11:54:06] ljarvis: and some guy called inkjet
[11:54:21] tobiasvl: don't people tab complete
[11:54:21] judofyr: #ruby-lang/2010-01-01_irc.freenode.net.txt: 223:22:33 Judofyr: right apieros?
[11:54:26] devoldmx: has joined #ruby
[11:54:34] judofyr: ah, inkjet
[11:54:40] ljarvis: tobiasvl: it's a running joke now
[11:54:47] ljarvis: judofyr: rip
[11:55:13] judofyr: #ruby-lang/2010-12-15_irc.freenode.net.txt: 18:20 Judofyr: inkjet *is* a nice one though
[11:55:29] ljarvis: into the history of awful aliases he goes
[11:55:40] judofyr: jlarvis works
[11:55:58] shevy: 5 years ago
[11:56:05] shevy: even from a channel that no longer exists, thanks to jhass!
[11:56:10] devoldmx: has joined #ruby
[11:56:35] Brom: has joined #ruby
[11:56:42] shevy: jlarvis... jerome larvis... ljarvis ... leeroy jarvis ... hmm
[11:56:53] judofyr: 2010-01-01 is actually the oldest log I have on this machine
[11:57:01] chipotle: has joined #ruby
[11:57:14] krz: has joined #ruby
[11:57:22] dgutierrez1287: has joined #ruby
[11:57:46] judofyr: so yeah, apieros might be even older
[11:58:00] devoldmx: has joined #ruby
[11:58:02] judofyr: actually: 22:33 Judofyr: erihk: we're good at nick mutilations here
[11:58:07] judofyr: so yeah, it's even older
[11:59:04] shevy: good old erikh
[11:59:20] shevy: he was the ruby-midi guy or? the one with the keyboard
[11:59:26] chinmay_dd: has joined #ruby
[11:59:39] atomical_: has joined #ruby
[11:59:46] devoldmx_: has joined #ruby
[12:00:27] judofyr: I liked him thoug
[12:01:02] ljarvis: erik is cool. He's gone the way of the gopher
[12:01:35] devoldmx: has joined #ruby
[12:02:45] Xeago_: has joined #ruby
[12:03:36] devoldmx: has joined #ruby
[12:04:30] eGGsha: has joined #ruby
[12:05:16] devoldmx: has joined #ruby
[12:06:56] zotherstupidguy: has joined #ruby
[12:07:02] devoldmx: has joined #ruby
[12:08:01] djellemah: has joined #ruby
[12:08:59] devoldmx_: has joined #ruby
[12:09:52] Jackneill: has joined #ruby
[12:10:07] sharpmachine: has joined #ruby
[12:10:41] devoldmx_: has joined #ruby
[12:11:03] hotpancakes: has joined #ruby
[12:11:13] aamador: has joined #ruby
[12:11:40] ndrei: has joined #ruby
[12:12:28] devoldmx: has joined #ruby
[12:13:52] skade: has joined #ruby
[12:14:16] allomov: has joined #ruby
[12:14:16] devoldmx_: has joined #ruby
[12:15:22] pandaant: has joined #ruby
[12:16:23] devoldmx: has joined #ruby
[12:17:54] devoldmx: has joined #ruby
[12:18:13] JDiPierro: has joined #ruby
[12:18:16] sgambino: has joined #ruby
[12:19:44] devoldmx: has joined #ruby
[12:20:17] Jackneill: has joined #ruby
[12:20:56] Xeago: has joined #ruby
[12:21:17] yorickpeterse: amazed nobody messed up my name so far
[12:21:23] yorickpeterse: (that I can remembeR)
[12:21:32] devoldmx: has joined #ruby
[12:21:57] mister_solo: has joined #ruby
[12:23:20] devoldmx_: has joined #ruby
[12:23:54] jhass: that's because it's so long that everybody is like "oh fck it, there must be tab com... oh hey it works!"
[12:25:09] devoldmx: has joined #ruby
[12:25:58] Ox0dea: 2015-06-29 10:05:03 consmans oops also yorikpeterse and sevenseacat
[12:26:44] sdwrage: has joined #ruby
[12:26:48] pontiki: "if you need something screwed up, call shevy" ??
[12:27:07] devoldmx_: has joined #ruby
[12:27:47] allomov_: has joined #ruby
[12:27:57] SOLDIERz: has joined #ruby
[12:28:08] senayar^: has joined #ruby
[12:28:45] shevy: my ruby code usually works!
[12:28:46] devoldmx: has joined #ruby
[12:29:12] txdv: i want to see your .bash_aliases file
[12:29:35] shevy: I can assure you that it is way too boring to read
[12:29:36] bougyman: my code only works for me
[12:29:43] bougyman: if someone else tries to run it... never.
[12:29:51] shevy: for instance, one alias is "rb" which is an alias to "ruby"
[12:29:53] pontiki: now there's security
[12:30:01] txdv: shevy: you got 5k of them
[12:30:07] txdv: of course a single one is boring
[12:30:11] Rollabunna: has joined #ruby
[12:30:13] txdv: the accumultaion of so many is the interesting part
[12:30:14] pontiki: i have an alias "gacp"
[12:30:29] shevy: it just grows over a time span of +10 years txdv!
[12:30:31] GarethAdams: has joined #ruby
[12:30:40] m4rCsi: has joined #ruby
[12:30:42] devoldmx: has joined #ruby
[12:30:44] bougyman: shevy: same, here.
[12:30:48] bougyman: but I still don't have too many.
[12:30:53] bougyman: most recently added: alias ????????='hdmi'
[12:30:59] shevy: yeah, new additions here slowed down tremendously
[12:31:23] bougyman: for when my kbd is in ru-mode.
[12:31:40] txdv: lol bougyman
[12:31:54] txdv: so basically the russian letters which happen to be there
[12:32:00] Ox0dea: alias ws="(tr '\na-z' '\0-\32' | od -An -td1 -w1 | paste -sd + | bc) <<<"
[12:32:07] txdv: "????????" is probably nonsense
[12:32:25] txdv: what does paste do
[12:32:27] devoldmx_: has joined #ruby
[12:32:29] shevy: the russians should adopt latin character set
[12:32:45] howdoicomputer: has joined #ruby
[12:33:14] bougyman: txdv: yeah, when I unsuspend sometimes my laptop monitor is all black and the hdmi doesn't engage, so i'm typing 'in the blind'
[12:33:18] Igorshp: has joined #ruby
[12:33:30] bougyman: I was so frustrated one day, typing hdmi over and over again
[12:34:17] devoldmx_: has joined #ruby
[12:34:22] Xeago: has joined #ruby
[12:34:59] bougyman: .til I realized i'd been typing ????????
[12:35:04] kobain: has joined #ruby
[12:36:01] devoldmx: has joined #ruby
[12:36:06] pontiki: better living through aliases
[12:36:54] Scrofff: has joined #ruby
[12:37:22] Ox0dea: My one prints its argument's "word sum".
[12:37:32] rbennacer: has joined #ruby
[12:37:53] devoldmx: has joined #ruby
[12:38:56] Ox0dea: I compulsively add up words throughout the day, and I like to be able to quickly check that I got it right.
[12:39:39] devoldmx: has joined #ruby
[12:40:04] tkuchiki_: has joined #ruby
[12:40:14] Ox0dea: This is a little neurotic, but I actually don't use that alias; my command_not_found_handle() does the same thing.
[12:40:26] a346: has joined #ruby
[12:41:29] ta: has joined #ruby
[12:41:39] devoldmx: has joined #ruby
[12:43:09] RegulationD: has joined #ruby
[12:43:17] devoldmx_: has joined #ruby
[12:43:37] khebbie: has joined #ruby
[12:43:56] Rubie: has joined #ruby
[12:45:15] devoldmx: has joined #ruby
[12:46:39] ahmetkapikiran: has joined #ruby
[12:46:53] lxsameer: has joined #ruby
[12:46:53] lxsameer: has joined #ruby
[12:46:55] devoldmx: has joined #ruby
[12:46:58] jhass: +b *!~devoldmx@*$#ruby-fix-your-connection
[12:48:50] Xeago: has joined #ruby
[12:51:23] freerobby: has joined #ruby
[12:52:25] futilegames: has joined #ruby
[12:54:24] Guest85: has joined #ruby
[12:55:28] tvb: has joined #ruby
[12:55:46] ndrei: has joined #ruby
[12:56:00] avahey: has joined #ruby
[12:56:06] El3k0n: has joined #ruby
[12:56:16] malconis: has joined #ruby
[12:59:42] allomov: has joined #ruby
[12:59:53] tkuchiki_: has joined #ruby
[13:00:45] futilegames: has joined #ruby
[13:01:50] Igorshp: has joined #ruby
[13:02:32] zacstewa_: has joined #ruby
[13:02:43] sankaber: has joined #ruby
[13:03:26] victortyau: has joined #ruby
[13:04:10] but3k4: has joined #ruby
[13:04:26] intyl: has joined #ruby
[13:04:47] j4cknewt: has joined #ruby
[13:06:20] balazs: has joined #ruby
[13:08:07] jhooker: has joined #ruby
[13:09:01] dblessing: has joined #ruby
[13:09:08] griffindy: has joined #ruby
[13:09:46] jimms: has joined #ruby
[13:10:58] sharpmachine: has joined #ruby
[13:11:15] lolmaus: has joined #ruby
[13:11:16] failshell: has joined #ruby
[13:11:45] bmurt: has joined #ruby
[13:11:56] momomomomo: has joined #ruby
[13:12:06] swills: has joined #ruby
[13:12:48] judofyr: this image I'm working on has *negative* (gray-scale) color values
[13:13:01] judofyr: (it's actually an output from an electron microscope)
[13:13:06] judofyr: how is that even legal in TIFF?
[13:13:15] judofyr: everything seems to be legal in TIFF
[13:13:20] hotpancakes: has joined #ruby
[13:14:10] blueOxigen: has joined #ruby
[13:14:14] casadei_: has joined #ruby
[13:14:27] lva_: has joined #ruby
[13:16:26] cashnguns: has joined #ruby
[13:17:00] Akagi201: has joined #ruby
[13:17:14] anisha: has joined #ruby
[13:18:08] Akagi201_: has joined #ruby
[13:19:21] senayar: has joined #ruby
[13:19:37] bullcitydev: has joined #ruby
[13:20:25] jlast: has joined #ruby
[13:20:51] khebbie: has joined #ruby
[13:20:52] xrlabs: has joined #ruby
[13:20:53] jlast_: has joined #ruby
[13:20:56] gamename: has joined #ruby
[13:21:05] CloCkWeRX: has joined #ruby
[13:21:23] kfpratt: has joined #ruby
[13:21:54] dgutierrez1287: has joined #ruby
[13:24:23] Rollabunna: has joined #ruby
[13:24:33] jpfuentes2: has joined #ruby
[13:25:13] Aryasam: has joined #ruby
[13:25:28] eGGsha: has joined #ruby
[13:25:28] gamename: has joined #ruby
[13:25:58] eggoez: has joined #ruby
[13:26:42] sevenseacat: has joined #ruby
[13:26:47] zacstewart: has joined #ruby
[13:26:51] tkuchiki_: has joined #ruby
[13:29:31] Rollabunna: has joined #ruby
[13:31:24] brain_shim: has joined #ruby
[13:31:35] havenwood: has joined #ruby
[13:31:52] chthon: has joined #ruby
[13:32:44] tkuchiki_: has joined #ruby
[13:33:01] rickmasta: has joined #ruby
[13:33:22] startupality: has joined #ruby
[13:33:29] howdoicomputer: has joined #ruby
[13:33:31] yorickpeterse: ho ho ho, hacking YARD's linking system
[13:33:35] yorickpeterse: so I can embed my own {fooobar} links
[13:33:43] yorickpeterse: one day I'm going to regret this
[13:33:58] jerius: has joined #ruby
[13:34:20] skade: has joined #ruby
[13:34:27] jhass: your last sentence lacks the "in" in front
[13:35:45] juanpablo_: has joined #ruby
[13:36:02] gamename: has joined #ruby
[13:36:24] arup_r1: has joined #ruby
[13:36:35] enebo: has joined #ruby
[13:36:44] shevy: judofyr cool, what kind of electron microscope? cryo-electronmicoscopy? on organic samples?
[13:38:27] _kfpratt: has joined #ruby
[13:38:44] krz: has joined #ruby
[13:39:35] platzhirsch: Default way of having a ruby server run at startup on Linux? init.d?
[13:39:54] bnizzle: has joined #ruby
[13:40:47] adaedra: init.d, systemd, upstart, launchd, whatever floats your system
[13:41:12] Kellin: has joined #ruby
[13:41:15] oddjob001: has joined #ruby
[13:41:47] oddjob001: hey all. how can I get the last line of output from an external command? Say you are simply running something like dir, or some command that gives ouput. How do I grab just the last line of that? Its not in a file
[13:41:57] shevy: oddjob001 result = `dir`
[13:42:05] shevy: last line, you can split that
[13:42:19] shevy: then .last
[13:42:27] oddjob001: ah so just split on the last /n because that would get me everything after it
[13:42:32] oddjob001: yes ok. thanks shevy
[13:43:04] shevy: yeah kinda; you may have to add a bit more code though perhaps, for instance, if that command fails, or does not exist, then handling result takes a bit more code
[13:43:12] adaedra: you can use each_line instead of split
[13:43:28] shevy: What I do often is to use this too: 2>&1, such as: result = `ruby -v 2>&1`
[13:43:29] jhass: or simply .lines.last
[13:43:42] adaedra: ah, lines, I was looking too far :p
[13:43:44] oddjob001: .lines.last really...
[13:43:53] shevy: result = `ruby -v 2>&1` # => "ruby 2.2.2p95 (2015-04-13 revision 50295) [x86_64-linux]\n"
[13:43:54] oddjob001: woo ill try it.
[13:44:03] shevy: result = `rubye -v 2>&1` # => "sh: 1: rubye: not found\n"
[13:44:06] RegulationD: has joined #ruby
[13:44:19] shevy: I have no rubye!
[13:44:26] jhass: shevy: make an alias
[13:44:32] shevy: haha... hmm
[13:44:48] shevy: actually I do have one for that :)))
[13:45:11] Igorshp: has joined #ruby
[13:45:13] Rubie: has joined #ruby
[13:45:47] whippythellama: has joined #ruby
[13:45:48] kfpratt: has joined #ruby
[13:46:04] oddjob001: jhass: worked perfectly. super simple too. thanks
[13:46:51] Scroff: has joined #ruby
[13:47:25] startupality: has joined #ruby
[13:47:33] rbennacer: has joined #ruby
[13:47:53] rbennacer: has joined #ruby
[13:48:10] fabrice31: has joined #ruby
[13:48:11] chinmay_dd: has joined #ruby
[13:48:33] hinbody: has joined #ruby
[13:49:35] zacstewart: has joined #ruby
[13:49:42] oddjob001: so jhass is there an easy way to get one line above that? the last line appears to be blank in most instances, returning an empty result
[13:50:58] jhass: oddjob001: .lines returns an array
[13:51:09] jhass: you can do whatever array operations on it
[13:51:23] i8igmac: has joined #ruby
[13:51:30] jhass: (like .reject'ing .strip.empty? lines...)
[13:51:34] shevy: oddjob001 [-1] and [-2] and [-3], just as you cant [0] and [1] and [2] from an Array
[13:51:41] shevy: erm; cant == count
[13:51:46] shevy: the heat here is killing me
[13:52:01] oddjob001: ok. makes sense. I am newish to ruby. thanks both fo you
[13:52:46] NeverDie: has joined #ruby
[13:53:49] Muhannad: has joined #ruby
[13:54:10] axl__: has joined #ruby
[13:54:53] ebbflowgo: has joined #ruby
[13:58:48] Scrofff: has joined #ruby
[14:00:54] fmcgeough: has joined #ruby
[14:01:04] msnyon: has joined #ruby
[14:01:32] Igorshp: has joined #ruby
[14:02:05] jhooker: has joined #ruby
[14:02:31] last_staff: has joined #ruby
[14:03:38] Indian: has joined #ruby
[14:03:45] Indian: has joined #ruby
[14:07:15] kies^: has joined #ruby
[14:07:33] revoohc: has joined #ruby
[14:07:55] failshell: has joined #ruby
[14:08:02] findaway: has joined #ruby
[14:08:28] jlast: has joined #ruby
[14:10:47] zacstewart: has joined #ruby
[14:11:17] Kully3xf: has joined #ruby
[14:11:25] Kully3xf: how do I loop a dynamic amount of times with for
[14:11:32] Kully3xf: i.e. ask user for how many times to loop
[14:11:40] Kully3xf: then for i in 0..loop do
[14:11:47] sevenseacat: you dont use for loops in ruby
[14:11:48] sharpmachine: has joined #ruby
[14:12:28] Kully3xf: what should I use to loop?
[14:13:10] juanpablo_: has joined #ruby
[14:13:13] fantasticsid: has joined #ruby
[14:13:23] sevenseacat: times, each, etc.
[14:13:24] jpfuentes2: has joined #ruby
[14:13:30] Darkwater: Kully3xf: if you really need to loop a set number of times, the most ruby way to do it is to loop through a range I guess
[14:13:35] hotpancakes: has joined #ruby
[14:13:39] genpaku: has joined #ruby
[14:13:48] adaedra: var.times do ... end
[14:13:51] yokel: has joined #ruby
[14:14:07] Darkwater: it really depends on what you want
[14:14:19] Darkwater: 5.times do something end # does something 5 times
[14:14:21] jhass: loop do; stuff; break if condition; end; if stuff determines whether you'll continue
[14:14:23] sevenseacat: for loops should be removed from the language.
[14:14:35] Darkwater: (5..10).each do |n| puts n end # puts 5, 6, 7, 8, 9, 10
[14:14:43] ljarvis: meh, I think *all* we should have is for loops
[14:15:04] Darkwater: but in real applications you'd use stuff like arr.each
[14:15:06] jhass: Darkwater: 5.upto(10) do |n|
[14:15:09] adaedra: meh, I think we remove everything and just use gotos.
[14:15:10] ljarvis: Darkwater: pointless range object is pointless
[14:15:27] ljarvis: +1 adaedra
[14:15:34] heftig: ljarvis: that's what the infant murderer is for
[14:15:34] Papierkorb: has joined #ruby
[14:15:42] ljarvis: heftig: for loops?
[14:15:51] heftig: shortlived objects
[14:16:07] ljarvis: that's a bit dark
[14:16:08] ljarvis: but i agree
[14:16:28] momomomomo: has joined #ruby
[14:17:13] Macaveli: has joined #ruby
[14:17:17] Darkwater: speaking of ruby, a few days ago I wrote this:
[14:17:18] Darkwater: if event[:criteria].each_pair.all? { |key, value| msg[key] == value }
[14:17:25] Darkwater: (ew damn that indenting sorry)
[14:17:40] davedev24_: has joined #ruby
[14:17:51] Darkwater: checks if msg has the same keys (and matching values) as event[:criteria]
[14:18:07] ljarvis: event[:criteria].all?
[14:18:16] Darkwater: it's a hash
[14:19:39] Darkwater: ah, didn't know that'd work
[14:19:39] jhass: please say either side is a superset of the other...
[14:19:41] Ox0dea: Darkwater: Um... Hash#==?
[14:19:46] jhass: because else it's just ==
[14:19:47] Darkwater: yeah, that's exactly what it checks
[14:20:03] Darkwater: it's not going to be equal
[14:20:21] Darkwater: msg will be a superset of the matching event criteria
[14:21:30] ljarvis: anyway, surely you can just use merge(other) == hash if you're checking for subsets
[14:21:50] Ox0dea: msg.to_set.superset?(event[:criteria].to_set)
[14:21:54] Ox0dea: Probably overkill, though.
[14:22:03] ljarvis: yeah I thought that too, agreed on overkill
[14:22:17] charliesome: has joined #ruby
[14:22:54] ivanskie: has joined #ruby
[14:23:03] adaedra: overkill is best kill
[14:23:32] Darkwater: hm, I'll use sets then
[14:23:36] Darkwater: don't want it to look too hacky
[14:23:41] Spami: has joined #ruby
[14:23:52] jhass: .all? is fine (if you strip the .each_pair.)
[14:24:22] rdar: has joined #ruby
[14:24:22] ljarvis: yeah I'd use that over sets
[14:24:33] ljarvis: or, use sets in the first place
[14:24:39] Ox0dea: Darkwater: It doesn't look hacky, you're just doing the wrong thing. :)
[14:24:44] ljarvis: but im guessing you want hashes
[14:24:53] Darkwater: yeah otherwise defining them would look ugly
[14:24:53] Ox0dea: Why not msg.merge(event[:criteria]) == msg?
[14:25:00] Darkwater: Ox0dea: it'
[14:25:02] jhass: maybe just annotate or extract (def matches?(msg, criteria))
[14:25:05] Darkwater: s a superset, they're not equal
[14:25:12] Ox0dea: Read again.
[14:25:13] ljarvis: ACTION points at ljarvis> anyway, surely you can just use merge(other) == hash if you're checking for subsets
[14:25:21] Darkwater: oh right, but that just looks ugly imo
[14:25:25] jhass: Ox0dea: unnecessary intermediate
[14:25:27] Darkwater: doesn't explain what it does
[14:25:39] Ox0dea: It explains what it does if you know what Hash#merge and Hash#== do...
[14:25:45] Maletor: has joined #ruby
[14:25:48] Ox0dea: ljarvis: Sorry, not sure how I missed you having already suggested it.
[14:25:49] _joes_: has joined #ruby
[14:26:00] dopie: has joined #ruby
[14:26:01] chipotle: has joined #ruby
[14:26:02] ljarvis: I think all? is the best anyway
[14:26:17] Darkwater: I'm not trying to merge anything, I want to check something
[14:26:22] Guest85: has left #ruby: ("Textual IRC Client: www.textualapp.com")
[14:26:39] anjen: has joined #ruby
[14:26:44] Ox0dea: I grant that the #all? approach certainly reads better.
[14:27:05] Ox0dea: And yes, unnecessary intermediates are not best intermediates.
[14:28:21] ryba: has joined #ruby
[14:28:25] jude90: has joined #ruby
[14:28:29] sei_: has joined #ruby
[14:28:45] Ox0dea: Hm... why does Hash#each_pair exist?
[14:29:07] jhass: because somebody thought it's a good idea at some point?
[14:29:13] jhass: you're the one with the 0.49 Ruby
[14:29:25] penzur: has joined #ruby
[14:29:39] Darkwater: because hash.each { |k, v| } isn't obvious, at least not to newcomers maybe?
[14:29:54] Ox0dea: What else could it possibly mean?
[14:30:00] ljarvis: there's each_key and each_value I guess they wanted to complete the list of uneccesary methods
[14:30:17] zacstewart: has joined #ruby
[14:30:34] jhass: heh those are useful
[14:30:39] Xeago: has joined #ruby
[14:30:46] jude90: Has anyone patched a monkey patched to a activerecord adapter ?
[14:30:48] ljarvis: yeah i know i was being spiteful
[14:30:53] eggoez: has joined #ruby
[14:31:05] Ox0dea: jude90: Please try again.
[14:31:13] ruboto: Just ask your question, if anyone has or can, they will respond.
[14:31:21] ruboto: We can't help you without your code, please post it to https://gist.github.com
[14:33:13] Darkwater: each_key/value are useful imo
[14:33:24] zotherstupidguy: has joined #ruby
[14:33:45] zotherstupidguy: has joined #ruby
[14:34:29] momomomomo: has joined #ruby
[14:34:37] howdoicomputer: has joined #ruby
[14:34:42] s2013: has joined #ruby
[14:35:13] Soda: has joined #ruby
[14:35:31] yorickpeterse: my favourite is people using "i"
[14:37:05] Kully3xf: how can I concatinate a dynamic integer on to this
[14:37:05] Kully3xf: http://pasted.co/ffc57f73
[14:37:22] Kully3xf: i.e. if I ask what number, then put that number onto that
[14:37:33] dling`: has joined #ruby
[14:37:52] Pisuke: has joined #ruby
[14:38:03] Ox0dea: Kully3xf: What resource(s) are you using to learn Ruby?
[14:38:16] jude90: I want to change some method of ActiveRecord::ConnectionAdapters::PostgreSQL::SchemaStatements . someone suggests me using a monkey patch . when i write a rb script that override some methods , I don't know how to load it in rails
[14:38:23] Kully3xf: nothing - I have a script I need to make loop. Never used ruby before
[14:38:30] Kully3xf: i'm a python guy
[14:38:31] Mia: has joined #ruby
[14:38:31] Mia: has joined #ruby
[14:38:37] chthon: has joined #ruby
[14:38:45] jlast_: has joined #ruby
[14:38:59] Spami_: has joined #ruby
[14:39:03] momomomomo: jude90: 99% of the time, a monkey patch is a bad idea
[14:39:06] momomomomo: what are you trying to do?
[14:39:15] casadei__: has joined #ruby
[14:39:24] adaedra: And 60% of the time, it works all the time
[14:39:28] chouhoul_: has joined #ruby
[14:39:28] lacrosse_: has joined #ruby
[14:39:30] rho45dium_: has joined #ruby
[14:39:32] spastorino_: has joined #ruby
[14:39:42] Scroff: has joined #ruby
[14:39:43] deavidsedice: has joined #ruby
[14:39:48] Wobbley_: has joined #ruby
[14:39:51] skmp_: has joined #ruby
[14:39:52] justinmcp: has joined #ruby
[14:39:58] Indian: has joined #ruby
[14:40:20] avdi_: has joined #ruby
[14:40:21] bb010g_: has joined #ruby
[14:40:25] ramblinpeck_: has joined #ruby
[14:40:28] dukedave_: has joined #ruby
[14:40:29] RegulationD: has joined #ruby
[14:40:29] tobyx_: has joined #ruby
[14:40:50] saintcajetan_: has joined #ruby
[14:40:56] claws: has joined #ruby
[14:41:00] JoshL: has joined #ruby
[14:41:01] hagebake: has joined #ruby
[14:41:02] benlakey_: has joined #ruby
[14:41:04] crowell_: has joined #ruby
[14:41:05] tonini_: has joined #ruby
[14:41:08] kapowaz_: has joined #ruby
[14:41:09] joaomdmoura_: has joined #ruby
[14:41:19] anisha: has joined #ruby
[14:41:20] rikai_: has joined #ruby
[14:41:21] ltd_: has joined #ruby
[14:41:26] parus_: has joined #ruby
[14:41:29] lotherk_: has joined #ruby
[14:41:31] multi_io_: has joined #ruby
[14:41:37] kalleth_: has joined #ruby
[14:41:39] crankhar1er: has joined #ruby
[14:41:42] Nirgali43: has joined #ruby
[14:41:44] chihhsin_: has joined #ruby
[14:41:46] heftig_: has joined #ruby
[14:41:47] angelixd: has joined #ruby
[14:41:48] Mattias: has joined #ruby
[14:41:48] hostess_: has joined #ruby
[14:41:53] ptierno_: has joined #ruby
[14:41:57] izzol2: has joined #ruby
[14:41:58] cscheib_: has joined #ruby
[14:41:59] ejnahc_: has joined #ruby
[14:42:00] lnx_: has joined #ruby
[14:42:01] Nigel__: has joined #ruby
[14:42:08] dstarh: has joined #ruby
[14:42:09] major_ma1ors: has joined #ruby
[14:42:11] TvL: has joined #ruby
[14:42:12] Sypheren_: has joined #ruby
[14:42:12] graft_: has joined #ruby
[14:42:12] graft_: has joined #ruby
[14:42:14] sivoais_: has joined #ruby
[14:42:17] rfi_: has joined #ruby
[14:42:18] Darkwater: what's happening
[14:42:23] ec\_: has joined #ruby
[14:42:26] gigetoo_: has joined #ruby
[14:42:43] Ox0dea: ~ $ whatis happening
[14:42:44] shevy: Darkwater the sun is shining and it kills me
[14:42:45] Ox0dea: happening: nothing appropriate.
[14:42:49] emdub_: has joined #ruby
[14:43:01] camilasann: has joined #ruby
[14:43:03] rodferso1: has joined #ruby
[14:43:12] shevy: Kully3xf simplest way would be like this: loop { puts 'Hello world!'; sleep 1; exit if rand(6) == 0 }
[14:43:29] patronus_: has joined #ruby
[14:43:34] jeanlinux: has joined #ruby
[14:43:42] abbec: has joined #ruby
[14:43:54] Kully3xf: I got the loop to work - but I have this section that's creating the name tag for an AWS instance, and I need to include the loop number in the name
[14:43:55] zero7_: has joined #ruby
[14:43:57] Heero_: has joined #ruby
[14:44:06] Kully3xf: and I can't figure out how to concatinante the loop number into the variable name
[14:44:14] stacktracer: has joined #ruby
[14:44:16] Ox0dea: Kully3xf: Are you using #times?
[14:44:23] slash_nick: >> loop { puts 'Hello world!'; exit if rand(6) == 0 }
[14:44:24] ruboto: slash_nick # => Hello world! ...check link for more (https://eval.in/390441)
[14:44:36] shevy: you can keep track of the current run of the loop; what is the way to call or use the AWS instance?
[14:44:37] Ox0dea: slash_nick: People don't do that; it has the potential to never terminate.
[14:44:42] Ox0dea: s/People/Please/
[14:44:45] duper`: has joined #ruby
[14:45:04] unsymbol_: has joined #ruby
[14:45:05] vikram____: has joined #ruby
[14:45:10] soulcake: has joined #ruby
[14:45:17] luzidco_: has joined #ruby
[14:45:21] danshultz_: has joined #ruby
[14:45:22] jhass|off: has joined #ruby
[14:45:22] Junaos_: has joined #ruby
[14:45:27] DanKnox_: has joined #ruby
[14:45:27] JaTochNietDan_: has joined #ruby
[14:45:28] DANtheBE-: has joined #ruby
[14:45:29] universal: has joined #ruby
[14:45:31] kkh: has joined #ruby
[14:45:35] retornam_: has joined #ruby
[14:45:35] Scotteh: has joined #ruby
[14:45:41] duckson_: has joined #ruby
[14:45:48] Aeyrix_: has joined #ruby
[14:45:56] slash_nick: an ever more infinitesimal potential, the longer it runs
[14:46:07] Rixius|Alt: has joined #ruby
[14:46:10] Ox0dea: It would nevertheless be quite unkind of you to send ruboto chasing after his tail till kingdom come.
[14:46:17] Ox0dea: Whatever the odds.
[14:46:25] slash_nick: aw he's protected, is he not?
[14:46:28] Ox0dea: Yes, he is.
[14:46:33] Kully3xf: http://pasted.co/9d4de8f3
[14:46:44] kalzz_: has joined #ruby
[14:46:53] shevy: counter = 0; loop { counter += 1; sleep 1; puts "Hello #{counter}"; exit if rand(12) == 0 }
[14:46:53] kalzz: has joined #ruby
[14:47:05] shevy: the servers variable keeps the number?
[14:47:09] Riking: has joined #ruby
[14:47:16] Ox0dea: slash_nick: Why does Kernel.rand become more likely to return 0 the more times you call it?
[14:47:18] Kully3xf: that is what I have so far - need to loop through dependant on how many servers the user wants to create and then concatinate the number on the :hn => 'ae1aimis'
[14:47:25] Kully3xf: yes servers should keep the number
[14:47:29] shevy: I am not quite sure where your loop is there actually
[14:47:35] Kully3xf: it's not in that version
[14:47:43] Kully3xf: that version just asks a user how many times they want but only makes one
[14:48:03] davidcelis: has joined #ruby
[14:48:03] davidcelis: has joined #ruby
[14:48:13] stephenh: has joined #ruby
[14:48:13] EvilJStoker: has joined #ruby
[14:48:34] iamdevnul: has joined #ruby
[14:48:43] tsvenson: has joined #ruby
[14:48:44] kent\n: has joined #ruby
[14:48:45] kent\n: has joined #ruby
[14:48:45] slash_nick: Ox0dea: it's the probability of drawing !0 x times consecutively as x goes to infinity?
[14:48:54] Kully3xf: should change the name at the bottom instance[:hn].upcase from ae1 to ae11 and ae12 and ae13 etc
[14:49:07] crowell: has joined #ruby
[14:49:20] x3cion: has joined #ruby
[14:49:30] jlast: has joined #ruby
[14:49:32] haasn`: has joined #ruby
[14:49:34] Ox0dea: slash_nick: Isn't that the gambler's fallacy?
[14:49:48] werelivinginthef: has joined #ruby
[14:50:03] mary5030: has joined #ruby
[14:50:07] shevy: Kully3xf you have your counter somewhere, right? let's say it is that i variable
[14:50:21] codeitagile: has joined #ruby
[14:50:21] dseitz: has joined #ruby
[14:50:29] Darkwater: the probability of that loop never ending is about 1 / (6 * infinity), is it not?
[14:50:30] shevy: not sure where you increment it, but let's ignore that for the moment; the i variable then already has the number that you want
[14:50:44] slash_nick: Ox0dea: (6/7)^n, no?
[14:50:51] shevy: so you only need to keep track of it as part of the hash, the key that is :hn
[14:50:55] mburns: has joined #ruby
[14:51:19] shevy: Kully3xf in your example, the leading "ae" part of the string seems to remain constant, so only the counter changes
[14:51:34] tflat: has joined #ruby
[14:51:38] shevy: so you'd have: data[:int] = [ { :subnet => 'subnet-9', :hn
[14:51:44] slash_nick: Ox0dea: it'd be 6/7^(infinity), the probability of never exiting that
[14:51:45] Ox0dea: slash_nick: rand is exclusive, so that should be (5/6), but I'm still not sure it applies.
[14:51:45] shevy: hmm actually... why do you use an Array there?
[14:51:55] dblessing: has joined #ruby
[14:52:06] vcoinminer: has joined #ruby
[14:52:06] slash_nick: Ox0dea: it's like drawing with replacement... or rolling dice
[14:52:19] Guest85414______: has joined #ruby
[14:52:38] shevy: Kully3xf anyway, [:hn] = 'ae'+counter.to_s or "ae#{counter}"; in your case, the variable i, if that is the counter variable (though I don't see where you use any variable that increments)
[14:52:41] CustosLimen: has joined #ruby
[14:52:45] beilabs_: has joined #ruby
[14:52:48] ndrst: has joined #ruby
[14:52:49] bascht: has joined #ruby
[14:52:59] certainty: has joined #ruby
[14:53:02] soulcake: has joined #ruby
[14:53:07] Ox0dea: slash_nick: Having rolled !12 the previous trillion rolls does not make the next roll any more likely to be 12.
[14:53:07] mandarinkin: has joined #ruby
[14:53:14] elliottcable: has joined #ruby
[14:53:15] slash_nick: Ox0dea: http://mathcentral.uregina.ca/QQ/database/QQ.09.06/s/matt1.html
[14:53:15] atom3: has joined #ruby
[14:53:15] noobQ: has joined #ruby
[14:53:16] soulcake: has joined #ruby
[14:53:17] kies^: has joined #ruby
[14:53:18] marcoamorales: has joined #ruby
[14:53:33] slash_nick: Ox0dea: it's not the probability of each roll... it's the probability that ALL of them will be !0
[14:53:47] ballPointPenguin: has joined #ruby
[14:53:51] Encapsulation: has joined #ruby
[14:53:52] Kully3xf: so to_s works
[14:53:57] Tarential: has joined #ruby
[14:54:15] shevy: yeah, or you use #{} which should be faster, because + will create a new object
[14:54:49] bigkevmcd: has joined #ruby
[14:55:02] GGMethos: has joined #ruby
[14:55:02] Kully3xf: that's great. I'll give that a shot thank you so much
[14:55:16] torpig: has joined #ruby
[14:55:18] judofyr: shevy: if that's your bottleneck you sure have some optimized code :)
[14:55:33] shevy: the whole of ruby is a bottleneck!!!
[14:55:45] slash_nick: Ox0dea: each sampling is a 6/7 chance of not being 0... that's true. but the odds of getting not zero twice in a row is (6/7)(6/7)... it's just statistics junk, everyone hates it
[14:55:48] shevy: until mruby will come to rule this world
[14:55:50] holsee_: has joined #ruby
[14:55:57] nobitanobi: has joined #ruby
[14:56:04] Ox0dea: slash_nick: Why are you still using 6/7?
[14:56:14] slash_nick: Ox0dea: it's what I used with ruboto
[14:56:20] slash_nick: rand(6) == 0
[14:56:33] Ox0dea: rand(6) will never return 6.
[14:56:44] frode15243: has joined #ruby
[14:56:47] slash_nick: then that's the fallacy :)
[14:56:58] zipkid: has joined #ruby
[14:57:16] Ox0dea: I confess that I was mostly being contrarian.
[14:57:21] jeanlinux: has joined #ruby
[14:57:22] Guest85: has joined #ruby
[14:57:37] slash_nick: my stats were right, my ruby was wrong :D
[14:57:49] ESpiney: has joined #ruby
[14:58:04] Ox0dea: I think I would be entertained by watching a loop that had a 16% chance of terminating just... never do so.
[14:58:19] atom3: has joined #ruby
[14:58:22] xrlabs: has joined #ruby
[14:58:36] AlexRussia: has joined #ruby
[14:58:53] slash_nick: Ox0dea: but... it's 16%^n where n is number of loops
[14:58:55] judofyr: slash_nick: hm. the odds of getting not zero twice in a row wouldn't be (6/7)(6/7), but (1 - (1/7)(1/7)), right?
[14:58:58] slash_nick: ACTION covers face
[14:59:39] jlyndon: has joined #ruby
[14:59:40] shevy: all I know is... the more possibilities, the lesser the chance to win in lottery
[15:00:04] rippa: has joined #ruby
[15:00:05] cstrahan: has joined #ruby
[15:00:47] cbednarski: has joined #ruby
[15:00:50] Xeago: has joined #ruby
[15:01:06] shevy: so who thinks that this is a good API:
[15:01:10] shevy: table.attach(frame, x, x + 1, y, y + 1, Gtk::EXPAND | Gtk::FILL | Gtk::SHRINK, Gtk::EXPAND | Gtk::FILL | Gtk::SHRINK, 0, 0)
[15:01:22] Regulati_: has joined #ruby
[15:01:25] sharpmachine: has joined #ruby
[15:01:28] judofyr: for C, yes
[15:01:37] delianides: has joined #ruby
[15:01:43] shevy: yeah kinda true
[15:01:53] gambl0re: has joined #ruby
[15:02:00] judofyr: the bit-set is a bit odd
[15:02:05] bestie: has joined #ruby
[15:02:15] judofyr: [:expand, :fill, :shrink, :expand] seems more Ruby-like
[15:02:22] zacstewart: has joined #ruby
[15:02:23] shevy: you are right!
[15:02:39] khebbie: has joined #ruby
[15:02:45] jxf: has joined #ruby
[15:03:02] judofyr: Ruby???: Why not waste a dynamic allocation for something that can be solved with a single byte?
[15:03:09] ndrei: has joined #ruby
[15:03:28] _ixti_: has joined #ruby
[15:03:30] akitada: has joined #ruby
[15:03:34] judofyr: Answer: Because everything is so slow it doesn't matter \o/
[15:03:43] judofyr: (not saying this is a bad thing)
[15:04:05] SuperTux88: has joined #ruby
[15:04:15] shevy: ah, the two entries for Gtk::EXPAND are for x-row and y-row; in html this should be sorta similar to <tr><td> and some cellspacing or cellpadding value
[15:04:20] jbw: has joined #ruby
[15:04:48] senayar: has joined #ruby
[15:04:53] howdoi: has joined #ruby
[15:05:19] atomical: has joined #ruby
[15:05:34] carlosoliveira: has joined #ruby
[15:05:38] toddperkinz: has joined #ruby
[15:05:57] Trieste: has joined #ruby
[15:06:00] thesheff17: has joined #ruby
[15:06:19] pawz: has joined #ruby
[15:06:28] soahccc: has joined #ruby
[15:07:10] alekst_: has joined #ruby
[15:07:16] shevy: (important upon resize events)
[15:07:28] phrozen77: has joined #ruby
[15:07:29] shevy: so I guess it's not exactly the same as in HTML :(
[15:07:32] _whitelogger: has joined #ruby
[15:07:44] balazs_: has joined #ruby
[15:07:46] drPoggs: has joined #ruby
[15:07:48] elektronaut: has joined #ruby
[15:07:50] jhass: granted, it's kinda hard to come up with a good syntax for enums
[15:08:39] Kully3xf: has joined #ruby
[15:08:46] sivoais: has joined #ruby
[15:08:51] RegulationD: has joined #ruby
[15:09:04] Xeago_: has joined #ruby
[15:09:15] sandstrom: has joined #ruby
[15:10:57] hotpancakes: has joined #ruby
[15:11:27] shevy: perhaps I should do it like hanmac and use wxwidgets
[15:11:29] bauruine: has joined #ruby
[15:11:48] prestorium: has joined #ruby
[15:11:50] slash_nick: Ox0dea: This has a 1/6 chance of never exiting... verrry different: https://gist.github.com/rthbound/7c7692a920137d2ff2f4
[15:12:10] adaedra: shevy: use the MFCs
[15:12:21] slash_nick: Ox0dea: whoops... 1/6 chance of exiting,e ver
[15:14:03] shadoi: has joined #ruby
[15:18:16] radialneon: has joined #ruby
[15:18:54] _kfpratt: has joined #ruby
[15:19:26] startupality: has joined #ruby
[15:19:34] vyorkin: has joined #ruby
[15:19:34] renderful: has joined #ruby
[15:20:52] allomov: has joined #ruby
[15:21:24] ebbflowgo: has joined #ruby
[15:21:35] dfockler: has joined #ruby
[15:22:04] heyimwill: has joined #ruby
[15:23:04] jamesaxl: has joined #ruby
[15:23:10] shevy: hanmac what's up with ya, haven't read from you in years
[15:24:18] zacstewart: has joined #ruby
[15:24:23] failshell: im trying to test if a file is ruby code or not. i tried 'file foo' but that says its ASCII text. is there a way to test a file to figure out if it's ruby code or not? its for a git pre-commit
[15:24:48] judofyr: failshell: try to parse it with the parser gem
[15:25:03] jhass: or simply whitelist on name/extension
[15:25:11] judofyr: there's also a Ruby-flags which checks for syntax
[15:25:12] skade: has joined #ruby
[15:25:32] eggoez: has joined #ruby
[15:25:38] judofyr: ruby -c foo.rb # => Syntax OK
[15:25:38] revath: has joined #ruby
[15:25:39] kfpratt: has joined #ruby
[15:25:54] judofyr: doesn't mean it *actually* is a Ruby file though
[15:26:07] judofyr: (as intended by the author)
[15:26:16] failshell: yeah it says a regular file has a correct syntax
[15:26:18] stoodfarback: failshell: Check out github's linguist: https://github.com/github/linguist
[15:26:19] frenda: has joined #ruby
[15:26:36] frenda: Hi there; Which one is better to install ruby on linux (Fedora): 1. by package manager 2. via RVM?
[15:26:40] Kully3xf_: has joined #ruby
[15:26:48] frenda: RVM: https://www.digitalocean.com/community/tutorials/how-to-install-ruby-on-rails-on-ubuntu-12-04-lts-precise-pangolin-with-rvm
[15:26:52] jhass: frenda: what are you installing ruby for?
[15:27:04] judofyr: (I've found ruby-install easier to use)
[15:27:05] shinnya: has joined #ruby
[15:27:08] jhass: are you going to need specific or multiple versions?
[15:27:09] stoodfarback: It's what github uses for language statistics, but you can use it to get the info of a single file as well.
[15:27:18] frenda: jhass: To run this app: https://github.com/catarse/catarse
[15:27:29] jerius: has joined #ruby
[15:27:29] Kully3xf_: has joined #ruby
[15:28:04] Ox0dea: "Cat arse"?
[15:28:11] k3asd`: has joined #ruby
[15:28:27] snockerton: has joined #ruby
[15:28:28] langlands: has joined #ruby
[15:28:41] JDiPierro: has joined #ruby
[15:29:00] Pupeno: has joined #ruby
[15:29:09] Kully3xf_: thanks for the help on my last problem, now I have a question I'm not sure if it's possible, but each one of the jobs I'm spawing in the loop takes 30+ minutes, if I have to do 40 of them that's too long
[15:29:24] Kully3xf_: how can I make it so instead of a loop, it spawns them all as individual jobs
[15:29:39] frenda: Ox0dea: I don't know! its developer are from Brazil; It's an opensource crowdfunding platform like www.indiegogo.com
[15:30:10] frenda: I think it means sth in ES
[15:30:46] jhooker: has joined #ruby
[15:31:14] jhass: frenda: you'll probably be fine with the system ruby, though they seem to test only against 2.2.2
[15:31:36] mister_solo: has joined #ruby
[15:32:26] frenda: I asked about best process to install ruby on Fedora!
[15:32:30] jhass: frenda: but I'd try the system (= package manager) ruby and replace the bundle install step with bundle install --deployment --without development test
[15:33:05] tacotaco_: has joined #ruby
[15:33:15] tacit7: has joined #ruby
[15:33:25] woodruffw: has joined #ruby
[15:33:41] frenda: jhass: Ah, What happens whith your replacement code?
[15:33:49] bluOxigen: has joined #ruby
[15:33:49] frenda: `bundle install --deployment --without development test`
[15:33:52] sankaber: has joined #ruby
[15:33:57] Regulati_: has joined #ruby
[15:34:08] ndrei: has joined #ruby
[15:34:13] jhass: the --without stuff only skips installing a whole bunch of deps you ain't gonna need in production
[15:34:28] frenda: I prefer guys here to use `` when you drop a code!
[15:34:29] jhass: --deployment makes it so you don't install dependencies to a local site dir
[15:34:41] Rubie: has joined #ruby
[15:34:43] jhass: er, don't install them system wide but to a local site dir I meant to write
[15:35:02] jhass: frenda: and then you have people who copy them when running it ;)
[15:35:16] sandstrom: has joined #ruby
[15:35:23] rcvalle: has joined #ruby
[15:35:26] howdoicomputer: has joined #ruby
[15:35:34] jhass: mmh, meh, actually their Gemfile even forces 2.2.2
[15:35:41] revdan: has joined #ruby
[15:36:17] frenda: They will give an error in their machine; then they solve it, next time, they won't copy it! though I hate copy-pasting codes!
[15:36:30] vyorkin: has joined #ruby
[15:36:32] jhass: oh, but fedora 22 already has 2.2.2 <3
[15:36:55] shevy: faster than debian!
[15:37:13] frenda: 2.2.2 --> this the version on my machine
[15:37:25] jeanlinux: has joined #ruby
[15:37:52] frenda: shevy: Fedora is more cutting edge!
[15:38:13] shevy: I sorta don't really know actually, I ended up compiling from source like an idiot :(
[15:38:19] shevy: but using ruby scripts \o/
[15:38:26] txdv: why is fedora more cutting edge?
[15:38:31] frenda: Moving on the edge of technology!
[15:38:56] ta: has joined #ruby
[15:39:01] frenda: txdv: They are usually the first to test new technologies
[15:39:22] Agoldfish: has joined #ruby
[15:39:32] txdv: As in? the most recent versions of software?
[15:39:42] langlands: has joined #ruby
[15:39:44] txdv: i thought ubuntu was
[15:39:54] jhass: txdv: you're trolling again...
[15:40:00] navs__: yea hence the name, they use versions of software you probably havent heard of
[15:40:13] frenda: I mean technologies, not new update! to have new updates instantly, I think Archlinux is the best
[15:40:37] navs__: gentoo is best linux
[15:40:47] ruboto: this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related problems. Thanks!
[15:40:54] ruboto: this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related problems. Thanks!
[15:41:30] chinmay_dd: has joined #ruby
[15:42:08] txdv: jhass: no, im not
[15:42:13] ndrei: has joined #ruby
[15:42:25] txdv: i use ubuntu because the ruby packages are newer than on debian!
[15:42:30] jhass: txdv: no arguing
[15:42:33] momomomomo: has joined #ruby
[15:43:31] mrmargolis: has joined #ruby
[15:44:42] txdv: jhass: you are speaking false words and i can't even defend myself against that
[15:44:48] txdv: stop opressing me
[15:44:51] [H]unt3r: has joined #ruby
[15:44:52] jhass: !mute txdv
[15:44:52] ruboto: +q txdv!*@*
[15:44:52] ruboto: -o ruboto
[15:44:59] jhass: take it elsewhere
[15:45:36] bakednotfried: has joined #ruby
[15:45:36] bakednotfried: has joined #ruby
[15:45:40] frenda: jhass: I used dnf (default package manager) to install ruby --> Total download size: 4.1 M Installed size: 13 M |||| I doubt it is a complete version of ruby; Is 4MB normal?!
[15:46:03] jhass: frenda: we'll find out, just proceed for now
[15:46:03] adaedra: dnf? sounds like fedora, they love to split things in small packages
[15:46:10] miah: sounds like its compressed
[15:46:23] miah: the download size being 4mb, the installed size being 13mb
[15:47:01] NeverDie: has joined #ruby
[15:47:04] miah: i will say that my ruby 2.2.2 build is 85mb. but maybe the fedora package has split things up into like, ruby-dev, ruby-doc, etc.
[15:47:19] ndrei: has joined #ruby
[15:47:21] frenda: adaedra: These are installed packages: http://pastie.org/10268376
[15:47:48] adaedra: looks right to me
[15:48:35] delianides: has joined #ruby
[15:49:21] jhass: 21M for Ruby and 24M for the docs here
[15:49:44] jhass: but yeah, fedora splits a ton out of the upstream distribution
[15:49:45] frenda: miah: ruby-* http://pastie.org/10268379
[15:50:44] NeverDie: has joined #ruby
[15:50:58] vyorkin1: has joined #ruby
[15:52:06] krasnus: has joined #ruby
[15:52:10] hotpancakes: has joined #ruby
[15:52:17] frenda: has left #ruby: ()
[15:54:38] delianides: has joined #ruby
[15:54:59] ndrei: has joined #ruby
[15:55:05] droidburgundy: has joined #ruby
[15:55:06] diegoviola: has joined #ruby
[15:55:18] diegoviola: has joined #ruby
[15:55:28] mrmargol_: has joined #ruby
[15:55:30] baweaver: has joined #ruby
[15:56:57] fantasticsid: has joined #ruby
[15:57:00] allomov_: has joined #ruby
[15:58:19] shevy: poor txdv
[15:58:27] shevy: he always gets the whip, from apeiros and jhass :D
[15:59:02] towski_: has joined #ruby
[15:59:03] jhass: shevy: join #ruby-banned if you want to discuss it
[15:59:14] shevy: oh why, will you ban me?
[15:59:16] theRoUS: which is considered better practice: putting defs into a modules eigenclass, or declaring them as module_function()s ?
[15:59:23] allomov__: has joined #ruby
[15:59:24] jhass: shevy: if you don't follow that, yes
[15:59:31] shevy: oh ok please don't ban me
[16:00:19] jhass: theRoUS: ruby core uses module_function (which copies them to the singleton class), so there's that
[16:00:45] nobitanobi: has joined #ruby
[16:00:47] fantasti`: has joined #ruby
[16:01:25] theRoUS: jhass: aha. how about module-level attributes (not to be inherited via include) ?
[16:01:53] diegoviola: has joined #ruby
[16:02:22] jhass: I'd probably document that the module is not meant to be included or at least document that it'll use these variables when it is
[16:02:43] JCOE: has joined #ruby
[16:03:13] thumpba: has joined #ruby
[16:03:16] theRoUS: jhass: i've got one that is both supposed to be included (provide methods) *and* have module-wide variables
[16:03:52] bigkevmcd: has joined #ruby
[16:03:55] jhass: mh, sounds a bit fishy, could you share it?
[16:04:25] casadei_: has joined #ruby
[16:04:30] bigkevmcd: has joined #ruby
[16:05:07] theRoUS: jhass: not conveniently nor without embarrassment :-P
[16:05:14] j4cknewt: has joined #ruby
[16:05:15] jobewan: has joined #ruby
[16:05:25] jhass: nah, don't worry about the latter ;P
[16:07:04] fmcgeough: has joined #ruby
[16:07:36] lancetw: has joined #ruby
[16:07:42] sulky: has joined #ruby
[16:09:38] hotpancakes: has joined #ruby
[16:10:04] vickleton: has joined #ruby
[16:10:23] jpfuente_: has joined #ruby
[16:10:35] blueOxigen: has joined #ruby
[16:10:46] ferr: has joined #ruby
[16:10:57] DexterLB: has joined #ruby
[16:11:48] msgodf: has joined #ruby
[16:12:15] spider-mario: has joined #ruby
[16:14:34] zendrix: has joined #ruby
[16:14:39] atom3: has joined #ruby
[16:14:53] sandstrom: has joined #ruby
[16:16:21] rbennacer: has joined #ruby
[16:16:47] wallerdev: has joined #ruby
[16:18:32] ndrei: has joined #ruby
[16:18:46] micmus: has joined #ruby
[16:20:05] Alayde: has joined #ruby
[16:20:29] jerius: has joined #ruby
[16:20:32] griffindy: has joined #ruby
[16:20:36] s2013: has joined #ruby
[16:22:32] mrmargolis: has joined #ruby
[16:24:22] RobertBirnie: has joined #ruby
[16:24:37] Spami_: has joined #ruby
[16:24:42] eggoez: has joined #ruby
[16:27:32] Alayde_: has joined #ruby
[16:28:13] bigkevmcd: has joined #ruby
[16:28:51] bricker: has joined #ruby
[16:28:55] fabrice31: has joined #ruby
[16:28:56] shevy: https://github.com/chneukirchen/styleguide/blob/master/RUBY-STYLE any parts where anyone would disagree with (the specific style there)?
[16:29:28] shevy: I think rubocop adheres to a slightly different one but I am not sure.
[16:30:51] jhass: rubocop adheres to the one of it's author, bbatsov
[16:31:01] jhass: in its default config that is
[16:31:17] jhass: didn't you post that one before?
[16:31:22] shevy: ok let's see https://github.com/bbatsov/ruby-style-guide
[16:31:29] shevy: I am unaware of differences between these two
[16:32:08] shevy: I shall vigorously note down the differences into a new file \o/
[16:32:52] Senjai: Good morning ruby
[16:33:12] zacstewart: has joined #ruby
[16:34:25] shevy: nobody says hi... hi Senjai!
[16:34:41] Senjai: I always say hi? Or do you mean back?
[16:34:46] Spami_: has joined #ruby
[16:34:58] Senjai: Occassionally I get a bregruding nod from jhass.
[16:35:08] eam: shevy: WHAT'S UP
[16:35:32] jhass: THE SKY OR ELSE WE ALL WOULD MOSTLY LIKELY BE DEAD
[16:35:40] jhass: uhm, I mean
[16:35:46] judofyr: has joined #ruby
[16:36:09] podman: has joined #ruby
[16:36:09] howdoicomputer: has joined #ruby
[16:36:13] uber: has joined #ruby
[16:36:53] shevy: eam dunno, not much up yet... working on some biology thing (biopython has Restriction.EcoRI.site # => 'GAATTC' which I find pretty cool, -> http://biopython.org/DIST/docs/cookbook/Restriction.html#mozTocId101269 ) ... and comparing different ruby style guides... which will take a while before it's finished ...
[16:37:26] olistik: has joined #ruby
[16:37:39] judofyr: shevy: what kind of bio are you doing?
[16:37:39] hotpancakes: has joined #ruby
[16:38:59] zacstewart: has joined #ruby
[16:39:10] eam: shevy: neat. I'm writing a blog 'cuz Senjai reminded me I've been super slacking
[16:39:17] eam: (it's about ruby and Timeout)
[16:39:24] Senjai: ACTION cracks the wip
[16:39:25] yfeldblum: has joined #ruby
[16:39:31] eam: I see what you did there
[16:39:37] eam: it is indeed a WIP
[16:40:02] Senjai: I totally wish that was an intentional spelling error
[16:40:05] jpfuentes2: has joined #ruby
[16:40:16] eam: we'll just pretend it was and credit you for cleverness
[16:41:01] Senjai: ACTION is clever, bow
[16:41:32] rbennacer: has joined #ruby
[16:42:32] Rubie: has joined #ruby
[16:44:14] pengin: has joined #ruby
[16:44:16] DCameronMauch: has joined #ruby
[16:45:02] blackmesa: has joined #ruby
[16:45:51] Tarkers34: has joined #ruby
[16:45:56] phat4life: eam: what are you using to blog
[16:46:18] khebbie: has joined #ruby
[16:46:19] phat4life: currenlty, im use jekyll, but it doesn't have all of what i need
[16:46:20] blue_deref: has joined #ruby
[16:46:24] Tarkers34: Hello all...can I mix and index and a regex to manipulate a string?
[16:46:55] sharpmachine: has left #ruby: ()
[16:47:02] revath: has joined #ruby
[16:47:17] apeiros: Tarkers34: that's a bit vague
[16:47:40] jhass: Tarkers34: post your input and the output you desire, use gist.github.com if that takes more than 3 lines of text
[16:47:51] jhass: also post your existing attempts
[16:47:53] Tarkers34: thanks both
[16:48:07] Asher: has joined #ruby
[16:48:11] judofyr: >> "123 hello 123".match(/\d+/, 5)
[16:48:13] ruboto: judofyr # => #<MatchData "123"> (https://eval.in/390539)
[16:48:20] judofyr: >> "123 hello 456".match(/\d+/, 5)
[16:48:21] ruboto: judofyr # => #<MatchData "456"> (https://eval.in/390540)
[16:48:43] judofyr: (wild guess)
[16:48:52] judofyr: (at least it's related to index and regexes)
[16:49:03] jhass: ACTION pats judofyr's back
[16:49:21] judofyr: it's not really "manipulate" though
[16:49:54] jhass: you got 2/3, it's fine. Not everybody can be perfect
[16:50:28] Tarkers34: I'm not great at regex...do you see what I mean though? abcdefg@xyz.index_and_regex( 2, /[f].*(@)/) #=> "cdefg@"
[16:50:35] dreinull75: has left #ruby: ("undefined")
[16:50:58] Tarkers34: sorry, this: abcdefg@xyz.index_and_regex( 2, /.*(@)/) #=> "cdefg@"
[16:51:06] j4cknewt: has joined #ruby
[16:51:24] judofyr: >> "abcdefg@xyz".match(/.*@/, 2)
[16:51:25] ruboto: judofyr # => #<MatchData "cdefg@"> (https://eval.in/390541)
[16:51:30] jhass: any non fake data?
[16:51:34] judofyr: Tarkers34: ^
[16:51:47] Tarkers34: judofyr, thanks that should do it :)
[16:51:53] judofyr: jhass: hah! I was right!
[16:51:56] jhass: you might be hiding a pattern in it that leads to a nicer pattern
[16:52:01] judofyr: 2/3 still wins
[16:52:41] Tarkers34: how cool would it be to integrate irb with an irc somehow? :P
[16:52:45] jpfuente_: has joined #ruby
[16:52:52] Senjai: >> puts "hi"
[16:52:53] ruboto: Senjai # => hi ...check link for more (https://eval.in/390542)
[16:52:56] Senjai: Tarkers34: ^
[16:53:05] shevy: judofyr dunno really, just trying to see what bioperl and biopython can offer, and what bioruby lacks
[16:53:18] judofyr: Tarkers34: ruboto is nice. only one command though.
[16:53:22] wildroman2: has joined #ruby
[16:53:27] judofyr: (e.g. it's not an interactive shell)
[16:53:40] Senjai: judofyr: Yeah, but why would you ever need an interactive shell in irc
[16:53:42] Senjai: just use irb
[16:53:58] judofyr: I mostly use eval.in for examples
[16:54:00] shevy: so that others can see how clever you are :)))
[16:54:03] Senjai: >> print "one command"; print "two command"
[16:54:04] ruboto: Senjai # => one commandtwo commandnil (https://eval.in/390543)
[16:54:12] casadei_: has joined #ruby
[16:54:27] hotpancakes: has joined #ruby
[16:54:35] eam: phat4life: company blog so not my choice, and it does use jekyll
[16:54:36] shevy: for quick one-liners demo purpose, ruboto is awesome
[16:54:45] hotpancakes: has joined #ruby
[16:55:18] phat4life: eam: i am hosting my jekyll blog on github pages, i have a heroku backend ednpoint for sendgrid, i am also going to use heroku for elastic searc
[16:55:25] Tarkers34: judofyr yeah ruboto is fun. I think github is working on some sort of irc killer...might be cool. Pastebin will literally loose all of their custom overnight x,D
[16:55:34] phat4life: eam: but i need to write a ruby plugin to index everything
[16:55:40] judofyr: Tarkers34: there's Gitter.im
[16:55:46] Tarkers34: that's the one
[16:55:56] judofyr: I want Github to focus on creating a better mailing list system
[16:56:04] judofyr: although I guess Discourse is taking over that
[16:56:32] Senjai: phat4life: use aws man
[16:56:41] Senjai: or digital ocean
[16:56:43] phat4life: that costs money
[16:56:50] Senjai: Like $5-10 a month
[16:56:55] phat4life: github pages is free
[16:56:56] eam: if it were up to me I'd just use markdown and a makefile
[16:57:06] MatthewsFace: has joined #ruby
[16:57:21] Senjai: eam: A coworker does that
[16:57:40] phat4life: well, i have a layout that just has json of all the content i want to index
[16:57:41] Senjai: eam: I want a bit more heavy of a blog so.. yeah.
[16:58:21] miah: i use jekyll
[16:58:22] phat4life: is there an alternative to jekyll that stores the markdown fiels in a db?
[16:58:27] MatthewsFace: has joined #ruby
[16:58:36] miah: why would you want the db dependency?
[16:58:44] jlast: has joined #ruby
[16:58:59] miah: simple html text is great, because my webserver can load it all into memory
[16:59:14] phat4life: i guess if you wanted a rails backend
[16:59:20] eam: or not even copy it into memory, with zero-copy
[16:59:39] eam: filesystems are great databases for reading (not so much for writing)
[16:59:58] jhooker: has joined #ruby
[17:00:12] judofyr: writing is fine as well. searching on the the other hand.
[17:00:14] [H]unt3r: has joined #ruby
[17:00:20] phat4life: yeah searching, paginating, tagging
[17:00:35] eam: judofyr: writing a file to a filesystem is going to be much slower than inserting a row into a table
[17:00:43] miah: you can have all that without rails
[17:00:56] eam: (or unlinking a file)
[17:01:05] phat4life: but doing that stuff with purely jekyll, not as easy
[17:01:12] judofyr: eam: that only means your database doesn't store things on disk
[17:01:15] eam: judofyr: nope
[17:01:17] ivanskie: has joined #ruby
[17:01:18] s2013: has joined #ruby
[17:01:28] eam: judofyr: it's because a posix filesystem specifies all sorts of serialization points
[17:01:39] eam: whereas a sql database does not
[17:01:44] miah: my site has archiving and tagging. i don't care about search because Google does that already.
[17:01:50] eam: eg rename() is an atomic operation
[17:01:57] judofyr: eam: and how does a database ensure persistence, if not by writing to the disk?
[17:01:58] miah: plus my site loads in less than a second
[17:02:02] phat4life: miah: i want ajax type ahead though
[17:02:14] eam: judofyr: it writes to disk, but there is not a file-per-row datastructure
[17:02:26] judofyr: eam: ooooh. writing a *new* file. sure.
[17:02:31] judofyr: creating a file
[17:02:33] eam: it's the object creation that's expensive in a filesystem
[17:02:37] judofyr: that's different from writing to it ;)
[17:02:39] judofyr: (in my head)
[17:02:42] davedev24: has joined #ruby
[17:03:02] phat4life: my page would load faster, if facebook, twitter, didn't load the share buttons via an iframe
[17:03:11] phat4life: is there a better way to do that?
[17:03:14] miah: i dont have any javascript on my site =)
[17:03:18] judofyr: remove facebook/twitter buttons
[17:03:25] phat4life: aside from that
[17:03:47] eam: judofyr: for large, high throughput volumes it's common to split up filesystems for this reason -- serialization on link/unlink can become the long pole
[17:03:54] miah: somebody has probably written better 'buttons'
[17:04:13] Kully3xf_: what is a subcommand
[17:04:17] eam: I had one particular case where I broke up a multi-TB volume into 10 parts spread across loopback-mounted filesystems
[17:04:24] eam: massive throughput increase
[17:04:31] emptyflask: has joined #ruby
[17:04:31] Kully3xf_: if I run something in a loop or by it self it works/but when I run it as threads it fails because it cannot find hte subcommand
[17:04:35] eam: workload was mostly tempfile related
[17:05:02] sbhatore: has joined #ruby
[17:05:19] phat4life: judofyr: you may have a point https://twitter.com/smashingmag/status/204955763368660992
[17:05:28] dseitz: has joined #ruby
[17:06:11] judofyr: Kully3xf_: dunno. there's no concept in Ruby of "subcommands". must come from a package/gem you use?
[17:06:25] miah: Kully3xf_: gist?
[17:06:32] Kully3xf_: yea I think you're right
[17:06:36] Kully3xf_: I think it's a chef thing
[17:06:40] zacstewart: has joined #ruby
[17:06:53] revdan: has joined #ruby
[17:07:05] judofyr: if it's chef, then I'm out. I have no idea how that works :)
[17:07:27] genpaku: has joined #ruby
[17:07:43] yokel: has joined #ruby
[17:07:52] rbennacer: has joined #ruby
[17:08:18] hahuang65: has joined #ruby
[17:08:19] atom3: has joined #ruby
[17:08:33] Kully3xf: has joined #ruby
[17:08:34] miah: #chef, but also just gist and ask question i know chef =)
[17:09:05] balazs_: has joined #ruby
[17:10:12] howdoicomputer: has joined #ruby
[17:10:35] chouhoulis: has joined #ruby
[17:11:02] paulcsmith: has joined #ruby
[17:11:45] momomomomo_: has joined #ruby
[17:12:02] chouhoulis: has joined #ruby
[17:12:04] msnyon: has joined #ruby
[17:12:19] Tarkers34: guys any idea how I can select the contents of a match but not the flanking characters? AfooA #=> "foo". See here http://rubular.com/r/RlcA4Gjcip I'd like :three to be selected, not /:three/
[17:12:20] woodruffw: has joined #ruby
[17:13:03] Tarkers34: I could gsub! away those slashes but I'm just wondering if it can be selected
[17:13:24] Jackneill: has joined #ruby
[17:14:00] hotpanca_: has joined #ruby
[17:14:10] thiagovsk: has joined #ruby
[17:14:24] ndrei: has joined #ruby
[17:14:28] Kully3xf_: has joined #ruby
[17:14:34] lkba: has joined #ruby
[17:14:58] lkba_: has joined #ruby
[17:15:21] jhass: Tarkers34: lookaround expressions do not capture: http://rubular.com/r/RlcA4Gjcip
[17:15:26] B1n4r10_: has joined #ruby
[17:15:43] Eiam: has joined #ruby
[17:15:51] n008f4g_: has joined #ruby
[17:16:22] jhass: ( (anything|.*$) is redundant, it'll always match)
[17:16:26] mistym: Tarkers34: What about: http://rubular.com/r/mo3X2vIMD5
[17:16:34] B1n4r10_: has joined #ruby
[17:16:44] mistym: Er sorry, misunderstood
[17:17:15] RegulationD: has joined #ruby
[17:17:23] Tarkers34: no worries, I'm just messing about with regex; not a project. Trying to learn it...I hate it a bit :/
[17:17:28] jhass: oh, damn I didn't copy my permanlink >.<
[17:17:32] Tarkers34: jhass haha yeah
[17:17:36] jhass: http://rubular.com/r/mo3X2vIMD5
[17:18:14] jhass: now I copied mistym
[17:18:19] jhass: somethings wrong with me :/
[17:18:31] Darkwater: jhass: what's the temperature in your area?
[17:18:32] Tarkers34: to much regexy goodness in your brain
[17:18:37] jhass: http://rubular.com/r/Ei9bfzOliJ
[17:18:42] zendrix: has joined #ruby
[17:18:59] Tarkers34: jhass: Hooorah! that's it thanks man
[17:19:18] Tarkers34: could you explain it a little? each character
[17:19:31] jhass: Darkwater: 29??C outside
[17:19:54] jhass: Tarkers34: http://www.regular-expressions.info/lookaround.html
[17:20:16] Darkwater: then there's nothing wrong with you
[17:20:23] Darkwater: blame the sun
[17:20:31] shevy: quite hot
[17:20:33] atom3: has joined #ruby
[17:20:42] Tarkers34: BOILING yesterday. rainy today
[17:20:51] Tarkers34: jhass: thanks man
[17:20:51] shevy: Tarkers34 where do you reside at?
[17:20:55] platzhirsch: has left #ruby: ()
[17:20:59] Darkwater: oh saturday is boiling day
[17:21:05] oddjob001: can someone help me figure out how to pull 2.1.4.27 out of this? or a regex that will always and only pull number dot number dot and anything after that until the whitespace? http://pastebin.com/eywFNPP1 - I assume its some form of select, but I cant seem to find a regex to work
[17:21:06] ruboto: oddjob001, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/94b93c22b76ee74aa970
[17:21:06] ruboto: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
[17:21:09] Tarkers34: shevy: Devon UK :)
[17:21:16] brettnem: has joined #ruby
[17:21:23] JCOE: has joined #ruby
[17:22:14] shevy: central europe, austria, vienna
[17:22:17] RegulationD: has joined #ruby
[17:22:25] shevy: lots of ruby programmers from the UK here
[17:22:52] bullcitydev: has joined #ruby
[17:23:25] Tarkers34: shevy: always good haha. I do like that about programming though. especially github collaboration. Just no predudices at all about culture/religion w/e. it's nice.
[17:23:59] dionysus69: has joined #ruby
[17:24:09] ItSANgo_: has joined #ruby
[17:24:20] bluOxigen: has joined #ruby
[17:25:13] Alayde: has joined #ruby
[17:25:16] emptyflask: has left #ruby: ()
[17:26:34] Tarkers34: is there a += operator in ruby? I don't think there is...surprising, ruby's normally so concicse. Do you have to say a = a + b?
[17:27:04] eam: >> a = 1; a += 1
[17:27:05] ruboto: eam # => 2 (https://eval.in/390548)
[17:27:49] jhass: oddjob001: how consistent is the output?
[17:27:52] Tarkers34: ahh I was running it on an uncast integer :)
[17:28:20] jhass: oddjob001: like, will it always be the 6th line?
[17:28:20] thang: has joined #ruby
[17:28:22] pothibo: has joined #ruby
[17:28:41] jhass: oddjob001: because then I'd just .lines[5].split.first
[17:28:45] NeverDie_: has joined #ruby
[17:29:44] mikecmpbll: has joined #ruby
[17:29:52] woodruffw: has joined #ruby
[17:29:58] ht__: has joined #ruby
[17:30:13] havenwood: oddjob001: Is the output consistent?
[17:30:31] havenwood: oddjob001: Might it be negative?
[17:30:49] havenwood: oddjob001: join.scan /-?(?:\d\.)+\d/
[17:30:57] oddjob001: jhass: let me look at that. what I dont understand is the output.
[17:31:05] oddjob001: here is the command vs, how it shows to ruby - https://gist.github.com/tek0011/7c374f79f507b3ef6a48
[17:31:20] oddjob001: that seems all out of order to me vs how windows is atually displaying it
[17:31:31] thang: has joined #ruby
[17:32:04] jhass: it's like it's spawning two processes that start outputting...
[17:32:08] oddjob001: does that make any sense to you ?
[17:32:18] oddjob001: i dont get it one bit either lol
[17:32:27] oddjob001: chalk it up to windows
[17:32:32] jhass: well, that makes output non deterministic
[17:32:50] JCOE: has joined #ruby
[17:33:13] havenwood: oddjob001: If it's unsigned: scan /(?:\d\.)+\d/
[17:33:15] yossarian: has joined #ruby
[17:33:38] oddjob001: ya. so in that case i cant assume i have certain lines to use. however, to answer the previous question yes. the only output I care about is the 2.1.4.27 which will always be the only line that starts with a number. so I at least have something to work with
[17:33:43] eam: oddjob001: does Facter::Core::Execution.exex capture stderr as well as stdout?
[17:33:58] eam: that would likely be the source of the ordering difference
[17:34:07] oddjob001: eam: good question. i doubt it does capture stderr.
[17:34:08] havenwood: oddjob001: (One or more digit then period pairs followed by a trailing digit.)
[17:34:18] rehat: has joined #ruby
[17:34:39] havenwood: oddjob001: #=> ["2.1.4.2"]
[17:34:43] eam: oddjob001: I suspect it does, and I suspect some of those lines are stderr and some are stdout
[17:34:54] benlieb_: has joined #ruby
[17:34:54] oddjob001: havenwood: let me give that a try. I am just lurning ruby gud and was using this atrocity. newdrivers = Facter::Core::Execution.exec("qaucli -iscsi -dv").lines.select {|v| v=~ /([0-9][\.][0-9][\.][0-9][\.][0-9]{1,})/}
[17:35:38] oddjob001: so yea learning how to program has made me decide I f'ing hate regex. for now.
[17:36:00] wasamasa: replace [0-9] with \d
[17:36:10] wasamasa: and [\.] with \.
[17:36:30] wasamasa: also, why do you group the entire thing
[17:36:50] eam: oddjob001: hating regex is healthy. You'll love it again when you go to parse text using non-regex utilities
[17:36:51] wasamasa: I'm pretty sure #lines is deprecated
[17:36:53] oddjob001: because its my 5th time ever using regex :)
[17:37:04] wasamasa: =~ looks like perl
[17:37:12] wasamasa: I've seen foo[/regex/] more often
[17:37:16] oddjob001: i thought .lines was same as each_line?
[17:37:42] oddjob001: havenwood: worked perfect. thank you
[17:38:55] oddjob001: havenwood: wait a sec though. that cuts off the last number
[17:39:02] paulcsmith: has joined #ruby
[17:39:10] upsell5: has joined #ruby
[17:39:13] havenwood: oddjob001: Using?: /(?:\d\.)+\d/
[17:39:15] havenwood: oddjob001: oh
[17:39:29] havenwood: oddjob001: right, more than one digit in a row, sec
[17:39:34] oddjob001: ya. should expect 2.1.4.27 - returns 2.1.4.2
[17:39:48] havenwood: oddjob001: So I guess: /(?:\d+\.)+\d+/
[17:39:51] upsell5: I have a number like: 1920099 that I need to convert to 19200.99 how can I do that?
[17:39:56] upsell5: i.e. last 2 digits are decimal place
[17:40:29] havenwood: oddjob001: One or more digits followed by a period at least once, with a trailing one or more digits.
[17:40:53] Musashi007: has joined #ruby
[17:41:34] oddjob001: havenwood: I think that should work. i dont know all instances of drivers I would have out there. in laymens I basically need a regex that grabs a new line that starts with a digit (it will always be the only line that starts with a digit) and then stop when it gets to the first whitespace
[17:41:38] jackjackdripper: has joined #ruby
[17:41:51] oddjob001: well the regex does, but i can make new lines and then apply the regex t it
[17:41:58] havenwood: oddjob001: Yeah, I should have looked at the output before proposing solutions. >.>
[17:42:13] havenwood: Wheee, Ruby!
[17:42:31] samleb: has joined #ruby
[17:42:55] psye: has joined #ruby
[17:43:02] oddjob001: so if I can just .lines it. Ill have "2.1.4.27 (STOR wx64)\n" So i thinka better solution would be to find any line that starts with a digit and grab everything after that until the first whitespace
[17:43:13] oddjob001: because what if I get a driver that is 12.22.4.12
[17:43:27] havenwood: >> 1920099.fdiv 100
[17:43:28] ruboto: havenwood # => 19200.99 (https://eval.in/390557)
[17:43:33] oddjob001: i guess I will also always know that Ill have 4 sets of numbers
[17:43:47] postmodern: has joined #ruby
[17:44:12] upsell5: havenwood: i see, thanks i???ll look that up.
[17:44:46] freerobby: has joined #ruby
[17:44:53] havenwood: >> 1920099 / 100.0
[17:44:54] ruboto: havenwood # => 19200.99 (https://eval.in/390558)
[17:44:55] havenwood: upsell5: ^ note
[17:45:34] oddjob001: that being said. would it be easier to take the entire output as a string and always look for number.number.number.number - or to take each line of the ouptut and trying to ten only grab num.num.num.num and end at whitespace
[17:45:49] Kully3xf: has joined #ruby
[17:46:58] MuffinPimp_: has joined #ruby
[17:46:59] Santana: has joined #ruby
[17:46:59] prestorium: has joined #ruby
[17:47:18] oddjob001: my only constant is that it will be num.num.num.num - but I dont know how many numbers will be in each
[17:49:13] armyriad: has joined #ruby
[17:49:39] Indian: has joined #ruby
[17:49:49] oddjob001: havenwood: Im thinking your (?:\d+\.)+\d+ will work regardless of how many physical numbers are in each set, ya?
[17:50:10] Kully3xf_: has joined #ruby
[17:50:43] havenwood: oddjob001: The + means one or more, so yup. Try it in irb or pry or better yet write some Minitest tests or specs!
[17:50:52] DCameronMauch: has joined #ruby
[17:51:28] oddjob001: i just tested it out on rubular with about 20 different varieties. seems to handle it all. thanks much!
[17:52:23] towski_: has joined #ruby
[17:52:28] serivich: has joined #ruby
[17:52:29] Xeago: has joined #ruby
[17:53:12] yqt: has joined #ruby
[17:53:22] frenda: has joined #ruby
[17:53:34] havenwood: oddjob001: The `()` is a group and the `?:` makes it a non-capture group. The `\d` is a digit and the `\.` period has to be escape since it has special meaning unescaped.
[17:53:45] frenda: Hi, How can I run ruby in terminal of linux?
[17:53:48] upsell5: havenwood: is it possible to force it to always have 2 digits after teh decimal?
[17:53:57] Senjai: frenda: what.
[17:54:01] havenwood: upsell5: Always in what since?
[17:54:01] jlast: has joined #ruby
[17:54:18] upsell5: 19200.fdiv(100) gives me 192.0
[17:54:23] frenda: When run below command, I get this error: bash: bundle: command not found
[17:54:23] havenwood: frenda: `ruby -e "ruby code here"` or `irb` for a REPL.
[17:54:24] frenda: `bundle install --deployment --without development test`
[17:54:25] upsell5: i want 192.00 (it is a price)
[17:54:31] havenwood: frenda: gem install bundle
[17:54:46] havenwood: frenda: Rather: gem install bundler
[17:54:59] bubbys: has joined #ruby
[17:55:06] oddjob001: havenwood: thanks. i got most of that but the ?: is what was confusing until i read about it. it works great. tyvm
[17:55:07] NeverDie: has joined #ruby
[17:55:18] havenwood: oddjob001: yw
[17:55:25] frenda: havenwood: Isn't available package manager! should I do it by `gem`?
[17:55:41] havenwood: frenda: Yeah: gem install bundler
[17:55:57] frenda: ok, thanks
[17:56:42] Scroff: has joined #ruby
[17:57:36] havenwood: upsell5: So you want a String as a result?
[17:57:45] havenwood: upsell5: Or BigDecimal?
[17:58:02] upsell5: bigdecimal
[17:58:47] havenwood: >> '%.2f' % 9200.fdiv(100)
[17:58:48] ruboto: havenwood # => "92.00" (https://eval.in/390563)
[17:58:50] nwhirschfeld: has joined #ruby
[17:59:46] havenwood: >> require 'bigdecimal'; BigDecimal.new 9200.fdiv(100), 2
[17:59:47] ruboto: havenwood # => #<BigDecimal:41f46500,'0.92E2',9(27)> (https://eval.in/390564)
[18:00:03] olistik: has joined #ruby
[18:00:36] havenwood: err, that's not right
[18:01:13] havenwood: upsell5: Wait, this is money?
[18:01:19] havenwood: upsell5: Are you doing calculations or just printing it?
[18:01:43] yorickpeterse: fuck, there's kids playing in an inflatable pool behind my apartment
[18:01:47] yorickpeterse: I want an inflatable pool too :<
[18:01:59] yorickpeterse: but I can't fit anything on my balcony
[18:02:33] shevy: yorickpeterse go over to them and play; tell them you'll write some ruby scripts for them if they'll let you :)
[18:02:50] woodruffw: has joined #ruby
[18:02:59] havenwood: yorickpeterse: get a pickup and a tarp
[18:03:06] havenwood: yorickpeterse: show them how to pool in style
[18:03:13] upsell5: havenwood: i will be doing both
[18:03:24] upsell5: so calculations then :)
[18:03:51] yorickpeterse: shevy: that would get me a free ticket to the local police department
[18:03:58] yorickpeterse: havenwood: don't have a driver's license
[18:04:01] yorickpeterse: nor the money for a pickup :P
[18:04:13] havenwood: yorickpeterse: Get a salvage, engine optional.
[18:04:26] pengin: has joined #ruby
[18:04:33] revath: has joined #ruby
[18:04:48] havenwood: or jacked up on cinder blocks might be nice flare
[18:05:42] dfockler: tarp off your balcony and turn it into a hottub
[18:06:10] rbennacer: has joined #ruby
[18:06:32] shevy: may be rather unlikely that you'll get lots of great suggestions pertaining to your balcony here yorickpeterse
[18:06:43] havenwood: upsell5: So Floats are completely out of the question. BigDecimal, Rational or Integers are options.
[18:07:08] yorickpeterse: shevy: I'm not surprised
[18:07:37] olistik: has joined #ruby
[18:07:41] Jackneill: has joined #ruby
[18:08:31] upsell5: bigdecimal is always good for pricing right?
[18:08:42] Musashi007: has joined #ruby
[18:08:44] lkba: has joined #ruby
[18:09:05] saaki: ACTION invoices a zillion dollars
[18:09:15] yorickpeterse: For pricing you'll want to store numbers in the most accurate form possible, but you might not need BigDecimal for that
[18:09:41] yorickpeterse: at least in Ruby a Fixnum will overflow automatically when needed
[18:10:11] NeverDie_: has joined #ruby
[18:10:35] Scroff: has joined #ruby
[18:10:41] eam: just be careful what kind of math you do to it
[18:11:09] djbkd: has joined #ruby
[18:11:35] upsell5: my product feed has numbers, like: 1920000
[18:11:43] eam: personally I'd stick to BigDecimal to avoid accidental errors
[18:11:44] upsell5: the last 2 are the decimals
[18:12:19] Spami: has joined #ruby
[18:12:33] yorickpeterse: upsell5: that's not a bigdecimal
[18:12:52] eam: it could be!
[18:12:58] atomical: has joined #ruby
[18:12:58] yorickpeterse: and there's no reason to store that in a bigdecimal either unless it _has_ to be a bigdecimal
[18:13:08] eam: yorickpeterse: there are a ton of valid reasons to
[18:14:00] upsell5: yorickpeterse: true
[18:16:25] hotpancakes: has joined #ruby
[18:18:53] kies^: has joined #ruby
[18:19:16] Marisa_: has joined #ruby
[18:21:31] cepokop: has joined #ruby
[18:21:46] wallerdev2: has joined #ruby
[18:21:56] PatrickHoward: has joined #ruby
[18:22:22] momomomomo: has joined #ruby
[18:22:34] ryba: has joined #ruby
[18:23:38] alphaatom: has joined #ruby
[18:23:39] malconis: has joined #ruby
[18:23:46] graydot: has joined #ruby
[18:23:49] nateberkopec: has joined #ruby
[18:24:08] GBrawl: has joined #ruby
[18:24:25] eGGsha: has joined #ruby
[18:24:51] revath: has joined #ruby
[18:25:39] langlands: has joined #ruby
[18:25:50] einarj: has joined #ruby
[18:26:25] failshell: has joined #ruby
[18:27:46] failshell: has joined #ruby
[18:28:15] peter_paule: has joined #ruby
[18:28:39] woodruffw: has joined #ruby
[18:28:54] choke: has joined #ruby
[18:29:11] kirun: has joined #ruby
[18:29:41] lessless: has joined #ruby
[18:30:53] zacstewart: has joined #ruby
[18:31:00] Marisa_: has joined #ruby
[18:31:28] anisha: has joined #ruby
[18:31:32] phutchins1: has joined #ruby
[18:31:34] bubbys: has joined #ruby
[18:31:38] baweaver: has joined #ruby
[18:32:31] ddv: has joined #ruby
[18:32:32] samleb: has joined #ruby
[18:32:44] ddv: has joined #ruby
[18:33:20] soulcake: has joined #ruby
[18:34:56] c_nick: has joined #ruby
[18:35:09] sarkyniin: has joined #ruby
[18:35:40] micmus: has joined #ruby
[18:36:03] c_nick: In Sinatra how can we do a dynamic table rendering on click you change the contents of the table
[18:36:24] mike___1234: has joined #ruby
[18:36:32] howdoicomputer: has joined #ruby
[18:36:56] sarkyniin: has joined #ruby
[18:36:56] jhass: c_nick: how's sinatra relevant to that question? sounds like frontend work
[18:37:06] iamninja: has joined #ruby
[18:37:37] Oka: has joined #ruby
[18:38:18] sross07: has joined #ruby
[18:39:22] soulcake: has joined #ruby
[18:40:04] JDiPierro: has joined #ruby
[18:41:28] dopie: has joined #ruby
[18:42:08] shevy: c_nick probably via a javascript action
[18:42:52] multi_io: has joined #ruby
[18:43:17] momomomomo_: has joined #ruby
[18:43:42] soulcake: has joined #ruby
[18:44:07] kfpratt: has joined #ruby
[18:44:12] workmad3: has joined #ruby
[18:44:22] yardenbar: has joined #ruby
[18:44:41] bruno-: has joined #ruby
[18:45:00] hinbody: has joined #ruby
[18:45:56] bmurt: has joined #ruby
[18:46:23] blueOxigen: has joined #ruby
[18:47:01] jhooker: has joined #ruby
[18:47:29] jeanlinux: has joined #ruby
[18:47:56] c_nick: has joined #ruby
[18:48:18] aef: has joined #ruby
[18:48:30] kerrizor: has joined #ruby
[18:49:31] c_nick: jhass: Yes indeed frontend work but wanted to know how I can get that achieved through Sinatra+haml, couldnt find a tutorial or an article on it will continue to search
[18:50:16] jhass: c_nick: with some javascript, likely
[18:50:22] last_staff: has joined #ruby
[18:51:47] bradleyprice: has joined #ruby
[18:52:02] chouhoul_: has joined #ruby
[18:52:07] JoshL: has joined #ruby
[18:53:13] ivanskie: has joined #ruby
[18:54:24] baweaver: has joined #ruby
[18:54:25] tonyhb: has joined #ruby
[18:54:33] eGGsha: has joined #ruby
[18:55:16] frenda: has left #ruby: ()
[18:55:34] c_nick: hmm jhass yes i need to try on that
[18:57:02] zacstewart: has joined #ruby
[18:57:12] sbhatore: hey! what does a function starting with _(underscore) convey or when is it used ?
[18:57:49] jhass: sbhatore: got some context? looks like gettext on first glance, which is rarely used in ruby land
[18:57:53] duggiefresh: has joined #ruby
[18:58:17] DexterLB: has joined #ruby
[18:58:19] frenda: has joined #ruby
[18:58:20] Rakunh0: has joined #ruby
[18:58:52] frenda: Error: http://pastebin.com/MbcHcqN5 --> I can't install `json` :(
[18:58:53] ruboto: frenda, we in #ruby do not like pastebin.com, I reposted your paste to gist for you: https://gist.github.com/fe95230b0e19bf4f8c1b
[18:58:53] ruboto: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
[18:59:21] jhass: frenda: install ruby-devel or whatever the package was
[18:59:31] Senjai: ruboto does that now
[18:59:36] sbhatore: jhass: yeah! have a look at this, https://github.com/rails/rails/blob/master/activesupport/lib/active_support/message_encryptor.rb
[18:59:44] jhass: Senjai: since like two months
[19:00:00] ljarvis: sbhatore: it's sometimes so the public API doesn't change
[19:00:34] ljarvis: sometimes though it's for no good damn reason at all
[19:00:44] jhass: yeah, no idea why they did it there
[19:00:46] jhass: makes no sense
[19:01:12] baweaver: has joined #ruby
[19:01:15] allomov: has joined #ruby
[19:01:27] ljarvis: or they expect a subclass to define those methods *shrug*
[19:01:33] Senjai: jhass: Poor sod who had to write the interface for pastebin
[19:01:35] ljarvis: silly either way from what I can see
[19:01:55] baweaver: has joined #ruby
[19:02:16] jhass: Senjai: fairly easy in fact, you just regex the id from the URL and monkey build the one to the raw output
[19:02:26] jhass: pastebin.com even calls doing so "API"
[19:03:20] Scripore: has joined #ruby
[19:03:26] sbhatore: jhass: Lets see what #rubyonrails has to say
[19:03:38] ljarvis: >> require "date"; Date._parse("5/6/7")
[19:03:39] ruboto: ljarvis # => {:year=>2005, :mon=>6, :mday=>7} (https://eval.in/390592)
[19:03:40] jhass: ljarvis: sbhatore looks like there used to be public API with the same names https://github.com/rails/rails/commit/71e84a3b514b6a2630dfd7f658f4e7597424d6e3
[19:03:44] ljarvis: still exists
[19:04:22] jhass: I'd say you'll have good chances on getting a PR in that renames them now
[19:07:38] sbhatore: jhass: hmmm...I see. This has to be the reason for it. Thanks :) and u too ljarvis
[19:09:10] lkba_: has joined #ruby
[19:09:22] Oka: has joined #ruby
[19:10:02] zendrix: has joined #ruby
[19:10:12] centrx: has joined #ruby
[19:13:03] graydot: has joined #ruby
[19:14:21] workmad3: has joined #ruby
[19:15:18] atom3: has joined #ruby
[19:15:18] alphaatom: has joined #ruby
[19:15:25] yqt: has joined #ruby
[19:16:01] Maletor: has joined #ruby
[19:16:04] frenda: What's going on: https://gist.github.com/diff-/0543b8fcf6b083fed129 (I'm sorry for inconvenience)
[19:16:12] zacstewart: has joined #ruby
[19:16:43] sharpmachine: has joined #ruby
[19:16:51] voker57: has joined #ruby
[19:16:54] jhass: frenda: libxml2-devel or something this time
[19:17:10] jhass: also iconv-devel or so
[19:17:46] frenda: jhass, Yeah! It's there
[19:18:03] Xeago: has joined #ruby
[19:18:06] frenda: libxml2-devel
[19:18:32] frenda: Should i install `iconv-devel` too? @jhass
[19:18:35] howdoicomputer: has joined #ruby
[19:18:59] ndrei: has joined #ruby
[19:21:06] jhass: idk what the package name is
[19:21:24] baweaver: has joined #ruby
[19:21:54] jhass: it doesn't find libxml2
[19:22:33] Kully3xf_: @miah thanks but I figured it out
[19:23:07] frenda: has left #ruby: ()
[19:24:31] Kully3xf_: how many threads is too many threads
[19:24:44] Kully3xf_: I know it's subjective - but there has to be a rule of thumb?
[19:25:03] _kfpratt: has joined #ruby
[19:25:16] jhass: Kully3xf_: no there isn't
[19:25:28] jhass: the answer is _vastly_ different depending on your CPU and workload
[19:25:41] Kully3xf_: yea I figured
[19:26:36] swgillespie: has joined #ruby
[19:26:45] Kully3xf_: c3.4xl - 16vcpu and 30gb ram
[19:26:56] Kully3xf_: I think it can prbably handle more than 10 threads?
[19:26:59] sandstrom: has joined #ruby
[19:27:17] failshell: has joined #ruby
[19:27:35] tonyhb: has joined #ruby
[19:27:48] jhass: yes, probably it can handle 1000
[19:27:50] Rakunh0: has joined #ruby
[19:27:52] jhass: depending on the workload
[19:28:11] Kully3xf_: shouldn't need to launch more than 100 concurrent threads so I'll up the limit to 100
[19:28:43] yfeldblum: has joined #ruby
[19:29:15] tonyhb_: has joined #ruby
[19:29:16] axl_: has joined #ruby
[19:29:48] dfockler: FOUR MORE THREADS!
[19:30:17] alphaatom: has joined #ruby
[19:30:23] jhass: looks like my number wasn't absurd enough yet to bring my point across :/
[19:30:39] blackmesa: has joined #ruby
[19:31:04] Scroff: has joined #ruby
[19:31:22] roolo: has joined #ruby
[19:31:39] Kully3xf_: ah you mean it could handle an absorbanant amount of thread
[19:31:39] skade: has joined #ruby
[19:31:47] Kully3xf_: day 1 of ruby
[19:32:08] jhass: not related to ruby
[19:32:50] jhass: 16 can fully exhaust your CPU, or maybe 8 do because it's all hyper threading stuff and the context switching would slow you down already
[19:33:22] jhass: but if all your threads do is waiting for some event or whatever, you can have 10k of them
[19:33:38] jhass: it's completely irrelevant to talk about this in the abstract
[19:33:40] renderful: has joined #ruby
[19:33:44] Kully3xf_: I'll have to read up on it
[19:33:46] appledroid: has joined #ruby
[19:34:03] Frem: has joined #ruby
[19:34:50] jhass: or come up with a _concrete_ way to measure throughput for your _actual workload_ and experiment
[19:35:25] Kully3xf_: yea that's hard - gets expensive. The work load it's doing is launching large size instances, so I can only test it occasionally
[19:35:41] drewvanstone: has joined #ruby
[19:37:51] c_nick: has left #ruby: ()
[19:38:02] kadoppe: has joined #ruby
[19:38:45] zacstewart: has joined #ruby
[19:39:36] sharpmachine: has joined #ruby
[19:43:05] momomomomo_: has joined #ruby
[19:43:33] nfk: has joined #ruby
[19:43:50] jerius: has joined #ruby
[19:44:38] momomomomo__: has joined #ruby
[19:44:52] AustinMatherne: has joined #ruby
[19:45:09] bullcitydev: has joined #ruby
[19:45:27] Xeago: Kully3xf_: does it matter if it takes 10s to spawn or 1 minute to spawn?
[19:45:30] jerius: has joined #ruby
[19:46:01] zendrix: has joined #ruby
[19:46:01] Xeago: if you're operating on a scale where 10s is not fast enough, you're better to overprovision
[19:46:10] jpfuentes2: has joined #ruby
[19:46:37] NeverDie: has joined #ruby
[19:47:40] Kully3xf_: it takes 35 minutes to spawn a node - in a loop that takes WAY to long if you do even 2 of them. Thus the threading, cuts times like crazy
[19:47:51] Kully3xf_: if I can thread 100 we can launch 100 in 35 minutes
[19:48:14] Kully3xf_: if I can thread only ten then I'm still looking at 6 hours
[19:48:16] jhass: looks like you'll be mostly waiting on IO
[19:48:24] Kully3xf_: much better than before though
[19:48:43] Kully3xf_: yea I'm not really sure what happens on the back end - I'll have to do some testing when I get the chance next
[19:48:45] jhass: if that's the case you can probably do 200 in 40 minutes or so
[19:48:52] Kully3xf_: it be really sweet if I could up that limit
[19:49:03] Kully3xf_: maybe I'll include it as an upgrade xD
[19:49:26] SCHAAP137: has joined #ruby
[19:49:34] idafyaid: has joined #ruby
[19:50:11] mcclurmc: has joined #ruby
[19:50:37] vyorkin: has joined #ruby
[19:50:52] eggoez: has joined #ruby
[19:52:31] lordkryss: has joined #ruby
[19:52:42] dented42: has joined #ruby
[19:52:49] frenda: has joined #ruby
[19:53:16] danman: has joined #ruby
[19:53:27] rodfersou: has joined #ruby
[19:53:41] jbourassa: has joined #ruby
[19:53:49] frenda: I'm ashamed !!! https://gist.github.com/diff-/b5742c55435393bbbb5e
[19:53:59] eGGsha: has joined #ruby
[19:54:12] mcclurmc: has joined #ruby
[19:54:50] jbourassa: Hey Ruby friends. I???m trying to figure out of Array#each is thread safe ??? say two threads are iterating the same array, is the result going to be as expected? Otherwise said, where???s the iterator current value saved?
[19:55:10] blackmesa: has joined #ruby
[19:55:13] Indian: has joined #ruby
[19:55:14] adaedra: There's no #shift for string? Disapointing.
[19:56:07] Papierkorb: has joined #ruby
[19:56:34] benlieb_: has joined #ruby
[19:56:45] adaedra: slice!(0) does the job
[19:56:50] ljarvis: jbourassa: well, is the array modified in another read or is it readonly?
[19:56:58] ljarvis: s/read/thread/
[19:57:17] jbourassa: It is not ??? it???s only being iterated on.
[19:57:22] wallerdev2: has joined #ruby
[19:57:27] ljarvis: then I'm not sure I understand your question
[19:57:50] ljarvis: if the array isn't ever modified, it'll contain the same contents across all threads
[19:57:58] Eiam_: has joined #ruby
[19:58:36] jbourassa: Yes, of course. I???m curious about the iterator pointer ??? or whatever keeps track of where an iterator is at.
[19:58:36] brettnem: has joined #ruby
[19:58:42] zacstewart: has joined #ruby
[19:59:31] jbourassa: (I???m not sure about Ruby???s implemenation of Array, my question might be more about Enumerable)
[20:00:06] mrmargolis: has joined #ruby
[20:00:10] adaedra: ljarvis: I think the question is to know if the iterator when doing #each is internal to the array (so shared) or not
[20:00:26] jbourassa: ^ Exactly, thank you :)
[20:00:43] ljarvis: right, thanks adaedra
[20:00:51] ljarvis: jbourassa: you could test this pretty easily
[20:00:57] jhass: jbourassa: it's on the stack of the #each call
[20:01:15] langlands: has joined #ruby
[20:02:07] Alayde: has joined #ruby
[20:02:09] RegulationD: has joined #ruby
[20:02:54] Maletor: has joined #ruby
[20:02:59] jbourassa: jhass: pardon my non-understanding ?????that means that multiple `#each` on the same Array will _not_ share the pointer. Correct?
[20:03:21] jhass: correct, keep in mind that each is a regular method call
[20:03:33] adaedra: Doing parallel #each as long as you don't modify the array should be safe
[20:03:38] jenrzzz: has joined #ruby
[20:03:41] rbennacer: has joined #ruby
[20:03:51] langlands: has joined #ruby
[20:03:53] graydot: has joined #ruby
[20:03:58] pfish: has joined #ruby
[20:04:00] jhass: you can picture it as being a less naive version of i = 0; while i < size; yield self[i]; end;
[20:04:04] ljarvis: jbourassa: http://rxr.whitequark.org/mri/source/array.c#1693
[20:04:12] jhass: + i += 1 of course
[20:04:29] jbourassa: Awesome ??? makes a lot of sens.
[20:04:31] ljarvis: the index is stored on the stack (i.e local to that function) which means it's local to the method call
[20:04:36] jbourassa: Thank you all.
[20:04:47] pfish: In the C code for ruby is there a proc_invoke equivalent in 2.2?
[20:04:59] enebo: has joined #ruby
[20:05:21] ljarvis: pfish: proc_call?
[20:05:41] ljarvis: pretty sure proc_invoke exists in 2.2 though
[20:05:45] mcclurmc: has joined #ruby
[20:08:02] pfish: i did a grep and its only in the change logs
[20:08:21] sinkensabe: has joined #ruby
[20:08:29] mrmargol_: has joined #ruby
[20:09:15] tuelz: has joined #ruby
[20:09:29] yqt: has joined #ruby
[20:09:56] [H]unt3r_: has joined #ruby
[20:10:01] frenda: has left #ruby: ()
[20:10:38] punkerplunk: has joined #ruby
[20:10:38] peter_paule: has joined #ruby
[20:11:51] bullcitydev: has joined #ruby
[20:13:14] VictorBjelkholm: has joined #ruby
[20:14:27] bradleyprice: has joined #ruby
[20:15:38] momomomomo_: has joined #ruby
[20:15:46] swgillespie: has joined #ruby
[20:16:22] chinmay_dd: has joined #ruby
[20:17:15] nofxx: has joined #ruby
[20:17:47] dopie: has joined #ruby
[20:18:50] art-solopov: has joined #ruby
[20:19:09] Hobogrammer: has joined #ruby
[20:19:30] Channel6: has joined #ruby
[20:20:10] sarkyniin: has joined #ruby
[20:21:05] zacstewart: has joined #ruby
[20:21:26] rodfersou: has joined #ruby
[20:25:40] but3k4: has joined #ruby
[20:26:01] futilegames: has joined #ruby
[20:26:05] Muhannad: has joined #ruby
[20:26:08] _blizzy_: has joined #ruby
[20:26:11] eggoez: has joined #ruby
[20:29:26] renderful: has joined #ruby
[20:31:20] dseitz: has joined #ruby
[20:33:03] Eiam_: has joined #ruby
[20:33:36] _blizzy_: has joined #ruby
[20:33:45] A205B064: has joined #ruby
[20:33:53] wallerdev2: has joined #ruby
[20:36:29] gix: has joined #ruby
[20:37:07] mrmargolis: has joined #ruby
[20:37:18] pdoherty: has joined #ruby
[20:37:33] shevy: oh people are sleepy now
[20:41:20] sumark: has joined #ruby
[20:42:10] mcclurmc: has joined #ruby
[20:42:22] peter_paule: has joined #ruby
[20:42:28] zacstewart: has joined #ruby
[20:42:44] Eiam_: has joined #ruby
[20:43:05] yorickpeterse: summer weather is too warm to do anything
[20:43:19] yorickpeterse: it's a shame the grocery store was out of icecream :<
[20:43:30] kinduff: has joined #ruby
[20:43:30] kinduff: has joined #ruby
[20:43:34] yorickpeterse: apparently the whole neighbourhood had the same idea as me, except they had it a few hours earlier
[20:44:38] j4cknewt: has joined #ruby
[20:45:35] nofxx: yorickpeterse, that's the problem of my hemisphere. Not warm only may to august/sep
[20:46:13] rbennacer: has joined #ruby
[20:46:33] ljarvis: the UK was insanely hot today
[20:46:36] ljarvis: never said that before
[20:46:53] yorickpeterse: same here in .nl
[20:46:59] yorickpeterse: it's probably the only week of sun we'll get for the entire year
[20:47:05] yorickpeterse: so better get tanned while it lasts
[20:47:18] yorickpeterse: (or just sit outside)
[20:47:29] jeanlinux: has joined #ruby
[20:47:32] ljarvis: like you have it bad
[20:47:35] ljarvis: ACTION looks at the UK
[20:47:43] dudedudeman: ACTION blinks
[20:47:45] yorickpeterse: our weather isn't much different
[20:48:13] qsuscs: has left #ruby: ("WeeChat 1.2-dev")
[20:48:52] GitGud: has joined #ruby
[20:49:14] mantas322: has joined #ruby
[20:49:29] wildroman2: has joined #ruby
[20:49:31] mantas322: jesus guys, I need help
[20:49:39] mantas322: i've been tryign to parse a date for like 30 mins now
[20:49:53] ljarvis: >> require "date"; Date.parse("06-22-2015")
[20:49:54] ruboto: ljarvis # => invalid date (ArgumentError) ...check link for more (https://eval.in/390645)
[20:49:56] Senjai: >> "06-22-2015"
[20:49:57] ruboto: Senjai # => "06-22-2015" (https://eval.in/390646)
[20:49:59] shevy: dudedudeman!!! you are BACK!
[20:50:01] Senjai: god damnit ljarvis
[20:50:04] Senjai: I was right about to do that
[20:50:33] ht__: has joined #ruby
[20:50:36] shevy: the weather forecast for europe says - it'll be even hotter the coming days
[20:50:38] s2013: has joined #ruby
[20:50:43] mantas322: `parse': invalid date (ArgumentError)
[20:50:48] mantas322: doesnt work
[20:50:51] yorickpeterse: like, it's so warm I can't get my apartment's temperature below the 25-something C it is now
[20:50:56] yorickpeterse: with 2 fans at max speed and all windows open
[20:50:57] mantas322: i've tried all sorts of combinations of parse and strptime
[20:51:03] yorickpeterse: it's cooler outside now than inside :/
[20:51:10] ljarvis: >> require "date"; Date.parse("06-22-2015".tr("-", "/"))
[20:51:11] ruboto: ljarvis # => invalid date (ArgumentError) ...check link for more (https://eval.in/390648)
[20:51:26] nofxx: yorickpeterse, 25 that's A/C! We get 35 here =P
[20:51:29] shevy: yorickpeterse yeah that is the strangest part
[20:51:37] yorickpeterse: >> require 'date'; Date.strptime('06-22-2015', '%m-%d-%Y')
[20:51:38] ruboto: yorickpeterse # => #<Date: 2015-06-22 ((2457196j,0s,0n),+0s,2299161j)> (https://eval.in/390649)
[20:51:45] yorickpeterse: nofxx: no AC here :<
[20:52:03] yorickpeterse: the only thing really enjoying the weather is my lemon tree
[20:52:14] yorickpeterse: pretty sure that thing grew more in the past few days than in the past year
[20:52:21] sphex: hey. is there an easy way to make a class "writable"? e.g. if I could just define a "write" method, and then include a mixin to get "puts", "printf", "putc", etc.
[20:52:21] grey_beard: has joined #ruby
[20:52:46] nofxx: sphex, there's not such a thing as class not writable in ruby
[20:52:54] mcclurmc: has joined #ruby
[20:52:59] zendrix: has joined #ruby
[20:53:01] nofxx: can you freeze a class?
[20:53:12] ljarvis: clearly that's not even close to what they were asking
[20:53:12] havenwood: >> require 'date'; Date.parse '06-22-2015'.split('-').rotate.join('-')
[20:53:13] ruboto: havenwood # => #<Date: 2015-06-22 ((2457196j,0s,0n),+0s,2299161j)> (https://eval.in/390652)
[20:53:14] mantas322: thank uyou very much yorickpeterse
[20:53:18] jhass: sphex: I think that's pretty much the contract for IO
[20:53:20] nofxx: sphex, check isntance_method, class_method, or even reopening the class
[20:53:22] sphex: nofxx: I just mean a class that behaves like a writable I/O stream
[20:53:23] wildroman3: has joined #ruby
[20:53:24] s2013: has joined #ruby
[20:53:27] yorickpeterse: IIRC you can extend IO
[20:53:31] yorickpeterse: and define your own "write"
[20:53:32] djbkd: has joined #ruby
[20:53:35] nofxx: sphex, ah, beg yr pardon
[20:53:45] yorickpeterse: but I might be mistaken
[20:54:00] sphex: nofxx: hey, np!
[20:54:07] Hanmac: has joined #ruby
[20:54:53] sphex: yorickpeterse, jhass: oh ok. I'm gonna try that. thanks
[20:54:54] dopie: has joined #ruby
[20:55:12] dede: has joined #ruby
[20:55:12] havenwood: nofxx: FREEZE ALL THE THINGS \o/
[20:55:14] havenwood: >> String.freeze; class String; def to_i; 0 end end
[20:55:15] ruboto: havenwood # => can't modify frozen class (RuntimeError) ...check link for more (https://eval.in/390656)
[20:55:32] nofxx: havenwood, haha, nice ;)
[20:55:38] ljarvis: should create a gem called frozen
[20:55:41] NeverDie_: has joined #ruby
[20:55:42] s2013: has joined #ruby
[20:55:42] ljarvis: which just freezes shit
[20:55:43] djbkd: has joined #ruby
[20:55:58] nofxx: subzero... Subzero.come_here(Class)
[20:56:11] nofxx: subzero... Subzero.come_here(Class).jab
[20:56:20] eam: >> ObjectSpace.each_object &:freeze
[20:56:21] ruboto: eam # => /tmp/execpad-b8d206430359/source-b8d206430359:1:in `p': can't modify frozen Hash (RuntimeError) ...check link for more (https://eval.in/390658)
[20:56:23] STONECOLDDEVIN: except scorpion does that
[20:56:33] nofxx: stonecolddevin, ouch!
[20:56:47] nofxx: they are cousins stonecolddevin
[20:57:44] nofxx: the best named gem ever is 'jesus' the web interface of god for the mankind
[20:57:51] nofxx: charlock holmes is funny too
[20:57:55] vickleton: has joined #ruby
[20:58:00] shevy: I don't know
[20:58:16] shevy: if I install jesus, what do I get?
[20:58:31] shevy: not even jesus on rails?
[20:59:05] shevy: I wonder why weird names seem to dominate gems
[20:59:08] shevy: like sinatra
[20:59:34] shevy: gem install phuby
[20:59:40] rickmasta: has joined #ruby
[20:59:49] shevy: failed with a "php is missing!" message :(
[21:00:08] eam: shevy: have I told you about my rules for naming a ruby gem?
[21:00:38] mrmargol_: has joined #ruby
[21:00:48] dgutierrez1287: has joined #ruby
[21:01:18] eam: 1) figure out what your gem does. This gem prints text. 2) Figure out a clever angle three abstractions removed. For example:
[21:01:39] eam: a) writers print text b) Hemmingway is a writer c) Hemmingway was fond of six toed cats
[21:01:46] eam: so the gem's name is six-toes
[21:01:53] nofxx: creative names are nice. the only naming prob with gem is that there's no enforce on the rules naming to require rules.. I mean, ppl write foo-bar gem and require 'foo_bar' for isntance.
[21:02:03] yorickpeterse: according to the thermostat in my attic it's 34C somewhere in my roof (the temperature sensor for some reason is in my roof)
[21:02:18] eam: the more oblique the references the better a rubyist you are
[21:02:26] shevy: yorickpeterse 27?C here
[21:02:42] eam: wow you both must be freezing
[21:04:04] eam: 102 over here
[21:04:12] bougyman: that's the same, isn't it?
[21:04:17] eam: yeah about ;)
[21:04:24] bougyman: a bit cooler
[21:04:35] zacstewart: has joined #ruby
[21:04:40] bougyman: 103-104 here.
[21:04:47] bougyman: (in stupid Farenheit)
[21:04:51] bougyman: Farenheit should be banned.
[21:04:58] adaedra: what's a farenheit
[21:05:01] eam: I climed up in my attic to replace a broken attic fan a few summers ago, and I brought an infrared thermostat gun with me
[21:05:10] eam: it was 73C
[21:05:14] havenwood: adaedra: something about burning books
[21:05:39] hagabaka: has joined #ruby
[21:05:49] eam: attics get hot
[21:05:50] jpfuentes2: has joined #ruby
[21:05:56] adaedra: oh, bits of rain announced sunday
[21:07:31] alphaatom: has joined #ruby
[21:07:32] yorickpeterse: eam: what the fuck
[21:08:25] eam: yorickpeterse: I lost 10lb of water weight that day, even though I drank over a gallon of water
[21:08:49] eam: I had my wife stand by in case I passed out, it was unbearable
[21:09:01] eam: "if I don't reply don't come in after me just dial 911"
[21:09:30] eam: the fan I installed that day keeps it closer to 50C
[21:10:18] yorickpeterse: I'm probably going to stock up on an extra fan this weekend
[21:10:22] yorickpeterse: and create a little whirldwind
[21:10:33] yorickpeterse: hopefully that at least keeps things a bit cool
[21:10:55] nateberkopec: has joined #ruby
[21:11:56] txdv: has joined #ruby
[21:12:05] eam: yorickpeterse: oh I found it, I lied, only 158F https://twitter.com/3ameam/status/214118215876476928
[21:12:13] senayar: has joined #ruby
[21:12:13] senayar: has joined #ruby
[21:13:40] n_blownapart: has joined #ruby
[21:13:52] brianjlandau: has joined #ruby
[21:15:20] baweaver: has joined #ruby
[21:16:07] A205B064: has joined #ruby
[21:16:44] jpfuentes2: has joined #ruby
[21:16:53] CatMartyn: has joined #ruby
[21:17:55] jeanlinux: has joined #ruby
[21:18:19] vickleton: has joined #ruby
[21:21:07] swgillespie: has joined #ruby
[21:21:28] alno1: has joined #ruby
[21:22:28] howdoicomputer: has joined #ruby
[21:24:37] bubbys: has joined #ruby
[21:25:47] danman: has joined #ruby
[21:26:13] Tarkers34: has joined #ruby
[21:26:28] zacstewart: has joined #ruby
[21:28:14] Musashi007: has joined #ruby
[21:29:36] mandarinkin2: has joined #ruby
[21:29:53] nfk: has joined #ruby
[21:30:18] mrmargolis: has joined #ruby
[21:30:26] dfockler: has joined #ruby
[21:30:27] mandarinkin: has joined #ruby
[21:31:47] mandarinkin2: has joined #ruby
[21:32:15] mandarinkin: has joined #ruby
[21:33:20] kfpratt: has joined #ruby
[21:34:18] alphaatom: has joined #ruby
[21:34:23] benlieb_: has joined #ruby
[21:35:18] momomomomo_: has joined #ruby
[21:38:06] NeverDie: has joined #ruby
[21:39:11] but3k4: has joined #ruby
[21:39:41] facebook: has joined #ruby
[21:40:29] alphaatom: has joined #ruby
[21:40:42] NeverDie: has joined #ruby
[21:40:43] mrmargol_: has joined #ruby
[21:43:38] Senjai: Can people even live in that gees
[21:44:29] choke: has joined #ruby
[21:44:41] dudedudeman: 158 F. no way
[21:44:56] mrmargolis: has joined #ruby
[21:46:51] dfockler: We'd turn into human jerky
[21:47:33] dudedudeman: ... sorry. wrong window and i was attemping to do some keystrokes
[21:48:00] dudedudeman: i'm a big fan of alt+d in a browser window lol
[21:48:17] kinduff: has joined #ruby
[21:48:54] eam: 158F you'll die eventually. I was going up for about 10-15 minutes at a time
[21:48:58] kinduff: Is it possible to stop `gets` user input in anyway (in a while or loop)?
[21:49:19] ljarvis: kinduff: interupt?
[21:49:30] ljarvis: interrupt*
[21:49:34] ljarvis: no i mean, hit control-c
[21:49:45] kinduff: Not by the user, whithin the script
[21:50:04] ljarvis: could you provide some background?
[21:51:03] kinduff: Got a Thread with a sleep method inside, after the sleep a variable changes. If this variable changes, `gets` should be interrupted. My `gets` is inside a loop that breaks if var from Thread changes.
[21:51:39] kinduff: I'm looking for a way to break it and interrupt the `gets` before the next loop iteration
[21:51:44] Guest69107: has joined #ruby
[21:52:00] kinduff: Or could a `gets` be interrupted inside a Thread?
[21:52:14] alphaatom: has joined #ruby
[21:52:14] jhass: I wonder if $stdin.write("\n") works :D
[21:52:40] nateberkopec: has joined #ruby
[21:52:52] kinduff: let me check
[21:53:48] mgorbach: has joined #ruby
[21:54:23] pengin: has joined #ruby
[21:54:36] MikeGib: has joined #ruby
[21:55:17] howdoicomputer: has joined #ruby
[21:55:24] kinduff: Thread.new { sleep(5); $stdin.write("\n") }; gets
[21:55:30] kinduff: doesn't work
[21:55:33] sshuff: has joined #ruby
[21:55:51] JDiPierro: has joined #ruby
[21:56:29] niemcu: has joined #ruby
[21:58:10] apeiros: kinduff: use Kernel#select (or IO.select) to determine whether $stdin/ARGF is ready to read
[21:58:27] apeiros: loop over select and your variable condition
[21:58:36] apeiros: just try to not make it a busy loop
[21:58:36] momomomomo: has joined #ruby
[21:58:55] jeanlinux: has joined #ruby
[22:00:19] kinduff: apeiros: I'm not getting it, how does that method works?
[22:00:53] apeiros: it works by not invoking gets until you actually can read from $stdin/ARGF (note that Kernel#gets is ARGF.gets, not $stdin.gets)
[22:00:55] jenrzzz_: has joined #ruby
[22:00:59] apeiros: so you don't have to interrupt it
[22:01:19] ljarvis: duh, I always forget about IO.select, such awesome
[22:01:32] crdpink: has joined #ruby
[22:01:36] apeiros: also you'll have to use read_nonblock instead of gets
[22:01:50] apeiros: since the IO being read to read doesn't mean it has a full line. so gets would still block.
[22:02:28] kinduff: How can IO.select be integrated to the piece of code I wrote up there?
[22:02:45] kinduff: apeiros: or could you write a quick example? :)
[22:03:00] kinduff: Never worked with this layer
[22:03:00] apeiros: midnight here, so no. I'm sure somebody else can.
[22:03:17] kinduff: np, thanks for pointing out IO
[22:03:49] genpaku: has joined #ruby
[22:04:02] arescorpio: has joined #ruby
[22:04:13] jhass: IO.select doesn't guarantee a gets will return though
[22:04:25] eam: you can raise in the thread
[22:04:36] eam: jhass: right, gets() will block on all kinds of stuff
[22:04:45] eam: will need sysread()
[22:05:06] apeiros: jhass: read on
[22:05:21] apeiros: 00:01 apeiros: also you'll have to use read_nonblock instead of gets
[22:05:21] apeiros: 00:02 apeiros: since the IO being read to read doesn't mean it has a full line. so gets would still block.
[22:05:21] bradleyp_: has joined #ruby
[22:05:29] eroc: has joined #ruby
[22:05:32] apeiros: being *ready to read
[22:05:42] jhass: totally skipped over that line
[22:05:58] jhass: my concentration is ... somewhere where I'm not
[22:06:01] apeiros: iow, I fully agree with you :)
[22:06:28] eam: >> c = Thread.current; Thread.new { sleep 0.1; c.raise }; STDIN.gets rescue "broke out"
[22:06:29] ruboto: eam # => (https://eval.in/390686)
[22:06:34] benlieb_: has joined #ruby
[22:06:56] eam: whooa ok can't thread in eval.in -- but run that
[22:07:36] eam: this is a dangerous mechanism though, the approach with read/select is what you really should do
[22:07:38] kinduff: eam: woah, my console just crashed
[22:07:51] kinduff: c = Thread.current; Thread.new { sleep 3; c.raise }; STDIN.gets rescue "broke out"
[22:07:56] apeiros: eam: that's potentially breaking stuff, though
[22:07:56] kinduff: if you trype something and press enter
[22:08:03] eam: apeiros: indeed, it's as bad as Timeout
[22:08:26] kinduff: why does it crash?
[22:08:50] skade: has joined #ruby
[22:09:08] klaas_: has joined #ruby
[22:09:12] eam: not sure what you mean by crash
[22:09:21] kaleido: has joined #ruby
[22:10:11] kinduff: so if you exit earlier of the `gets`, the Thread.current would be the irb console itself
[22:10:20] kinduff: it that true?
[22:10:45] kinduff: so if I input something to that gets and wait for the c.raise, the console exists
[22:10:46] eam: kinduff: ah, yes
[22:11:05] marr123: has joined #ruby
[22:11:05] eam: you can insert something into that watchdog thread to not kill if (whatever condition)
[22:11:06] shevy: I feel so left alone in the ruby GUI world :(
[22:11:32] eam: eg set_watchdog(); blocking_call(); unset_watchdog()
[22:11:44] baweaver: has joined #ruby
[22:11:47] eam: kinduff: but, you really should use IO.select
[22:11:58] prasselpikachu: has joined #ruby
[22:12:00] Janusz1: has joined #ruby
[22:12:07] paulcsmith: has joined #ruby
[22:12:12] kinduff: eam: thanks!
[22:12:19] skmp: has joined #ruby
[22:12:21] eam: raising in another thread is essentially like dropping in a goto randomly
[22:12:25] warreng: has joined #ruby
[22:12:26] KetaPan: has joined #ruby
[22:12:31] slash_nick: has joined #ruby
[22:12:31] slash_nick: has joined #ruby
[22:12:32] Shidash: has joined #ruby
[22:13:22] dopie: has joined #ruby
[22:13:26] digifiv5e: has joined #ruby
[22:13:29] chipotle: has joined #ruby
[22:14:21] eroc: Is there a way to do something like eval to execute arbitrary code, but to specify what subset of Ruby is considered valid? Specifically, I don't want people to be able to use System or something like that. I'd also like to avoid having to create a parser. Any ideas?
[22:14:44] havenwood: Eroc: What do you need to parse in particular?
[22:14:55] zacstewa_: has joined #ruby
[22:14:56] casadei: has joined #ruby
[22:15:01] zendrix: has joined #ruby
[22:15:20] uber: has joined #ruby
[22:15:45] havenwood: Eroc: You just want a syntax check?
[22:15:54] eroc: Logical expressions. I want to have a hash that represents some context, but then it would just be operations on that. Here's an example: "context[:foo][:bar] == 'baz'"
[22:16:16] havenwood: Eroc: ruby -c -e "context[:foo][:bar] == 'baz'"
[22:16:24] havenwood: Eroc: #=> Syntax OK
[22:17:02] eroc: havenwood: Yes, a syntax check, but I want the universe of what can be evaluated minimized. So, no system calls, no logging, etc.
[22:17:14] eroc: I want to eval something in a safe way.
[22:17:24] momomomomo_: has joined #ruby
[22:17:31] eroc: And seriously restrict what the user does and does not have access to.
[22:18:00] eroc: And also make a few convenience methods available to the user.
[22:18:14] havenwood: Eroc: So you want to check the syntax of the script and exit without executing?
[22:18:29] fantasti`: has joined #ruby
[22:18:49] eroc: No, if it is valid and within the subset of Ruby that I consider safe, then I want to execute it.
[22:19:18] dented42: has joined #ruby
[22:19:35] zenspider: zomg it's been hours! what'd I miss!?!?!
[22:19:42] eam: Eroc: unlikely to be an effective approach outside of an academic exercise; it's pretty easy to break out of limits
[22:21:13] zenspider: Eroc: you can use a combination of ruby_parser + sexp_processor to write a validator
[22:21:26] eroc: eam: Any ideas on a safe way to write this? I'm thinking I might need to define my own Ruby-like language for the expressions and write a parser for it.
[22:21:27] kfpratt: has joined #ruby
[22:21:34] benlieb_: has joined #ruby
[22:21:50] eroc: I agree that calling eval itself is probably going to be pretty messy and error-pront.
[22:22:02] havenwood: Eroc: Why are you doing this?
[22:22:13] zenspider: you don't even need to use eval if you don't want to, given my suggestion above
[22:23:22] eroc: I am implementing a workflow system and each node in the workflow needs a series of conditions that determine what the next step in the workflow is. Each condition looks at data gathered previously in the workflow to make the determination.
[22:23:28] alphaatom: has joined #ruby
[22:23:32] eroc: zenspider: Missed your comment. I'll check those out.
[22:23:59] workmad3: has joined #ruby
[22:24:56] vickleton: has joined #ruby
[22:25:51] revoohc: has joined #ruby
[22:27:15] bootstrappm: has joined #ruby
[22:30:24] jpfuentes2: has joined #ruby
[22:30:44] mcclurmc: has joined #ruby
[22:31:13] howdoicomputer: has joined #ruby
[22:33:16] irb1: has joined #ruby
[22:36:28] irb1: hello all
[22:37:22] irb1: anyone have experience with the rest-client gem?
[22:38:30] Senjai: ?use irb1
[22:38:30] ruboto: irb1, Don't ask "does anyone use <thing>?". It's better to just state your problem and if anyone has used <thing> they will most likely answer.
[22:39:26] irb1: i am am trying to set the correct http headers using a cookie value but with no luck
[22:39:30] ylluminarious: has joined #ruby
[22:39:35] irb1: these are the values i am trying to set
[22:39:36] irb1: Cookie:NITRO_AUTH_TOKEN=<tokenvalue>
[22:39:37] irb1: Content-Type:application/vnd.com.citrix.netscaler.nsfeature+json
[22:39:40] Radar: http headers with a cookie value? :\
[22:39:56] Radar: Are you conflating HTTP headers and cookies?
[22:40:25] irb1: the ???content??? header i am setting correctly but the cookies i can???t seem to correctly name and pass
[22:40:37] irb1: well the cookies are set in the headers :>)
[22:40:46] irb1: per the protocol
[22:40:59] Ropeney: has joined #ruby
[22:41:10] luckyno7: has joined #ruby
[22:41:39] irb1: and i am following this documentation to set the correct cookie value http://www.rubydoc.info/gems/rest-client/1.8.0
[22:42:03] irb1: this is my code
[22:42:04] irb1: data_response = RestClient.post(url,feats, :cookies => {"NITRO_AUTH_TOKEN" => session_token}, :content_type => "application/vnd.com.citrix.netscaler.nsconfig+json")
[22:42:36] irb1: that is failing
[22:43:53] tflat_: has joined #ruby
[22:44:14] workmad3: has joined #ruby
[22:44:17] Asher: has joined #ruby
[22:44:26] dseitz: has joined #ruby
[22:44:43] jeanlinux: has joined #ruby
[22:44:46] irb1: any help would be appreciated
[22:45:53] Senjai: ?gist irb1
[22:45:53] ruboto: irb1, https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[22:46:27] bootstrappm: irb1 as Radar said, the cookie value doesn't go in the HTTP header, the cookie ID does
[22:46:37] bootstrappm: or so i thought
[22:47:36] apeiros: bootstrappm: no. the complete cookie is in the headers.
[22:47:48] bootstrappm: yep, just checked, you're right
[22:47:52] apeiros: bootstrappm: your webframework may choose to associate data with your cookie, and store those elsewhere
[22:48:07] apeiros: and that's then usually called "session data"
[22:48:37] bootstrappm: so yeah, in that case irb1, gist some code and send it over
[22:50:19] jfarmer: has joined #ruby
[22:50:36] irb1: https://gist.github.com/anonymous/51ef5570e0cd1dc67893
[22:51:52] cbz: has joined #ruby
[22:57:33] blaines: has joined #ruby
[22:57:35] celly: has joined #ruby
[22:58:49] michael_mbp: has joined #ruby
[22:59:09] danman: has joined #ruby
[23:02:00] jenrzzz: has joined #ruby
[23:03:18] danielpclark: has joined #ruby
[23:05:53] sgambino: has joined #ruby
[23:06:47] rickmasta: has joined #ruby
[23:07:09] NeverDie: has joined #ruby
[23:08:04] ItSANgo__: has joined #ruby
[23:08:20] langlands: has joined #ruby
[23:09:13] Indian: has joined #ruby
[23:09:27] langlands: has joined #ruby
[23:10:08] dseitz: has joined #ruby
[23:10:24] endash: has joined #ruby
[23:12:39] neanderslob: has joined #ruby
[23:14:14] balazs_: has joined #ruby
[23:14:15] paulcsmith: has joined #ruby
[23:20:09] djbkd: has joined #ruby
[23:20:42] cbz: has joined #ruby
[23:20:52] Muhannad: has joined #ruby
[23:21:32] startupality: has joined #ruby
[23:22:55] howdoicomputer: has joined #ruby
[23:24:16] ruboto: al2o3-cr # => /tmp/execpad-0d4e16032159/source-0d4e16032159:2: syntax error, unexpected '>' ...check link for more (https://eval.in/390695)
[23:27:28] dgutierrez1287: has joined #ruby
[23:27:52] sbhatore: has joined #ruby
[23:29:32] mcclurmc: has joined #ruby
[23:30:26] nettoweb: has joined #ruby
[23:31:40] renderful: has joined #ruby
[23:32:00] icarus_: has joined #ruby
[23:32:50] j4cknewt: has joined #ruby
[23:33:16] dgutierrez1287: has joined #ruby
[23:33:57] hinbody: has joined #ruby
[23:37:17] baweaver: has joined #ruby
[23:37:28] ESpiney_: has joined #ruby
[23:37:57] chouhoulis: has joined #ruby
[23:38:03] serivich: has joined #ruby
[23:39:16] n_blownapart: has joined #ruby
[23:42:19] mcclurmc: has joined #ruby
[23:44:21] dgutierrez1287: has joined #ruby
[23:44:24] duncannz: has joined #ruby
[23:46:53] tuelz: has joined #ruby
[23:46:54] FernandoBasso: has joined #ruby
[23:47:34] idafyaid: has joined #ruby
[23:48:12] momomomomo_: has joined #ruby
[23:48:51] nettoweb: has joined #ruby
[23:48:56] RegulationD: has joined #ruby
[23:49:28] bullcitydev: has joined #ruby
[23:50:11] kfpratt: has joined #ruby
[23:51:36] ellisTAA: has joined #ruby
[23:51:43] jeramy_s: has joined #ruby
[23:52:12] kinduff: has joined #ruby
[23:52:12] kinduff: has joined #ruby
[23:53:08] bootstrappm: has joined #ruby
[23:54:02] mrmargolis: has joined #ruby
[23:54:31] jtdoncas: has joined #ruby
[23:57:14] senayar: has joined #ruby
[23:59:22] rcvalle: has joined #ruby