« Back to channel list

#ruby - 07 April 2017

« Back 1 day Forward 1 day »
[00:01:10] marcdel: has joined #ruby
[00:01:21] gusrub: has joined #ruby
[00:04:47] duckpupp1: has joined #ruby
[00:05:01] Rodya_: has joined #ruby
[00:06:53] JeanCarloMachado: has joined #ruby
[00:09:12] kith: has joined #ruby
[00:09:51] CloCkWeRX: has joined #ruby
[00:11:10] charliesome: has joined #ruby
[00:16:01] knight33: has joined #ruby
[00:16:07] fmcgeough: has joined #ruby
[00:18:57] AndBobsYourUncle: has joined #ruby
[00:26:09] charliesome: has joined #ruby
[00:28:07] binaryplease: has joined #ruby
[00:29:25] Guest96: has joined #ruby
[00:32:02] minimalism: has joined #ruby
[00:37:09] LuckyABA: has joined #ruby
[00:39:57] gusrub: has joined #ruby
[00:40:29] ctompkinson: has joined #ruby
[00:42:30] jgt1: has joined #ruby
[00:46:59] chouhoulis: has joined #ruby
[00:48:50] esObe_: has joined #ruby
[00:48:58] agent_white: has joined #ruby
[00:50:18] armyriad: has joined #ruby
[00:51:03] Betwack: has joined #ruby
[00:51:55] Pumukel: has joined #ruby
[00:52:20] PaulCapestany: has joined #ruby
[00:55:34] lethan: has joined #ruby
[01:04:46] danielpclark: has joined #ruby
[01:05:46] juggler: has joined #ruby
[01:06:42] chouhoulis: has joined #ruby
[01:08:12] charliesome: has joined #ruby
[01:08:31] jusa: has joined #ruby
[01:21:32] JeanCarloMachado: has joined #ruby
[01:23:37] gdonald: has joined #ruby
[01:24:34] BTRE: has joined #ruby
[01:33:48] gusrub: has joined #ruby
[01:41:56] ptx0: has joined #ruby
[01:42:28] knight33: has joined #ruby
[01:43:08] im314ous_: has joined #ruby
[01:45:48] hndk: has joined #ruby
[01:46:38] gdonald: has joined #ruby
[01:48:10] ule: has joined #ruby
[01:51:32] raul782: has joined #ruby
[01:53:27] Rodya_: has joined #ruby
[01:53:54] Pumukel: has joined #ruby
[01:54:54] d^sh: has joined #ruby
[02:01:08] xall: has joined #ruby
[02:03:20] Verity: I bought "the ruby programming language" but now looking at the 1.8 on cover I fear its out of date
[02:03:42] Rodya_: has joined #ruby
[02:04:54] libastral: has joined #ruby
[02:05:48] duckpupp1: has joined #ruby
[02:07:10] baweaver: heavily. There's a 2.0 version
[02:08:35] hutch34_: has joined #ruby
[02:08:36] Verity: in print?
[02:08:54] Verity: It's actually 1.9
[02:09:11] Channel6: has joined #ruby
[02:10:07] dar123: has joined #ruby
[02:11:05] baweaver: Ah, was thinking pickaxe book
[02:11:09] jeyraof^mbpr: has joined #ruby
[02:11:59] tercenya: has joined #ruby
[02:19:35] Jayson_Virissimo: has joined #ruby
[02:20:49] Jameser: has joined #ruby
[02:29:27] Xiti: has joined #ruby
[02:30:16] spicerack: has joined #ruby
[02:30:39] JoshS: has joined #ruby
[02:30:40] gusrub: has joined #ruby
[02:30:47] Rodya_: has joined #ruby
[02:32:06] charliesome: has joined #ruby
[02:33:11] Verity: .1 version different can't be too significant, hopefully
[02:33:19] JoshS: has joined #ruby
[02:35:12] JoshS: has joined #ruby
[02:36:57] naprimer: has joined #ruby
[02:37:08] t-recx: I've read it and found it useful when I was learning ruby not that long ago
[02:37:12] __Yiota: has joined #ruby
[02:37:17] JoshS: has joined #ruby
[02:41:09] ctompkinson: has joined #ruby
[02:42:25] BTRE: has joined #ruby
[02:46:09] itsautomatisch: has joined #ruby
[02:47:34] cfec0b8d1: has joined #ruby
[02:50:18] esObe_: has joined #ruby
[02:57:34] cfec0b8d: has joined #ruby
[03:01:33] enterprisey: has joined #ruby
[03:02:34] cfec0b8d: has joined #ruby
[03:07:13] naprimer: has joined #ruby
[03:09:24] jeffreylevesque: has joined #ruby
[03:10:27] ptx0: has joined #ruby
[03:10:41] xall: has joined #ruby
[03:11:28] dar123: has joined #ruby
[03:18:30] hutch34_: has joined #ruby
[03:23:20] etehtsea: has joined #ruby
[03:23:59] spicerack: has joined #ruby
[03:29:39] pifon: has joined #ruby
[03:32:03] _tk421_: has joined #ruby
[03:34:11] xall: has joined #ruby
[03:34:56] __Yiota: has joined #ruby
[03:46:04] claw: has joined #ruby
[03:49:43] gix: has joined #ruby
[03:50:35] statelesscode: has joined #ruby
[03:56:17] raul782: has joined #ruby
[03:57:53] Pumukel: has joined #ruby
[04:01:02] gusrub: has joined #ruby
[04:03:07] allisio: Verity: 1.8 -> 1.9 was considerably bumpier than 1.9 -> 2.0, for your records.
[04:04:55] allisio: You only said ".1", not words like "major" and "minor", but I trust you see the point I mean to make.
[04:06:34] duckpupp1: has joined #ruby
[04:07:41] raul782: has joined #ruby
[04:11:51] duderonomy: has joined #ruby
[04:13:47] minimalism: has joined #ruby
[04:19:35] hutch34_: has joined #ruby
[04:20:00] Azure|dc: has joined #ruby
[04:20:32] Rodya_: has joined #ruby
[04:21:05] JeanCarloMachado: has joined #ruby
[04:22:00] astrobunny: has joined #ruby
[04:27:30] yaewa: has joined #ruby
[04:29:08] jcao219: has joined #ruby
[04:33:11] _whitelogger: has joined #ruby
[04:34:24] renchan: has joined #ruby
[04:39:04] djbkd: has joined #ruby
[04:41:28] Guest96: has joined #ruby
[04:41:49] ctompkinson: has joined #ruby
[04:43:33] Verity: allisio, I'm not sure I do. Is this book a good choice for me?
[04:43:50] nofxxx: has joined #ruby
[04:46:24] cschneid_: has joined #ruby
[04:50:12] knight33: has joined #ruby
[04:51:43] esObe_: has joined #ruby
[04:52:47] moei: has joined #ruby
[04:54:20] ovaltine: has joined #ruby
[04:55:22] jane_booty_doe: has joined #ruby
[04:59:44] Pumukel: has joined #ruby
[05:03:02] Pumukel: has joined #ruby
[05:03:54] milardovich: has joined #ruby
[05:04:59] Pumukel: has joined #ruby
[05:05:11] nadir: has joined #ruby
[05:06:00] Pumukel: has joined #ruby
[05:06:12] Pumukel: has joined #ruby
[05:14:02] howdoi: has joined #ruby
[05:14:25] BabyMario: has joined #ruby
[05:15:12] Bock: has joined #ruby
[05:15:31] jcao219: has joined #ruby
[05:15:42] dhollinger: has joined #ruby
[05:16:49] binarycodess: has joined #ruby
[05:21:27] Rodya_: has joined #ruby
[05:25:12] binarycodess: has joined #ruby
[05:30:53] harfangk: has joined #ruby
[05:32:34] qba73: has joined #ruby
[05:34:30] BabyMario: has left #ruby: ("bbl")
[05:35:56] gdonald: has joined #ruby
[05:37:04] toretore: has joined #ruby
[05:38:47] jaequery: has joined #ruby
[05:39:30] bjfish2: has joined #ruby
[05:43:08] jgt1: has joined #ruby
[05:44:28] last_staff: has joined #ruby
[05:45:39] burgestrand: has joined #ruby
[05:45:50] anisha: has joined #ruby
[05:52:24] FastJack: has joined #ruby
[05:53:32] milardovich: has joined #ruby
[06:00:37] Rodya_: has joined #ruby
[06:00:44] duckpupp1: has joined #ruby
[06:05:38] Beverage: has joined #ruby
[06:07:55] biberu: has joined #ruby
[06:11:01] binarycodess: has joined #ruby
[06:13:11] qba73: has joined #ruby
[06:14:04] User458764: has joined #ruby
[06:14:58] vali: has joined #ruby
[06:21:08] binarycodess: has joined #ruby
[06:21:31] JeanCarloMachado: has joined #ruby
[06:22:58] harfangk: has joined #ruby
[06:23:03] binarycodess: has joined #ruby
[06:23:46] binarycodess: has left #ruby: ()
[06:24:56] binarycodess: has joined #ruby
[06:26:23] def_jam: has joined #ruby
[06:27:08] eb0t_: has joined #ruby
[06:34:23] andikr: has joined #ruby
[06:34:41] gigetoo: has joined #ruby
[06:36:21] Bozo: has joined #ruby
[06:37:44] raul782: has joined #ruby
[06:39:32] binarycodess: has joined #ruby
[06:41:14] jamesaxl: has joined #ruby
[06:41:32] last_staff: has joined #ruby
[06:42:49] ctompkinson: has joined #ruby
[06:45:36] raul782: has joined #ruby
[06:45:39] kernelPaniq: has joined #ruby
[06:48:20] jusa: has joined #ruby
[06:48:35] flying: has joined #ruby
[06:51:38] charliesome: has joined #ruby
[06:52:09] InsaneSplash: has joined #ruby
[06:52:53] InsaneSplash: morning, could someone tell me what this content looks like in Ruby, is this a hash? #<TEXT:0x815e32c0
[06:53:06] esObe_: has joined #ruby
[06:53:27] havenwood: InsaneSplash: That looks like an instance of a TEXT, whatever that is. Where's it from?
[06:54:44] havenwood: InsaneSplash: Ask it its class?: #<TEXT:...>.class
[06:55:21] havenwood: InsaneSplash: Consider taking a look at it with Pry.
[06:55:23] ruby[bot]: Pry, the better IRB, provides easy object inspection `ls`, `history`, viewing docs `?`, viewing source `$`, syntax highlighting and other features (see `help` for more). Put `binding.pry` in your source code for easy debugging. Install Pry (https://pryrepl.org/): gem install pry pry-doc
[06:58:05] InsaneSplash: cool, i tried pp, but that didnt help
[06:58:11] InsaneSplash: let me have a squiz
[06:59:24] Silthias: has joined #ruby
[07:04:03] BTRE: has joined #ruby
[07:07:20] patarr: has joined #ruby
[07:08:44] brianpWins: has joined #ruby
[07:09:29] TomyWork: has joined #ruby
[07:09:37] skweek: has joined #ruby
[07:11:09] burgestrand: has joined #ruby
[07:13:28] astrobunny: has joined #ruby
[07:15:06] esObe_: has joined #ruby
[07:16:57] solocshaw: has joined #ruby
[07:17:41] esObe_: has joined #ruby
[07:17:49] aufi: has joined #ruby
[07:21:57] Rodya_: has joined #ruby
[07:23:19] hutch34_: has joined #ruby
[07:24:46] Arpanet69: has joined #ruby
[07:26:56] djbkd: has joined #ruby
[07:28:50] cyphase: has joined #ruby
[07:29:04] mark_66: has joined #ruby
[07:35:44] vondruch: has joined #ruby
[07:36:22] griff: has joined #ruby
[07:44:37] solocshaw: has joined #ruby
[07:55:24] grh: has joined #ruby
[07:57:57] burgestrand: has joined #ruby
[07:58:25] DaniG2k: has joined #ruby
[07:59:44] blackmesa: has joined #ruby
[08:02:34] duckpupp1: has joined #ruby
[08:05:41] raul782: has joined #ruby
[08:06:42] manjaro-kde5: has joined #ruby
[08:07:25] romain_t: has joined #ruby
[08:08:03] ctompkinson: has joined #ruby
[08:10:05] jeyraof^mbpr: has joined #ruby
[08:11:53] Beams: has joined #ruby
[08:14:23] dionysus69: has joined #ruby
[08:15:09] gdonald: has joined #ruby
[08:16:54] grillon_: has joined #ruby
[08:19:29] mim1k: has joined #ruby
[08:20:25] xall: has joined #ruby
[08:20:29] rgtk: has joined #ruby
[08:21:48] marr: has joined #ruby
[08:26:40] johnzorn: has joined #ruby
[08:33:02] jeyraof^mbpr: has joined #ruby
[08:35:18] jsrn__: has joined #ruby
[08:43:17] nhhc: has joined #ruby
[08:45:48] xdqioh: has joined #ruby
[08:53:37] jlebrech: has joined #ruby
[08:54:20] jlebrech: is there a way for a yield inside of a block to set variable outside of the block rather than need to create a nil value before the block?
[08:54:45] matthewd: jlebrech: No
[08:55:03] govg: has joined #ruby
[08:56:23] lxsameer: has joined #ruby
[09:04:00] sepp2k: has joined #ruby
[09:08:14] patarr: has joined #ruby
[09:09:50] pandaant: has joined #ruby
[09:11:27] johnzorn: has joined #ruby
[09:11:58] netmole: has joined #ruby
[09:12:16] netmole: good day rubbists
[09:13:01] netmole: i have strange error with ransack gem can anyone take look on this http://stackoverflow.com/q/43271132/6925129
[09:15:59] johnzorn: has joined #ruby
[09:16:28] ledestin: has joined #ruby
[09:17:58] mim1k: has joined #ruby
[09:18:53] dminuoso: netmole: What exactly is the problem you are experiencing?
[09:19:09] centrx: has joined #ruby
[09:19:09] centrx: has joined #ruby
[09:19:46] dminuoso: Ohh nevermind I spotted it.
[09:19:47] netmole: i am have controller when i am search two tems
[09:19:55] dminuoso: netmole: the problem is with how you use modifier_unless
[09:19:57] dminuoso: Let me demonstrate
[09:20:16] dminuoso: >> a = "foo"; a = 1 if false; p a
[09:20:17] ruby[bot]: dminuoso: # => "foo" ...check link for more (https://eval.in/770087)
[09:20:56] tvw: has joined #ruby
[09:22:03] netmole: well how to use code which executes when is no params [q ] or key in q datum_eq or sklad_id and recall controller with new search terms
[09:22:07] dminuoso: netmole: mm, Im not sure whether its a wise idea to modify the ransack objec directly
[09:22:38] netmole: well exist any other way
[09:23:24] centrx: There is no code
[09:24:34] dminuoso: Sure, you could do something like def defaultFilter; return { datum_eq: Date.current, cil_id_eq = Sklad.first.id }; end; and then inside your action you do: filters = params[:q] || defaultFilter(); @events = Event.search(filters).result
[09:24:44] dminuoso: netmole: ^- something along those lines.
[09:24:47] Guest96: has joined #ruby
[09:24:50] hutch34_: has joined #ruby
[09:25:24] dminuoso: Oh well, slight typo there in the Hash, but you get the idea.
[09:26:26] dminuoso: Or better yet to keep things more testable:
[09:27:07] cfec0b8d: has joined #ruby
[09:27:55] netmole: https://gist.github.com/netmoleCBA/4d2b302653bf8be22586087beae3882c
[09:28:08] dminuoso: netmole: https://gist.github.com/dminuoso/34fb3d73b6dbd8e21bbe614e5db648fd
[09:28:29] johnzorn: has joined #ruby
[09:28:57] dminuoso: Or better yet!
[09:29:46] dminuoso: Ah well lets not bikeshed.
[09:32:33] dminuoso: netmole: By the way you should be using .ransack instead of .search - .search will be deprecated.
[09:34:09] netmole: thanks a lot
[09:38:15] skweek: has joined #ruby
[09:41:07] rgr: has joined #ruby
[09:54:52] v1n: has joined #ruby
[09:56:20] blackmesa: has joined #ruby
[09:56:35] mikecmpbll: has joined #ruby
[10:03:16] duckpupp1: has joined #ruby
[10:06:26] patarr: has joined #ruby
[10:06:40] Beams: has joined #ruby
[10:09:03] raul782: has joined #ruby
[10:11:59] howlinbash: has joined #ruby
[10:12:00] GSilva: has joined #ruby
[10:14:41] mim1k: has joined #ruby
[10:16:16] Lartza: has joined #ruby
[10:16:31] Lartza: How do I force a program to use gems installed into vendor/bundle or similar
[10:16:43] Lartza: sudo bundle install sounds like the worst idea ever so that's not a solution
[10:17:54] matthewd: Lartza: bundle exec
[10:18:39] Lartza: Oh yeah, thanks :)
[10:23:12] futilegames: has joined #ruby
[10:24:34] milardovich: has joined #ruby
[10:26:21] nowhereman: has joined #ruby
[10:30:06] aupadhye: has joined #ruby
[10:30:17] kke: has joined #ruby
[10:33:48] AnoHito: has joined #ruby
[10:36:10] BSaboia: has joined #ruby
[10:44:20] fergal: has joined #ruby
[10:44:52] dasher00: has joined #ruby
[10:46:05] johnzorn: has joined #ruby
[10:46:21] IRCFrEAK: has joined #ruby
[10:47:54] IRCFrEAK: has left #ruby: ()
[10:48:05] burgestrand: has joined #ruby
[10:48:23] HoloIRCUser6: has joined #ruby
[10:51:07] Fernando-Basso: has joined #ruby
[10:51:16] milardovich: has joined #ruby
[10:52:46] Ishido: has joined #ruby
[10:57:22] nadir: has joined #ruby
[10:57:37] mim1k: has joined #ruby
[11:00:31] netmole: has joined #ruby
[11:01:24] Arpanet69: has joined #ruby
[11:03:16] Beams: has joined #ruby
[11:05:01] Beams: has joined #ruby
[11:05:44] netmole_: has joined #ruby
[11:07:30] netmole_: good day rubbists
[11:08:20] duckpupp1: has joined #ruby
[11:09:03] User458764: has joined #ruby
[11:11:22] gdonald: has joined #ruby
[11:20:35] Guest96: has joined #ruby
[11:22:34] millerti: has joined #ruby
[11:23:57] Arpanet69: has joined #ruby
[11:24:55] uyptva: has joined #ruby
[11:25:33] burgestrand: has joined #ruby
[11:26:45] hutch34_: has joined #ruby
[11:28:31] blackmesa: has joined #ruby
[11:31:33] netmole_: i am thanked to dminuso for his help https://gist.github.com/dminuoso/34fb3d73b6dbd8e21bbe614e5db648fd but it has one drawback with this hack short_link ignores search fields because path wont change with changed search criteria
[11:37:04] conta: has joined #ruby
[11:37:28] ldnunes: has joined #ruby
[11:37:44] milardovich: has joined #ruby
[11:39:01] JeanCarloMachado: has joined #ruby
[11:43:05] Hekata: has joined #ruby
[11:43:13] rgtk: has joined #ruby
[11:43:52] dminuoso: netmole_: You can fix this with the following modification:
[11:44:18] dminuoso: netmole_: @ransacked_object.sorts = "id DESC" if @ransacked_object.sorts.empty?
[11:44:33] dminuoso: If you want some default sort order.
[11:44:52] dminuoso: netmole_: Or.. mm. I understand -> but you can still do the same thing. Just activate your brian.
[11:45:23] dminuoso: Either use a different object to transport sort information, or just check whether params[:q] has anything beyond sort links.
[11:46:42] dminuoso: netmole_: Keep in mind that I would be careful about default filters in the backend like this, as its opaque to the user.
[11:47:54] dminuoso: I.e. if you could just default the search fields in the frontend, then your controller gets easier because it will provide *exactly* what its asked of.
[11:48:04] dminuoso: And you could immediately provide some visual clue to the user.
[11:50:43] dionysus69: um any ideas how I can run ruboto example app I downloaded from ruboto repo on android?
[11:50:57] cfec0b8d: has joined #ruby
[11:50:58] dionysus69: there's no documentation about that I could find
[11:52:40] User458764: has joined #ruby
[11:54:53] AnoHito: has joined #ruby
[11:57:01] knight33: has joined #ruby
[11:59:29] raul782: has joined #ruby
[11:59:46] GodFather_: has joined #ruby
[12:03:11] HoierM: has joined #ruby
[12:16:13] ayonkhan: has joined #ruby
[12:16:19] raspado: has joined #ruby
[12:17:16] ctompkinson: has joined #ruby
[12:17:37] moeSizlak: has joined #ruby
[12:17:56] moeSizlak: any idea why installing filemagic gem wants to install 50 other gems, including rails, sinatra, etc?
[12:18:39] matthewd: moeSizlak: Because it depends on them?
[12:18:50] moeSizlak: it didnt used to
[12:18:59] moeSizlak: and no, it cant possibly
[12:19:37] matthewd: https://rubygems.org/gems/filemagic shows two versions, with identical deps
[12:20:18] allisio: moeSizlak: I think you probably used a different Ruby wrapper around libmagic.
[12:20:35] allisio: There's a gem called ruby-filemagic that might be the one you used previously.
[12:20:35] mnemon: moeSizlak: there's also ruby-filemagic with less dependencies
[12:21:07] bonhoeffer: has joined #ruby
[12:21:36] charliesome: has joined #ruby
[12:21:44] canton7: filemagic has a runtime dependency of rails, ruby-filemagic doesn't. I suspect you used ruby-filemagic before ;)
[12:22:07] allisio: Why on earth does filemagic have rails as a dependency, though?
[12:23:19] burgestrand: Heh, because it provides a form builder helper.
[12:23:37] cfec0b8d: has joined #ruby
[12:23:37] burgestrand: Looks like it also provides controllers for upload/deletion.
[12:25:15] burgestrand: Quite simply it's a rails engine.
[12:26:45] matthewd: It still shouldn't actually depend on rails, but rather railties -- though that wouldn't really solve the "why am I downloading half the internet" problem
[12:27:26] allisio: dminuoso: I really want to pass a Proc to Binding#eval. Please halp.
[12:27:37] hutch34_: has joined #ruby
[12:28:10] allisio: InstructionSequence#to_s -> valid Ruby would be <3.
[12:29:20] charliesome: has joined #ruby
[12:30:48] shortCiruit__: has joined #ruby
[12:30:54] shortCiruit__: I had a question
[12:31:11] allisio: Do you still have it?
[12:31:44] shortCiruit__: lets say there is class A def abc puts "super" end end . and class B < A end .. now if I say B.new.abc .. is it possible to know inside abc who called the method
[12:32:36] mim1k: has joined #ruby
[12:32:55] allisio: shortCiruit__: https://eval.in/770373
[12:33:55] shortCiruit__: the problem I am having is with the current setup of an application we have, the letter_opener is not working .. so we have a super class called template .. where I added a show_email method, which write the email to an html file in tmp/ . what I am facing problem is naming the output file .. so if its say EmailVerificationTemplate < EMailTemplate .. then EmailVerificationTemplate.new.show_email would create a file like email_ver
[12:34:12] blackmesa: has joined #ruby
[12:37:16] GSilva: has joined #ruby
[12:39:09] CGibsonmm: has joined #ruby
[12:39:41] hutch34_: has joined #ruby
[12:41:01] moeSizlak: thank you mnemon that was my problem
[12:41:05] moeSizlak: has left #ruby: ("Leaving")
[12:43:05] milardovich: has joined #ruby
[12:44:05] fmcgeough: has joined #ruby
[12:44:27] pulkit4tech: has joined #ruby
[12:44:34] pupsicle: has joined #ruby
[12:45:13] haxrbyte: has joined #ruby
[12:47:02] mim1k: has joined #ruby
[12:47:32] aupadhye: has joined #ruby
[12:55:19] hutch34_: has joined #ruby
[13:02:50] GodFather_: has joined #ruby
[13:03:29] rwb: has joined #ruby
[13:03:41] jeffreylevesque: has joined #ruby
[13:09:06] am55: has joined #ruby
[13:11:50] __Yiota: has joined #ruby
[13:12:09] hutch34_: has joined #ruby
[13:14:52] blackmesa: has joined #ruby
[13:16:53] burgestrand: has joined #ruby
[13:17:55] griff: has joined #ruby
[13:25:59] rippa: has joined #ruby
[13:26:04] patarr: has joined #ruby
[13:28:27] haxrbyte: has joined #ruby
[13:29:28] zun: has joined #ruby
[13:31:27] sifu: has joined #ruby
[13:32:48] User458764: has joined #ruby
[13:34:34] gk_1wm_su: has joined #ruby
[13:36:26] mrgrieves: has joined #ruby
[13:37:55] Ishido: has joined #ruby
[13:38:35] raul782: has joined #ruby
[13:40:12] rgtk: has joined #ruby
[13:41:55] DLSteve: has joined #ruby
[13:43:00] Ishido: has joined #ruby
[13:43:38] charliesome: has joined #ruby
[13:43:51] Ishido: has joined #ruby
[13:46:34] patarr: has joined #ruby
[13:48:45] burgestrand: has joined #ruby
[13:51:07] mim1k: has joined #ruby
[13:52:31] soahccc: Do you guys prefer A: class MyException < ArgumentError; end or B: MyException = Class.new(ArgumentError)
[13:53:44] soahccc: I find B cleaner but with A it's easier to read what it inherits from since it's directly next to each other
[13:53:48] allisio: Semicolons are strictly verboten by some style guides.
[13:54:04] soahccc: yeah I don't really like the 2 line version as well :D
[13:54:14] allisio: The choice is clear.
[13:54:34] allisio: Class.new with an argument should read just as clearly to anybody who knows the rudiments of the language.
[13:57:40] soahccc: allisio: that is true but I see A a lot in gems but Class.new I haven't seen in the wild so far
[13:58:07] allisio: soahccc: Read more code, I guess?
[14:01:00] Pumukel: has joined #ruby
[14:02:08] ctompkinson: has joined #ruby
[14:02:47] vuoto: has joined #ruby
[14:03:29] milardovich: has joined #ruby
[14:03:30] patarr: has joined #ruby
[14:03:45] allisio: soahccc: Rake, RSpec, RuboCop, and Sequel all use `Class.new(StandardError)` all over the place.
[14:03:55] haylon: has joined #ruby
[14:04:13] allisio: As do thousands of other gems, I'm sure.
[14:07:39] soahccc: allisio: I will do that then I guess. I looked at the wrong gems it seems :) I just noticed that Sequel did it this way but with a weird ().name wrapper
[14:07:55] mim1k: has joined #ruby
[14:08:51] b3l914n: has joined #ruby
[14:09:12] bjfish2: has joined #ruby
[14:09:22] allisio: soahccc: Only in one place, and it appears to be some kind of stop-gap.
[14:09:58] solocshaw: has joined #ruby
[14:10:43] allisio: Oh, never mind. That is weird.
[14:11:23] allisio: Are they doing that to appease the documentation generator or some such?
[14:12:31] soahccc: allisio: hmm.... https://github.com/jeremyevans/sequel/commit/9d420c2169bcd27d2b27317d96bdb297f4d653fa
[14:12:43] jlebrech: how do gems perform something on the next line of a helper, say here for example? https://www.skylight.io/support/getting-more-from-skylight#method-instrumentation
[14:12:48] max_v: has joined #ruby
[14:13:34] allisio: soahccc: Huh. Good find. I've always assumed assigning to a constant was sufficient.
[14:13:35] jlebrech: caller line number + 1 and monkey patch that method?
[14:14:11] allisio: jlebrech: It's not clear what you're asking.
[14:14:24] yeticry_: has joined #ruby
[14:14:40] soahccc: allisio: so it's ruby cache? If I have to call name on them now I might as well just use the "old fashion" way?
[14:15:31] jlebrech: say i want to put "add_new_line_to_all_puts" before def a_method_that_outputs_stuff
[14:16:10] allisio: soahccc: Seems so. Feels like an unnecessary optimization to me.
[14:16:14] jlebrech: i see those helper methods that perform an action on the next code
[14:17:01] workmad3: has joined #ruby
[14:17:24] dysfigured: has joined #ruby
[14:17:37] User458764: has joined #ruby
[14:18:03] soahccc: jlebrech: Do you really want this? I already hate the way private/protected works. I personally prefer blocks depending on the actual case
[14:19:05] cfec0b8d: has joined #ruby
[14:19:14] solocshaw: has joined #ruby
[14:19:32] jlebrech: soahccc: not per se, just wanted to know how it works
[14:19:40] skweek: has joined #ruby
[14:20:05] jlebrech: soahccc: i'd rather have this type of code inside of what it wants to affect actually :)
[14:20:29] mim1k: has joined #ruby
[14:20:33] matthewd: jlebrech: Probably method_added. Just find the source for one of the examples you're looking at?
[14:21:38] dysfigured: has joined #ruby
[14:22:01] jlebrech: matthewd: that would be nasty to code :)
[14:22:56] soahccc: jlebrech: in case of instrument_method in your example they use class variables (sorta class globals) to "remember" that the next method is going to be instrumented. How they actually hook into the method? Dirty (imho) metaprogramming... See here https://github.com/skylightio/skylight-ruby/blob/master/lib/skylight/helpers.rb#L81
[14:23:51] soahccc: And yes it's based on method_added as matthewd said
[14:25:51] jlebrech: ew, i'd rather use caller and do the magic from a method.
[14:26:08] __Yiota: has joined #ruby
[14:27:27] mephistophocles: has joined #ruby
[14:30:57] RobertBirnie: has joined #ruby
[14:31:00] Toledo: has joined #ruby
[14:32:22] JeanCarloMachado: has joined #ruby
[14:33:23] synthroid: has joined #ruby
[14:33:50] narval: has joined #ruby
[14:35:08] Mon_Ouie: has joined #ruby
[14:35:28] cdg: has joined #ruby
[14:37:35] ldnunes: has joined #ruby
[14:37:55] rakm: has joined #ruby
[14:39:49] patarr: has joined #ruby
[14:40:38] gk_1wm_su: has joined #ruby
[14:45:15] joelwallis: has joined #ruby
[14:46:39] planigan: has joined #ruby
[14:48:22] __Yiota: has joined #ruby
[14:48:28] Lord_of_Life: has joined #ruby
[14:49:06] [Butch]: has joined #ruby
[14:50:14] shinnya: has joined #ruby
[14:53:12] bjfish2: has left #ruby: ()
[14:53:18] ledestin: has joined #ruby
[14:54:48] jgpawletko: has joined #ruby
[14:55:12] cpruitt: has joined #ruby
[14:59:57] ctompkinson: has joined #ruby
[15:00:45] etehtsea: has joined #ruby
[15:02:03] hahuang61: has joined #ruby
[15:03:32] jusa: has joined #ruby
[15:06:50] cschneid_: has joined #ruby
[15:07:32] kristofferR: has joined #ruby
[15:08:50] JeanCarloMachado: has joined #ruby
[15:08:57] dionysus69: has joined #ruby
[15:09:38] etehtsea: has joined #ruby
[15:10:44] minimalism: has joined #ruby
[15:10:47] tqswkk: has joined #ruby
[15:12:37] LuckyABA: has joined #ruby
[15:13:50] Bock: has joined #ruby
[15:15:59] __Yiota: has joined #ruby
[15:17:10] howlinbash: has joined #ruby
[15:18:56] Bock: has joined #ruby
[15:21:06] gizmore|2: has joined #ruby
[15:21:44] rakm: has joined #ruby
[15:22:43] jcao219: has joined #ruby
[15:23:09] raul782: has joined #ruby
[15:26:23] mim1k: has joined #ruby
[15:26:36] Pumukel: has joined #ruby
[15:27:40] Pumukel: has joined #ruby
[15:28:28] synthroid: has joined #ruby
[15:28:58] raul782: has joined #ruby
[15:31:06] TomyLobo: has joined #ruby
[15:33:46] danguita: has joined #ruby
[15:36:20] blackwind_123: has joined #ruby
[15:36:57] Toledo: has left #ruby: ("http://quassel-irc.org - Chat comfortably. Anywhere.")
[15:37:07] Meow-J: has joined #ruby
[15:41:46] Mon_Ouie: has joined #ruby
[15:42:57] JeanCarloMachado: has joined #ruby
[15:43:32] allisio: jlebrech: One slightly gross way to do it without #method_added is to take advantage of the fact that method definition resolves to a Symbol for the method name.
[15:45:02] jlebrech: allisio: something like a hypothetical: `rainbowify_methods :method1, :method2`
[15:45:28] jlebrech: allisio: and the second example https://www.skylight.io/support/getting-more-from-skylight#method-instrumentation
[15:45:28] matthewd: allisio: That's not gross... that's *why* the method definition now returns the symbol
[15:46:18] allisio: matthewd: Well, sure, it's so that you can say `private def foo...`, but I think they should've gone whole-hog with it and made bespoke method "decoration" easy.
[15:48:38] rakm: has joined #ruby
[15:49:34] allisio: jlebrech: https://eval.in/770493
[15:50:04] jlebrech: allisio: beautiful :)
[15:50:39] antoniobeyah: has joined #ruby
[15:51:19] apeiros: ACTION friday-hugs the channel
[15:51:24] apeiros: weeek-eeeeend! :D
[15:51:44] allisio: matthewd: I once tried to make it look like how Python does it, but just mentioning an instance variable doesn't trigger anything in TracePoint.
[15:52:03] havenwood: apeiros: Happy Freyja's Day!
[15:52:50] baweaver: Thankfully Thorsday is over
[15:56:30] amclain: has joined #ruby
[16:02:14] agent_white: has joined #ruby
[16:02:51] gusrub: has joined #ruby
[16:04:38] matthewd: allisio: https://eval.in/770503
[16:04:45] Xiti: has joined #ruby
[16:06:02] allisio: matthewd: Brilliant.
[16:07:00] johnmilton: has joined #ruby
[16:07:32] tdy: has joined #ruby
[16:08:34] gusrub: has joined #ruby
[16:10:12] __Yiota: has joined #ruby
[16:10:25] cdg_: has joined #ruby
[16:12:08] rwb: has joined #ruby
[16:13:04] cyberRodent: has joined #ruby
[16:16:53] marr: has joined #ruby
[16:19:40] nersoh: has joined #ruby
[16:21:00] nchambers: has joined #ruby
[16:21:15] esObe_: has joined #ruby
[16:22:15] raul782: has joined #ruby
[16:22:29] agent_white: Mornin' folks
[16:23:39] DTSCode: has left #ruby: ()
[16:27:01] nanoz: has joined #ruby
[16:27:27] mim1k_: has joined #ruby
[16:28:57] CGibsonmm: has joined #ruby
[16:32:31] cyberRodent: has joined #ruby
[16:33:46] nitric: has joined #ruby
[16:35:10] FastJack: has joined #ruby
[16:35:20] outreachdan: has joined #ruby
[16:36:06] Ishido: has joined #ruby
[16:36:10] nowhereman: has joined #ruby
[16:37:27] Lord_of_Life: has joined #ruby
[16:40:41] kiltzman: has joined #ruby
[16:41:11] rippa: has joined #ruby
[16:41:35] max_v: has joined #ruby
[16:41:36] kiltzman: has joined #ruby
[16:41:59] esObe_: has joined #ruby
[16:42:18] kiltzman: has joined #ruby
[16:42:36] beatdown: has joined #ruby
[16:42:46] joelwall_: has joined #ruby
[16:44:24] kiltzman: has joined #ruby
[16:44:54] kiltzman: has joined #ruby
[16:45:24] kiltzman: has joined #ruby
[16:45:58] kiltzman: has joined #ruby
[16:46:07] solocshaw: has joined #ruby
[16:47:03] havenwood: agent_white: g'mornin'
[16:52:20] jgpawletko: has joined #ruby
[16:52:43] dionysus69: has joined #ruby
[16:53:20] t-recx: has joined #ruby
[16:54:10] nofxx: has joined #ruby
[16:54:37] rgr_: has joined #ruby
[16:56:42] gigetoo: has joined #ruby
[17:02:58] binarycodess: has joined #ruby
[17:03:06] hahuang61: has joined #ruby
[17:04:23] ResidentBiscuit: has joined #ruby
[17:06:45] jusa: has joined #ruby
[17:06:53] AndBobsYourUncle: has joined #ruby
[17:07:02] naprimer: has joined #ruby
[17:08:14] binarycodess: has joined #ruby
[17:09:42] rwb: has joined #ruby
[17:14:47] mroth: has joined #ruby
[17:17:05] Ishido: has joined #ruby
[17:18:04] preyalone: has joined #ruby
[17:18:44] gusrub: has joined #ruby
[17:19:28] djbkd: has joined #ruby
[17:20:47] moufl: has joined #ruby
[17:21:20] Authenticator: has joined #ruby
[17:22:08] last_staff: has joined #ruby
[17:22:31] Authenticator: What's the difference between the builtin OpenSSL and the gem OpenSSL?
[17:23:15] matthewd: Authenticator: Nothing, beyond the fact the gem could be more up to date
[17:24:23] ldnunes: has joined #ruby
[17:24:33] jaequery: has joined #ruby
[17:24:43] SteenJobs: has joined #ruby
[17:25:07] Authenticator: matthewd: Thanks.
[17:25:21] jcao219: has joined #ruby
[17:27:47] last_staff: has joined #ruby
[17:28:25] [Butch]: has joined #ruby
[17:28:27] Renich: has joined #ruby
[17:30:34] govg: has joined #ruby
[17:30:50] johnzorn: has joined #ruby
[17:31:02] gusrub: has joined #ruby
[17:33:19] hutch34: has joined #ruby
[17:35:14] BTRE: has joined #ruby
[17:36:00] planigan: has joined #ruby
[17:36:22] pupsicle: has joined #ruby
[17:37:54] esObe_: has joined #ruby
[17:38:06] tax: has joined #ruby
[17:40:18] last_staff: has joined #ruby
[17:40:45] ldnunes: has joined #ruby
[17:41:32] danguita: has joined #ruby
[17:42:55] haylon: has joined #ruby
[17:43:41] aviraldg: has joined #ruby
[17:43:41] aviraldg: has joined #ruby
[17:44:13] haylon_: has joined #ruby
[17:45:50] cfec0b8d: has joined #ruby
[17:46:01] tlaxkit: has joined #ruby
[17:46:20] johnzorn: has joined #ruby
[17:49:07] hndk: has joined #ruby
[17:51:18] last_staff: has joined #ruby
[17:51:45] mjolnird: has joined #ruby
[17:52:50] duderonomy: has joined #ruby
[17:53:39] binarycodess: has joined #ruby
[17:53:41] AndBobsYourUncle: has joined #ruby
[17:55:07] Arpanet69: has joined #ruby
[17:57:16] BTRE: has joined #ruby
[18:00:01] sparr: has joined #ruby
[18:04:17] tercenya: has joined #ruby
[18:04:31] gusrub: has joined #ruby
[18:06:01] hotpancakes: has joined #ruby
[18:07:49] hotpanca_: has joined #ruby
[18:09:49] jonatasdaniel: has joined #ruby
[18:13:04] vali: has joined #ruby
[18:17:38] sonOfRa: Is there a good way to calculate the distance between the occurence of a certain string *within* a string?
[18:17:53] SteenJobs_: has joined #ruby
[18:17:54] sonOfRa: I'm writing a vigenère cipher solver, and wondering what the best approach to find the period of a digraph is
[18:18:46] Verity: is <^'> or @--__~~ preferred
[18:19:32] Verity: wrong room, sorry
[18:20:18] synthroid: has joined #ruby
[18:20:35] Rutix: has joined #ruby
[18:20:35] Rutix: has joined #ruby
[18:21:34] hotpancakes: has joined #ruby
[18:22:32] hotpancakes: has joined #ruby
[18:23:33] Aloy: has joined #ruby
[18:24:12] RobertBirnie: has joined #ruby
[18:24:26] CGibsonmm: has joined #ruby
[18:25:37] User458764: has joined #ruby
[18:26:50] dagda1: has joined #ruby
[18:27:27] hotpancakes: has joined #ruby
[18:29:07] patarr: Is there any way to explicitly set the "cause" of a Ruby Error?
[18:29:37] allisio: patarr: Define "cause".
[18:29:42] allisio: Verity: What was that?
[18:29:45] patarr: The method `.cause`
[18:29:52] patarr: Returns the cause. I would like to set the cause.
[18:30:55] patarr: COme to think of it, I haven't tried .cause = something...
[18:31:41] allisio: That won't do.
[18:32:18] allisio: It's stored in a hidden instance variable.
[18:32:23] allisio: You could write to it from a C extension.
[18:33:36] patarr: ACTION exasperated sigh
[18:33:48] allisio: It's not something you're supposed to want to do, for what that's worth.
[18:34:20] binarycodess: has joined #ruby
[18:35:00] hotpancakes: has joined #ruby
[18:35:06] allisio: >> 'lemonlemonle'[/(\w+)\1/].size / 2 # sonOfRa
[18:35:06] MasterAsia: How would I wrote a regex to capture something like
[18:35:07] ruby[bot]: allisio: # => 5 (https://eval.in/770630)
[18:35:14] allisio: What timing.
[18:35:15] MasterAsia: <img class="test">
[18:35:20] allisio: masterasia: No.
[18:35:32] kristofferR: has joined #ruby
[18:35:39] dminuoso: allisio: hidden instance variables are not hidden to me!
[18:35:44] allisio: dminuoso: Nor I. :)
[18:36:36] ule: has joined #ruby
[18:38:35] dminuoso: allisio: There's nothing my Fiddle cant fiddle.
[18:39:22] impermanence: has joined #ruby
[18:40:10] impermanence: Is there a channel for more chat-related questions, as opposed to strictly Ruby language-related questions? I have a question about Ruby and SysOps culture.
[18:41:15] allisio: baweaver's your man.
[18:41:32] hotpancakes: has joined #ruby
[18:41:38] hotpancakes: has joined #ruby
[18:43:13] havenwood: impermanence: ask away
[18:43:58] impermanence: havenwood: give me a second to type it out, please.
[18:44:18] impermanence: well, I guess I'll make it succint:
[18:44:44] sonOfRa: allisio: I don't quite understand that solution
[18:44:56] aryaching: has joined #ruby
[18:44:59] sonOfRa: Maybe my question wasn't well-formed
[18:45:23] allisio: No, perhaps not. I thought you wanted to know the period of the key for a Vigenère cipher.
[18:45:47] allisio: What is your input and expected output?
[18:45:47] impermanence: havenwood: I notice that a lot of senior level DevOps position I look at out of the Silicon Valley area prefer knowledge in Ruby, it seems for SysOps work beyond configuration management tools (i.e. Chef, Puppet). What I'm trying to understand is, for what? Are these companies actually doing SysOps work in Ruby? I know this is possible...but wha
[18:45:48] impermanence: t else could it be for? So I am a bit confused.
[18:45:50] sonOfRa: oooh, I see now
[18:46:04] sonOfRa: Question was well-formed, and the answer now makes sense
[18:46:10] allisio: Good deal.
[18:47:40] allisio: /(\w+)\1/ matches some sequence of "word" characters followed by itself; you can take half the length of that result to find the size of the word that's being repeated to form the key.
[18:48:57] havenwood: impermanence: They may have internal tooling and apis written in Ruby as well. It's a popular lang for such things.
[18:49:36] blackmesa: has joined #ruby
[18:49:42] cfec0b8d: has joined #ruby
[18:51:10] ltem: has joined #ruby
[18:51:30] CGibsonmm: has joined #ruby
[18:52:02] Mon_Ouie: has joined #ruby
[18:52:11] havenwood: impermanence: They may not be sticklers on it being Ruby if you're able to quickly make command line apps and apis in another lang. Depends.
[18:53:19] impermanence: havenwood: hm. I suppose the API thing is a good point. I was just trying to figure out if there is going to be a trend in SysOps of: Bash+Python (current state, typical) -> Ruby
[18:54:06] havenwood: impermanence: I'd think shell scripting as well as Python or Ruby makes perfect sense.
[18:54:42] dminuoso: ACTION votes for a new if-syntax: puts foo not if havenwood.nil?
[18:54:48] havenwood: impermanence: More silicon valley shops might be already using Ruby for other things and just naturally lean in that direction.
[18:55:21] allisio: dminuoso: Huh?
[18:55:32] johnzorn: has joined #ruby
[18:55:33] nofxx: ruby for *nix admin is perfect, just fun... as everything ruby
[18:55:46] nofxx: dminuoso, you can write yrself some coffeescript
[18:56:12] allisio: >> 42 if not nil
[18:56:13] ruby[bot]: allisio: # => 42 (https://eval.in/770642)
[18:57:39] dminuoso: allisio: But that's against Ruby's policy of making the language read well!
[18:58:01] impermanence: havenwood: Right. Hence my concern. I'm going to be applying for these jobs, but I'm worried if I dive headlong into Ruby I'll be pinning myself against a corner for all the less-than-bleeding-edge companies that are still a bit behind...
[18:58:29] allisio: dminuoso: Oh, I see now. Sticking a comma in your original made it make sense.
[18:58:46] allisio: What you're really saying is we need a `but` keyword.
[18:59:10] Mon_Ouie: >> 42 unless nil
[18:59:12] ruby[bot]: Mon_Ouie: # => 42 (https://eval.in/770643)
[19:00:59] hotpancakes: has joined #ruby
[19:01:04] dminuoso: Mon_Ouie: Which sane person uses "unless" in their day-to-day speech?
[19:01:46] lupine: everyone?
[19:01:54] tildes: has joined #ruby
[19:02:04] jaequery: has joined #ruby
[19:02:42] allisio: dminuoso: Did you know `if not` was so unoptimized?
[19:03:54] hahuang61: has joined #ruby
[19:04:12] my123: has joined #ruby
[19:04:53] allisio: You made me run `kill -9 1` as root for shits and giggles.
[19:04:54] my123: on Windows, I get `require': cannot load such file -- rails/all even after doing gem install rails, what should I do?
[19:04:54] dminuoso: allisio: Actually I do. Mostly because I myself added some of those optimizations. :)
[19:05:13] dminuoso: Well one to be exact.
[19:05:39] workmad3: has joined #ruby
[19:05:43] havenwood: impermanence: What would you prefer?
[19:05:57] nofxx: my123, remove windows, partition if you game, install linux, thank me later
[19:06:10] allisio: my123: You just say `require 'rails'`, but also consider ^.
[19:06:55] allisio: Well, no, I guess it depends on what you're doing, so just do the Linux thing.
[19:07:11] blackmesa: has joined #ruby
[19:07:57] my123: nofxx, I'm a Windows Server user
[19:08:23] Xeago_: has joined #ruby
[19:08:50] grh: has joined #ruby
[19:09:44] matthewd: my123: You have an existing rails app you're trying to start? You'll need to run it through 'bundle exec'
[19:09:48] nofxx: well, ignorance IS bliss ... cant help thinking in the red pill hehe
[19:09:51] allisio: dminuoso: Was it `unless` you optimized?
[19:10:02] dminuoso: allisio: Yeah.
[19:10:20] cdg: has joined #ruby
[19:10:20] matthewd: my123: (though we should probably head over to #rubyonrails if that doesn't get it going)
[19:10:23] allisio: dminuoso: Would it be harder to apply the same optimizations to `if not`?
[19:10:46] my123: matthewd, tried bundle exec... same behavior
[19:11:27] my123: It works on the Windows Subsystem for Linux, but with around 30-90 seconds *per request*, so...
[19:12:02] impermanence: havenwood: sorry for the late response. Ruby, of course.
[19:12:19] dminuoso: allisio: I'd have to look at it to be sure, but from what I remember it should be as trivial.
[19:12:29] matthewd: my123: Okay, let's continue in #rubyonrails
[19:12:43] hotpanca_: has joined #ruby
[19:13:01] impermanence: havenwood: Let me ask another question. Does Ruby have the gems to be able to speak deeply to a Linux kernel/OS such as Bash and Python? And therefore actually be a viable scripting language?
[19:13:17] matthewd: Is anyone really going to write `if not`? :/
[19:13:25] matthewd: `if !`, sure.. but you can't optimize that
[19:14:31] AlexRussia: has joined #ruby
[19:14:56] allisio: Also, is this not a bug? https://eval.in/770656
[19:15:26] Mon_Ouie: No, 'unless' just doesn't implicitly call #!
[19:15:43] allisio: Shouldn't it?
[19:16:23] matthewd: Oh, I didn't realise `not` did
[19:17:01] dminuoso: allisio: No it shouldn't.
[19:17:13] dminuoso: allisio: All "unless" does is insert an "if" but reverse the branch targets.
[19:17:24] Mon_Ouie: I don't really think it matters, the problem with defining #! is that the behavior of 'if x' can't be changed
[19:18:18] matthewd: +1.. "shouldn't unless call #!" heads down a path of "shouldn't if call #! twice", etc
[19:18:50] dminuoso: Besides, calling #! would have some serious performance impact.
[19:20:29] blackmesa: has joined #ruby
[19:21:41] binarycodess: has joined #ruby
[19:23:11] dminuoso: allisio: Interesting yeah, I also was not aware of not calling !, this makes it impossible for the compiler to optimize it.
[19:24:37] dminuoso: I mean on a limb case could be made for optimizing the case of "if not nil/false" on the assumption that if someone modified NilClass#! they deserve to have their code break, but it still would have no value.
[19:24:41] matthewd: It does make sense... `and` and `or` aren't more boolean than `&&` / `||`.. so it follows that `not` is strictly a low-associativity spelling of `!`
[19:25:21] dminuoso: matthewd: Well it's still very interesting as "and/or" are commonly advertised as code flow mechanisms.
[19:25:57] Aete: has joined #ruby
[19:26:00] dminuoso: At least in the resources that I read, which may not be very representative.
[19:26:03] minimalism: has joined #ruby
[19:28:03] matthewd: Yeah, I subscribe to that viewpoint. Which arguably makes `not` a bit weird just for existing, though I guess the argument would be that it's reasonable *inside* an and/or using expression -- though not on its own.
[19:28:52] kirun: has joined #ruby
[19:29:05] skweek: has joined #ruby
[19:29:56] dminuoso: matthewd: I suppose I finally found a good argument for !using "not" anymore. :)
[19:32:18] CGibsonmm: has joined #ruby
[19:32:38] mikecmpbll: has joined #ruby
[19:34:53] SteenJobs: has joined #ruby
[19:36:46] esObe_: has joined #ruby
[19:38:35] Aete: has joined #ruby
[19:39:32] Arpanet69: has joined #ruby
[19:40:36] CGibsonmm: has joined #ruby
[19:41:11] tercenya: has joined #ruby
[19:42:37] Mon_Ouie: has joined #ruby
[19:42:38] perlnecrohacker: has joined #ruby
[19:43:15] stupidsenpai: has joined #ruby
[19:47:25] tercenya: has joined #ruby
[19:47:59] raul782: has joined #ruby
[19:49:24] BTRE: has joined #ruby
[19:49:40] mjolnird: has joined #ruby
[19:50:39] raul782: has joined #ruby
[19:52:07] hotpancakes: has joined #ruby
[19:53:57] jgt1: has joined #ruby
[19:55:44] workmad3: has joined #ruby
[20:00:36] stupidsenpai: has joined #ruby
[20:02:48] LambdaSix: has joined #ruby
[20:03:42] enilsen16: has joined #ruby
[20:04:22] enilsen16: has joined #ruby
[20:05:09] blackmesa: has joined #ruby
[20:06:28] hotpancakes: has joined #ruby
[20:06:52] S1kx: has joined #ruby
[20:07:25] raul782: has joined #ruby
[20:07:31] ghoti: has joined #ruby
[20:09:54] jenrzzz: has joined #ruby
[20:10:27] jgt1: has joined #ruby
[20:15:11] _whitelogger: has joined #ruby
[20:22:09] kristofferR: has joined #ruby
[20:24:01] nowhereman: has joined #ruby
[20:26:19] hotpancakes: has joined #ruby
[20:26:44] fp-: has joined #ruby
[20:28:17] hotpanca_: has joined #ruby
[20:30:05] gdonald: has joined #ruby
[20:30:13] baweaver: impermanence: I'm in SV and I work with primarily Ruby in a fairly large shop
[20:30:15] haxrbyte: has joined #ruby
[20:30:22] baweaver: Well, SF more accurately
[20:30:58] baweaver: Was off at lunch for a while
[20:31:34] baweaver: Anyways, a lot of the same tools have bindings in Ruby / Python / Perl to the point where you'd be hard pressed to find something one of them _didn't_ do.
[20:31:36] jgt1: has joined #ruby
[20:31:46] impermanence: baweaver: wow!
[20:32:44] impermanence: I'm very curious to hear how baweaver: so you write Ruby to complete Ops work. File stuff, Storage Stuff, Linux admin stuff, other stuff...?
[20:32:51] Xeago_: has joined #ruby
[20:33:09] baweaver: To the point where I'd considered at one point writing a Ruby CloudOps book. We're primarily AWS.
[20:34:00] impermanence: baweaver: wow. So you don't use Bash for working with Linux?
[20:34:09] baweaver: AWS, Chef, Sensu (monitoring - Ruby), Grafana (charts - go/angularjs)
[20:34:13] baweaver: very rarely.
[20:34:17] lxsameer: has joined #ruby
[20:34:32] impermanence: Mmm. Yeah, the Chef thing. I can see why Ruby would be relevant.
[20:34:42] baweaver: though it depends on how big the task is
[20:34:53] baweaver: I may just use bash to do small oneliners
[20:35:15] impermanence: right. wow, that's great. good for you.
[20:35:53] baweaver: Though admittedly I may be switching to a pure JS frontend team soon to shake it up a bit.
[20:36:19] baweaver: I'll probably still write that book later for kicks and stick it on LeanPub.
[20:36:59] baweaver: http://rubyforadmins.com/preface - This was a pretty decent guide
[20:37:03] impermanence: So how accessible is a Linux OS via Ruby?
[20:37:09] baweaver: but I felt like there was a ton left unsaid
[20:37:10] impermanence: yes I have that in my browser right now :)
[20:37:24] baweaver: depends on what you mean by accessible. It has C bindings for most everything
[20:37:46] impermanence: ah, okay. I'm just trying to wrap my head around being able to admin Linux with Ruby.
[20:38:04] Moosashi: has joined #ruby
[20:38:10] FastJack: has joined #ruby
[20:38:10] baweaver: Pretty much if you can do it in Bash / Python / Perl you can do it in Ruby
[20:38:11] esObe_: has joined #ruby
[20:38:17] impermanence: Is it possible to use Linux builtin's with Ruby like grep, tr, tree, strace, etc.? Or...how does that work?
[20:38:21] baweaver: finding exceptions to that are rare
[20:40:08] allisio: impermanence: Open3 pretty much gives you all the foundation you need to do pipelines "natively".
[20:40:23] baweaver: either shell out to them: `command` or system("command") or stdout, stderr, status = Open3.capture3("command")
[20:40:24] allisio: Of course, you can always just shell out when quick-and-dirty'll do.
[20:40:36] baweaver: danged ninjas :P
[20:40:42] `derpy: http://ruby-doc.org/stdlib-2.4.0/libdoc/open3/rdoc/Open3.html
[20:41:30] baweaver: Dir, File, and some others have globbing options that'd do the same as grep and there are some other native extensions which do the same thing
[20:41:53] baweaver: there are a few other ways to exec commands, those just tend to be the big ones
[20:42:11] impermanence: hm. So...would you consider yourself at Ruby developer level now? Whatever that means...
[20:42:39] baweaver: I've worked full dev, full ops, and devops with Ruby so I suppose so.
[20:43:06] impermanence: when did you start writing Ruby?
[20:43:32] baweaver: ACTION thinks back
[20:43:39] baweaver: professionally, ~2012.
[20:44:01] baweaver: screwing around, probably 2006-08 or so, I forget.
[20:44:23] hotpancakes: has joined #ruby
[20:44:29] baweaver: RPG Maker XP had Ruby "support" so I ended up learning it to make cool things in it
[20:44:48] allisio: Was that really your start?
[20:44:53] baweaver: so maybe even a few years before
[20:45:02] baweaver: for Ruby, yeah.
[20:45:06] allisio: Imagine that.
[20:45:31] baweaver: Think I learned from SephirothSpawn on the forums forever ago.
[20:45:53] impermanence: hm. So OG, essentially. Okay.
[20:46:17] baweaver: then I realized in my first job that Ruby was useful for other things and I had free reign to do whatever.
[20:46:34] baweaver: So I automated an entire network of Ubiquiti antennas
[20:47:31] baweaver: firmware upgrades, status pages, auto repair, interference mitigation, and a few other fun bits. I think I automated myself out of 3 jobs in a row as an intern and they made me full time after that
[20:47:41] baweaver: then it was free reign to do whatever was useful.
[20:48:12] kiltzman: has joined #ruby
[20:48:35] baweaver: but that involved a lot of SSH, SCP, JSON, and working with Busy Box (ASH) which is lightweight Linux running on wireless antennas
[20:50:18] baweaver: but dang did I have some dirty Ruby back then XD
[20:50:56] impermanence: I can image. Even as new as I am when I look at code from even a year ago I "smile"
[20:50:59] baweaver: I OSS'd some of the tools when I left (with permission) - https://github.com/baweaver/ubiquiti
[20:51:12] baweaver: don't use those as good examples of Ruby
[20:51:15] baweaver: they're not :P
[20:52:00] ohcibi: has joined #ruby
[20:52:14] impermanence: I appreciate the insight.
[20:52:42] impermanence: Is there a good consensus on a good starter Ruby OOP book?
[20:53:27] baweaver: Practical Object Oriented Design in Ruby
[20:53:33] baweaver: see the channel topic
[20:53:37] baweaver: I have a book list on there
[20:53:44] baweaver: explains quite a few of them and their uses
[20:53:46] jeffreylevesque: has joined #ruby
[20:53:55] SteenJobs: has joined #ruby
[20:54:25] baweaver: "Books: https://goo.gl/wpGhoQ "
[20:56:14] griff: has joined #ruby
[20:57:18] bodgix: has joined #ruby
[20:57:36] GodFather: has joined #ruby
[20:57:50] haxrbyte: has joined #ruby
[21:02:35] outreachdan: has joined #ruby
[21:04:49] hahuang61: has joined #ruby
[21:05:28] rgtk: has joined #ruby
[21:15:02] t-recx: has joined #ruby
[21:23:05] howlinbash: has joined #ruby
[21:28:45] __Yiota: has joined #ruby
[21:29:06] hotpanca_: has joined #ruby
[21:31:10] jenrzzz_: has joined #ruby
[21:33:06] mim1k: has joined #ruby
[21:34:15] johnzorn: has joined #ruby
[21:37:04] outreachdan: has joined #ruby
[21:39:30] bodgix: has joined #ruby
[21:39:30] jusa: has joined #ruby
[21:42:08] bkxd: has joined #ruby
[21:42:37] galtgendo: has joined #ruby
[21:44:03] nofxx: has joined #ruby
[21:45:22] galtgendo: in Psych, how does init_with method accounts for yaml anchors ? I'm getting '`*': nil can't be coerced into Fixnum (TypeError)' in such cases with a method that works when no anchors
[21:52:02] [Butch]: has joined #ruby
[22:00:45] b3l914n: has joined #ruby
[22:07:16] rwb: has joined #ruby
[22:07:22] SeepingN: has joined #ruby
[22:15:20] tvw: has joined #ruby
[22:15:51] cseder: has joined #ruby
[22:18:54] hutch34: has joined #ruby
[22:19:11] cseder: Does anyone use TextMate 2? I purchased a license for it a while back, but now I hear that it's free (as in beer) and open sourced?
[22:19:12] tvw: has joined #ruby
[22:19:29] SeepingN: it's a disaster
[22:20:00] SeepingN: "here's the code, everyone go do whatever" doesn't work out too cleanly
[22:20:04] baweaver: Most use Sublime
[22:20:08] cseder: I like TM2, but I also have a license for Sublime 3
[22:20:18] SeepingN: ST3 all the way
[22:20:21] baweaver: or Atom in some cases
[22:20:40] baweaver: Depending on what I'm doing I switch between Vim, Sublime 3, and Typora.
[22:20:50] baweaver: Though Typora is only really for long-form tech docs
[22:20:57] baweaver: (markdown editor)
[22:21:10] cseder: Yes, I don't see many reasons to keep using TM, as the time has passed, Sublime has gotten really good
[22:21:36] cseder: I was just wondering about TM because when I installed it it still asked for my license
[22:22:08] ytti: vim, vcs, atom, slt3, tm3
[22:22:09] cseder: But people says it's now free and Open Source
[22:22:11] ytti: seem to be the options toda
[22:22:19] SeepingN: well you can 1: ignore it, 2: buy it, or 3: edit a few bytes
[22:22:49] cseder: Ok, so it is still "license is optional" like Sublime?
[22:23:02] jenrzzz: has joined #ruby
[22:24:13] ytti: seems entirely unethical not to buy editor you use hours on end, day in, day out
[22:24:16] ytti: if it costs money
[22:24:19] SeepingN: oh TM? TM should be free. open source. if ijt isn't, ... are you sure you found a "current' version?
[22:24:21] bonhoeffer: has joined #ruby
[22:26:01] cseder: I purchased a license for Sublime a while back when it was rumoured that it was going into release, not beta, but that didn't happen. Still optional license for Sublime as it is still in beta (v3)
[22:27:06] ytti: i too have SL license, don't use it though
[22:27:11] ytti: and i don't imagine i will
[22:27:51] ytti: been trying to jump on vcs, but hard to move out from vim
[22:28:27] cseder: One thing I've noticed when using Sublime is that it doesn't work for writing git commit messages when I have it as my default text editor in zsh... Anybody experiencing the same?
[22:28:54] cseder: I mean if you do git commit -a -m "blabla"
[22:29:17] cseder: it works, but not if you don't use -m
[22:30:23] cseder: Sublime pops up, waiting for me to write a commit message, than, when I save the file and quit Sublime, the commit gets discarded
[22:31:04] jcao219: has joined #ruby
[22:31:14] cseder: this is off topic, but I was just curious. Only thing that works for me is vim
[22:31:20] ddffg: has joined #ruby
[22:32:16] aspiers: has joined #ruby
[22:32:22] impermanence: has joined #ruby
[22:32:59] impermanence: baweaver: what do you mean in your book list when you refer to "Programming Ruby" as the "pickaxe book"?
[22:33:08] baweaver: Look at the cover
[22:33:51] postmodern: has joined #ruby
[22:34:22] impermanence: baweaver: I thought it might be something like that, lol. Looking now...
[22:34:28] cseder: It has always been called the PickAxe
[22:34:53] cseder: I'm reading the latest edition as we type! Great book!
[22:34:59] havenwood: impermanence: Learn to Program is a Tree. The Ruby Programming Language is Sparrows. Programming Ruby is the Pickaxe.
[22:36:07] cseder: What is that second book? Have a link?
[22:36:12] nankyokusei: has joined #ruby
[22:36:26] baweaver: By and far my favorite "Learn Ruby" book is Eloquent Ruby.
[22:36:30] havenwood: cseder: http://akamaicovers.oreilly.com/images/9780596516178/cat.gif
[22:36:39] impermanence: I see. For a Ruby beginner, but not a beginning programmer what book is the best? I don't like terse, but I probably need something at least a little advanced. So like...spice == medium.
[22:37:04] baweaver: Its entire goal is to teach people to Ruby like Ruby people
[22:37:35] baweaver: The definitive tome book is The Ruby Way
[22:37:37] cseder: I really like the way the PickAxe is built. Good progression
[22:39:31] esObe_: has joined #ruby
[22:40:26] cseder: The Ruby Programming Language by Oreilly isn't updated for Ruby 2.0?
[22:40:34] havenwood: cseder: Nope
[22:40:42] impermanence: baweaver: but eloquent seems to presume (as you stated in your git list) an already working knowledge of ruby...
[22:40:47] charliesome: has joined #ruby
[22:40:59] havenwood: cseder: The Well-Grounded Rubyist, Second Edition is.
[22:41:10] impermanence: that's another concern. I'd prefer to just start learning 2...wouldn't that be best?
[22:41:19] cseder: And not the Eloquent Ruby book either?
[22:41:24] havenwood: impermanence: Thing of Ruby 1.9 as 2.0 release candidate.
[22:41:33] havenwood: impermanence: As long as it's post 1.8, you should be fine.
[22:41:48] impermanence: hm, good advice.
[22:42:14] havenwood: impermanence: 1.8- was the interpreter MRI. 1.9+ is the virtual machine YARV.
[22:42:29] cseder: Ok, I think I'll stick with the PickAxe and Ruby Cookbook
[22:42:37] havenwood: impermanence: yet another Ruby vm
[22:42:59] impermanence: heh. should've known.
[22:42:59] havenwood: impermanence: http://www.atdot.net/yarv/oopsla2005eabstract-rc1.pdf
[22:44:05] impermanence: looks like I may need to buy a couple books. I guess I need to get "Rubyist" for sure.
[22:44:32] havenwood: impermanence: The author has written a tool that precompiled the IR bytecode for Ruby then runs it directly in the VM. It reduces runtime by about 30%: https://github.com/ko1/yomikomu#readme
[22:44:53] havenwood: impermanence: It might be part of Ruby 3. We'll see!
[22:44:58] cseder: I've been programming on and off for over 20 years, and as a profession for the last 3 years, but I've never had much "fun" learning different languages, until I started learning Ruby. It sounds cliche, but it's true!
[22:45:51] havenwood: https://blog.heroku.com/ruby-3-by-3
[22:45:54] ludicocr: has joined #ruby
[22:46:39] baweaver: Eloquent assumes that you know some programming
[22:46:42] baweaver: not necessarily Ruby
[22:47:02] baweaver: It assumes you tried a basic tutorial, maybe, but nothing past that
[22:47:17] ludicocr: has left #ruby: ()
[22:47:35] cseder: But I feel that the PickAxe also has a reasonable tempo, even if I've programmed in other languages
[22:48:01] cseder: And it is updated for Ruby 2.0
[22:48:23] cseder: And I have it both as pdf and dead tree version
[22:49:28] cseder: Trivia time: Did you know know that the keyword yield was chosen to echo the yield function in Liskov’s language CLU, a language that is more than thirty years old and yet contains features that still haven’t been widely exploited by the CLU-less
[22:49:33] perlnecrohacker: Hello, where I can read about mruby?
[22:49:54] havenwood: perlnecrohacker: Are you just getting into it, or looking for something in particular?
[22:50:31] havenwood: perlnecrohacker: The mruby gitter is one place to ask questions or review the log: https://gitter.im/mruby/mruby
[22:51:34] havenwood: perlnecrohacker: http://mruby.org/docs/articles/executing-ruby-code-with-mruby.html
[22:52:02] perlnecrohacker: I just into it) I find about mruby, have more info (onle japaness)
[22:52:35] impermanence: has joined #ruby
[22:54:49] cseder: My main goal with learning Ruby was to start developing in Rails after learning just enough Ruby to get by, but the more I learn about Ruby, the more I want to learn. It's scary.
[22:55:23] rakm: has joined #ruby
[22:56:21] galtgendo: in Psych, how does init_with method account for yaml anchors ? I'm getting '`*': nil can't be coerced into Fixnum (TypeError)' in such cases with a method that works when no anchors are present
[22:56:54] perlnecrohacker: havenwood, ok. 10q for links
[22:57:08] nemesit|znc: has joined #ruby
[22:59:33] Suslov: has joined #ruby
[23:00:05] esObe_: has joined #ruby
[23:00:06] unreal: has joined #ruby
[23:05:32] ludicocr: has joined #ruby
[23:05:55] hahuang61: has joined #ruby
[23:12:25] chare: has joined #ruby
[23:12:50] cam27: has joined #ruby
[23:15:19] SteenJobs: has joined #ruby
[23:16:24] cseder: For those with some knowledge in C and interest in learning how Ruby really works under the hood, try the book "Ruby Under a Microscope"
[23:16:55] hotpancakes: has joined #ruby
[23:16:57] snickers: has joined #ruby
[23:18:05] hutch34: has joined #ruby
[23:19:45] Renich___: has joined #ruby
[23:20:25] bkxd: has joined #ruby
[23:20:52] ThePortWhisperer: has joined #ruby
[23:21:08] ThePortWhisperer: hello, if im having trouble with ruby's active_support gem, is this a place to ask
[23:21:25] ThePortWhisperer: it's part of setting up a jekyll page on github
[23:22:48] ThePortWhisperer: this screen shows error: https://snag.gy/Ymx3bt.jpg
[23:27:47] gusrub: has joined #ruby
[23:28:15] am55: has joined #ruby
[23:28:53] AlexRussia: has joined #ruby
[23:31:43] FastJack_: has joined #ruby
[23:32:04] charliesome: has joined #ruby
[23:32:13] havenwood: ThePortWhisperer: Put `gem 'active_support` in your Gemfile, run `bundle` then try `bundle exec jekylll build` again.
[23:33:03] ThePortWhisperer: havenwood, okay thanks. just uninstalled all gems so will try from scratch
[23:33:13] aryaching: has joined #ruby
[23:33:22] electrostat: has joined #ruby
[23:33:35] mim1k: has joined #ruby
[23:34:16] cschneid_: has joined #ruby
[23:37:41] hotpancakes: has joined #ruby
[23:40:18] FastJack_: has joined #ruby
[23:41:58] ThePortWhisperer: havenwood, so theres no gem name active_support, but there is one called activesupport
[23:42:44] ThePortWhisperer: wondering if active_support resolves to activesupport
[23:43:01] CloCkWeRX: has joined #ruby
[23:43:46] GSilva: has joined #ruby
[23:44:02] tax: has left #ruby: ("Leaving")
[23:44:17] ThePortWhisperer: strange i guess the activesupport folder has the underscore but the gem itself lacks one
[23:48:18] allisio: Very unfortunate.
[23:48:43] planigan: has joined #ruby
[23:49:05] djbkd: has joined #ruby
[23:49:44] hotpanca_: has joined #ruby
[23:52:49] levifig: has joined #ruby
[23:58:03] ThePortWhisperer: hello, can someone walk me through what the warn means https://snag.gy/mBEDdW.jpg
[23:59:45] impermanence: has joined #ruby