« Back to channel list

#ruby - 24 July 2018

« Back 1 day Forward 1 day »
[00:07:22] fluxAeon_: has joined #ruby
[00:10:13] alfiemax: has joined #ruby
[00:13:05] jrafanie: has joined #ruby
[00:15:17] lxsameer: has joined #ruby
[00:21:20] postmodern: has joined #ruby
[00:27:07] alfiemax: has joined #ruby
[00:31:35] graphene: has joined #ruby
[00:47:05] r29v: has joined #ruby
[00:55:31] apeiros: has joined #ruby
[00:58:52] negatifze: has joined #ruby
[01:00:15] weaksauce: has joined #ruby
[01:02:44] cthulchu: has joined #ruby
[01:03:57] c0ncealed2: has joined #ruby
[01:05:13] pr0ton: has joined #ruby
[01:07:04] def_jam: has joined #ruby
[01:07:38] eb0t_: has joined #ruby
[01:10:02] pr0ton: has joined #ruby
[01:14:42] karapetyan: has joined #ruby
[01:14:58] marius: has joined #ruby
[01:23:40] dstrunk: has joined #ruby
[01:28:47] pr0ton: has joined #ruby
[01:34:04] Asher: has joined #ruby
[01:36:11] jrafanie: has joined #ruby
[01:37:10] r29v: has joined #ruby
[01:41:00] amar: has joined #ruby
[01:50:42] cagomez: has joined #ruby
[01:51:30] karapetyan: has joined #ruby
[01:53:43] amar: has joined #ruby
[01:56:06] karapetyan: has joined #ruby
[02:00:31] karapetyan: has joined #ruby
[02:14:02] zenspider: any graphviz wizards out there?
[02:16:10] lxsameer: has joined #ruby
[02:17:44] jp: has joined #ruby
[02:19:41] c0ncealed2: has joined #ruby
[02:26:51] pastorinni: has joined #ruby
[02:28:37] tdy: has joined #ruby
[02:30:46] konsolebox: has joined #ruby
[02:37:51] zenspider: I'm trying to get a cluster's contents to break rank w/ the surrounding graph and just layout independently... want to generate a legend that's actually compact
[02:38:00] zenspider: and then incorporate that into my graph gem
[02:38:41] graphene: has joined #ruby
[02:48:04] darkhanb: has joined #ruby
[02:49:27] ogres: has joined #ruby
[02:50:17] kubuntu: has joined #ruby
[02:51:32] Guest84349: I want to do OOP in ruby, but I think it's gonna turn out like how I do perl, and 95% of the stuff I do in perl is non-GUI.
[02:51:42] Guest84349: I mean non-OOP
[02:52:08] baweaver: by merit of using Ruby you're already using OOP.
[02:52:16] baweaver: What do you mean by non?
[02:52:34] Guest84349: Like I don't create classes and member-variables
[02:53:13] Guest84349: I use perl like a super bash shell that is integrated into its own single-process space
[02:53:40] Guest84349: I want to use ruby like a super super bash shell with GUI stuff maybe
[02:53:57] baweaver: There's nothing stopping you from doing so.
[02:54:16] baweaver: Though you're likely going to find that your scripts are impossible to test, reason about, and upgrade later as a cost
[02:55:55] zenspider: you're certainly welcome to write ruby the way you write perl... but it'll come at a cost
[02:56:26] baweaver: (I'd answer your question but I know jack-all on graphviz except that it exists)
[02:57:34] zenspider: I know a bit more than that... but it all boils down to "it's a horrible tool but I'm stuck with it"
[02:58:40] havenwood: Speaking of Perlesque Ruby, saw this was recently committed to Ruby: https://github.com/ruby/ruby/blob/e613cdd53d16327dccf8237f8d5b672804a69eca/sample/trick2018/02-mame/entry.rb
[02:59:57] baweaver: I saw trick and mame, and avoided clicking :P
[03:00:22] havenwood: baweaver: It's a pretty fancy animation quine.
[03:00:47] baweaver: This is the only type of animation I'm dealing with at the moment: https://twitter.com/keystonelemur/status/1021557475592495105
[03:01:10] baweaver: that, and lots of slide notes. So many slide notes
[03:01:30] havenwood: baweaver: woot!
[03:06:32] cthulchu_: has joined #ruby
[03:08:02] karapetyan: has joined #ruby
[03:09:11] braincrash: has joined #ruby
[03:16:39] Azure: has joined #ruby
[03:16:54] podlech: has joined #ruby
[03:22:27] SeepingN: has joined #ruby
[03:26:31] graphene: has joined #ruby
[03:32:56] mynameisdebian: has joined #ruby
[03:36:27] gix-: has joined #ruby
[03:39:08] postmodern: has joined #ruby
[03:44:41] erratic: has joined #ruby
[03:46:40] mynameisdebian: has joined #ruby
[03:54:41] amar: has joined #ruby
[04:06:06] dinfuehr: has joined #ruby
[04:16:39] jzhu: has joined #ruby
[04:16:49] lxsameer: has joined #ruby
[04:37:53] profetes_: has joined #ruby
[04:43:50] dellavg: has joined #ruby
[04:45:22] kapil___: has joined #ruby
[04:45:41] _icantc_: has joined #ruby
[04:45:43] Puffball_: has joined #ruby
[04:45:43] zenspider_: has joined #ruby
[04:46:14] moei: has joined #ruby
[04:47:59] modin: has joined #ruby
[04:51:05] c0ncealed2: has joined #ruby
[04:54:01] donofrio: has joined #ruby
[04:57:06] karapetyan: has joined #ruby
[04:59:15] za1b1tsu: has joined #ruby
[04:59:53] mahlon: has joined #ruby
[05:00:17] ged: has joined #ruby
[05:04:00] anisha: has joined #ruby
[05:06:45] thejoecarroll: has joined #ruby
[05:06:53] herbmillerjr: has joined #ruby
[05:10:29] lytol_: has joined #ruby
[05:15:07] milanj: has joined #ruby
[05:19:49] tty: has joined #ruby
[05:25:11] ColeW_Picaro: has joined #ruby
[05:25:59] anisha: has joined #ruby
[05:29:35] cthulchu: has joined #ruby
[05:31:41] sauvin: has joined #ruby
[05:38:42] cthulchu_: has joined #ruby
[05:42:25] aupadhye: has joined #ruby
[05:48:59] User458764: has joined #ruby
[05:55:03] tvw: has joined #ruby
[05:55:27] amar: has joined #ruby
[06:13:35] biberu: has joined #ruby
[06:17:26] lxsameer: has joined #ruby
[06:18:09] graphene: has joined #ruby
[06:18:56] dnewkerk: has left #ruby: ()
[06:20:30] cyberRodent: has joined #ruby
[06:32:37] Phate: has joined #ruby
[06:40:28] andikr: has joined #ruby
[06:42:37] sina: has joined #ruby
[06:45:18] anisha: has joined #ruby
[06:45:51] anikras: has joined #ruby
[06:48:16] venmx: has joined #ruby
[06:50:56] aufi: has joined #ruby
[06:53:45] zenspider: has joined #ruby
[07:01:33] yohji: has joined #ruby
[07:04:50] hidir_de: has joined #ruby
[07:06:13] amar: has joined #ruby
[07:11:49] amar_: has joined #ruby
[07:14:08] sysvalve: has joined #ruby
[07:16:13] lxsameer: has joined #ruby
[07:16:24] TomyWork: has joined #ruby
[07:16:30] anisha: has joined #ruby
[07:28:45] amar: has joined #ruby
[07:37:13] clemens3: has joined #ruby
[07:48:25] Mike11: has joined #ruby
[07:56:01] sarna: has joined #ruby
[07:57:18] venmx: has joined #ruby
[08:00:37] conta: has joined #ruby
[08:07:46] venmx: has joined #ruby
[08:08:08] graphene: has joined #ruby
[08:11:50] anisha: has joined #ruby
[08:14:06] karapetyan: has joined #ruby
[08:14:54] venmx_: has joined #ruby
[08:16:03] alem0lars: has joined #ruby
[08:16:43] lxsameer: has joined #ruby
[08:16:54] alem0lars: has joined #ruby
[08:17:39] alem0lars: has joined #ruby
[08:18:55] reber: has joined #ruby
[08:20:27] aufi_: has joined #ruby
[08:21:58] graphene: has joined #ruby
[08:23:28] maufart__: has joined #ruby
[08:25:49] kapil___: has joined #ruby
[08:26:48] amar: has joined #ruby
[08:26:57] Some-body_: has joined #ruby
[08:27:29] amar: has joined #ruby
[08:29:24] Megamos: has joined #ruby
[08:30:08] iamnix: has joined #ruby
[08:30:47] jraavis: has joined #ruby
[08:31:48] jottr: has joined #ruby
[08:32:46] schleppel: has joined #ruby
[08:32:54] aufi_: has joined #ruby
[08:33:57] Zaab1t: has joined #ruby
[08:42:44] Sylario: has joined #ruby
[08:44:56] Alec: has joined #ruby
[08:46:43] hays: has joined #ruby
[08:46:57] maufart__: has joined #ruby
[08:47:18] quobo: has joined #ruby
[08:53:02] Nicmavr: has joined #ruby
[08:53:45] hays: has joined #ruby
[08:58:06] venmx: has joined #ruby
[09:01:16] dhollin3: has joined #ruby
[09:14:24] Oct2pus: has joined #ruby
[09:18:40] alex``: has joined #ruby
[09:20:43] eb0t: has joined #ruby
[09:22:41] Megamos: has joined #ruby
[09:23:12] anisha_: has joined #ruby
[09:30:16] InfinityFye: has joined #ruby
[09:39:30] xall: has joined #ruby
[09:40:51] naftilos76: has joined #ruby
[09:42:54] RougeR: has joined #ruby
[09:42:54] RougeR: has joined #ruby
[09:47:20] clemens3: has joined #ruby
[10:07:30] dani1lpi4ug1n: has joined #ruby
[10:08:15] apparition: has joined #ruby
[10:18:50] alem0lars: has joined #ruby
[10:20:45] milanj: has joined #ruby
[10:21:18] conta: has joined #ruby
[10:25:34] howdoi: has joined #ruby
[10:25:35] Dbugger: has joined #ruby
[10:27:33] beefjoe: has joined #ruby
[10:29:08] jrafanie: has joined #ruby
[10:32:55] zlib_is_awesome: has joined #ruby
[10:37:39] alfiemax_: has joined #ruby
[10:59:45] ur5us: has joined #ruby
[11:02:52] karapetyan: has joined #ruby
[11:10:24] dstrunk: has joined #ruby
[11:15:51] sphenxes: has joined #ruby
[11:17:04] Megamos: has joined #ruby
[11:22:30] anisha: has joined #ruby
[11:24:40] wolfshappen: has joined #ruby
[11:41:28] Puffball: has joined #ruby
[11:43:08] shinnya: has joined #ruby
[11:43:28] Oct2pus: has joined #ruby
[11:56:45] AJA4350: has joined #ruby
[12:00:39] mikecmpbll: has joined #ruby
[12:09:14] kapil___: has joined #ruby
[12:13:14] webhat: has joined #ruby
[12:20:05] snuz: has joined #ruby
[12:20:38] snuz: has left #ruby: ()
[12:21:18] hidir_de: has joined #ruby
[12:25:24] jzhu: has joined #ruby
[12:36:14] user4: has joined #ruby
[12:38:42] mikecmpbll: has joined #ruby
[12:39:14] psychicist__: has joined #ruby
[12:44:53] livcd: has joined #ruby
[12:46:13] mikecmpbll: has joined #ruby
[12:46:33] user3: has joined #ruby
[12:47:16] GodFather: has joined #ruby
[12:48:57] mroutis: has joined #ruby
[12:51:56] karapetyan: has joined #ruby
[12:53:58] psychicist__: has joined #ruby
[12:56:31] vondruch: has joined #ruby
[12:57:45] user4: has joined #ruby
[13:00:26] ur5us: has joined #ruby
[13:00:58] user_: has joined #ruby
[13:04:11] user3: has joined #ruby
[13:04:28] tvw: has joined #ruby
[13:06:48] alireza: has joined #ruby
[13:06:55] alireza: how can i convert this into one line?
[13:07:22] user4: has joined #ruby
[13:07:34] alireza: http://vpaste.net/f0gWf
[13:07:51] alireza: check status and change state of variable based on true/false
[13:08:00] alireza: is there way to shorten this?
[13:08:48] alireza: a simple if/else
[13:13:06] mroutis: I like it that way, alireza
[13:13:44] mroutis: just the `imported.unconfirmed` chain doesn't make sense for me
[13:14:08] mroutis: why are you adding the `imported` right there if you are checking for `unconfirmed` ?
[13:14:46] mroutis: also, what's `unconfirmed_status`? a param?
[13:15:12] graphene: has joined #ruby
[13:16:21] vondruch: has joined #ruby
[13:17:58] mroutis: if it is so, maybe you can give https://github.com/plataformatec/has_scope a try
[13:18:57] mroutis: has left #ruby: ()
[13:21:13] Mia: has joined #ruby
[13:21:13] Mia: has joined #ruby
[13:28:11] RougeR: has joined #ruby
[13:28:11] RougeR: has joined #ruby
[13:29:27] alireza: mroutis, thanks
[13:34:31] krawchyk: has joined #ruby
[13:34:53] aufi_: has joined #ruby
[13:39:15] Caerus: has joined #ruby
[13:39:27] maufart__: has joined #ruby
[13:39:51] qolq: alireze: @scope = unconfirmed_status? ? @scope.imported.unconfirmed : @scope.confirmed
[13:40:03] qolq: alireza: ^
[13:40:22] alireza: qolq: thanks
[13:41:05] Inline: has joined #ruby
[13:42:09] qolq: you may also want to take a look at https://github.com/rubocop-hq/ruby-style-guide#use-if-case-returns
[13:47:04] conta1: has joined #ruby
[13:53:34] pastorinni: has joined #ruby
[13:59:28] dtomic: has joined #ruby
[14:06:48] anisha: has joined #ruby
[14:08:09] Rapture: has joined #ruby
[14:10:03] jrafanie: has joined #ruby
[14:11:07] scrptktty: has joined #ruby
[14:15:34] eblip: has joined #ruby
[14:17:57] krawchyk: has joined #ruby
[14:22:41] Cthulu201: has joined #ruby
[14:24:20] nythalcrow: has joined #ruby
[14:25:49] snuz: has joined #ruby
[14:27:37] bmurt: has joined #ruby
[14:28:36] gigetoo: has joined #ruby
[14:31:43] krawchyk: has joined #ruby
[14:36:18] snuz: has joined #ruby
[14:42:41] TinkerT: has joined #ruby
[14:52:20] Emmanuel_Chanel: has joined #ruby
[14:53:19] Asher: has joined #ruby
[15:01:01] ur5us: has joined #ruby
[15:04:52] snuz: has joined #ruby
[15:05:20] Rish: has joined #ruby
[15:10:51] tdy: has joined #ruby
[15:12:09] DTZUZO: has joined #ruby
[15:16:05] Rish: Could not find in bundle install any one help me
[15:16:07] NoidedSuper: has joined #ruby
[15:16:57] havenwood: Rish: Couldn't find what? You're running `bundle install` and something is going wrong?
[15:17:22] crankharder: has joined #ruby
[15:17:58] Rish: i just want to setup an project on my system when i am run bundle install command
[15:18:00] Rish: Could not find figaro-1.1.0 in any of the sources
[15:18:30] Rish: come after that gem install figaro-1.1.0 then it's goes
[15:21:26] krawchyk: has joined #ruby
[15:21:52] r29v: has joined #ruby
[15:22:48] crankharder: has joined #ruby
[15:24:24] conta1: has joined #ruby
[15:27:09] krawchyk: has joined #ruby
[15:27:55] tcopeland: has joined #ruby
[15:28:23] jcarl43: has joined #ruby
[15:29:08] r29v: has joined #ruby
[15:33:11] spectra: has joined #ruby
[15:37:50] havenwood: Rish: What do you have set as the remote source?: gem env remotesources
[15:37:58] havenwood: Rish: Did you install bundler with apt or gem?
[15:41:11] phenom: has joined #ruby
[15:42:28] alireza: has joined #ruby
[15:44:44] kapil___: has joined #ruby
[15:48:19] za1b1tsu: has joined #ruby
[15:54:26] cagomez: has joined #ruby
[15:57:05] cagomez: has joined #ruby
[15:59:58] beowuff: has joined #ruby
[16:01:40] akaiiro: has joined #ruby
[16:01:50] pastorinni: has joined #ruby
[16:03:48] kent\n: has joined #ruby
[16:05:16] ldepandis: has joined #ruby
[16:07:45] zachk: has joined #ruby
[16:07:46] zachk: has joined #ruby
[16:09:36] snuz: has joined #ruby
[16:11:11] hkais: has joined #ruby
[16:11:37] graphene: has joined #ruby
[16:13:05] biberu: has joined #ruby
[16:13:56] dviola: has joined #ruby
[16:21:06] yohji: has joined #ruby
[16:23:33] agent_white: has joined #ruby
[16:27:25] pr0ton: has joined #ruby
[16:27:42] karapetyan: has joined #ruby
[16:27:49] crankharder: has joined #ruby
[16:30:34] amar_: has joined #ruby
[16:31:41] amar_: has joined #ruby
[16:31:46] schleppel: has joined #ruby
[16:34:02] rippa: has joined #ruby
[16:34:09] deadnull: has joined #ruby
[16:35:54] darkhanb: has joined #ruby
[16:41:57] Pisuke: has joined #ruby
[16:43:31] r29v: has joined #ruby
[16:51:51] TvL: has joined #ruby
[16:52:40] orbyt_: has joined #ruby
[16:54:26] bmurt: has joined #ruby
[16:58:48] snuz: has joined #ruby
[17:01:46] ur5us: has joined #ruby
[17:03:29] Caerus: has joined #ruby
[17:03:29] mikecmpbll: has joined #ruby
[17:05:49] ellcs1: has joined #ruby
[17:11:05] alex``: has joined #ruby
[17:20:37] amar_: has joined #ruby
[17:20:52] eckhardt: has joined #ruby
[17:22:17] Zaab1t: has joined #ruby
[17:25:20] crankharder: has joined #ruby
[17:26:56] amarks: has joined #ruby
[17:29:45] amarok_: has joined #ruby
[17:49:23] pr0ton: has joined #ruby
[17:52:50] ssolomon: has joined #ruby
[17:54:36] \void: has joined #ruby
[17:55:51] alfiemax: has joined #ruby
[17:56:49] jamesaxl: has joined #ruby
[17:57:22] a1ph4g33k: has joined #ruby
[17:57:33] a1ph4g33k: has left #ruby: ()
[18:01:27] amar_: has joined #ruby
[18:03:54] sameerynho: has joined #ruby
[18:04:14] alireza: has joined #ruby
[18:07:32] karapetyan: has joined #ruby
[18:16:20] beefjoe: has joined #ruby
[18:20:52] pastorinni: has joined #ruby
[18:24:42] sphenxes: has joined #ruby
[18:28:57] chkhanch: has joined #ruby
[18:29:04] snuz: has joined #ruby
[18:29:50] snuz: has joined #ruby
[18:30:14] alfiemax: has joined #ruby
[18:32:08] cagomez: has joined #ruby
[18:32:50] quobo: has joined #ruby
[18:33:24] karapetyan: has joined #ruby
[18:34:27] jp: has joined #ruby
[18:34:35] codymj: has joined #ruby
[18:37:19] snuz: has joined #ruby
[18:37:30] alfiemax_: has joined #ruby
[18:40:14] snuz: has joined #ruby
[18:42:32] jamesaxl: has joined #ruby
[18:50:49] fluxAeon: has joined #ruby
[18:50:58] alireza1: has joined #ruby
[18:55:05] Caerus: has joined #ruby
[18:57:32] karapetyan: has joined #ruby
[18:59:53] ur5us: has joined #ruby
[19:08:22] alex``: has joined #ruby
[19:22:24] karapetyan: has joined #ruby
[19:27:22] alireza1: has joined #ruby
[19:28:48] milanj: has joined #ruby
[19:34:17] Nicmavr: has joined #ruby
[19:34:46] ptx0: has joined #ruby
[19:39:44] alireza1: has joined #ruby
[19:44:18] spiette: has joined #ruby
[19:45:18] pr0ton: has joined #ruby
[19:47:56] claudiuinberlin: has joined #ruby
[19:57:19] jenrzzz: has joined #ruby
[19:57:19] jenrzzz: has joined #ruby
[20:04:38] pastorinni: has joined #ruby
[20:07:28] Es0teric: has joined #ruby
[20:10:49] mistergibson: has joined #ruby
[20:15:01] snuz: has joined #ruby
[20:24:22] venmx: has joined #ruby
[20:26:17] cthulchu: has joined #ruby
[20:26:36] tty: has joined #ruby
[20:28:49] nowhere_man: has joined #ruby
[20:32:19] crankharder: has joined #ruby
[20:34:10] ur5us: has joined #ruby
[20:37:54] jenrzzz_: has joined #ruby
[20:38:13] milanj: has joined #ruby
[20:40:08] amar_: has joined #ruby
[20:41:37] r29v: has joined #ruby
[20:44:01] Slown: has joined #ruby
[20:44:08] Slown: what's up ?
[20:45:18] Slown: how are you havenwood ?
[20:47:20] pastorinni: has joined #ruby
[20:52:44] jenrzzz: has joined #ruby
[20:52:44] jenrzzz: has joined #ruby
[20:56:29] Slown: havenwood ?
[21:00:06] karapetyan: has joined #ruby
[21:01:29] SeepingN: has joined #ruby
[21:06:59] havenwood: >> require 'prime'; 1.upto(4).map { |n| x = Prime.lazy.take(100).find { |k| (k ** n + n).prime? }; (x ? n ** x + x : 0) + 100 }.map(&:chr).join # Slown
[21:07:00] ruby[bot]: havenwood: # => "good" (https://eval.in/1041089)
[21:07:35] havenwood: https://oeis.org/A303122
[21:08:03] havenwood: We need a #map_select ;-P
[21:08:15] havenwood: Yay for #filter alias in 2.6!
[21:11:32] wsylvest: has joined #ruby
[21:12:58] amarks: has joined #ruby
[21:15:13] iamnix: has joined #ruby
[21:15:43] amarok_: has joined #ruby
[21:18:08] graphene: has joined #ruby
[21:28:50] alex``: has joined #ruby
[21:29:52] a1ph4g33k: has joined #ruby
[21:30:31] a1ph4g33k: has left #ruby: ()
[21:32:44] pr0ton1: has joined #ruby
[21:39:50] gr33n7007h: has joined #ruby
[21:39:59] amar_: has joined #ruby
[21:40:00] quarters: has joined #ruby
[21:40:00] quarters: has joined #ruby
[21:42:01] jenrzzz: has joined #ruby
[21:42:01] jenrzzz: has joined #ruby
[21:42:27] alireza1: has joined #ruby
[21:49:02] monoprotic: has joined #ruby
[21:49:02] monoprotic: has joined #ruby
[21:49:04] dstrunk: has joined #ruby
[21:49:13] Megamos: has joined #ruby
[21:49:16] Alec: has joined #ruby
[21:49:35] shah^: has joined #ruby
[21:51:13] jcarl43: has joined #ruby
[21:58:13] hidir_de: has joined #ruby
[21:58:15] zenspider: anyone know if ruby's const lookup heuristic has been emulated anywhere? I need it for some static code analysis stuff I'm doing.
[21:59:34] lupine: someone tried once, but the necessary hardware achieved self-awareness and took itself off to orion's belt
[22:03:22] jenrzzz_: has joined #ruby
[22:03:28] Caerus: has joined #ruby
[22:06:23] orbyt_: has joined #ruby
[22:06:36] shinnya: has joined #ruby
[22:06:51] baweaver: banister may have, but he's not around looks like
[22:08:27] zenspider: I can probably flub a good amount of it and still get good results... I'd just rather borrow than poke at it too much
[22:08:48] baweaver: >> def map_select(vs, &fn) vs.reduce([]) { |a, v| fn[v] ? (a<<fn[v]) : a } end; map_select([1,2,3]) { |v| v.even? && v * 2 } # havenwood
[22:08:49] ruby[bot]: baweaver: # => [4] (https://eval.in/1041093)
[22:11:53] pr0ton: has joined #ruby
[22:14:46] baweaver: >> guard = -> *cs, &fn { -> v { cs.all? { |c| c === v } && fn[v] } }; def map_select(vs,&fn) vs.reduce([]) { |a, v| fn[v] ? (a<<fn[v]) : a } end; map_select([1,2,3], &guard[:even?.to_proc] { |v| v * 2 }) # havenwood
[22:14:52] ruby[bot]: baweaver: I'm terribly sorry, I could not evaluate your code because of an error: NoMethodError:undefined method `[]' for nil:NilClass
[22:14:55] baweaver: Guard functions :D
[22:15:01] baweaver: crashed bot
[22:15:10] venmx: has joined #ruby
[22:15:31] baweaver: Ruby _really_ dislikes multiple `to_proc`s in the format of `&`....
[22:15:31] havenwood: baweaver: woot
[22:16:37] baweaver: Think I should add that as a bug?
[22:16:48] alireza1: has joined #ruby
[22:16:52] baweaver: You might have something that can be used as a block inside a block that returns a block
[22:17:08] havenwood: baweaver: module MapSelect; refine Enumerable do; def map_select(&fn) reduce([]) { |a, v| fn[v] ? (a << fn[v]) : a } end end end
[22:17:14] pr0ton: has joined #ruby
[22:17:41] baweaver: map_select([1,2,3], &guard.call(&:even?, &:zero?) { |v| v * 10 })
[22:17:52] baweaver: I'd argue that should be valid, but Ruby will flip out on it
[22:18:17] baweaver: If you sub in to_proc it'll work though. Probably just how YARV deals with `&`
[22:18:18] zenspider: you don't need to to_proc it yourself I don't think...
[22:18:21] zenspider: >> module Enumerable; def map_select(pred, &b); lazy.select(&pred).map(&b); end; end; (1..3).map_select(:even?) { |n| n * 2 }.to_a
[22:18:22] ruby[bot]: zenspider: # => [4] (https://eval.in/1041094)
[22:18:57] zenspider: maybe it should be called select_map instead?
[22:20:09] herbmillerjr: has joined #ruby
[22:20:39] ssolomon: has joined #ruby
[22:20:57] havenwood: "I consider filter_map mostly a mistake so it is unlikely we will add a similar function to that." ~Jose Valim
[22:22:03] havenwood: I'm curious why they removed filter_map.
[22:22:21] havenwood: I've certainly wanted it in Ruby.
[22:34:33] RougeR: has joined #ruby
[22:34:57] RougeR: has joined #ruby
[22:36:20] alfiemax: has joined #ruby
[22:37:03] amar_: has joined #ruby
[22:40:51] jp: has joined #ruby
[22:41:17] zenspider: havenwood: interesting. I wonder why
[22:41:24] Radar: havenwood: I believe they removed it because there is both filter + map and you can pipe one to the other.
[22:41:41] jenrzzz: has joined #ruby
[22:41:41] jenrzzz: has joined #ruby
[22:41:52] Radar: (which I think is what that function did, but I am going to find the source to back that up)
[22:43:10] Radar: Oh not quite: https://github.com/elixir-lang/elixir/blob/v1.3.0/lib/elixir/lib/enum.ex#L806-L808
[22:43:40] Radar: "Filters the enumerable and maps its elements in one pass." is the documentation for that function.
[22:44:03] cthulchu_: has joined #ruby
[22:44:11] Radar: p.s. why are you people writing perl? You know this is #ruby right?
[22:46:14] graphene: has joined #ruby
[22:46:28] havenwood: https://elixirforum.com/t/why-enum-filter-map-is-deprecated/6945/8
[22:46:59] havenwood: So I guess it's just the basic principle of fused functions being edge cases and Stream sufficing for single-pass needs.
[22:49:03] karapetyan: has joined #ruby
[22:53:52] dstrunk: has joined #ruby
[22:54:44] jp: has joined #ruby
[22:55:58] orbyt_: has joined #ruby
[22:56:13] alireza1: has joined #ruby
[22:59:11] subroot: has joined #ruby
[23:05:57] Lyubo1: has joined #ruby
[23:07:41] unreal: has joined #ruby
[23:08:08] graphene: has joined #ruby
[23:08:12] dstrunk: has joined #ruby
[23:14:59] graphene: has joined #ruby
[23:29:09] Sammitch: has joined #ruby
[23:29:34] Sammitch: to which dark god must I make sacrifice to in order to have this page load? https://www.rubydoc.info/gems/chef/Chef/Platform
[23:36:05] havenwood: Sammitch: You can run it yourself: gem server
[23:36:14] Alec: Sammitch: your mother.
[23:36:25] lupine: or just run yardoc in $GEM_HOME/gems/chef-14.3.37 or so
[23:36:31] havenwood: Alec: be nice.
[23:36:40] Alec: or just be happy that she didn't charge extra... okay.
[23:37:00] Alec: Sammitch: it was too easy - I couldn't not take it - I of course don't actually know Sammitch's mother, nor her occupation.
[23:37:38] havenwood: !kick Alec "Be even nicer!"
[23:37:38] ruby[bot]: +bbb $a:Alec$#ruby-banned Alec!*@*$#ruby-banned *!*@94.197.121.85.threembb.co.uk$#ruby-banned
[23:37:38] ruby[bot]: ruby[bot] kicked Alec: even nicer!"
[23:38:27] jenrzzz: has joined #ruby
[23:38:28] jenrzzz: has joined #ruby
[23:38:40] havenwood: Sammitch: Running it locally with rdoc or yard is probably the best way. The chef docs take a while to parse even locally, so it'll probably eventually show up on that page.
[23:39:09] havenwood: Sammitch: With `gem server` just go in your browser to: http://0.0.0.0:8808/doc_root/chef-14.3.37/Chef.html
[23:39:21] ruby[bot]: -bbb $a:Alec$#ruby-banned Alec!*@*$#ruby-banned *!*@94.197.121.85.threembb.co.uk$#ruby-banned
[23:39:49] Sammitch: oooof I just want find one property and/or method T_T
[23:40:11] Sammitch: yum info yardoc
[23:40:16] r29v: has joined #ruby
[23:43:55] Freshnuts: has joined #ruby
[23:47:07] havenwood: Sammitch: brew install yardoc
[23:47:17] havenwood: Sammitch: gem install**
[23:47:50] havenwood: Sammitch: err, yeard?
[23:48:11] havenwood: I'm so failing at multi-tasking...
[23:48:31] havenwood: Sammitch: The yard gem ships with yardoc.
[23:48:41] havenwood: Sammitch: gem install yard && yardoc
[23:48:51] havenwood: what lupine said
[23:49:48] havenwood: I'ts just: require 'yard'; YARD::CLI::Yardoc.run(*ARGV)
[23:52:22] Sammitch: I already generated it with rdoc, am reading it with lynx, and am hating life. :I
[23:53:57] alireza1: has joined #ruby
[23:55:14] cthu|: has joined #ruby
[23:55:58] r29v: has joined #ruby
[23:56:55] apeiros: has joined #ruby
[23:58:10] Sammitch: has left #ruby: ()