havenwood changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 3.1.3, 3.0.5, 2.7.7, 3.2.0-rc1: https://www.ruby-lang.org | Paste 4+ lines to: https://gist.github.com | Books: https://goo.gl/wpGhoQ | Logs: https://libera.irclog.whitequark.org/ruby/
Rounin has quit [Ping timeout: 248 seconds]
markong has quit [Ping timeout: 256 seconds]
FullMetalStacker has joined #ruby
FullMetalStacker has quit [Client Quit]
caedmon has joined #ruby
caedmon has quit [Client Quit]
caedmon has joined #ruby
caedmon has quit [Client Quit]
caedmon has joined #ruby
crax23 has joined #ruby
Y05hito__ has quit [Ping timeout: 256 seconds]
caedmon has quit [Ping timeout: 268 seconds]
caedmon has joined #ruby
caedmon has quit [Client Quit]
Y05hito__ has joined #ruby
caedmon has joined #ruby
crax23 has quit [Ping timeout: 265 seconds]
caedmon has quit [Ping timeout: 268 seconds]
caedmon has joined #ruby
caedmon has quit [Quit: caedmon]
caedmon has joined #ruby
barbaneigro has joined #ruby
barbaneigro has quit [Remote host closed the connection]
caedmon has quit [Ping timeout: 260 seconds]
moldorcoder7 has quit [Ping timeout: 268 seconds]
Sankalp has quit [Ping timeout: 252 seconds]
Sankalp has joined #ruby
barbaneigro has joined #ruby
barbaneigro has quit [Remote host closed the connection]
barbaneigro has joined #ruby
Sankalp has quit [Ping timeout: 264 seconds]
barbaneigro has quit [Remote host closed the connection]
barbaneigro has joined #ruby
pandabot has quit [Quit: HE IS FRIENDLY TO ME]
Sankalp has joined #ruby
pandabot has joined #ruby
sagax has joined #ruby
Cata[m]1 has joined #ruby
finsternis has quit [Read error: Connection reset by peer]
ur5us has quit [Ping timeout: 252 seconds]
crax23 has joined #ruby
Y05hito__ has quit [Ping timeout: 256 seconds]
ssh0732 has quit [Remote host closed the connection]
ssh0732 has joined #ruby
otisolsen70 has joined #ruby
otisolsen70 has quit [Remote host closed the connection]
otisolsen70 has joined #ruby
Linux_Kerio has joined #ruby
Y05hito__ has joined #ruby
crax23 has quit [Ping timeout: 256 seconds]
crax23 has joined #ruby
Y05hito__ has quit [Ping timeout: 256 seconds]
Sankalp has quit [Ping timeout: 265 seconds]
teclator has joined #ruby
Sankalp has joined #ruby
crax23 has quit [Ping timeout: 255 seconds]
cartdrige has joined #ruby
FullMetalStacker has joined #ruby
FullMetalStacker has quit [Client Quit]
ur5us has joined #ruby
heartburn has quit [Ping timeout: 255 seconds]
heartburn has joined #ruby
Rounin has joined #ruby
Rounin has quit [Changing host]
Rounin has joined #ruby
Aminda has quit [Remote host closed the connection]
Aminda has joined #ruby
ssh0732 has quit [Quit: Ping timeout (120 seconds)]
Linux_Kerio has quit [Ping timeout: 256 seconds]
crax23 has joined #ruby
cartdrige has quit [Ping timeout: 260 seconds]
ur5us has quit [Ping timeout: 255 seconds]
reset has joined #ruby
jvalleroy has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
jvalleroy has joined #ruby
dionysus69 has joined #ruby
dionysus70 has joined #ruby
dionysus69 has quit [Ping timeout: 260 seconds]
dionysus70 is now known as dionysus69
nemesit has joined #ruby
TomyWork has joined #ruby
Aminda has quit [Read error: Connection reset by peer]
Aminda has joined #ruby
markong has joined #ruby
cognemo has joined #ruby
crax23 has quit [Remote host closed the connection]
crax23 has joined #ruby
tomtmym has joined #ruby
Y05hito__ has joined #ruby
crax23 has quit [Remote host closed the connection]
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #ruby
moldorcoder7 has joined #ruby
<isene> ox1eef_: OK, I'm trying to figure this stuff out. Firstly, I've included the gemspec in the xrpn gem. I have renameg all the files under lib to have the .rb extension. Now, how do I make it so that all the files under lib (and cmd - where I should not rename files to have the .rb extension) are required/read in when I add the `require 'xrpn'` in the main xrpn executable. And please do treat me as a
<isene> baby in this regard.
<isene> adam12: ^^^
Y05hito__ has quit [Ping timeout: 260 seconds]
<adam12> isene: Are you doing this in a branch on GitHub?
<isene> Hmm... no. You can see the files on Github, and the gem is pushed... (with the gemspec included)
<adam12> isene: I'd probably recommend doing all your work in a branch on github. That will save anybody trying to help you from having to fetch and unpack your newest gem release.
<adam12> isene: I see mostly same issues as I mentioned earlier. `lib` is shared by default among gems, so everything you stick in `lib` will run risk of clobbering something else. `optparse` immediately is conflicting.
<adam12> isene: If you want to keep stuff as-is for the most part, don't use lib. Use something else (libdata, libexec, libextra, ??, name doens't matter).
<adam12> Then, inside lib, the only file you'll have is `xrpn.rb`. That will do a walk of `__dir__ + "/../libwhatever"` and then load each file. But you have to do it after your extra requires, because they need some bits (like tty-prompt).
<adam12> So you can't require 'xrpn' first. It would have to be last.
<adam12> You can also rename `lib` inside your gemspec but that might make things even more confusing. https://guides.rubygems.org/specification-reference/#require_paths=
cartdrige has joined #ruby
Linux_Kerio has joined #ruby
_aeris_ is now known as aeris
<ox1eef_> Everything adam12 said, plus you will still need to add your own XRPN.load method when you want to reload your gem. I pasted a sample implementation earlier (as XRPN.require).
<ox1eef_> I would recommend you create lib/xprn, lib/xrpn/cmd, and follow what's generally standard for gems. The conflict issue is real, so you definitely want lib/xprn/optparse, and not lib/optparse.
<ox1eef_> If you want other Ruby programmers to feel at home, and make contributions I'd also recommend two space indentation. That's pretty much the standard in Ruby.
<ox1eef_> Technically, you could avoid the conflict issue with require_relative but I don't generally recommend that. It is better to create lib/xrpn as a namespaced directory.
joto has quit [Ping timeout: 256 seconds]
willfish has joined #ruby
dionysus69 has quit [Ping timeout: 248 seconds]
caedmon has joined #ruby
willfish has quit [Ping timeout: 260 seconds]
barbaneigro has quit [Ping timeout: 265 seconds]
markong has quit [Remote host closed the connection]
brw has quit [Remote host closed the connection]
cartdrige has quit [Ping timeout: 256 seconds]
TomyWork has quit [Remote host closed the connection]
<adam12> Docker Hub not being able to auto-build for aarch64 is kind of crazy considering how popular the arch is.
gonix has joined #ruby
gonix has quit [Ping timeout: 256 seconds]
<adam12> havenwood: when you were looking at adding pre-built binaries to ruby-install, do you remember where you were sourcing them from?
<adam12> With the openssl 1/3 debacle right now, I wonder if it's even possible to offer pre-built binaries of Ruby.
joto has joined #ruby
neshpion has joined #ruby
caedmon has quit [Ping timeout: 268 seconds]
pvalenta has quit [Quit: ZNC - https://znc.in]
pvalenta has joined #ruby
dionysus69 has joined #ruby
pvalenta has quit [Quit: ZNC - https://znc.in]
pvalenta has joined #ruby
cartdrige has joined #ruby
_ht has joined #ruby
seydar has joined #ruby
<seydar> "y" < "y".succ # => true
<seydar> "z" < "z".succ # => false
<seydar> this feels... wrong
axisys has joined #ruby
<neshpion> because "z".succ == "aa", which has a string comparison greater than "z", since it's two characters long
<neshpion> but i guess sort(1) disagrees with that ordering :/
<axisys> how to improve this so I don't repeat get_test_account(airport_code)
<axisys> prod_accounts[airport_code] = get_test_account(airport_code) unless get_test_account(airport_code).nil?
<neshpion> test_account = get_test_account(airport_code); prod_accounts[airport_code] = test_account unless test_account.nil?
caedmon has joined #ruby
<seydar> neshpion: ... should I file a bug report?
<seydar> this is a harder bug to fix since it'll break, like, a million things
<seydar> (i'm sure there's something out there depending on this behavior'
<neshpion> seydar: i don't think that will be regarded as a bug
<neshpion> there's more than one philosophy about how things should be ordered and this is probably just one of them
<seydar> yeah you're prolly right
seydar has quit [Quit: leaving]
<ox1eef_> prod_accounts[airport_code] ||= get_test_account(airport_code) might work as well, it depends whether or not you care if there's a key with nil as a value.
<neshpion> looks like the concern is wanting to avoid nil values, since the original implementation would prevent even setting the key
<ox1eef_> Yeah, very well may be the case.
Guest6359 is now known as gr33n7007h
agent_white has joined #ruby
cahoots has joined #ruby
<cahoots> hi, is it possible to mutate a number inplace? e.g., something like a = 1 ; a.inc! # a is now 2
<havenwood> adam12: I was just using the RVM ones. We stopped building those for a while due to the OpenSSL 1/3 debacle. I'm having trouble remembering the exact issue now, but betcha RVM will resume shipping those when Debian/Ubuntu are fully OpenSSL3 with updated Rubies.
<havenwood> adam12: I had it working fine, but the PR is extremely out of date and would need binary versions in ruby-versions repo now that they've been extracted.
<havenwood> adam12: As a fix in the interim, postmodern has ruby-install using OpenSSL 1 in some cases IIR.
<havenwood> You might need an update of ruby-install itself to get that patch, since it won't get applied with `ruby-install --update` definitions fetch.
<havenwood> cahoots: Nope.
ur5us has joined #ruby
<leah2> use an array :^)
cahoots_ has joined #ruby
<cahoots_> havenwood, ty. leah2, good idea
cahoots has quit [Ping timeout: 260 seconds]
Linux_Kerio has quit [Ping timeout: 268 seconds]
joto has quit [Ping timeout: 260 seconds]
<adam12> havenwood: I switched to ruby-build for this specific instance.
<adam12> havenwood: I've humoured the idea of building ruby for various archs myself, but I am not sure I have the bandwidth.
Mikaela has joined #ruby
neshpion has quit [Ping timeout: 255 seconds]
otisolsen70 has quit [Quit: Leaving]
Aminda has quit [Remote host closed the connection]
neshpion has joined #ruby
dionysus69 has quit [Ping timeout: 268 seconds]
neshpion has quit [Remote host closed the connection]
neshpion has joined #ruby
Mikaela has quit [Remote host closed the connection]
cahoots_ has quit [Ping timeout: 260 seconds]
Mikaela has joined #ruby
cahoots has joined #ruby
FullMetalStacker has joined #ruby
FullMetalStacker has quit [Client Quit]
crax23 has joined #ruby
cartdrige has quit [Ping timeout: 256 seconds]
crax23 has quit [Remote host closed the connection]
crax23 has joined #ruby
crax23 has quit [Ping timeout: 256 seconds]
aeris has quit [Remote host closed the connection]
aeris has joined #ruby
cahoots has quit [Ping timeout: 256 seconds]
cahoots has joined #ruby
neshpion_ has joined #ruby
neshpion has quit [Remote host closed the connection]
neshpion_ has quit [Remote host closed the connection]
neshpion has joined #ruby
agent_white has quit [Remote host closed the connection]
tomtmym has quit [Quit: Gone.]
_ht has quit [Quit: _ht]
caedmon has quit [Ping timeout: 256 seconds]
teclator has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
cartdrige has joined #ruby
moldorcoder7 has quit [Ping timeout: 248 seconds]
moldorcoder7 has joined #ruby
cartdrige has quit [Ping timeout: 255 seconds]
neshpion has quit [Quit: neshpion]
cartdrige has joined #ruby
work has joined #ruby
_aeris_ has joined #ruby
aeris has quit [Remote host closed the connection]
_aeris_ is now known as aeris
ruby[bot] has quit [Remote host closed the connection]
ruby[bot] has joined #ruby
cartdrige has quit [Ping timeout: 248 seconds]
CalimeroTeknik has quit [Ping timeout: 260 seconds]
CalimeroTeknik has joined #ruby