« Back to channel list

#ruby - 03 July 2016

« Back 1 day Forward 1 day »
[00:04:22] jenrzzz: has joined #ruby
[00:05:29] lupine: sure, ruby isn't sane enough to stop you
[00:06:03] roamingdog: has joined #ruby
[00:06:53] rkazak: has joined #ruby
[00:07:02] Illya: I was having some problems, but it was because I was putting it a module block, not sure why I was doing that. It's all fixed now though
[00:07:39] lupine: personally, I would avoid monkey-patching ::String, but that's a design thing
[00:07:58] Oclair: has joined #ruby
[00:09:09] ghr: has joined #ruby
[00:09:35] Illya: yeah, I know it's an awful solution, but it's for one-use scripts (famous last words)
[00:10:11] ftj: has joined #ruby
[00:13:05] macsteps: has joined #ruby
[00:13:30] millerti: has joined #ruby
[00:15:28] dsaur: has joined #ruby
[00:17:38] skweek: has joined #ruby
[00:21:10] ghr: has joined #ruby
[00:27:17] astrobunny: has joined #ruby
[00:29:57] millerti: has joined #ruby
[00:30:40] ghr: has joined #ruby
[00:40:11] ghr: has joined #ruby
[00:40:34] darix: Illya: you publish it as a gem....
[00:40:55] agentmeerkat: has joined #ruby
[00:41:08] spudowiar: has joined #ruby
[00:43:30] KnownSyntax: has joined #ruby
[00:43:30] KnownSyntax: has joined #ruby
[00:44:34] yfeldblum: has joined #ruby
[00:46:09] cd-rum: has joined #ruby
[00:47:17] roamingdog: has joined #ruby
[00:47:57] `tim`: has joined #ruby
[00:50:21] Carella: has joined #ruby
[00:52:44] ghr: has joined #ruby
[00:57:30] bnjf: has joined #ruby
[00:59:42] jenrzzz: has joined #ruby
[01:02:12] ghr: has joined #ruby
[01:02:52] wnd: has joined #ruby
[01:03:10] bkxd: has joined #ruby
[01:04:20] solocshaw: has joined #ruby
[01:05:52] Rasi: has joined #ruby
[01:12:41] nankyokusei: has joined #ruby
[01:12:42] ur5us: has joined #ruby
[01:12:43] ghr: has joined #ruby
[01:13:27] aibot: has joined #ruby
[01:16:34] JeanCarloMachado: has joined #ruby
[01:19:06] edwinvdgraaf: has joined #ruby
[01:22:43] ghr: has joined #ruby
[01:27:25] l4v2: has joined #ruby
[01:27:57] Kus: has joined #ruby
[01:28:09] astrobunny: has joined #ruby
[01:29:51] nando293921: has joined #ruby
[01:32:14] ghr: has joined #ruby
[01:32:33] nando293921: has joined #ruby
[01:35:09] pragmatism: has joined #ruby
[01:40:40] Arcaire: has left #ruby: ()
[01:41:08] agentmeerkat: has joined #ruby
[01:42:15] ghr: has joined #ruby
[01:43:18] ekinmur: has joined #ruby
[01:48:58] alfiemax: has joined #ruby
[01:49:06] n1x-nz: has joined #ruby
[01:51:45] ghr: has joined #ruby
[02:00:00] jaguarmagenta: has joined #ruby
[02:00:35] arnonhongklay: has joined #ruby
[02:00:50] isberg: has joined #ruby
[02:01:16] ghr: has joined #ruby
[02:02:01] coffeecupp: has joined #ruby
[02:03:51] opus: has joined #ruby
[02:08:46] arnonhongklay: has joined #ruby
[02:09:09] wnd: has joined #ruby
[02:09:59] pawnbox: has joined #ruby
[02:10:17] kent\n: has joined #ruby
[02:10:17] kent\n: has joined #ruby
[02:11:20] ghr: has joined #ruby
[02:16:25] dsaur: has joined #ruby
[02:20:47] ghr: has joined #ruby
[02:28:49] astrobunny: has joined #ruby
[02:30:47] ghr: has joined #ruby
[02:32:00] coffeecupp: has joined #ruby
[02:33:09] coffeecupp: has joined #ruby
[02:34:39] arnonhongklay: has joined #ruby
[02:34:55] enterprisey: has joined #ruby
[02:36:35] dsaur: has joined #ruby
[02:40:18] ghr: has joined #ruby
[02:42:09] agentmeerkat: has joined #ruby
[02:43:15] dannyh: has joined #ruby
[02:44:20] nando293921: has joined #ruby
[02:49:03] arnonhongklay: has joined #ruby
[02:49:49] ghr: has joined #ruby
[02:51:07] Carella: has joined #ruby
[02:52:17] pontiki: has joined #ruby
[02:56:12] jenrzzz: has joined #ruby
[02:59:19] ghr: has joined #ruby
[03:01:27] TheWhip: has joined #ruby
[03:04:09] alfiemax: has joined #ruby
[03:08:50] ghr: has joined #ruby
[03:10:20] LoneHerm_: has joined #ruby
[03:12:53] bkxd: has joined #ruby
[03:13:34] nankyokusei: has joined #ruby
[03:13:39] pawnbox: has joined #ruby
[03:13:49] jaguarmagenta: has joined #ruby
[03:15:34] charliesome: has joined #ruby
[03:18:20] ghr: has joined #ruby
[03:19:01] xcesariox: has joined #ruby
[03:19:29] LoneHerm_: has joined #ruby
[03:21:03] gix: has joined #ruby
[03:26:48] xall: has joined #ruby
[03:29:34] astrobunny: has joined #ruby
[03:30:21] ghr: has joined #ruby
[03:31:27] jenrzzz: has joined #ruby
[03:33:12] arnonhongklay: has joined #ruby
[03:37:10] Devalo: has joined #ruby
[03:40:51] ghr: has joined #ruby
[03:43:10] agentmeerkat: has joined #ruby
[03:44:04] bkxd: has joined #ruby
[03:49:40] alfiemax: has joined #ruby
[03:51:22] ghr: has joined #ruby
[03:51:59] dsaur: has joined #ruby
[03:53:20] harfangk: has joined #ruby
[03:56:14] CloCkWeRX: has joined #ruby
[03:57:39] SilverKey: has joined #ruby
[04:00:12] mistermocha: has joined #ruby
[04:01:23] ghr: has joined #ruby
[04:01:39] dionysus69: has joined #ruby
[04:08:46] pawnbox: has joined #ruby
[04:08:59] wldcordeiro: has joined #ruby
[04:10:25] crystal77: has joined #ruby
[04:10:53] ghr: has joined #ruby
[04:12:28] hk238: has joined #ruby
[04:13:16] alfiemax: has joined #ruby
[04:18:01] zenlot: has joined #ruby
[04:18:56] jaguarmagenta: has joined #ruby
[04:19:44] c0mrad3: has joined #ruby
[04:20:24] ghr: has joined #ruby
[04:20:32] arnonhongklay: has joined #ruby
[04:25:59] dsaur: has joined #ruby
[04:30:20] astrobunny: has joined #ruby
[04:30:54] ghr: has joined #ruby
[04:33:09] arnonhongklay: has joined #ruby
[04:34:06] dionysus69: has joined #ruby
[04:40:50] xcyclist: has joined #ruby
[04:43:25] agentmeerkat: has joined #ruby
[04:43:25] ghr: has joined #ruby
[04:51:54] Carella: has joined #ruby
[04:52:03] ftj: has joined #ruby
[04:52:56] ghr: has joined #ruby
[04:56:45] n1xnz: has joined #ruby
[04:58:01] bkxd: has joined #ruby
[04:58:18] shevy: hmmm ... if you have to work with frozen strings, and need to e. g. append to it, what would you rather use? the +'foo' variant or .dup ? or some other way?
[05:00:30] pwnd_nsfw: What's your situation though?
[05:00:36] pwnd_nsfw: I don't understand, seems like a trivial question
[05:02:26] ghr: has joined #ruby
[05:03:37] shevy: in general
[05:04:13] dragon9783: has joined #ruby
[05:05:08] arnonhon_: has joined #ruby
[05:05:26] pwnd_nsfw: ofc strings are immutable, but yeah, I'd just +
[05:05:37] pwnd_nsfw: or string interpolation
[05:09:43] yfeldblum: has joined #ruby
[05:14:24] nankyokusei: has joined #ruby
[05:16:27] ghr: has joined #ruby
[05:19:23] Mattx: has joined #ruby
[05:19:25] Mattx: Hey people!
[05:19:53] Mattx: I want to combine a hash like this {:a=>[5, 10, 15], :b=>["open", "close"]}
[05:20:04] Mattx: and get something like this [{:a=>5, :b=>"open"}, {:a=>5, :b=>"close"}, {:a=>10, :b=>"open"}, {:a=>10, :b=>"close"}, {:a=>15, :b=>"open"}, {:a=>15, :b=>"close"}]
[05:20:12] yfeldblum: has joined #ruby
[05:20:55] Mattx: Is there any built in function for that? I'm looking for an elegant and quick solution, since you know the output could be huge depending on the input
[05:22:09] Mattx: just in case, I don't know the length of the input, there could be more keys or the arrays could be larger
[05:22:22] pwnd_nsfw: both arrays are of variable length?
[05:22:41] Mattx: yep, everything is of variable length
[05:22:53] pwnd_nsfw: Couldn't you just use map
[05:23:09] pwnd_nsfw: nested maps
[05:23:18] pwnd_nsfw: Well,.... yeah, map
[05:23:30] pwnd_nsfw: Or, since I'm shit programmer
[05:25:24] Mattx: I'm thinking about doing it recursively
[05:25:58] ghr: has joined #ruby
[05:27:02] shevy: pwnd_nsfw hmm good idea, I have not thought about #{}
[05:27:25] gareeoliz: has joined #ruby
[05:31:05] astrobunny: has joined #ruby
[05:31:46] Mattx: [4] pry(main)> [1,2,3].product [4,5,6]
[05:31:47] Mattx: => [[1, 4], [1, 5], [1, 6], [2, 4], [2, 5], [2, 6], [3, 4], [3, 5], [3, 6]]
[05:31:48] Mattx: that's cool!
[05:33:12] arnonhongklay: has joined #ruby
[05:33:28] ruby-lang561: has joined #ruby
[05:33:36] PaulCapestany: has joined #ruby
[05:34:09] ruby-lang561: what is an eager class?
[05:34:37] pwnd_nsfw: One that just CANT wait
[05:36:01] bernardofire: has joined #ruby
[05:37:04] mistermocha: has joined #ruby
[05:37:28] ghr: has joined #ruby
[05:38:51] wuyin: has joined #ruby
[05:44:22] agentmeerkat: has joined #ruby
[05:44:57] phrozen77: has joined #ruby
[05:48:59] ghr: has joined #ruby
[05:49:15] JeanCarloMachado: has joined #ruby
[05:49:38] mtkd: has joined #ruby
[05:50:32] mp19uy: has joined #ruby
[05:51:47] mp19uy: Hello, I'm new to ruby and I'm trying to understand what does this code do: https://gist.github.com/mp19uy/63f30f6fa8e3cfde68f470d31d588a16
[05:52:52] chopin: has joined #ruby
[05:54:45] mp19uy: I don't get why there is a hash right before the line: path=File.join(filename), maybe it doesn't do anything
[05:55:12] aries_liuxueyang: has joined #ruby
[05:56:04] mp19uy: That gist come from this ruby script: https://github.com/jglovier/gifs/blob/gh-pages/script/build_site_index
[05:58:21] rkazak: has joined #ruby
[05:58:27] Azure|dc: has joined #ruby
[05:58:42] PaulCape_: has joined #ruby
[05:58:45] bkxd: has joined #ruby
[05:59:35] mp19uy: I understand almost everthing on it, but I can't crack what that specific part does. Looking at the different version of the file in the github repo, I figured out is has something to do with YAML because that specific piece of code was added alongside "require ''yaml'"
[06:01:02] ghr: has joined #ruby
[06:01:15] mp19uy: has joined #ruby
[06:03:00] shevy: that hash is returned from the method
[06:04:25] mp19uy: ohhh, great!
[06:04:44] mp19uy: thanks shevy
[06:05:28] mp19uy: is possible that the first parameter of that method (dir( isn't used at all?
[06:05:44] mp19uy: (that would be my second question)
[06:06:02] mp19uy: or it is used in some indirect way?
[06:07:32] shevy: if that really is the method
[06:07:43] shevy: then there is no point to mandate input of an argument that is not used within the method
[06:10:32] ghr: has joined #ruby
[06:10:39] mp19uy: thanks for the help
[06:16:57] chipotle: has joined #ruby
[06:17:06] mp19uy: has left #ruby: ()
[06:18:05] bkxd: has joined #ruby
[06:20:15] karapetyan: has joined #ruby
[06:20:31] ghr: has joined #ruby
[06:22:51] DevMagpie: has joined #ruby
[06:25:58] arnonhongklay: has joined #ruby
[06:27:05] DevMagpie: has joined #ruby
[06:27:36] PaulCapestany: has joined #ruby
[06:29:42] jaguarmagenta: has joined #ruby
[06:29:49] dsaur: has joined #ruby
[06:30:01] ghr: has joined #ruby
[06:31:04] UnKnOwN|: has joined #ruby
[06:31:49] astrobunny: has joined #ruby
[06:38:05] Yzguy: has joined #ruby
[06:38:33] Devalo: has joined #ruby
[06:38:43] phredus: hello, I want to install a Ruby Version Manager, chruby was recomende, is chruby cable of installing diferent version of ruby or does it just switch between installed versions?
[06:39:30] vinay_: has joined #ruby
[06:40:02] Yzguy: rbenv is good
[06:40:17] Yzguy: rbenv can install diff versions and switch between them
[06:41:29] vinay_: Hello.. This is Vinay here. I am trying to use 'win32ole' gem for visualstudio project file parsing
[06:41:29] postmodern: phredus, chruby switches, ruby-install installs, the both go together
[06:41:32] ghr: has joined #ruby
[06:43:04] vinay_: I created object dte = WIN32OLE.new("VisualStudio.DTE.9.0") and listed all methods using dte.ole_methods
[06:43:43] kraken: has joined #ruby
[06:43:58] vinay_: now, I have all methods available with dte, but I do not know the usage of all these methods. How can I get the methods help?
[06:44:12] krakenr: is there any way for a case statement to have a case for "bob" or "cat"
[06:44:25] krakenr: I can't just do case "bob" || "cat"
[06:44:52] agentmeerkat: has joined #ruby
[06:45:10] archio: has joined #ruby
[06:46:30] shevy: kraken_ does when 'bob','cat' not work?
[06:48:38] nhhc: has joined #ruby
[06:49:43] Devalo: has joined #ruby
[06:49:56] vinay_: kraken_, case "BOB" when "BOB" puts "BOB" else puts "CAT" end
[06:50:00] Sashimi: has joined #ruby
[06:50:02] vinay_: is that you are looking for?
[06:50:15] krakenr: shevy was right
[06:50:19] krakenr: I just didnt know the syntax
[06:51:02] ghr: has joined #ruby
[06:51:19] vinay_: How to get the help for object methods
[06:52:38] shevy: Vinay_ there are some workarounds
[06:52:42] Carella: has joined #ruby
[06:52:59] shevy: source location and you can obtain the documentation too; also see how ri does it
[06:53:27] shevy: RDoc::RI::Driver.process_args
[06:53:34] vinay_: ok. I tried wirble.
[06:55:18] phredus: postmodern: could you please explain a bit more I have never used a vesion manager and I am pretty new to ruby, also I know there is rvm rbenv chruby, which do you recomend and why? Thank you
[06:55:53] deecross: has joined #ruby
[06:56:41] postmodern: phredus, so ruby-install handles the downloading, compiling, installing of the rubies (really the ruby Makefiles handle this under the hood)
[06:56:50] vinay_: Shevy, Could you please elaborate RDoc::RI::Driver.process_args?
[06:57:42] postmodern: phredus, once installed into the desired location (~/.rubies/ or /opt/rubies/), chruby can automatically detect them and switch to them
[06:58:50] postmodern: phredus, chruby does this by loading bash/zsh hooks into your shell, so every time a command executes it checks if there's a .ruby-version file. Or you can explicitly invoke chruby to switch to another ruby.
[06:59:15] shevy: Vinay_ it depends on what you want to do. if you just want to obtain some documentation for a method, use ri from the commandline or pry and show-doc or whatever was the name
[06:59:54] phredus: postmodern: I use gentoo and ruby is part of the os, So chruby will install other stand alone ruby versions and not mess with my ruby at all?
[07:00:34] ghr: has joined #ruby
[07:00:43] vinay_: ok. I also searched in http://ruby-doc.org/, but not getting the required information anywhere..
[07:00:47] postmodern: phredus, correct, i'm a huge fan of having a go-to system ruby, that just works
[07:00:57] phredus: postmodern: I am also reading https://github.com/postmodern/ruby-install#readme right now
[07:01:05] vinay_: basically, I am trying to get help for win32ole methods
[07:01:11] postmodern: phredus, you use a ruby manager to switch to alternate rubies for various projects etc, as opposed to your everyday ruby
[07:01:25] archio: has joined #ruby
[07:01:29] phredus: postmodern: ok good I will give chruby a try, thank you
[07:01:42] last_staff: has joined #ruby
[07:01:57] vinay_: there are few examples for excel parsing using win32ole, but not for visual studio projects
[07:02:21] interki: has joined #ruby
[07:04:23] Dimik: has joined #ruby
[07:04:46] charliesome: has joined #ruby
[07:07:26] interki: has joined #ruby
[07:07:49] interki: has joined #ruby
[07:08:11] interki: has joined #ruby
[07:08:56] interki: has joined #ruby
[07:09:37] bkxd: has joined #ruby
[07:12:35] ghr: has joined #ruby
[07:15:18] nankyokusei: has joined #ruby
[07:16:54] greenhat|: has joined #ruby
[07:18:52] xall: has joined #ruby
[07:19:41] harfangk: has joined #ruby
[07:20:15] deecross: has joined #ruby
[07:21:46] PaulCape_: has joined #ruby
[07:22:04] ghr: has joined #ruby
[07:26:35] User458764: has joined #ruby
[07:27:08] User458764: has joined #ruby
[07:31:38] rkazak: has joined #ruby
[07:32:05] ghr: has joined #ruby
[07:32:28] firstdayonthejob: has joined #ruby
[07:32:36] astrobunny: has joined #ruby
[07:36:29] bluOxigen: has joined #ruby
[07:39:05] anisha_: has joined #ruby
[07:41:02] User458764: has joined #ruby
[07:42:06] ghr: has joined #ruby
[07:43:38] symm-: has joined #ruby
[07:45:19] DevMagpie: has joined #ruby
[07:46:05] agentmeerkat: has joined #ruby
[07:48:06] PaulCapestany: has joined #ruby
[07:49:06] multi_io: has joined #ruby
[07:51:14] conta: has joined #ruby
[07:51:38] ghr: has joined #ruby
[07:54:25] Sashimi: has joined #ruby
[07:55:19] rbennacer: has joined #ruby
[08:01:38] Silthias: has joined #ruby
[08:02:07] ghr: has joined #ruby
[08:04:05] agent_wh1te: has joined #ruby
[08:05:02] agent_white: has joined #ruby
[08:05:41] malleable: has joined #ruby
[08:09:48] interki: anyone have experience using bundler as a bsd port?
[08:10:11] Yzguy: has joined #ruby
[08:10:42] dc4: has joined #ruby
[08:10:49] Hyuk: has joined #ruby
[08:12:07] ghr: has joined #ruby
[08:13:31] ramfjord: has joined #ruby
[08:15:43] agent_white: has joined #ruby
[08:15:46] PaulCape_: has joined #ruby
[08:17:10] marr: has joined #ruby
[08:23:08] ghr: has joined #ruby
[08:26:36] xall: has joined #ruby
[08:29:01] depesz: has joined #ruby
[08:31:13] rippa: has joined #ruby
[08:32:38] ghr: has joined #ruby
[08:33:21] astrobunny: has joined #ruby
[08:33:45] rbennacer: has joined #ruby
[08:39:39] matp: has joined #ruby
[08:40:16] PaulCapestany: has joined #ruby
[08:40:44] jaguarmagenta: has joined #ruby
[08:42:54] rbennacer: has joined #ruby
[08:43:09] ghr: has joined #ruby
[08:43:24] yeticry: has joined #ruby
[08:43:42] SilverKey: has joined #ruby
[08:49:54] SCHAAP137: has joined #ruby
[08:51:24] spider-mario: has joined #ruby
[08:52:01] harfangk: has joined #ruby
[08:52:08] rbennacer: has joined #ruby
[08:52:54] Illya: has joined #ruby
[08:53:09] ghr: has joined #ruby
[08:58:44] jhass: interki: apparently not, but ask your question anyway
[09:02:39] u0_a134: has joined #ruby
[09:02:40] ghr: has joined #ruby
[09:04:19] interki: I think ive narrowed down that the port doesnt set an accessible location for the gems, as im researching its becomming more of a BSD/bundler issue then a ruby one so ill chase up there, but ty for responce
[09:05:37] fiifi: need prep for a ruby interview
[09:05:58] rbennacer: has joined #ruby
[09:06:36] jhass: http://exercism.io/
[09:07:46] PaulCape_: has joined #ruby
[09:08:11] charliesome: has joined #ruby
[09:16:11] nankyokusei: has joined #ruby
[09:16:49] maloik: has joined #ruby
[09:17:32] rikkipitt: has joined #ruby
[09:17:46] ghr: has joined #ruby
[09:18:44] Sashimi: has joined #ruby
[09:18:50] lxsameer: has joined #ruby
[09:20:26] wigust_: has joined #ruby
[09:22:02] Silthias: has joined #ruby
[09:24:47] rbennacer: has joined #ruby
[09:27:21] blackgoat: has joined #ruby
[09:28:11] ghr: has joined #ruby
[09:28:51] kirun: has joined #ruby
[09:31:17] genpaku: has joined #ruby
[09:33:16] PaulCapestany: has joined #ruby
[09:33:56] rbennacer: has joined #ruby
[09:34:06] astrobunny: has joined #ruby
[09:35:17] Dreamer3: has joined #ruby
[09:38:42] ghr: has joined #ruby
[09:39:13] axisys: has joined #ruby
[09:39:39] toretore: has joined #ruby
[09:40:40] darkxploit: has joined #ruby
[09:41:19] pLaToOn: has joined #ruby
[09:42:01] nankyokusei: has joined #ruby
[09:42:20] zeroDi: has joined #ruby
[09:43:04] rbennacer: has joined #ruby
[09:45:14] dsaur: has joined #ruby
[09:47:06] agentmeerkat: has joined #ruby
[09:49:12] ghr: has joined #ruby
[09:51:04] Carella: has joined #ruby
[09:55:01] Darwinr: has joined #ruby
[09:56:21] rbennacer: has joined #ruby
[09:59:08] antgel: has joined #ruby
[09:59:49] ponga: has joined #ruby
[10:01:17] ghr: has joined #ruby
[10:04:02] enocom: has joined #ruby
[10:04:28] enocom: has left #ruby: ("Textual IRC Client: www.textualapp.com")
[10:05:32] rbennacer: has joined #ruby
[10:05:54] fiifi: has joined #ruby
[10:10:02] SteppenII: has joined #ruby
[10:10:44] ghr: has joined #ruby
[10:11:15] dc4: has joined #ruby
[10:17:01] deecross: has joined #ruby
[10:17:39] chip_: has joined #ruby
[10:19:32] rbennacer: has joined #ruby
[10:20:29] Xeago: has joined #ruby
[10:21:14] ghr: has joined #ruby
[10:22:46] der-landgraf: has joined #ruby
[10:26:15] PaulCape_: has joined #ruby
[10:28:40] biberu: has joined #ruby
[10:30:45] ghr: has joined #ruby
[10:34:55] astrobunny: has joined #ruby
[10:36:36] pawnbox: has joined #ruby
[10:36:37] Xeago_: has joined #ruby
[10:37:09] chrismytton: has joined #ruby
[10:37:11] beawesomeinstead: has joined #ruby
[10:37:16] sdothum: has joined #ruby
[10:37:30] jpinnix_______: has joined #ruby
[10:37:32] sepp2k: has joined #ruby
[10:37:43] tfitts: has joined #ruby
[10:37:44] zzak___: has joined #ruby
[10:37:53] Travis-42: has joined #ruby
[10:37:53] DukeDave: has joined #ruby
[10:37:54] incomprehensibly: has joined #ruby
[10:37:56] frode15243: has joined #ruby
[10:37:58] rflot: has joined #ruby
[10:38:00] mrsolo: has joined #ruby
[10:38:07] danzilio: has joined #ruby
[10:40:03] deepak_: has joined #ruby
[10:41:12] tomphp: has joined #ruby
[10:41:33] jaguarmagenta: has joined #ruby
[10:42:20] ghr: has joined #ruby
[10:45:03] User458764: has joined #ruby
[10:45:11] pawnbox: has joined #ruby
[10:47:20] dsaur: has joined #ruby
[10:48:23] agentmeerkat: has joined #ruby
[10:51:46] ghr: has joined #ruby
[10:52:07] Carella: has joined #ruby
[10:56:40] rbennacer: has joined #ruby
[10:59:47] UnKnOwN|: has joined #ruby
[11:00:51] Xeago_: has joined #ruby
[11:02:17] ghr: has joined #ruby
[11:04:00] gareeoliz: has joined #ruby
[11:05:32] rbennacer: has joined #ruby
[11:05:43] Beverage: has joined #ruby
[11:10:29] Xeago_: has joined #ruby
[11:11:47] ghr: has joined #ruby
[11:14:52] rbennacer: has joined #ruby
[11:16:36] moredhel: has joined #ruby
[11:18:05] PaulCapestany: has joined #ruby
[11:19:14] deecross: has joined #ruby
[11:21:18] ghr: has joined #ruby
[11:25:49] diegoviola: has joined #ruby
[11:27:46] ramfjord: has joined #ruby
[11:28:03] rbennacer: has joined #ruby
[11:29:46] allcentury: has joined #ruby
[11:31:19] ghr: has joined #ruby
[11:32:52] Xeago_: has joined #ruby
[11:34:13] mexis_: has joined #ruby
[11:34:13] im0b: has joined #ruby
[11:34:13] jmhmccr: has joined #ruby
[11:35:40] astrobunny: has joined #ruby
[11:36:09] codecop: has joined #ruby
[11:37:14] rbennacer: has joined #ruby
[11:38:36] der-landgraf: has joined #ruby
[11:44:48] karapetyan: has joined #ruby
[11:44:51] binaryplease1: has joined #ruby
[11:45:15] Xeago_: has joined #ruby
[11:46:27] rbennacer: has joined #ruby
[11:46:50] ghr: has joined #ruby
[11:47:31] Hanmac: has joined #ruby
[11:48:07] dsaur: has joined #ruby
[11:48:37] agentmeerkat: has joined #ruby
[11:49:24] luluapple: has joined #ruby
[11:54:30] edwinvdgraaf: has joined #ruby
[11:55:34] rbennacer: has joined #ruby
[11:56:31] blackgoat: has joined #ruby
[11:59:50] ghr: has joined #ruby
[12:01:14] der-land1: has joined #ruby
[12:01:36] gareeoliz: has joined #ruby
[12:03:01] interki: resolved, it was my experience that the freebsd port for bundler didn't create /etc/.bundle at install so didn't have write perms to that path.
[12:09:21] ghr: has joined #ruby
[12:09:34] rbennacer: has joined #ruby
[12:11:43] gareeoliz: has joined #ruby
[12:12:11] Hyuk: has joined #ruby
[12:12:29] IHB: has joined #ruby
[12:12:41] Illya: has joined #ruby
[12:14:29] IHB: hey guys, hoping someone can help guide me in the right direction with this DSL that I'm building
[12:16:19] IHB: I need to replace nested module and class definitions which represent protobuf messages and enums, with DSL-provided blocks, but doing so with instance_eval loses the lexical scoping of constants, which means the nested classes can no longer reference the enum module constants
[12:16:27] IHB: what would be the best way to solve this?
[12:18:20] jhass: well, first I'd question if you really need to
[12:18:42] jhass: second is whether you really need to instance_eval or if a context object yielding API wouldn't suffice
[12:18:51] ghr: has joined #ruby
[12:20:43] jhass: if both to these is "yes, otherwise I'll die", you could try to get a hold of the callee's Module.nesting and built an anonymous module/class in which you include everything you need to be callable plus everything in Module.nesting and then class_eval with it as context, or something into that venue
[12:20:44] IHB: jhass: I need a DSL in this case to be able to implement the abstraction that is needed. I'd very much prefer to use instance_eval, as using yielded objects would only add to line noise and these definitions don't need to access other unrelated objects
[12:20:59] m0rph84: has joined #ruby
[12:21:34] IHB: I was hoping there was a better solution than Module.nesting, which I'm not even sure works with classes
[12:21:36] jhass: the other easier way is to not rely on relative constant resolution of course
[12:22:04] IHB: Would an example make what I'm trying to accomplish more clear?
[12:22:17] ferr: has joined #ruby
[12:22:25] dionysus69: has joined #ruby
[12:22:28] jhass: I think I have a fairly clear picture
[12:22:44] jhass: I consider it an over engineered approach due to the issue you're facing
[12:23:03] IHB: The problem is, any other approach is not very ruby-like
[12:23:13] jhass: that's entirely subjective
[12:23:21] IHB: I've been working with protobuf the way that it is implemented by beefcake for years nwo
[12:24:02] m0rph84: has left #ruby: ()
[12:24:14] IHB: Having to look up a bunch of Messages::MessageName::Flag::FlagName, add them together and then set them to the flags for each message is simply far too verbose, non-ruby-like, and extremely un-DRY
[12:24:30] IHB: I would really like to be able to abstract enums and flags completely
[12:25:06] IHB: Especially since I need to reuse this kind of thing for many projects, and many messages in each project
[12:25:11] Azure: has joined #ruby
[12:25:20] depesz: has left #ruby: ("WeeChat 1.5-dev")
[12:26:14] jhass: I guess you could refer to them with symbols in the API and look them up if they have a well defined place
[12:27:02] IHB: I can't even do that without something horrible like Module.nesting
[12:28:04] rbennacer: has joined #ruby
[12:28:09] jhass: or do a shadow system where they have to be defined using your API too
[12:28:22] ghr: has joined #ruby
[12:28:39] jhass: tbh next person who touches this will throw it away again though
[12:29:12] kent\n: has joined #ruby
[12:30:09] IHB: jhass: no one else will be touching any of these projects, I am the sole developer
[12:30:23] IHB: putting together a quick test case to clarify what I've like to do
[12:30:46] jhass: don't make the mistake of thinking future you will always have your opinion ;)
[12:31:01] jhass: thinking of future you as another developer you have to explain all this stuff to helps
[12:32:39] ruby[bot]: -b *!*@gateway/web/cgi-irc/kiwiirc.com/ip.119.157.221.169$#ruby-banned
[12:33:18] IHB: that really isn't something I need to worry about
[12:33:37] IHB: it's unlikely that another developer will ever work on any of these projects
[12:34:00] jhass: that's entirely besides my point
[12:34:12] IHB: but even if they had to, the abstraction would be intuitive and well worth using over raw class based stuff
[12:34:32] jhass: until it doesn't work 100%
[12:34:38] IHB: this is what I'm trying to accomplish: http://codepad.org/47DEtHOD
[12:35:06] gareeoliz: has joined #ruby
[12:35:10] IHB: this is a small abtraction which a lot of big abstractions are built on top of
[12:35:57] jhass: since you love symbols so much
[12:36:07] jhass: just keep everything in symbols
[12:36:15] jhass: including line 32
[12:36:22] IHB: the issue is that message fields need to be able to reference both constants in their class as well as upper level constants such as other enums or messages
[12:36:27] astrobunny: has joined #ruby
[12:36:42] IHB: even if I use symbols for those classes, I need to be able to hook them up to the classes
[12:37:21] rbennacer: has joined #ruby
[12:37:36] jokke: has joined #ruby
[12:37:59] yqt: has joined #ruby
[12:38:01] isberg: has joined #ruby
[12:38:21] User458764: has joined #ruby
[12:40:16] jhass: isn't there already an external DSL for defining protobufs? and aren't there ruby libs that can read those? why define that stuff in Ruby code in the first place?
[12:41:10] IHB: Saves having to maintain external markup and perform precompilation
[12:41:47] IHB: the actual DSL for defining protobuf fields (the required method call in the paste) is provided by the beefcake gem
[12:42:15] jaguarmagenta: has joined #ruby
[12:42:18] IHB: I have monkeypatched support for the flags helper method into the beefcake gem
[12:42:35] jhass: idk, sorry but this still all feels like not invented here
[12:42:40] jhass: https://developers.google.com/protocol-buffers/docs/proto3#simple
[12:43:15] IHB: I suppose what I could do, is hook up parent class/module reference using the define_protocol and message DSL methods, and the walk those references backwards and use that for constant lookup scope
[12:44:03] IHB: jhass: I do not use external protobuf definitions, it's that simple
[12:44:20] IHB: for ruby-only protocols, they are a total waste and not convenient to have to precompile
[12:44:35] IHB: but I don't even use them for projects that use two different languages
[12:44:44] jhass: so instead you spend who knows how many man hours reinventing them as a internal DSL
[12:44:48] IHB: I define all protocol using metaprogramming
[12:45:06] IHB: you don't seem to be following
[12:45:23] IHB: languages already support defining protobuf with metaprogramming
[12:45:44] IHB: I am simply trying to extend the support that beefcake provides to allow more ruby-ish abstraction
[12:45:52] IHB: which will lead to far more DRY code
[12:46:30] rbennacer: has joined #ruby
[12:47:06] jhass: yes and it's too verbose _for your taste_, so instead of using an _already existing_ implementation of a external, _more compact_ DSL with _existing widely used implementations_, you spend time on making your own
[12:47:53] ghr: has joined #ruby
[12:47:55] fiifi: has joined #ruby
[12:48:03] IHB: I think that having hundreds of lines like this is too verbose for almost anyones taste... Messages::ActionMessage::ActionFlag::Action1 | Messages::ActionMessage::ActionFlag::Action2 | Messages::ActionMessage::ActionFlag::Action3 | Messages::ActionMessage::ActionFlag::Action4
[12:48:21] jhass: I didn't counter that
[12:48:29] IHB: using external definitions would not solve this problem
[12:48:48] IHB: there is also no ruby library that does solve this problem as far as I am aware
[12:48:53] dsaur: has joined #ruby
[12:49:02] IHB: beefcake is supposed to be the most ruby-ish protobuf library
[12:49:07] IHB: but it falls terribly short
[12:49:39] IHB: and I've already had to monkeypatch it with a whole range of optimizations when it comes to encoding and decoding, and improvements when it comes to type conversion
[12:50:24] ych: has joined #ruby
[12:50:39] jhass: well, I've given the venues I'd pursue above, more specific hints would require hours spending on the actual code and you're locked into the path, so good luck!
[12:50:52] Mattx: has joined #ruby
[12:51:08] IHB: if you really think there is an existing solution which I can use to be able to use protobuf without insane amounts of repeated code everywhere filling my code base with horrible line noise, then I'll be willing to scrap all the improvements to beefcake, all my existing usage across 10+ projects, and start switching to it
[12:51:26] IHB: but I do not believe such a thing exists, and unless you can provide me with it, I will still need to create it myself
[12:51:36] UnKnOwN|: has joined #ruby
[12:51:38] LoneHerm_: has joined #ruby
[12:52:36] fiifi: has joined #ruby
[12:53:31] Carella: has joined #ruby
[12:54:22] ftj: has joined #ruby
[12:54:28] symm-: has joined #ruby
[12:55:40] rbennacer: has joined #ruby
[12:55:49] nando293921: has joined #ruby
[12:56:45] nofxx: has joined #ruby
[12:58:59] l4v2: has joined #ruby
[13:00:27] Es0teric: has joined #ruby
[13:03:56] ElFerna: has joined #ruby
[13:04:45] PaulCape_: has joined #ruby
[13:04:53] edwinvdgraaf: has joined #ruby
[13:08:24] ghr: has joined #ruby
[13:08:56] rbennacer: has joined #ruby
[13:09:24] pawnbox: has joined #ruby
[13:10:51] GodFather_: has joined #ruby
[13:14:21] Sashimi: has joined #ruby
[13:16:20] deecross: has joined #ruby
[13:16:44] miqlas-H: has joined #ruby
[13:16:44] loocash: has joined #ruby
[13:18:05] dionysus69: has joined #ruby
[13:18:09] rbennacer: has joined #ruby
[13:19:10] bluOxigen: has joined #ruby
[13:20:25] ghr: has joined #ruby
[13:20:57] pawnbox: has joined #ruby
[13:26:09] astrobunny: has joined #ruby
[13:26:10] blackmesa: has joined #ruby
[13:27:22] rbennacer: has joined #ruby
[13:28:04] hk238: has joined #ruby
[13:28:56] isberg: has joined #ruby
[13:29:14] deecross: has joined #ruby
[13:30:25] ghr: has joined #ruby
[13:36:26] rbennacer: has joined #ruby
[13:36:39] nerium: has joined #ruby
[13:39:56] ghr: has joined #ruby
[13:42:25] Miron: has joined #ruby
[13:42:56] burgestrand: has joined #ruby
[13:43:36] Devalo: has joined #ruby
[13:44:10] millerti: has joined #ruby
[13:45:40] rbennacer: has joined #ruby
[13:49:26] ghr: has joined #ruby
[13:49:38] dsaur: has joined #ruby
[13:50:07] agentmeerkat: has joined #ruby
[13:52:39] LoneHermit: has joined #ruby
[13:54:26] Carella: has joined #ruby
[13:54:45] rbennacer: has joined #ruby
[13:55:39] ftj: has joined #ruby
[13:57:01] chip_: has joined #ruby
[13:59:27] ghr: has joined #ruby
[13:59:48] conta: has joined #ruby
[13:59:57] JeanCarloMachado: has joined #ruby
[14:00:43] genpaku: has joined #ruby
[14:03:57] rbennacer: has joined #ruby
[14:08:06] ftj: has joined #ruby
[14:09:24] QORRiE: has joined #ruby
[14:10:25] vjacob: has joined #ruby
[14:10:58] ghr: has joined #ruby
[14:12:53] ekinmur: has joined #ruby
[14:12:53] Sashimi: has joined #ruby
[14:13:06] rbennacer: has joined #ruby
[14:15:08] codecop: has joined #ruby
[14:18:22] pontiki: has joined #ruby
[14:19:41] yqt: has joined #ruby
[14:20:28] ghr: has joined #ruby
[14:22:17] rbennacer: has joined #ruby
[14:23:15] fujinuma: has left #ruby: ("Leaving")
[14:23:41] futilegames: has joined #ruby
[14:25:02] QORRiE: has joined #ruby
[14:31:05] dsaur: has joined #ruby
[14:31:23] rbennacer: has joined #ruby
[14:32:34] JeanCarloMachado: has joined #ruby
[14:32:59] ghr: has joined #ruby
[14:33:18] Carella: has joined #ruby
[14:35:43] Devalo: has joined #ruby
[14:38:31] symm-: has joined #ruby
[14:40:38] rbennacer: has joined #ruby
[14:40:55] blackmesa: has joined #ruby
[14:41:47] codecop: has joined #ruby
[14:42:34] ghr: has joined #ruby
[14:43:04] jaguarmagenta: has joined #ruby
[14:45:36] astrobunny: has joined #ruby
[14:45:48] davedev24: has joined #ruby
[14:45:58] spudowiar: has joined #ruby
[14:46:14] Carella: has joined #ruby
[14:49:43] rbennacer: has joined #ruby
[14:49:52] gareeoliz: has joined #ruby
[14:51:48] freerobby: has joined #ruby
[14:51:54] freerobby1: has joined #ruby
[14:52:22] deecross: has joined #ruby
[14:53:05] ghr: has joined #ruby
[14:58:58] rbennacer: has joined #ruby
[15:03:31] ghr: has joined #ruby
[15:06:21] nando293921: has joined #ruby
[15:06:36] araujo: has joined #ruby
[15:07:43] araujo: has joined #ruby
[15:08:04] rbennacer: has joined #ruby
[15:08:49] dn`: has joined #ruby
[15:09:26] zeroDi: has joined #ruby
[15:09:52] araujo: has joined #ruby
[15:10:44] Devalo: has joined #ruby
[15:11:52] tvw: has joined #ruby
[15:13:31] ghr: has joined #ruby
[15:17:17] rbennacer: has joined #ruby
[15:17:20] ddfreyne: has joined #ruby
[15:17:45] johnmilton: has joined #ruby
[15:20:13] agentmeerkat: has joined #ruby
[15:23:02] ghr: has joined #ruby
[15:24:11] Ishido: has joined #ruby
[15:26:32] rbennacer: has joined #ruby
[15:26:49] blackmesa: has joined #ruby
[15:30:14] rkazak: has joined #ruby
[15:31:57] dsaur: has joined #ruby
[15:32:14] blaxter: has joined #ruby
[15:32:32] ghr: has joined #ruby
[15:33:14] Lord_of_Life: has joined #ruby
[15:35:45] rbennacer: has joined #ruby
[15:36:30] circ-user-sZsTA: has joined #ruby
[15:37:16] lxsameer: has joined #ruby
[15:39:00] hutch34: has joined #ruby
[15:39:36] Sp4rKy: has joined #ruby
[15:40:12] macsteps: has joined #ruby
[15:43:23] LoneHerm_: has joined #ruby
[15:44:03] ghr: has joined #ruby
[15:45:00] Es0teric: has joined #ruby
[15:46:50] l4v2: has joined #ruby
[15:48:41] rbennacer: has joined #ruby
[15:49:27] aryaching: has joined #ruby
[15:54:34] ghr: has joined #ruby
[15:57:52] perturbation: has joined #ruby
[15:59:33] millerti: has joined #ruby
[16:02:55] macsteps: has joined #ruby
[16:04:04] ghr: has joined #ruby
[16:05:12] kirun: has joined #ruby
[16:06:52] User458764: has joined #ruby
[16:08:26] macsteps: has joined #ruby
[16:14:35] ghr: has joined #ruby
[16:21:46] houhoulis: has joined #ruby
[16:23:18] yqt: has joined #ruby
[16:24:05] ghr: has joined #ruby
[16:24:39] millerti: has joined #ruby
[16:26:04] pawnbox: has joined #ruby
[16:26:46] ramfjord: has joined #ruby
[16:32:02] rikkipitt: has joined #ruby
[16:32:08] darkxploit: has joined #ruby
[16:32:38] dsaur: has joined #ruby
[16:34:06] ghr: has joined #ruby
[16:37:06] darkxploit: has joined #ruby
[16:39:17] millerti: has joined #ruby
[16:40:09] pawnbox: has joined #ruby
[16:42:32] dsaur: has joined #ruby
[16:42:40] darkxploit: has joined #ruby
[16:43:36] ghr: has joined #ruby
[16:43:48] jaguarmagenta: has joined #ruby
[16:44:29] nando293921: has joined #ruby
[16:50:02] blackmesa: has joined #ruby
[16:50:08] nando294021: has joined #ruby
[16:50:45] rikkipitt: has joined #ruby
[16:51:39] nando293921: has joined #ruby
[16:54:10] ghr: has joined #ruby
[16:54:58] last_staff: has joined #ruby
[16:55:00] agentmeerkat: has joined #ruby
[16:57:56] gix: has joined #ruby
[16:58:22] _tpavel: has joined #ruby
[16:58:59] IHB: it's interesting that Array lookups are considerably faster on instance variables than locals, but Hash lookups are faster on locals than instance variables
[16:59:54] diegoviola: has joined #ruby
[17:01:08] enterprisey: has joined #ruby
[17:01:25] dionysus69: has joined #ruby
[17:03:46] Alice112: has joined #ruby
[17:04:07] mistermocha: has joined #ruby
[17:04:10] flashpoint9: has joined #ruby
[17:05:07] ghr: has joined #ruby
[17:05:48] flashpoint9: has joined #ruby
[17:12:23] LoneHerm_: has joined #ruby
[17:12:59] mistermocha: has joined #ruby
[17:13:31] wigust: has joined #ruby
[17:14:50] diegoviola: has joined #ruby
[17:15:08] ghr: has joined #ruby
[17:18:54] xlegoman_: has joined #ruby
[17:21:38] anisha_: has joined #ruby
[17:22:04] UnKnOwN|: has joined #ruby
[17:22:54] mistermocha: has joined #ruby
[17:23:05] Alice112: has left #ruby: ()
[17:24:31] C0deMaver1ck: has joined #ruby
[17:24:39] ghr: has joined #ruby
[17:27:14] rbr: has joined #ruby
[17:27:42] Rory: has joined #ruby
[17:30:08] mistermocha: has joined #ruby
[17:30:20] JeremyM_: has joined #ruby
[17:30:39] nando293921: has joined #ruby
[17:32:08] yfeldblum: has joined #ruby
[17:32:12] dsaur: has left #ruby: ()
[17:34:09] ghr: has joined #ruby
[17:34:18] mistermocha: has joined #ruby
[17:34:32] binaryplease: Hi, I'm trying to run this script to request the header of websites, but get a lot of 503 (Service Unavaitible) responses. https://ptpb.pw/esHl What am I missing?
[17:35:14] binaryplease: Also netstat shows me a lot of http connecions being open
[17:35:17] pawnbox: has joined #ruby
[17:35:49] mello: has joined #ruby
[17:38:15] genpaku: has joined #ruby
[17:38:38] PaaYaw: has joined #ruby
[17:38:43] JeanCarloMachado: has joined #ruby
[17:39:07] PaaYaw: anyone home?
[17:39:13] rikkipitt: has joined #ruby
[17:39:28] jhass: ?anyone paayaw
[17:39:28] ruby[bot]: paayaw: Just ask your question, if anyone has, is or can, they will respond.
[17:39:42] binaryplease: Hi, I'm trying to run this script to request the header of websites, but get a lot of 503 (Service Unavaitible) responses. https://ptpb.pw/esHl What am I missing?
[17:41:15] PaaYaw: im doing some ruby and i just realized that u can perform arithmetic on string except multiplication(*)
[17:42:02] PaaYaw: i want to know how ruby does that under hood...my guess is it treats it as a loop
[17:42:11] alfiemax: has joined #ruby
[17:42:30] jhass: >> "a" * 5
[17:42:31] ruby[bot]: jhass: # => "aaaaa" (https://eval.in/599934)
[17:42:36] jhass: works just as well
[17:42:48] jhass: the trick is, operators are just method calls too
[17:42:53] jhass: >> "a".*(5)
[17:42:54] ruby[bot]: jhass: # => "aaaaa" (https://eval.in/599935)
[17:43:10] jhass: http://devdocs.io/ruby~2.3/string#method-i-2A
[17:46:10] ghr: has joined #ruby
[17:46:34] dh64: has joined #ruby
[17:46:53] xcyclist: has left #ruby: ()
[17:47:46] ruby-lang666: has joined #ruby
[17:47:48] ruby-lang666: hey, anybody there?
[17:48:09] dgynn: has joined #ruby
[17:48:10] DoubleMalt: has joined #ruby
[17:48:25] jhass: ?anyone ruby-lang666
[17:48:26] ruby[bot]: ruby-lang666: Just ask your question, if anyone has, is or can, they will respond.
[17:48:46] ruby-lang666: if anybody's here, I'm trying to make my own map method. it's working, but I can't get it to change my array without using ! in the call.
[17:48:47] ruby-lang666: def my_map self.my_each_with_index{|x| x = yield x} end
[17:49:20] PaaYaw: jhass i see...if i got u correctly...u r saying the "*" operator is the only math operator that handles srtrings...?
[17:49:33] jhass: ruby-lang666: x is a local variable, reassgning it will have no effect on self
[17:49:49] jhass: you have to use another array method, such as Array#[]=
[17:49:50] ruby-lang666: yeah, i tried using each_with_index and changing self[i] but that didn't help
[17:50:00] jhass: show your attempt of doing that
[17:50:10] jhass: paayaw: no
[17:50:18] jhass: sorry but not remotely what I said
[17:50:35] jhass: in the context of strings, * isn't even a math operator anymore
[17:50:41] jhass: just an operator
[17:50:43] ruby-lang666: def my_map self.my_each_with_index{|x,i| self[i] = yield x} end
[17:51:12] PaaYaw: jhass...ok
[17:51:18] jhass: ruby-lang666: looks good, assuming my_each_with_index works correct
[17:51:40] ruby-lang666: it works correctly, but it doesn't affect my_arr though. how would I go about using your solution?
[17:51:41] binaryplease2: has joined #ruby
[17:51:41] nanoz: has joined #ruby
[17:52:33] jhass: ruby-lang666: that seems quite unlikely, I think you're confused over your test code or that doesn't work correctly
[17:52:50] ruby-lang666: no, my each_with_index works
[17:52:57] jhass: maybe make a gist of everything you got
[17:52:59] ruby[bot]: https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
[17:52:59] ruby-lang666: and i'm not using rspec, i'm just running it from the terminal right now
[17:53:19] jhass: just gist the terminal session "proving" your statements
[17:53:25] jhass: and the code
[17:53:34] ruby-lang666: https://gist.github.com/karpimpski/1302a185a7f14b2c9dfa6c5aa7bf01b9
[17:54:39] ruby-lang666: i also commented my terminal output
[17:54:48] mdw: has joined #ruby
[17:54:53] User458764: has joined #ruby
[17:54:58] solocshaw: has joined #ruby
[17:55:00] jhass: note that gists can be edited and have multiple files
[17:55:21] jhass: I don't see your code called in the example code
[17:55:47] ruby-lang666: i call it at the bottom
[17:55:47] ruby-lang666: p better_arr.map{|x| x * 2}
[17:55:56] jhass: also note that your my_each and my_each_with_index behave like map and map.with_index respectively, not .each and .each_with_index
[17:56:03] mistermocha: has joined #ruby
[17:56:04] jhass: .map does not call .my_map
[17:56:17] ruby-lang666: wow, that's the second time i've done that
[17:56:46] ruby-lang666: and they don't, they don't, they behave the same as my normal each calls
[17:56:51] ruby-lang666: they don't change the array itself
[17:57:04] jhass: .each doesn't change any array
[17:57:12] jhass: it merely returns self
[17:57:12] RoryO: has joined #ruby
[17:57:18] jhass: unchanged
[17:57:47] ruby-lang666: each loops through the array, and does what is in the block
[17:57:49] ruby-lang666: that's what each does
[17:58:02] jhass: yes and it doesn't do anything with the blocks return values
[17:58:13] jhass: yours however does, making it behave like map
[17:58:41] LoneHerm_: has joined #ruby
[17:59:30] ruby-lang666: it looks like map, but in every example i've tried it gives the same exact output as each. and i've tried multiple online each examples, all giving the same output
[17:59:40] ruby-lang666: how would you suggest I solve this? just yield x inside of my each method?
[18:00:29] jhass: an example that would show the difference is as simple as p [1, 2].each {|x| x ** 2 } vs p [1, 2].my_each {|x| x ** 2 }
[18:00:38] l4v2: has joined #ruby
[18:00:51] ruby-lang666: does my each method look right now?
[18:01:24] jhass: there's no need for arr = [] and it doesn't return self yet
[18:02:15] ruby-lang666: yeah, i took that out in my code. i just forgot to do it in my gist
[18:02:24] Sashimi_: has joined #ruby
[18:02:44] ruby-lang666: and i always thought map changed the array itself. does it only change the array itself if you use map!?
[18:02:58] ruby-lang666: if that's the case then i did it right the first time
[18:04:22] jhass: yes that's right
[18:04:46] jaguarmagenta: has joined #ruby
[18:05:13] jhass: Ruby's core convention for ! methods is: if there's a method ending in !, there's one that without a ! that returns a modified copy instead. The ! version returns nil if it made no changes
[18:05:19] jhass: self otherwise
[18:05:56] jhass: so .map is essentially arr = dup; arr.map!(&block); arr
[18:05:59] ascarter: has joined #ruby
[18:07:23] ruby-lang666: okay, thanks! do my each and each_with_index methods look good to you?
[18:08:00] jhass: they still don't return self
[18:08:21] ruby[bot]: Ruby community standards recommend using 2 spaces as indentation (see https://github.com/bbatsov/ruby-style-guide#spaces-indentation and https://ukupat.github.io/tabs-or-spaces/).
[18:08:45] ruby-lang666: i have 2 space indentation in sublime, i guess i just didn't change it in the gisty
[18:09:00] ruby-lang666: but why would my each methods return self? they don't affect self
[18:09:02] shevy: evil tabster!
[18:09:08] jhass: also for x in y is internally rewritten to y.each do |x|, basically, so just use that directly
[18:09:45] ruby-lang666: and i know that part, i just can't use the each method for this exercise. only my own Enumerable methods
[18:09:46] jhass: they would because they mimic core ruby behavior and that's what core ruby does
[18:10:17] jhass: .upto and .times are other alternatives to for here
[18:11:04] ruby-lang666: i figured .times would be redundant because i would need to create a counter variable
[18:11:39] ruby-lang666: i have my each methods returning self now in my gist. is that what you meant?
[18:13:26] torandu: has joined #ruby
[18:15:18] ghr: has joined #ruby
[18:16:31] mikethefish: hey, it's me who you just helped. thanks a lot!
[18:16:47] mikethefish: now why exactly should they return self? I didn't notice a difference. and should i make all of my methods return self?
[18:16:52] jhass: mikethefish: http://devdocs.io/ruby~2.3/integer#method-i-times take another look, in particular what it yields ;)
[18:17:07] AlexRussia: has joined #ruby
[18:17:42] mikethefish: oh and that's cool! i didn't know it automatically counted the index. i'll update that next, thanks!
[18:17:47] jhass: mikethefish: no to the latter, the former I already answered, because Ruby core, which you reimplement here, does. It gives a well defined return value (opposed to leaking an implementation detail) as well
[18:18:50] jhass: btw your sublime is probably just configured to display tabs as two spaces, opposed to truly using two spaces (the "Indent using Spaces" setting)
[18:18:55] rikkipitt: has joined #ruby
[18:19:30] mikethefish: i get that it's ruby core, maybe i just don't exactly understand what that means. i know i'm reimplementing ruby core, but is there any specific purpose to make sure i return the self value other than that?
[18:19:49] mikethefish: i'm just wondering if there's a certain security issue or something like that with that, or if it's just convention
[18:20:43] jhass: since you repeat your question a third time I would just repeat my answer a third time. If something in my answer is unclear I would prefer being asked to clarify that specific part.
[18:21:26] mikethefish: i changed the question. i understand what you said about it being ruby core and that it's the way they do it in ruby core. i am asking why it's used in ruby core and why i should use it (other than it just being ruby core)
[18:21:52] jhass: as I already said, to have a well defined return value opposed to leaking an implementation detail
[18:22:55] mikethefish: i see now, i just had a loop and not a specific return value. i'm sorry, i'm just fairly new to ruby and i have a lot to learn
[18:22:58] jhass: keep in mind every Ruby expression has a value and Ruby returns the last expressions value of a method as its return value
[18:23:21] mikethefish: yeah, i know that it returns the last expression. in my dumb mind, that's what made me think it was ok to just have the loop and no implicit return value
[18:24:06] kavanagh: has joined #ruby
[18:27:12] ghr: has joined #ruby
[18:27:29] jenrzzz: has joined #ruby
[18:27:39] JeanCarloMachado: has joined #ruby
[18:28:23] nando293921: has joined #ruby
[18:30:14] nando293921: has joined #ruby
[18:31:03] malleable: has joined #ruby
[18:32:36] millerti: has joined #ruby
[18:32:47] smathy: has joined #ruby
[18:37:42] ghr: has joined #ruby
[18:39:37] JeanCarloMachado: has joined #ruby
[18:40:03] hutch34: has joined #ruby
[18:42:12] enterprisey: has joined #ruby
[18:42:39] nertzy: has joined #ruby
[18:42:51] kavanagh: has joined #ruby
[18:44:42] JeanCarl1Machado: has joined #ruby
[18:44:57] UnKnOwN|: has joined #ruby
[18:47:13] ghr: has joined #ruby
[18:51:15] roamingdog: has joined #ruby
[18:52:15] yqt: has joined #ruby
[18:55:11] enterprisey: has joined #ruby
[18:58:46] ghr: has joined #ruby
[18:59:48] Abonec: has joined #ruby
[19:00:06] ascarter: has joined #ruby
[19:02:26] pLaToOn: has joined #ruby
[19:03:01] davedev24: has joined #ruby
[19:05:31] mistermocha: has joined #ruby
[19:05:31] hutch34: has joined #ruby
[19:06:56] Es0teric: has joined #ruby
[19:07:57] AlphaKitty: has joined #ruby
[19:08:46] binaryplease: Hi, I'm trying to run this script to request the header of websites, but get a lot of 503 (Service Unavaitible) responses. https://ptpb.pw/esHl What am I missing?
[19:09:20] adam12: Sounds like you're being rate limited / overloading the server?
[19:10:19] ghr: has joined #ruby
[19:10:43] RoryO: You're blasting 100 connections as fast as possible to the server, it's probably rate limiting you to prevent you from doing exactly what you're doing.
[19:10:43] deecross: has joined #ruby
[19:13:12] Hobogrammer: has joined #ruby
[19:13:55] torandu: has joined #ruby
[19:15:14] hmnhf: has joined #ruby
[19:15:30] spudowiar: has joined #ruby
[19:17:27] duoi: has joined #ruby
[19:17:31] symm-: has joined #ruby
[19:20:14] ghr: has joined #ruby
[19:23:15] postmodern: has joined #ruby
[19:29:05] Kus: has joined #ruby
[19:29:45] ghr: has joined #ruby
[19:31:33] kavanagh: has joined #ruby
[19:32:47] genpaku: has joined #ruby
[19:33:21] jaguarmagenta: has joined #ruby
[19:33:47] Stazer: has joined #ruby
[19:33:53] Stazer: has left #ruby: ()
[19:34:20] alfiemax: has joined #ruby
[19:34:54] drbrain: Also, Connection: close is bad
[19:35:45] drbrain: if you're making multiple requests to the same server you want to use persistent connections
[19:36:42] jhass: if you're (also) making requests to a lot of different servers you also want to pay attention to not run out of available connections (OS limit) though
[19:37:04] jhass: especially using persistent connections that can easily happen
[19:38:43] kavanagh: has joined #ruby
[19:39:16] ghr: has joined #ruby
[19:41:14] hmnhf: has joined #ruby
[19:43:34] der-landgraf: has joined #ruby
[19:43:34] solars: has joined #ruby
[19:44:59] kavanagh: has joined #ruby
[19:45:10] hmnhf: has joined #ruby
[19:46:44] Devalo: has joined #ruby
[19:47:16] nando293921: has joined #ruby
[19:48:46] ghr: has joined #ruby
[19:49:09] mistermocha: has joined #ruby
[19:50:15] nhhc: has joined #ruby
[19:51:08] Lord_of_Life: has joined #ruby
[19:51:44] kavanagh: has joined #ruby
[19:52:18] aryaching: has joined #ruby
[19:54:09] pmyjavec: has joined #ruby
[19:56:20] Madplatypus: has joined #ruby
[19:57:17] kavanagh: has joined #ruby
[19:57:53] ur5us: has joined #ruby
[19:58:01] LoneHermit: has joined #ruby
[19:59:48] rbennacer: has joined #ruby
[19:59:59] zacstewart: has joined #ruby
[20:01:47] ghr: has joined #ruby
[20:04:43] phantummm: has joined #ruby
[20:04:55] swills: has joined #ruby
[20:09:19] kavanagh: has joined #ruby
[20:10:49] Dimik: has joined #ruby
[20:11:18] ghr: has joined #ruby
[20:11:32] chestz: has joined #ruby
[20:11:46] malleabl1: has joined #ruby
[20:13:26] phantummm: has left #ruby: ("WeeChat 1.4")
[20:13:33] mistermocha: has joined #ruby
[20:16:00] RoryO: has joined #ruby
[20:16:56] phantummm: has joined #ruby
[20:17:37] naftilos76: has joined #ruby
[20:21:15] JeanCarloMachado: has joined #ruby
[20:23:20] ghr: has joined #ruby
[20:25:41] bb010g: has joined #ruby
[20:27:45] pontiki: has joined #ruby
[20:30:11] Devalo: has joined #ruby
[20:31:58] phredus: Hey guys, I've intalled chruby and I have used "ruby-install" to install a version of ruby I want. How do I activate and switch back and forth between the different versions?
[20:32:35] pontiki: phredus: `chruby <version>`, so like `chruby 2.3.0`
[20:32:38] jhass: if you installed it into ~/.rubies/version or /opt/rubies/version (iirc) chruby should pick it up automatically
[20:32:53] jhass: if not you have to add the path you installed it to to the RUBIES environment variable
[20:33:44] pontiki: if you also have the chruby auto script loaded, you can use the usual .ruby-version files
[20:34:54] ghr: has joined #ruby
[20:34:56] phredus: I did not specify a path so I am assuming it used the default path. and "chruby" returns "-bash: chruby: command not found"
[20:35:15] pontiki: phredus: you don't have the scripts loaded then
[20:35:29] pontiki: check your .profile or .bash_profile
[20:35:53] phredus: what am i looking for in the .profiles?
[20:36:27] pontiki: https://github.com/postmodern/chruby#configuration
[20:37:17] moei: has joined #ruby
[20:38:30] phredus: .bashrc has: # Put your fun stuff here.
[20:38:30] phredus: export PATH=$HOME/bin:$PATH
[20:38:30] phredus: export PATH=$HOME/Apps/bin:$PATH
[20:38:30] phredus: source /usr/local/share/chruby/chruby.sh
[20:39:07] phredus: and I have restarted my terminal since making the entry
[20:39:29] pontiki: try this: `type chruby | head -1`
[20:39:41] pontiki: you should see "function chruby"
[20:40:05] phredus: $ chruby | head -1
[20:40:05] phredus: -bash: chruby: command not found
[20:40:14] pontiki: you forgot "type"
[20:40:30] phredus: $ type chruby | head -1
[20:40:30] phredus: -bash: type: chruby: not found
[20:40:50] pontiki: enter the source path from your .bashrc
[20:41:32] phredus: sorry I dont know what you mean
[20:41:42] pontiki: this: `source /usr/local/share/chruby/chruby.sh`
[20:42:48] phredus: yes, but enter it where?
[20:43:01] pontiki: at the command line
[20:43:07] pontiki: do you use command line much?
[20:43:46] tomphp: has joined #ruby
[20:43:54] phredus: yes, about 20 years now, but I dont know what you mean by enter it, 1 inpout into a file or type it at the command line
[20:44:51] spudowiar: has joined #ruby
[20:44:52] rkazak: has joined #ruby
[20:44:58] pontiki: i never knew "enter" was that ambiguous when discussing command line things
[20:45:31] phredus: the problem is that the chruby installation did not create /usr/local/share/chruby/ ---> $ ls /usr/local/share/chruby/
[20:45:32] phredus: ls: cannot access /usr/local/share/chruby/: No such file or directory
[20:46:11] postmodern: phredus, how did you install chruby?
[20:46:23] phredus: look Im sorry if I offended you, if want to help I appreciate it. But lets not get into a pissing contest here, please.
[20:46:30] pontiki: ACTION tags in postmodern, the master of the chruby!!
[20:46:48] pontiki: i'm not offended
[20:46:50] ghr: has joined #ruby
[20:47:02] pontiki: just confused
[20:47:11] smathy: has joined #ruby
[20:47:26] postmodern: phredus, depending on how you installed chruby (from a package manager or from source) it may be installed into /usr/local or /usr
[20:47:37] phredus: ok, good because that was not my intention. I was just not understanding what you wanted me to do. That is why I asked
[20:48:03] phredus: I used wget -O chruby-0.3.9.tar.gz https://github.com/postmodern/chruby/archive/v0.3.9.tar.gz
[20:48:03] phredus: tar -xzvf chruby-0.3.9.tar.gz
[20:48:03] phredus: cd chruby-0.3.9/
[20:48:04] phredus: sudo make install
[20:48:36] postmodern: phredus, ok then it should be installed into /usr/local/...
[20:48:45] postmodern: phredus, unless you have PREFIX set to something
[20:49:05] postmodern: echo $PREFIX
[20:49:42] phredus: returns nothing
[20:49:58] anisha_: has joined #ruby
[20:50:04] kavanagh: has joined #ruby
[20:50:16] postmodern: phredus, just curious what paths did you see when running `sudo make install`
[20:50:50] phredus: I did not notice, I could just run again if you think that may be the issue
[20:51:20] gorsuch: has joined #ruby
[20:51:46] postmodern: phredus, yep, run it again and paste the output
[20:51:55] ascarter: has joined #ruby
[20:51:56] phredus: ok will do, thanks brb
[20:54:11] houhoulis: has joined #ruby
[20:55:43] phredus: # make install
[20:55:43] phredus: for dir in `find etc lib bin sbin share -type d 2>/dev/null`; do mkdir -p /usr/local/$dir; done
[20:55:43] phredus: for file in `find etc lib bin sbin share -type f 2>/dev/null`; do cp $file /usr/local/$file; done
[20:55:43] phredus: mkdir -p /usr/local/share/doc/chruby-0.3.9
[20:55:43] phredus: cp -r *.md *.txt /usr/local/share/doc/chruby-0.3.9/
[20:58:26] QORRiE_: has joined #ruby
[20:58:59] postmodern: phredus, ok you should have a /usr/local/share/chruby directory
[21:00:18] phredus: yes I do have /usr/local/share/chruby now
[21:00:50] phredus: contains 2 scripts auto.sh chruby.sh
[21:00:58] postmodern: phredus, ok, now follow the directions in the README on how to load chruby.sh and auto.sh into your bash config
[21:01:36] postmodern: phredus, you can either do this by adding them to ~/.bashrc or creating a /etc/profile.d/chruby.sh file (assuming your system loads additional things from /etc/profile.d/)
[21:01:50] ghr: has joined #ruby
[21:03:09] phredus: I di if what you are refering to is add this line "source /usr/local/share/chruby/chruby.sh" to .bashrc. however "chruby" gets$ chruby
[21:03:09] phredus: bash: chruby: command not found
[21:04:02] postmodern: phredus, you also have to restart your shell, so it loads the new configuration
[21:04:58] phredus: done, please give a command to test it
[21:05:17] postmodern: chruby should now return successfully
[21:05:44] kavanagh: has joined #ruby
[21:05:53] phredus: while in the directory /usr/local/share/chruby $ chruby
[21:05:54] phredus: bash: chruby: command not found
[21:06:15] phredus: I may be missing something quite simple here but I dont see it
[21:06:45] phredus: /usr/local/share/chruby $ sh chruby.sh retuns silence
[21:07:15] postmodern: phredus, did you add those lines to .bashrc and restart your shell?
[21:07:38] phredus: yes on my own and then per your instructions just to make sure
[21:08:08] postmodern: phredus, it could be ~/.bashrc isn't being loaded for interactive shells
[21:08:18] postmodern: phredus, try adding the configuration to ~/.bash_profile
[21:10:57] phredus: I can troubleshoot the bash issue later on my own, could you please help me determine whether or not chruby is working correctly
[21:11:11] SCHAAP137: has joined #ruby
[21:11:21] ghr: has joined #ruby
[21:11:26] postmodern: phredus, it's not being loaded, so it's not working at all
[21:11:57] postmodern: phredus, try manually loading it with `source chruby.sh`
[21:12:01] phredus: what should the output of it loading correctly be?
[21:12:37] bzb: has joined #ruby
[21:14:53] postmodern: phredus, now try running chruby
[21:15:18] phredus: ok, if I run "sh /usr/local/share/chruby/chruby.sh" I get nothing, how do I test to see if it is working?
[21:15:41] phredus: postmodern: $ chruby
[21:15:41] phredus: bash: chruby: command not found
[21:16:05] postmodern: phredus, i said to run `source /usr/local/share/chruby/chruby.sh`
[21:16:20] postmodern: phredus, source loads the script into your current shell, sh just runs it in a sub-shell
[21:16:46] postmodern: source is how you load additional configuration files into your shell
[21:16:47] phredus: source /usr/local/share/chruby/chruby.sh returns nothing
[21:16:57] postmodern: phredus, ok now try running chruby
[21:17:13] phredus: ruby-2.2.2
[21:17:22] shevy: you did it!
[21:17:22] phredus: success!!! Yay
[21:17:30] shevy: even an old ruby!!!
[21:17:38] postmodern: phredus, ok, now you just need to figure out how to load chruby in your shell configuration
[21:17:59] phredus: well that is the one I need and I installed using ruby-install
[21:18:33] postmodern: phredus, usually adding `source .../chruby.sh` to ~/.bashrc or /etc/profile.d/ works, but some distros do weird things to the bash configuration files
[21:20:31] nofxx: has joined #ruby
[21:21:49] phredus: yeah that may be the issue I use gentoo and it doesent always handle things like other distros do, thank you much for the help
[21:22:38] postmodern: i've ran into minor variations where some distros only load .bashrc in non-interactive mode, where some load .bashrc and .bash_profile in interactive mode
[21:22:53] ghr: has joined #ruby
[21:23:50] phredus: chruby will install other versions of ruby and leave my main ruby wich is part of my os alone, I am not understanding how that switching back and forth work
[21:24:03] jhass: it's a matrix of distro/shell/terminal emulator IME
[21:24:39] postmodern: phredus, ruby-install installs rubies into ~/.rubies (for normal users) and /opt/rubies/ (when ran as root/sudo)
[21:24:52] postmodern: phredus, note that you have to restart your shell to see the new versions
[21:25:04] jhass: chruby system will switch back to your system ruby
[21:25:18] postmodern: phredus, /usr/bin/ruby should always be your default go-to ruby
[21:25:36] jhass: unless you're on RHEL 6 :P
[21:25:37] phredus: ok got that, how do I return to my os's ruby
[21:25:46] jhass: chruby system will switch back to your system ruby
[21:26:14] phredus: "chruby system" is a command?
[21:27:37] phredus: postmodern: jhass: pontiki: Perfect, thank you guys for all the help I will read from here on and fine tune, happy 4th
[21:28:20] pontiki: have a great one
[21:28:34] phredus: I was suspicious at first but I think I'm liking this minimal chruby approach :)
[21:29:07] floatingpoint: has joined #ruby
[21:29:35] houhoulis: has joined #ruby
[21:29:55] sepp2k: has joined #ruby
[21:33:05] postmodern: once you get it setup, you forget it's there. it's like a toothbrush
[21:33:09] burgestrand: has joined #ruby
[21:34:08] jaguarmagenta: has joined #ruby
[21:34:31] mrodrigues: has joined #ruby
[21:35:37] JeanCarloMachado: has joined #ruby
[21:35:52] ghr: has joined #ruby
[21:37:57] kavanagh: has joined #ruby
[21:39:00] jaguarmagenta: has joined #ruby
[21:44:59] phredus: postmodern: cool thanks
[21:45:23] ghr: has joined #ruby
[21:47:03] kavanagh_: has joined #ruby
[21:47:04] karapetyan: has joined #ruby
[21:47:15] spudowiar: has joined #ruby
[21:52:05] TriOptimum: has joined #ruby
[21:52:09] roamingdog: has joined #ruby
[21:54:06] vdamewood: has joined #ruby
[21:54:41] yfeldblum: has joined #ruby
[21:54:53] ghr: has joined #ruby
[22:03:53] LoneHerm_: has joined #ruby
[22:04:24] ghr: has joined #ruby
[22:05:07] Sashimi: has joined #ruby
[22:06:01] ur5us: has joined #ruby
[22:06:16] JeanCarloMachado: has joined #ruby
[22:07:13] shevy: a toothbrush
[22:07:31] cd-rum: has joined #ruby
[22:09:55] deecross: has joined #ruby
[22:11:01] crdpink: has joined #ruby
[22:11:10] Devalo: has joined #ruby
[22:11:29] kavanagh: has joined #ruby
[22:11:51] jaguarmagenta: has joined #ruby
[22:12:25] cd-rum_: has joined #ruby
[22:13:16] gomix: has joined #ruby
[22:14:33] spider-mario: has joined #ruby
[22:18:08] lupine: chruby + ruby-install = god
[22:18:15] lupine: (thanks postmodern :p)
[22:18:44] coffeecupp: has joined #ruby
[22:19:30] mistermocha: has joined #ruby
[22:19:34] nickjj: lupine, just wait until you discover docker
[22:19:38] nickjj: then you don't need any of that
[22:19:55] lupine: nickjj: I can say nothing polite in response to that
[22:20:28] kavanagh: has joined #ruby
[22:20:36] lupine: my production deployments are based around seriously good Debian packages ^^
[22:22:35] nickjj: lupine, me too, except they happen to be wrapped in docker too
[22:23:22] nickjj: why? now you get the advantage of pure isolation in dev too, and your buddies on windows, osx or linux can all run the same code
[22:23:26] pawnbox: has joined #ruby
[22:23:33] lupine: (I've actually been coming around to containers a fair bit recently, but the fact remains that the standard of the existing base is absolutely rubbish)
[22:24:14] nickjj: existing base of what? most official images are running debian inside
[22:24:55] ghr: has joined #ruby
[22:25:49] lupine: if a new release to Debian security doesn't trigger an automated rebuild and redeploy of your container based on debian, you are in trouble
[22:30:44] Parko: has joined #ruby
[22:31:02] Parko1: has joined #ruby
[22:31:42] nickjj: lupine, that would be up to your team, it could be done
[22:32:42] nickjj: also don't forget the compromise would be sandboxed to within the container, so the host isn't at any real risk as long as you're not doing something silly
[22:33:38] zenlot6: has joined #ruby
[22:35:25] ghr: has joined #ruby
[22:37:47] lupine: nickjj: the host is irrelevant. the user's data is what matters
[22:38:13] lupine: and yes, the problems with docker are much more about the community and common practices than with the actual tech
[22:38:27] lupine: containers are cool. extant containers and practices with them are less so
[22:39:17] nickjj: if you stick with official images you should be ok, they tend to be maintained by the teams in charge of that specific tech
[22:39:41] Nilium: Practices like having 1gb base images and nobody thinking it's weird to copy an entire OS into a container when none of it is used
[22:39:53] lupine: that kind of thing, aye
[22:39:53] karapetyan: has joined #ruby
[22:40:05] Nilium: Sorry, you're not my coworkers, I shouldn't screech about that.
[22:40:07] lupine: the inability to actually verify downloaded images sanely is also a problem
[22:40:11] nickjj: Nilium, those are other people tho
[22:40:14] Nilium: That one's pretty spooky.
[22:40:32] nickjj: you can use alpine based images and end up with very small images (~5mb larger than not using docker)
[22:40:37] lupine: if you start from debootstrap and always keep to your own container image server and also manage all build triggers yourself, you can get places
[22:41:03] lupine: also split build fromdeploy containers
[22:41:43] nickjj: lupine, when was the last time you looked at security btw?
[22:41:46] nickjj: because you can sign images
[22:41:48] Nilium: Most of my images are scratch-based
[22:42:16] shinnya: has joined #ruby
[22:42:22] nickjj: i forgot what version introduced it, but it was a long time ago, well over 6 months
[22:42:24] Nilium: i.e., no base image
[22:44:16] pawnbox: has joined #ruby
[22:44:56] ghr: has joined #ruby
[22:44:57] LoneHermit: has joined #ruby
[22:46:03] lupine: nickjj: you can sign them, but the verification is a pig and not done by default and not reliable even when it's done
[22:47:18] solars: has joined #ruby
[22:47:24] lupine: anyway, i'm not saying "don't use them", I'm saying "here's what needs to be done to use them sensibly"
[22:47:47] nickjj: it's actually pretty easy to sign and ensure you pull signed images, but you are right in that it's disabled by default
[22:47:52] lupine: I don't enjoy development environments as Vagrantfiles either
[22:51:04] freerobby: has joined #ruby
[22:52:15] dc4: has joined #ruby
[22:54:02] Nilium: I'm just hoping CoreOS's take on containers.. takes off I guess.
[22:54:11] Nilium: Mostly because of Jetpack on FreeBSD
[22:54:26] ghr: has joined #ruby
[22:58:37] Yzguy: has joined #ruby
[22:59:16] smathy: has joined #ruby
[22:59:23] JeanCarloMachado: has joined #ruby
[23:00:03] gomix: has joined #ruby
[23:01:28] ledestin: has joined #ruby
[23:03:57] ghr: has joined #ruby
[23:04:12] Yzguy: has joined #ruby
[23:04:30] jaguarmagenta: has joined #ruby
[23:09:58] macsteps: has joined #ruby
[23:10:16] cyphase: has joined #ruby
[23:10:24] roamingdog: has joined #ruby
[23:13:10] karapetyan: has joined #ruby
[23:13:28] diegoviola: has joined #ruby
[23:13:41] Rodya_: has joined #ruby
[23:13:58] ghr: has joined #ruby
[23:15:39] Bugboy1028: has joined #ruby
[23:16:38] xlegoman: has joined #ruby
[23:23:32] ghr: has joined #ruby
[23:24:00] Oog: has joined #ruby
[23:27:42] User458764: has joined #ruby
[23:29:47] rbennacer: has joined #ruby
[23:30:25] anth0ny_: has joined #ruby
[23:30:43] dc4: has joined #ruby
[23:31:11] Arcaire: has joined #ruby
[23:31:38] deecross: has joined #ruby
[23:32:11] anth0ny_: I’m trying to install “vagrant-berkshelf” but it throws an error about not being able to install “rack” due to my ruby version. Oddly, my version should be acceptable (it is higher than needed). Can anyone provide advice? For the record, I know nothing about Ruby. http://pastie.org/pastes/10898061/text?key=ledbhrklfoool8nrwrfg
[23:33:06] CybrGhost: has joined #ruby
[23:33:29] ghr: has joined #ruby
[23:34:58] gorsuch: has left #ruby: ("Killed buffer")
[23:38:17] Guest43: has joined #ruby
[23:38:54] Guest43: has joined #ruby
[23:42:59] ghr: has joined #ruby
[23:43:48] shevy: anth0ny_ what is your ruby version
[23:43:53] mistermocha: has joined #ruby
[23:44:36] roamingdog: has joined #ruby
[23:44:43] shevy: weird error indeed
[23:44:51] anth0ny_: yeah, I’m a bit clueless
[23:45:20] shevy: >= should mean "equal or higher than"
[23:45:29] shevy: if it would be ~= then I could understand the error perhaps
[23:45:34] shevy: do you have only one ruby version on your system?
[23:45:37] Yzguy: are you using rbenv or something
[23:46:17] Neobenedict_: has joined #ruby
[23:46:18] Yzguy: 2.3.1 is not the default ruby version for mac
[23:46:26] koooge: has joined #ruby
[23:47:39] ruby[bot]: -b JackiPo!*@*$#ruby-banned
[23:47:42] anth0ny_: Yzguy: I don’t believe I am using rbenv
[23:47:48] anth0ny_: is there any easy way to check?
[23:47:50] LoneHerm_: has joined #ruby
[23:47:55] anth0ny_: shevy: I believe I only have one version
[23:48:20] xlegoman: has joined #ruby
[23:48:46] Yzguy: type "which ruby"
[23:49:17] shevy: I assume that bundler probably has found another ruby
[23:49:25] anth0ny_: “/usr/local/bin/ruby"
[23:49:39] anth0ny_: is there a way to see what the bundler would find?
[23:49:55] Yzguy: /usr/bin/ruby --version is where the system ruby is
[23:49:58] shevy: why bundler does not show the version and location of the ruby it found, beats me though
[23:50:04] Yzguy: did you install another version of ruby with brew or something
[23:50:11] mistermo_: has joined #ruby
[23:50:14] anth0ny_: Yzguy: ah, there IS another version
[23:50:27] Yzguy: I think it's finding the system ruby for some reason
[23:50:29] anth0ny_: i installed ruby with brew. not sure how the 2.0.0 version stayed present
[23:50:43] Yzguy: well the 2.0.0 version is important for Mac stuff
[23:50:52] anth0ny_: oh, i didn’t know that it was included by default
[23:50:54] Yzguy: brew will install stuff into /usr/local/bin
[23:51:34] anth0ny_: so what is the typical method to upgrade the system’s ruby? is that a bad idea? or can I point bundler to the brew’s version of ruby?
[23:51:44] Yzguy: type "which gem"
[23:51:53] Yzguy: don't upgrade the system ruby
[23:52:43] anth0ny_: which gem points to the brew version
[23:52:59] ICantCook: has joined #ruby
[23:53:17] anth0ny_: (/usr/local/bin/gem)
[23:53:38] Yzguy: was trying to make sure it was using that, which it is so
[23:54:27] karapetyan: has joined #ruby
[23:56:00] ghr: has joined #ruby
[23:56:04] Yzguy: vagrant comes with a packaged ruby i believe
[23:56:46] Yzguy: ~/.vagrant.d/gems/ruby
[23:57:08] anth0ny_: so that’s likely the one that needs to be upgraded
[23:57:10] Yzguy: so it's prolly an issue with that ruby
[23:57:19] Yzguy: might just need to upgrade vagrant
[23:57:42] shevy: so he then has 3 ruby versions? :-)
[23:58:20] Yzguy: I lied, the ruby is in /opt/vagrant/embedded/bin
[23:58:50] Yzguy: ruby 2.2.3p173 is my vagrant ruby version
[23:58:58] Yzguy: Vagrant 1.8.1
[23:59:34] Yzguy: would be cool if vagrant was rewritten in go or something
[23:59:39] Yzguy: to match all their other tools