duderonomy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bsdbandit-01 has joined #ruby
banisterfiend has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bsdbandit-01 has quit [Read error: Connection reset by peer]
orbyt_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bsdbandit-01 has joined #ruby
BenDover has joined #ruby
akem_ has joined #ruby
akem has quit [Ping timeout: 240 seconds]
duderonomy has joined #ruby
impermanence has quit [Quit: Connection closed]
al2o3-cr has joined #ruby
duderonomy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
TCZ has joined #ruby
banisterfiend has joined #ruby
dionysus69 has joined #ruby
bsdbandit-01 has quit [Read error: Connection reset by peer]
somazero has joined #ruby
dionysus69 has quit [Ping timeout: 246 seconds]
al2o3-cr has quit [Quit: WeeChat 2.9]
al2o3-cr has joined #ruby
bsdbandit-01 has joined #ruby
fandre1986 has quit [Quit: Connection closed]
adu has joined #ruby
bsdbandit-01 has quit [Read error: Connection reset by peer]
BenDover has quit [Remote host closed the connection]
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
banisterfiend has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
kristian_on_linu has quit [Remote host closed the connection]
Technodrome has joined #ruby
TCZ has quit [Quit: Kindergarten is elsewhere!]
Rudd0 has quit [Read error: Connection reset by peer]
fanta1 has joined #ruby
bier has joined #ruby
cow[moo] has joined #ruby
blackmesa has quit [Ping timeout: 256 seconds]
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
lucasb has joined #ruby
Technodrome has joined #ruby
bsdbandit-01 has joined #ruby
bsdbandit-01 has quit [Read error: Connection reset by peer]
blackmesa has joined #ruby
<ruurd>
@TheBrayn install rvm
<ruurd>
then add ruby3 to that
<ruurd>
Well, a docker image is a bit hamfisted way to just try out a ruby version isn't it
<ruurd>
On a more general node - I'm using rvm to separate ruby versions and gemset versions, I use jabba to be able to run multiple Java version, nvm to run multiple node versions and pyenv to run multiple python versions.
blackmesa has quit [Ping timeout: 260 seconds]
<ruurd>
All that is more than reason enough to not use a Windows machine in the first place.
bsdbandit-01 has joined #ruby
Emmanuel_Chanel has quit [Quit: Leaving]
vondruch has quit [Quit: vondruch]
vondruch has joined #ruby
braincrash has quit [Ping timeout: 246 seconds]
bsdbandit-01 has quit [Read error: Connection reset by peer]
bsdbandit-01 has joined #ruby
al2o3-cr has quit [Quit: WeeChat 2.9]
Emmanuel_Chanel has joined #ruby
Emmanuel_Chanel has quit [Remote host closed the connection]
al2o3-cr has joined #ruby
akem_ has quit [Quit: Leaving]
bsdbandit-01 has quit [Read error: Connection reset by peer]
<adam12>
TheBrayn: Out of curiosity, what OS are you running?
<TheBrayn>
Archlinux
<TheBrayn>
Do I have to add a git branch to RVM or is there an easier way?
Emmanuel_Chanel has joined #ruby
<adam12>
Were you already using RVM?
<TheBrayn>
yeah
bsdbandit-01 has joined #ruby
<adam12>
TheBrayn: You might need to get rvm from github master branch, because Ruby 3 preview 2 changed packaging mechanism and that broke some ruby managers.
<TheBrayn>
Thanks, I'll just try ruby-head and will see how that works out
SeepingN has joined #ruby
prion has joined #ruby
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<nakilon>
17:29:26 <ruurd> All that is more than reason enough to not use a Windows machine in the first place.
<nakilon>
WSL is already 4 years old technology
<ruurd>
why would you want to use WSL in heavens' name
<ruurd>
then either use macos or use ubuntu but stop wasting energy by heating the universe with unnecessary clock cycles.
<ruurd>
or another linux to your liking
<adam12>
:| I use WSL2 for a solid 8 hours a day. It's _fine_.
bsdbandit-01 has quit [Read error: Connection reset by peer]
aremaref has joined #ruby
baojg_ has joined #ruby
baojg has quit [Ping timeout: 264 seconds]
Technodrome has joined #ruby
<TheBrayn>
adam12: building the master branch with rvm worked
<TheBrayn>
well not directly but you know what I mean
<adam12>
TheBrayn: Cool. Hopefully the fix to RVM ships soon. ruby-build just got it a few days ago as well.
cloud69 has quit [Quit: Connection closed for inactivity]
Rudd0 has joined #ruby
ChmEarl has joined #ruby
blackmesa has joined #ruby
prion has quit [Ping timeout: 260 seconds]
somazero has quit [Remote host closed the connection]
somazero has joined #ruby
SeepingN has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
prion has joined #ruby
SeepingN has joined #ruby
tekk has quit [Ping timeout: 260 seconds]
TCZ has joined #ruby
<nakilon>
forcing yourself to struggle trying to use linux as a development machine is like an infection that you may catch and then hopefully recover
duderonomy has joined #ruby
akem has joined #ruby
aremaref has quit [Ping timeout: 246 seconds]
duderonomy has quit [Ping timeout: 260 seconds]
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Technodrome has joined #ruby
elcontrastador has joined #ruby
cuerbot has joined #ruby
BTRE has quit [Remote host closed the connection]
elcuervo has quit [Ping timeout: 240 seconds]
ellcs has joined #ruby
prion has quit [Ping timeout: 264 seconds]
orbyt_ has joined #ruby
somazero has quit [Quit: Leaving]
TCZ has quit [Quit: Wawel - Czujesz sie dobrze, czynisz dobrze]
bsdbandit-01 has joined #ruby
bsdbandit-01 has quit [Read error: Connection reset by peer]
orbyt_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
somazero has joined #ruby
cjohnson has joined #ruby
<cjohnson>
Riddle me this batman. puts matching_upstream \n puts matching_upstream['local_bind_port'] gives me the following output
<cjohnson>
test.rb:29:in `[]': no implicit conversion of String into Integer (TypeError)
<cjohnson>
The first line is the output from the first puts, the second line is the error caused by the second puts
<adam12>
cjohnson: puts matching_upstream.class
yobro has joined #ruby
<yobro>
hi !
<adam12>
yobro: ohai
<yobro>
i like ruby because of msf.
bambanx has joined #ruby
<yobro>
hi adam12.
<cjohnson>
adam12: Array (wut)
<yobro>
adam12 are you a dev?
<cjohnson>
Ok, so I see my problem. I thought Array.select would return the first matching result. Is there a form that will return the first matching result instead of an array of matching results?
<adam12>
cjohnson: What did the Array say to the Hash? Quack.
<adam12>
cjohnson: Enumerable#first
<al2o3-cr>
cjohnson: detect/find
<cjohnson>
It's confusing that puts matching_upstream gives me output that doesn't include [ ]
<cjohnson>
But thanks for helping me spot the funkiness
<adam12>
err. Yeah. Enumerable#find
<cjohnson>
Thanks
<adam12>
cjohnson: Use `p` not `puts` for debugging since it calls #inspect.
<yobro>
adam12 why are you opped ?
<cjohnson>
adam12: ho ho, thanks for the tip
<cjohnson>
yobro: to make you ask questions
<yobro>
why?
<cjohnson>
Because it's entertaining to the rest of us
SeepingN has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bsdbandit-01 has joined #ruby
jinie has quit [Ping timeout: 246 seconds]
<apotheon>
havenwood: Have you tried opening irb and just entering ${} on the first line?
<havenwood>
apotheon: Not until you suggested. What am I supposed to see?
bsdbandit-01 has quit [Read error: Connection reset by peer]
prion has joined #ruby
<apotheon>
I'm not sure why it's behaving that way.
<havenwood>
apotheon: What's it doing? Indenting?
<apotheon>
It's odd, and I haven't figured out what the parser thinks is happening.
<apotheon>
yep
<apotheon>
every time I hit Enter
<havenwood>
apotheon: Thinks it's a block?
<havenwood>
$!> `${' is not allowed as a global variable name
<apotheon>
I'd think it would think the block closed.
<apotheon>
Oh, weird.
<apotheon>
It behaved differently this time.
<apotheon>
I just got the same error you indicated. The first time I tried it, that's not what happened.
<apotheon>
I entered ${}
<apotheon>
it indented on the next line with no output.
<apotheon>
I hit Enter again, and it indented again.
<apotheon>
I hit Ctrl-C, it went back to "normal".
<apotheon>
Something must have been screwed up in irb the first time.
<apotheon>
Never mind. Glitch. I have no idea how to reproduce it, now.
<apotheon>
Oh, the second time I accidentally ran it in an SSH session to a different machine.
<apotheon>
. . . so on a 32b system I get the repeated indentation, and on a 64b system I get the same result as you.
zenspider has quit [Quit: ZNC 1.6.6+deb1ubuntu0.2 - http://znc.in]
<apotheon>
$ irb
<apotheon>
irb(main):002:1>
<apotheon>
irb(main):001:1> ${}
<apotheon>
irb(main):003:1>
<apotheon>
002:1 is indented two columns
<apotheon>
003:1 is indented four columns
zenspider has joined #ruby
<apotheon>
It repeats that increasing indentation behavior, until Ctrl-C, then it resets to 001:0.
<apotheon>
hmm
ellcs has quit [Ping timeout: 258 seconds]
<apotheon>
The behavior on the 64b system makes sense.
<apotheon>
(same OS on both)
Technodrome has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
fanta1 has quit [Quit: fanta1]
SeepingN has joined #ruby
siaw23 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
panorain has joined #ruby
tomaw has quit [Ping timeout: 606 seconds]
tomaw_ has joined #ruby
BSaboia has quit [Quit: This computer has gone to sleep]
tomaw_ is now known as tomaw
bsdbandit-01 has joined #ruby
<nakilon>
how do I split useful optional development_dependencies and those that are needed to run tests in the gem CI testing?
bsdbandit-01 has quit [Read error: Connection reset by peer]
<nakilon>
for example, I'd like to have an environment variable that enables ruby-prof but I don't need to install it during test run because it needs to compile native extensions so I need build utils then wait, etc.
baojg has quit [Remote host closed the connection]
<nakilon>
the easiest way that probably will work is 'spec.add_development_dependency "ruby-prof" unless ENV["CI"]' but maybe there is a cleaner way
baojg has joined #ruby
Rudd0 has quit [Ping timeout: 256 seconds]
siaw23 has joined #ruby
<adam12>
nakilon: Do you use bundler? could use a Gemfile for this.
<apotheon>
havenwood: Now I get the difference in behavior. I installed the same version on the 64b system as on the 32b system (Ruby 2.7.2), and now it does the indentation thing instead of giving an error about variables.
<apotheon>
I just don't know what's going on behind the scenes for that indentation.
jinie has joined #ruby
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
siaw23 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
cd has joined #ruby
<nakilon>
adam12 you mean remove "gemspec" from Gemfile?
<adam12>
nakilon: Nah. I mean keep it and add a group like `profile`, and put those dependencies there.
<nakilon>
ah, and then somehow install the specified group when developing?
<adam12>
nakilon: Yeah.
tempate has quit [Ping timeout: 258 seconds]
hiroaki has quit [Ping timeout: 272 seconds]
siaw23 has joined #ruby
SeepingN has quit [Read error: Connection reset by peer]
SeepingN has joined #ruby
bsdbandit-01 has joined #ruby
Technodrome has joined #ruby
bsdbandit-01 has quit [Read error: Connection reset by peer]
blackmesa has quit [Quit: WeeChat 3.0]
SeepingN has quit [Quit: The system is going down for reboot NOW!]
tempate has joined #ruby
tempate has joined #ruby
SeepingN has joined #ruby
prion has quit [Ping timeout: 272 seconds]
<havenwood>
apotheon: Yeah, hard to get insights on things that aren't valid syntax.
<havenwood>
apotheon: See: ruby -yydebug -e '${'
Rudd0 has joined #ruby
<havenwood>
apotheon: It doesn't compile, but that'll ^ show you the parse.y grammar rules it followed.
<havenwood>
apotheon: Then again, could be an IRB-specific oddity?
<havenwood>
apotheon: Error as expected in Pry
<apotheon>
It's interesting if there's an IRB-specific oddity that doesn't exist in older versions.
bsdbandit-01 has joined #ruby
<apotheon>
It looks to me, from the debug output, like there's an error because it recognizes the opening brace as significant syntax when the dollar sign significance is left hanging.
<havenwood>
apotheon: IRB has changed lately.
<havenwood>
Some nice new changes in 3.0. Faster paste, particularly.
<apotheon>
How big a change are we discussing?
<apotheon>
Was parsing altered?
<apotheon>
substantially, I mean
BSaboia has joined #ruby
bsdbandit-01 has quit [Read error: Connection reset by peer]
<havenwood>
yup
<havenwood>
and lots of new features, like syntax highlighting
<havenwood>
and reline
<panorain>
hmm
<panorain>
I have never been involved with "programming before" one thing has brought me to Ruby.
bsdbandit-01 has joined #ruby
bsdbandit-01 has quit [Read error: Connection reset by peer]
dfucci has quit [Ping timeout: 256 seconds]
TCZ has quit [Quit: Wawel - Czujesz sie dobrze, czynisz dobrze]
panorain has quit [Remote host closed the connection]
bsdbandit-01 has joined #ruby
panorain has joined #ruby
prion has joined #ruby
<adam12>
panorain: welcome?
bsdbandit-01 has quit [Read error: Connection reset by peer]
dionysus69 has quit [Ping timeout: 256 seconds]
<panorain>
Thank you asam12 ..... I ugh have been struggling a bit with computers. I decided I like openSUSE Tumbleweed. I want you to talk about the Ruby programming language.
dfucci has joined #ruby
<havenwood>
panorain: Have any Ruby questions? Or comments or code to share?
FastJack has quit [Ping timeout: 240 seconds]
FastJack has joined #ruby
dfucci has quit [Ping timeout: 260 seconds]
BSaboia has quit [Ping timeout: 260 seconds]
<panorain>
I would like to work more with "Gsmartcontrol".
ruby[bot] has quit [Remote host closed the connection]
ruby[bot] has joined #ruby
<panorain>
havenwood: I do not know Perl
baojg has quit [Remote host closed the connection]
Cork has quit [Ping timeout: 260 seconds]
baojg has joined #ruby
dfucci has joined #ruby
siaw23 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
prion has quit [Ping timeout: 256 seconds]
Rudd0 has quit [Remote host closed the connection]
bsdbandit-01 has joined #ruby
adu has quit [Quit: adu]
bsdbandit-01 has quit [Ping timeout: 260 seconds]
<ian|>
i'm curious why '[1,2,3,4].map{|x|x+1}' works but '[1,2,3,4].map({|x|x+1})' doesn't
<CommunistWolf>
'[1,2,3,4].map(){|x|x+1}' does
<CommunistWolf>
the block syntax just isn't an argument to the function, in the way it would be in js (say)
<ian|>
ah so block parameters must be special, not just like 'lambdas' or w/e
<pabs>
ian|: the former is a block passed to map, and the latter is syntactically invalid, but it looks like it's supposed to be a proc passed as a parameter to map