karapetyan has quit [Remote host closed the connection]
redlegion has quit [Remote host closed the connection]
redlegion has joined #ruby
bruce_lee has quit [Remote host closed the connection]
k0mpa has joined #ruby
rivalome_ has quit []
z3uS has quit [Quit: /dev/null]
<al2o3-cr>
cthu|: puts "\x1b[38;2;219;112;114mSALMON\x1b[0m" rgb if your terminal supports it.
<cthu|>
hm
<cthu|>
it does
<cthu|>
weird
<cthu|>
why do they keep using this weird awkward old thing with 16 colors?
<al2o3-cr>
who?
<cthu|>
all these manuals about how to do PS1
<cthu|>
colored
<cthu|>
I guess some terminals don't support it
<cthu|>
mkay
z3uS has joined #ruby
cagomez has quit [Remote host closed the connection]
cagomez has joined #ruby
jabowa has joined #ruby
vyorkin has joined #ruby
clemens3_ has quit [Ping timeout: 240 seconds]
vyorkin has quit [Client Quit]
<elomatreb>
There are different standards for terminal colors, the oldest one defined the 16 colors, a next one defined a set of 256 colors, and there is a standard for "true" 24-bit RGB, but support decreases as you go up
<elomatreb>
Some terminals also fake support
cagomez has quit [Ping timeout: 264 seconds]
knight33 has quit [Ping timeout: 264 seconds]
<jabowa>
Hey, new to ruby. Is it possible to see assign gems when importing? Example: custom_gem = require "custom_gem"
<havenwood>
jabowa: No, there isn't anything like that.
<elomatreb>
Not really, there is no true namespacing in Ruby
<havenwood>
I think we'll see some namespace-related additions in the next few years.
bijan_ has quit [Ping timeout: 276 seconds]
<elomatreb>
Any gem can modify any other class when it's required, the only thing that prevents this are conventions to not touch other peoples code unless you make it explicit
* havenwood
peers into the mysterious future...
maiz has joined #ruby
jhack has quit [Quit: jhack]
<jabowa>
Oh okay. How about, is it possible to log all the "namespaces" from the required gems in a file?
t0xik has quit [Quit: Connection closed for inactivity]
pebble has quit [Remote host closed the connection]
orbyt_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
pebble has joined #ruby
pebble has quit [Remote host closed the connection]
jabowa has joined #ruby
bijan_ has quit [Ping timeout: 276 seconds]
white_lilies has quit [Ping timeout: 240 seconds]
<jabowa>
Hey, have a basic question - new to ruby. I came across a common code pattern a lot - func :symbol do {...}. How do you trigger the do block statement? https://repl.it/repls/ExtralargeSanePaint
Axy has joined #ruby
<elomatreb>
jabowa: You execute a block with the `yield` statement
Mia has quit [Ping timeout: 265 seconds]
jottr_ has joined #ruby
<elomatreb>
It doesn't have anything to do with the symbol in the method though, that's just an parameter to the method
bijan_ has joined #ruby
chouhoulis has quit [Remote host closed the connection]
k0mpa has quit [Remote host closed the connection]
chouhoulis has joined #ruby
<jabowa>
elomatreb: Thanks that makes sens
jottr_ has quit [Ping timeout: 256 seconds]
bijan_ has quit [Ping timeout: 255 seconds]
chouhoulis has quit [Ping timeout: 240 seconds]
konsolebox has quit [Ping timeout: 268 seconds]
starseed0000 has quit [Ping timeout: 265 seconds]
pebble2014 has joined #ruby
konsolebox has joined #ruby
bijan_ has joined #ruby
z3uS has quit [Quit: /dev/null]
jabowa has quit [Ping timeout: 260 seconds]
tvw has joined #ruby
taylorzr has quit [Ping timeout: 260 seconds]
_seanc_ has quit [Quit: _seanc_]
taylorzr has joined #ruby
z3uS has joined #ruby
bijan_ has quit [Ping timeout: 260 seconds]
bijan_ has joined #ruby
JamJam_kid has quit [Ping timeout: 265 seconds]
bijan_ has quit [Ping timeout: 256 seconds]
donofrio has quit [Remote host closed the connection]
ciscam has quit [Ping timeout: 240 seconds]
ciscam has joined #ruby
bijan_ has joined #ruby
karapetyan has joined #ruby
NightMonkey has quit [Ping timeout: 265 seconds]
JamJam_kid has joined #ruby
karapetyan has quit [Ping timeout: 240 seconds]
bijan_ has quit [Ping timeout: 245 seconds]
jamesaxl has quit [Quit: WeeChat 2.1]
NightMonkey has joined #ruby
JamJam_kid has quit [Read error: Connection reset by peer]
JamJam_kid has joined #ruby
BloopMonster has quit [Read error: Connection reset by peer]
BloopMonster has joined #ruby
bijan_ has joined #ruby
dreamthese has quit [Ping timeout: 276 seconds]
dreamthese has joined #ruby
bijan_ has quit [Ping timeout: 256 seconds]
bijan_ has joined #ruby
Axy has quit [Ping timeout: 256 seconds]
JamJam_kid has quit [Ping timeout: 256 seconds]
bijan_ has quit [Ping timeout: 256 seconds]
cadillac_ has quit [Read error: Connection reset by peer]
bijan_ has joined #ruby
cadillac_ has joined #ruby
shakes has quit [Quit: Leaving]
bijan_ has quit [Ping timeout: 245 seconds]
bijan_ has joined #ruby
Mia has joined #ruby
fluxAeon_ has quit [Ping timeout: 264 seconds]
ur5us has quit [Remote host closed the connection]
cadillac_ has quit [Read error: Connection reset by peer]
bijan_ has quit [Ping timeout: 245 seconds]
RougeR has quit [Ping timeout: 240 seconds]
roamingdog has quit [Remote host closed the connection]
bijan_ has joined #ruby
fluxAeon has joined #ruby
roamingdog has joined #ruby
segy has quit [Ping timeout: 256 seconds]
segy has joined #ruby
cadillac_ has joined #ruby
roamingdog has quit [Ping timeout: 240 seconds]
kryptoz has quit [Remote host closed the connection]
Guest74533_ has quit []
Guest74533_ has joined #ruby
kryptoz has joined #ruby
Guest74533_ has quit [Changing host]
Guest74533_ has joined #ruby
Guest74533_ has joined #ruby
aufi has joined #ruby
Guest74533_ is now known as braderhart
taylorzr has quit [Ping timeout: 264 seconds]
sauvin has joined #ruby
dviola has quit [Quit: WeeChat 2.1]
Guest93864 has quit [Remote host closed the connection]
aufi has quit [Ping timeout: 268 seconds]
anisha_ has joined #ruby
aupadhye has joined #ruby
kryptoz has quit [Remote host closed the connection]
apeiros has joined #ruby
kryptoz has joined #ruby
jottr_ has joined #ruby
segy has quit [Ping timeout: 245 seconds]
segy has joined #ruby
jottr_ has quit [Ping timeout: 256 seconds]
mike11 has joined #ruby
Inline has quit [Quit: Leaving]
conta has joined #ruby
agent_wh1te has quit [Quit: gnight]
pebble2014 has quit [Read error: Connection reset by peer]
pebble2014 has joined #ruby
pebble2014 has quit [Remote host closed the connection]
DoYouKnow has joined #ruby
biberu has joined #ruby
nima_m has joined #ruby
segy has quit [Ping timeout: 276 seconds]
roamingdog has joined #ruby
roamingdog has quit [Ping timeout: 264 seconds]
segy has joined #ruby
nima_m_ has joined #ruby
nima_m has quit [Ping timeout: 255 seconds]
nima_m_ is now known as nima_m
c0ncealed2 has quit [Remote host closed the connection]
c0ncealed2 has joined #ruby
za1b1tsu has joined #ruby
conta has quit [Quit: conta]
reber has joined #ruby
tdy has quit [Ping timeout: 264 seconds]
dionysus69 has joined #ruby
andikr has joined #ruby
bijan_ has quit [Remote host closed the connection]
suukim has joined #ruby
BloopMonster has quit [Ping timeout: 255 seconds]
zautomata1 has joined #ruby
pebble2015 has joined #ruby
zautomata has quit [Ping timeout: 265 seconds]
pebble2014 has joined #ruby
\void has quit [Quit: So long, and thanks for all the fish.]
cadillac_ has quit [Ping timeout: 240 seconds]
tdy has joined #ruby
bijan_ has joined #ruby
sysvalve has joined #ruby
pebble2016 has joined #ruby
bijan_ has quit [Ping timeout: 276 seconds]
TomyWork has joined #ruby
claudiuinberlin has joined #ruby
bijan_ has joined #ruby
clemens3_ has joined #ruby
nima_m has quit [Ping timeout: 240 seconds]
yohji has joined #ruby
MasukaV has joined #ruby
bijan_ has quit [Ping timeout: 260 seconds]
bijan_ has joined #ruby
mike11 has quit [Quit: Leaving.]
karapetyan has joined #ruby
SeepingN has quit [Quit: The system is going down for reboot NOW!]
kut20126 has quit [Remote host closed the connection]
pebble2014 has quit [Remote host closed the connection]
pebble2015 has quit [Remote host closed the connection]
<apeiros>
?crosspost MasukaV
<ruby[bot]>
MasukaV: Please do not crosspost without at least telling so and mentioning provided suggestions and their outcome in all channels. Experience shows that people don't do either, and not doing so is considered rude.
bijan_ has joined #ruby
nowhere_man has quit [Ping timeout: 256 seconds]
<MasukaV>
I can see where that would be relevant if any response had been received at all.
<apeiros>
poor excuse.
<MasukaV>
apeiros, do you have any helpful information?
<apeiros>
not in the mood to spend time trying to help a crossposter.
<MasukaV>
Ahh, now I have a label. All right, carry on with your power trip. I bet you twitch everytime you see you get to call the bot on someone. LOL
<apeiros>
!kick MasukaV adjust that attitude, will you?
MasukaV was kicked from #ruby by ruby[bot] [adjust that attitude, will you?]
bijan_ has quit [Ping timeout: 256 seconds]
aufi has joined #ruby
aufi has quit [Remote host closed the connection]
aufi has joined #ruby
anisha_ has quit [Read error: Connection reset by peer]
Burgestrand has joined #ruby
aufi_ has joined #ruby
anisha_ has joined #ruby
* dminuoso
.oO( is crossposting really that bad? )
<apeiros>
almost always crossposters are inconsiderate of other people's time. witnessed it often enough. I wouldn't kick or ban for it, though.
bijan_ has joined #ruby
aufi has quit [Ping timeout: 276 seconds]
MasukaV has joined #ruby
bijan_ has quit [Ping timeout: 245 seconds]
jottr_ has joined #ruby
maiz has joined #ruby
dionysus69 has quit [Ping timeout: 256 seconds]
jottr_ has quit [Ping timeout: 276 seconds]
bijan_ has joined #ruby
maiz has quit [Ping timeout: 240 seconds]
mjolnird has quit [Ping timeout: 240 seconds]
bijan_ has quit [Ping timeout: 276 seconds]
t0xik has quit [Quit: Connection closed for inactivity]
bijan_ has joined #ruby
tty has quit [Quit: tty]
NL3limin4t0r has quit [Quit: WeeChat 1.9.1]
mjolnird has joined #ruby
bijan_ has quit [Ping timeout: 245 seconds]
mikecmpbll has joined #ruby
amar_ has joined #ruby
schleppel has joined #ruby
bijan_ has joined #ruby
loveablelobster has joined #ruby
discopatrick has joined #ruby
bijan_ has quit [Ping timeout: 256 seconds]
amar_ has quit [Ping timeout: 276 seconds]
bijan_ has joined #ruby
DTZUZU has joined #ruby
DTZUZO has joined #ruby
bijan_ has quit [Ping timeout: 256 seconds]
dionysus69 has joined #ruby
DTZUZU has quit [Ping timeout: 240 seconds]
kent\n has quit [Ping timeout: 276 seconds]
DTZUZO has quit [Ping timeout: 260 seconds]
ur5us has joined #ruby
bijan_ has joined #ruby
bijan_ has quit [Ping timeout: 245 seconds]
maiz has joined #ruby
claudiuinberlin has quit [Ping timeout: 240 seconds]
BloopMonster has joined #ruby
fribmendes has quit [Quit: huh... i guess my bouncer crashed...]
fribmendes has joined #ruby
fribmendes is now known as Guest69107
ren0v0 has quit [Disconnected by services]
ren0v0_ has joined #ruby
bijan_ has joined #ruby
Guest63073 has quit [Read error: Connection reset by peer]
arne has joined #ruby
bijan_ has quit [Ping timeout: 245 seconds]
ellcs has joined #ruby
DTZUZU has joined #ruby
jottr_ has joined #ruby
jamesaxl has joined #ruby
Nicmavr has joined #ruby
Nicmavr is now known as Guest57744
maiz has quit [Quit: WeeChat 2.0.1]
amar_ has joined #ruby
DTZUZO has joined #ruby
jottr_ has quit [Ping timeout: 256 seconds]
bijan_ has joined #ruby
amar_ has quit [Ping timeout: 240 seconds]
Beams has joined #ruby
bijan_ has quit [Ping timeout: 256 seconds]
suukim has quit [Ping timeout: 256 seconds]
mikecmpb_ has joined #ruby
mikecmpbll has quit [Ping timeout: 240 seconds]
conta has joined #ruby
bijan_ has joined #ruby
<arne>
how do you guys endless chaining of modules?
<arne>
i mean if you want to use A::B::C you need to have A and B already
<arne>
do you do module A;end;require 'something_that_is_inside_A'
bijan_ has quit [Ping timeout: 265 seconds]
guille-moe has joined #ruby
<apeiros>
requires always on top. and yes, a.rb contains the requires to all a/*.rb's, a/b.rb contains all requires to a/b/*.rb etc.
<dminuoso>
arne: The ruby "idiomatic" way (whatever thats good for) is to manually eval everything in the right order so that everything is avaiulable.
<apeiros>
(and a/b/c.rb of course contains A::B::C)
<apeiros>
though I newer projects I tend to just have a single require in every file for the toplevel file and use autoload on each level.
<apeiros>
beware, though, matz doesn't like autoload.
<dminuoso>
arne: I'm looking into techniques to avoid nesting at all.
<dminuoso>
The problem is the mixing of namespace concepts with runtime behavior of objects.
<dminuoso>
It would be cool if we had namespaces that were part of a build process (and erased at runtime)
<dminuoso>
autoloading fakes this, but the problem is that its brittle, makes it unclear when what code is being executed and when
alem0lars has joined #ruby
<arne>
hm
<arne>
but i like namespaces
<dminuoso>
arne: The problem is that Ruby has no real namespaces.
bijan_ has joined #ruby
<arne>
i know, but always if i get into a ruby tool, and i inspect it with pry, im happy if it uses namespaces
<arne>
avoiding them seems off
amelliaa has joined #ruby
<dminuoso>
arne: It would require some major rework on the Ruby VM and require additional tooling.
<dminuoso>
Ruby was never designed to write complex programs with.
<dminuoso>
rubygems
BloopMonster has quit [Ping timeout: 255 seconds]
<dminuoso>
bundler
<dminuoso>
When my library uses `Object::Magic` and another library uses `Object::Magic` you are essentially screwed when you want to use both.
<arne>
well, i use docker, idc
<dminuoso>
What does docker have to do with this?
<arne>
well, gems don't collide, as long as you don't use these 2 in ONE project
<dminuoso>
When you want to use `libthing` and `libstuff` at the same time, and they both "monkey patch" Object (creating top level constants is just monkey patching Object), you're screwed.
<dminuoso>
That's the thing. What if you do want to use both in one project.
<dminuoso>
Now you cant.
<dminuoso>
And gem authors have to carefull design their packages to not collide with, essentially, the entire rest of rubygems.
<dminuoso>
Without a unified infrastructure to even *know* what modules/constants other libraries define, it's a guessing game./
bijan_ has quit [Ping timeout: 256 seconds]
<arne>
well, how do you tackle that? i mean.. if you use a c funciton mamed "pow"
<arne>
you also have a problem
<dminuoso>
arne: In C you can control includes and linkage.
<dminuoso>
And there's techniques to wrap libraries
<dminuoso>
But yeah, its a problem in C too.
<dminuoso>
But its manageable there
<arne>
so your suggestion is not to use namespaces?
<dminuoso>
arne: I mean ideally you'd create some top level constant that is named according to your library. And *everything* has to live inside that.
<arne>
well, that also sucks, i did that in my biggest project
<arne>
and i hate it
<dminuoso>
It's the only way to have a reasonably high probability to avoid conflicts
<dminuoso>
What rails promotes is amazingly bad
<arne>
yah, naming things is fun
<dminuoso>
class User < ApplicationRecord; .. end
<arne>
well, luckily in this project im doing it either way
<dminuoso>
Now you can't use *any* gem anymore that defines Object::User
<tbuehlmann>
rails even generates a top level module for your application
bijan_ has joined #ruby
<dminuoso>
tbuehlmann: Oh yeah it does. And then it generates the boilerplate in `app/...` and *not* use it.
<tbuehlmann>
yup
<arne>
that rails does it that way, makes it worse for me
<arne>
i mean, i won't have to create that top level namespace thing in the final project, do i
<arne>
i mean if i don't expect anyone else to use that thing
segy has quit [Ping timeout: 260 seconds]
<dminuoso>
Ruby developers have the mentality of "writing less code", but it's a red herring. It's not import statements that costs time. It's designing your software.
<dminuoso>
Writing code is the fastest and least problematic part of the job.
suukim has joined #ruby
<dminuoso>
I've had to fight rails autoloading so many times, probably a fair 50 hours wasted.
<tbuehlmann>
including spring hours? :)
bijan_ has quit [Ping timeout: 256 seconds]
<dminuoso>
tbuehlmann: I have very quickly developed a habit to restart spring on basically any issue.
<dminuoso>
When I get frustrated enough it gets thrown out until I get annoyed by the slow speed of Ruby
<tbuehlmann>
I have a `export DISABLE_SPRING=1` in my .zshrc, so I'm not using spring at all even if a project has it in its Gemfile
<Cork>
do ruby when have a way to write additional conditions or is nested ifs the only way?
<dminuoso>
Cork: Boolean operators?
<Cork>
no
<dminuoso>
No?
segy has joined #ruby
<Cork>
something like case variable; when "something" and other_var == 2
<Cork>
k thx
<arne>
dminuoso: you really do rails :o?
<dminuoso>
arne: Trying very hard not to.
<dminuoso>
Really want to yesod instead. :(
<arne>
but you have to because of #{job}?
<dminuoso>
Yeah.
<arne>
dminuoso: Yesod also looks too strict for me
<arne>
but warp looks cool
<dminuoso>
arne: What do you mean too strict?
<dminuoso>
warp and yesod are different things..
<arne>
i know, but if you're a normal person you would use them together
<dminuoso>
When comparing with Ruby world, the yesod equivalent might be rails, whereas warp is the equivalent of rack
<arne>
just like i like rack, but i hate rails
<dminuoso>
Heh :)
<arne>
well, actually i don't like rack either.. also too limited
<arne>
wanna have streaming, lul, nope
<dminuoso>
arne: rack has a really cumbersome API
<arne>
is there http2 for ruby yet?
<dminuoso>
arne: Plug in elixir is a decent abstraction
<dminuoso>
It's kind of similar to WAI
<arne>
i don't wanna learn elixir
<dminuoso>
arne: Im just saying it's decent, not that you should use it :)
<dminuoso>
arne: Rack is so mindbending, weird and badly documented.
<dminuoso>
Anyone who claims differently has never had to learn Rack the hard way.
<arne>
i wished there was something good :(
<arne>
but nothing makes me happy
DTZUZU has quit [Ping timeout: 276 seconds]
bijan_ has joined #ruby
DTZUZO has quit [Ping timeout: 256 seconds]
<dminuoso>
arne: All our new APIs are written in servant.
<arne>
that gives ma terrible earwig
RougeR has joined #ruby
<dminuoso>
Well it's really cool to have some interface module with the API specification, and then reuse the same types on clients and servers..
<dminuoso>
It's like swagger, except not shitty - and in the type system
bijan_ has quit [Ping timeout: 256 seconds]
<arne>
still not got warm with haskell
<arne>
feel like development takes too long if you.re not THE FP CRACK
<dminuoso>
arne: Well depending on your imperative background it takes a while to get used to. We are a lot more comfortable with it because it lets us write code much faster, that is much more stable with stronger guarantees.
<dminuoso>
And it's fast.
<dminuoso>
But in the end you didn't learn imperative programming in a week either.
crankharder has quit [Ping timeout: 256 seconds]
quiqua has joined #ruby
Burgestrand has quit [Quit: Closing time!]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
bijan_ has joined #ruby
<arne>
well, but if you fuckup in design, you won't be able to hack things in as easily
fcser__ has joined #ruby
<dminuoso>
arne: We find that Haskell makes designing software much easier.
<dminuoso>
Mostly because you can roughly sketch the program with just types.
<arne>
designing, yeah but if your type which you create can't handle something, and you have to rewrite it completely and all functions using it
<arne>
sure, it wont compile if you forgot something, which is great, but it feels like really time consumng
<dminuoso>
arne: Well you have that problem in any software. When your interface is wrong you have to rewrite code.
<dminuoso>
Not sure what your point is.
<arne>
in ruby you might be able to write a hack
<arne>
did that many times, never shoot my foot
<arne>
shotg
<arne>
shot*
<dminuoso>
We like robust software with provable properties.
<dminuoso>
12:03 arne | sure, it wont compile if you forgot something, which is great, but it feels like really time consumng
<dminuoso>
Thats the thing with Ruby. The fact that your code runs doesn't say much.
<arne>
yeah, everybody does that.. but a startup could die from not being able to quickly hack it
<arne>
don't you agree?
nima_m has joined #ruby
<dminuoso>
arne: Like I said, we find that Haskell lets us write software *faster* generally.
<arne>
well, i somehow doubt that, and even if, if you grow as a company, it will be harder to find employees
<dminuoso>
The type system doesnt constrain and slow you down, it saves you work in the long run because you are forced to fix issues as their arise, not as they get reported by consumers.
<canton7>
I find a lot depends on the depth of the program - how much of the application a single type is used in, how many types interact with each other. Beyond a certain depth, I really miss the guarantees of a good type system
<arne>
and ecosystem isn't as devfeloped as rubygems for example, that would slow me down af also
<dminuoso>
arne: Agreed, that is definitely an issue.
<dminuoso>
arne: What?
<canton7>
being able to say "find all the places where this is used" or "rename this" or "change the type of this, now tell me everywhere else I need to change" speeds you up a lot
<dminuoso>
arne: the rubygem ecosystem is garbage.
ha has joined #ruby
<dminuoso>
Shitty to not documented at all
<arne>
dminuoso: well, if i want to do something, ther eis always something
<dminuoso>
Tons of gems not maintained with nobody willing to fix them
<arne>
want to patch elf files? ruby has you covered
<dminuoso>
Extremely poor code quality
<arne>
want to write pdf? ruby has you covered
t0xik has joined #ruby
<dminuoso>
arne: Hackage has an elf parser. Hackage has several pdf libraries.
<dminuoso>
And they are well documented.
<dminuoso>
arne: The general quality of gems is really low.
DTZUZU has joined #ruby
<dminuoso>
There's some good gems, and sure overall there is more gems.
<dminuoso>
But so far I've not really felt like I was missing much in Haskell.
bijan_ has quit [Ping timeout: 265 seconds]
<arne>
what about apis, like aws/stripe similiar
<arne>
oh that exists, also
<arne>
man haskell folks ARE crazy.
DTZUZO has joined #ruby
workmad3 has quit [Ping timeout: 260 seconds]
dreamthese has quit [Remote host closed the connection]
dreamthese has joined #ruby
maiz has joined #ruby
maiz has quit [Max SendQ exceeded]
<dminuoso>
.0
apparition47 has joined #ruby
jottr_ has joined #ruby
kryptoz has quit [Remote host closed the connection]
kryptoz has joined #ruby
kryptoz has quit [Remote host closed the connection]
amelliaa has quit [Quit: -]
maufart__ has joined #ruby
aufi_ has quit [Ping timeout: 255 seconds]
Guest33711 has quit [Remote host closed the connection]
tpendragon has quit [Remote host closed the connection]
conta has quit [Quit: conta]
dr3w_ has joined #ruby
alem0lars has quit [Ping timeout: 264 seconds]
bijan_ has joined #ruby
ferr has quit [Quit: WeeChat 2.1]
ferr has joined #ruby
giraffe has joined #ruby
giraffe is now known as Guest34814
tpendragon has joined #ruby
sphenxes has joined #ruby
herbmillerjr has quit [Quit: Konversation terminated!]
<arne>
is there some geo-type to use for ruby?
guille-moe has quit [Ping timeout: 240 seconds]
loveablelobster has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
cyberg has joined #ruby
<lupine>
not in the stdlib
<lupine>
but consider class Cartesian ; attr_accessor :x, :y ; end
conta has joined #ruby
biberu has quit [Ping timeout: 265 seconds]
Burgestrand has joined #ruby
uso_ has joined #ruby
uso_ has left #ruby ["WeeChat 1.5"]
nowhere_man has joined #ruby
BloopMonster has joined #ruby
psychicist__ has joined #ruby
AJA4350 has joined #ruby
bijan_ has quit [Remote host closed the connection]
roamingdog has joined #ruby
biberu has joined #ruby
p4p0l0 has joined #ruby
roamingdog has quit [Ping timeout: 268 seconds]
<dminuoso>
arne: But it's also little and small things that are really amazing. It's fairly easy to achieve high concurrency without race conditions with STM.
zautomata1 has quit [Quit: WeeChat 1.9.1]
zautomata has joined #ruby
zautomata has quit [Changing host]
zautomata has joined #ruby
<dminuoso>
arne: Or green threads that make certain idioms really powerful. A server can be implemented as a simple handler that forkIOs *each* request. Haskell can run several million threads concurrently.
<arne>
i agree, but still, it sounds like hell before you'd be able to do that
<dminuoso>
Java ditched them because they didnt have a clean implementation
zautomata has left #ruby [#ruby]
* RougeR
is doing interviews today
<dminuoso>
arne: Dunno they feel ridiculously simple.
<arne>
RougeR: like on what side of the table?
<RougeR>
im being interviewed
<RougeR>
first dev job
<arne>
RougeR: uhhh good luck
<RougeR>
had one interview for a startup just...no ruby though
<arne>
dminuoso: everything seems simple when you grasped it
<dminuoso>
arne: I didn't have any trouble grasping STM.
<dminuoso>
It feems very natural.
<RougeR>
js/typescript/python totally full stack, 5 person team, london based
<RougeR>
finacial services SaaS
<dminuoso>
arne: Just consider how concurrency in databases is simple.
<dminuoso>
It's the same idea.
<RougeR>
next one is more interesting to me
<arne>
transactions are a lot of things
<arne>
but intuitive?
<dminuoso>
arne: To programmers they are.
<RougeR>
video broadcasting/social media SaaS, 30 person startup, ruby and python and js and even c++
<dminuoso>
Because it's ridiculously hard to reason about the state of your memory when multiple threads can ruin it.
Burgestrand has quit [Quit: Closing time!]
<dminuoso>
locks are a way of ensuring a consistent view of memory, but they are highly error prone and usually inefficient
ldnunes has joined #ruby
<dminuoso>
a transaction does the same thing but without the locks.
<dminuoso>
you stop thinking about synchronization
<dminuoso>
you start thinking in your domain logic
<dminuoso>
which is what a programmer wants anyway
<dminuoso>
It comes at a cost though, it costs extra memory for the house keeping - and implementations are tricky to write. But that's essentially a problem for the implementor.
<dminuoso>
With synchronization primitives it becomes a user problem
Burgestrand has joined #ruby
dionysus69 has quit [Remote host closed the connection]
dionysus69 has joined #ruby
conta has quit [Quit: conta]
bijan_ has joined #ruby
nowhere_man has quit [Remote host closed the connection]
nowhere_man has joined #ruby
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
<arne>
i agree, i know all that, still learning that is crazy, find masochist employees who do that impossible
conta has joined #ruby
bijan_ has quit [Ping timeout: 276 seconds]
guille-moe has joined #ruby
<arne>
god xpath syntax wo created that
<arne>
//a[b[c]] finds a a with a b as child with a c as child
<dminuoso>
arne: Wanna talk about lenses...? =)
ur5us has quit [Ping timeout: 240 seconds]
<arne>
dminuoso: i wish i could, but all i know about them, i learned from you
<dminuoso>
They are the universal solution to exactly what XPath tries to do.
<arne>
oh, now i see where you are going
<arne>
well as long as i can't search nokogiri with lenses, it doesnt help, really
<dminuoso>
arne: nokogiri supports css selectors.
<dminuoso>
in most cases they are sufficient, and they tend to be easier to write
<TheBrayn>
what's the difference between %i() and %I() for an array of symbols?
TinkerT has quit [Read error: Connection reset by peer]
kryptoz has joined #ruby
TinkerT has joined #ruby
Burgestrand has joined #ruby
bijan_ has quit [Ping timeout: 256 seconds]
karapetyan has joined #ruby
zapata has quit [Read error: Connection reset by peer]
dionysus69 has quit [Ping timeout: 256 seconds]
zapata has joined #ruby
kryptoz has quit [Remote host closed the connection]
jottr_ has quit [Ping timeout: 264 seconds]
<Bish>
dminuoso: trying to parse the very same json with haskell and im sad already
bijan_ has joined #ruby
p4p0l0 has quit [Remote host closed the connection]
<dminuoso>
Bish: Wat?
<Bish>
readFile gives me String, aeson wants Data.ByteString.Lazy.Internal.ByteString
<dminuoso>
Bish: Do you know what String is?
<Bish>
array of char
<dminuoso>
Dont use readFile then.
<dminuoso>
Bish: bytestring brings its own readFile
<dminuoso>
Not array.
<dminuoso>
A list.
<dminuoso>
use Data.ByteString.Lazy.readFile.
kryptoz has joined #ruby
<dminuoso>
Ive just completed writing about 2000 lines of JSON parsing and I must say it's quite a pleasant experience.
<dminuoso>
Using aeson.
<Bish>
and we're at monads and im lost again
Burgestrand has quit [Quit: Closing time!]
chouhoulis has joined #ruby
<Bish>
why do i need to distinquish between String and ByteString anyways
alem0lars has quit [Ping timeout: 245 seconds]
Burgestrand has joined #ruby
aupadhye has quit [Remote host closed the connection]
<dminuoso>
Bish: ByteString is a bit badly named. ByteVector or ByteArray might have been more appropriate.
ldnunes has joined #ruby
<dminuoso>
String is just [Char] which is an incredibly inefficient way to store textual data. Text is a packed unicode variant.
drale2k_ has joined #ruby
p4p0l0 has joined #ruby
pebble2019 has joined #ruby
p4p0l0 has quit [Remote host closed the connection]
<eising>
hey did the built-in OptionParser change somewhere between ruby 2.1 and 2.5?
<eising>
I'm finding some compatibility issues with older stuff
<dminuoso>
Bish: One thing that Haskell forces you is to acknowledge the difference between ByteString and Text/String very much. Ruby for example pretends everything is unicode.
shinnya has quit [Ping timeout: 265 seconds]
<dminuoso>
Part of the reason why developers frequently hop in this channel and complain about encoding issues is because they are never confronted with that problem.
<apeiros>
dminuoso: that's nonsense
<apeiros>
it could do better, but it certainly does not pretend everything was unicode.
<havenwood>
eising: it has changed, yeah - but not usually in breaking ways - what did work that now doesn't?
<dminuoso>
apeiros: It's completely transparent and you have to explicitly take control over it.
<dminuoso>
apeiros: Reading a file should always require an explicit encoding.
<apeiros>
that's just like… your opinion.
<eising>
havenwood: well, the code I'm looking at right now is 9 years old or more, and rather dead. Looks like it does a opts.parse!(ARGV) and that throws wrong number of arguments (given 3, expected 2) (ArgumentError)
* apeiros
works in a sane env and is happy not to have to redundantly specify utf-8 all over the place
<bhaak>
having a default is something else than "it just assumes unicode"
<apeiros>
dminuoso: also no amount of type will save you from developer ignorance about encodings.
<dminuoso>
bhaak: no it means *exactly that8
RougeR has quit [Ping timeout: 256 seconds]
<dminuoso>
Ruby by default assumes everything is UTF8 encoded.
<dminuoso>
Source code, external files.
<eising>
havenwood: I would guess that parse! takes a hash rather than an array now.
<apeiros>
dminuoso: yeah, no, those are not equivalents
<apeiros>
dminuoso: and you being the pedant you are know that full well :-p
<bhaak>
dminuoso: how come my Encoding.default_external looks like this => => #<Encoding:ISO-8859-1>
<bhaak>
<dminuoso>
bhaak: oh wait. is that the system locale? =)
<dminuoso>
this is even better.
<dminuoso>
Id say this promotes "well it runs on my machine"
Burgestrand has quit [Quit: Closing time!]
<apeiros>
I'd file that under things it could have done better. afaik defaults are now always utf-8.
<apeiros>
it's still not equivalent to pretending everything was utf-8.
<bhaak>
it depends from where the string is coming and possibly what environment you are running.
nowhere_man has quit [Ping timeout: 245 seconds]
<bhaak>
but the usual default is utf-8. because we aren't living in the 1990s anymore
synthroi_ has joined #ruby
synthroid has quit [Ping timeout: 240 seconds]
fluxAeon_ has joined #ruby
dminuoso has left #ruby ["WeeChat 2.0.1"]
jottr_ has joined #ruby
ha has quit [Quit: Leaving]
<Bish>
bhaak: this wasn't a ruby question :/
DoYouKnow has quit []
Burgestrand has joined #ruby
starseed0000 has quit [Ping timeout: 260 seconds]
<bhaak>
Bish: ah. well. it depends :-]
<rodd>
is there a way to avoid "repetition" in a hash where key/value are the same? i.e { email: email, username: username } -> { email, username }
jottr_ has quit [Ping timeout: 255 seconds]
roamingdog has joined #ruby
<bhaak>
Bish: a "String" is just a data type. different languages have different solutions on how to represent that. therefore you can't say what encoding a general String has, you have to put it in context
<Bish>
never understood that
<bhaak>
Bish: you know the difference between integers and floats and how they look at byte level?
<Bish>
sure
<Bish>
i also get the difference between encoding
<Bish>
s
<bhaak>
then why are they different? why not one byte representation to rule them all?
<bhaak>
the same with strings. different approaches have different use cases and different advantages and disadvantages
<bhaak>
Ruby chose to put an explicit encoding on a string. in Python, AFAIK, everything is converted to a Unicode representation.
<Bish>
^ that is so stupid
<bhaak>
with the latter, you don't have any issues with encoding as there is only one. but if you need to go latin-1 or shift-jis, you have to fall back to byte strings handling
<Bish>
everything should be utf8 if you ask me
<Bish>
why wouldn't it?
<bhaak>
what if you don't want to uft8? like when you need to output latin1?
za1b1tsu has joined #ruby
gizmore has joined #ruby
apeiros has quit []
Burgestrand has quit [Quit: Closing time!]
starseed0000 has joined #ruby
biberu has quit []
<havenwood>
bhaak: there's no such thing as latin1 if everything is utf8 ¯\_(ツ)_/¯
braincrash has quit [Ping timeout: 268 seconds]
<Bish>
bhaak: why wouldn't anyone want utf8? is there something you can't express with it?
<Bish>
havenwood: why do we need latin1?
<Bish>
for äüö?
<havenwood>
Bish: I don't find myself needing latin1. I'm not Roman though.
<bhaak>
havenwood: closing your eyes, putting your hands over your ears and going "lalala" is not a proper issue resolving strategy ;-)
delsol has joined #ruby
<havenwood>
bhaak: I'm just saying the normative claim that everything *should* be utf8 would mean the latin1 should be too
<delsol>
I can't seem to get ruby to execute certain command line scripts.
<havenwood>
delsol: How's it not working?
za1b1tsu has quit [Quit: WeeChat 2.1]
<Bish>
use uncertain command line scripts
<bhaak>
Bish: what about legacy systems? what about systems that don't use utf-8 but utf-16 (it's broken, but they do exist)? or even utf-32?
<Bish>
well f* them for not inventing utf8
<delsol>
ruby GUI app just basically refuses to do certain things, like sh /etc/rc.d/rc.vncservers restart
<bhaak>
havenwood: if we would live in an ideal world, yes. but we don't.
<Bish>
delsol: what does refuse mean
<havenwood>
bhaak: descriptivlely, that's true, but wasn't it a normative claim?
<delsol>
it doesn't work. No execution happens
<havenwood>
delsol: Does it hang?
<delsol>
same with bash scripts that include scp or ssh, etc
<delsol>
there is no execution of the other script.
<Bish>
sigh
<ccooke>
Bish: $? is the exit code of the last process executed
<bhaak>
havenwood: I don't believe in normative claims with programming languages. there are always advantages and disadvantages that need to be considered.
<Bish>
how do you invoke it, whats the value of $? after it
<Bish>
ccooke: tell him.
<delsol>
for example, when i backtic, or system the script that has scp and ssh, the other machine that it SCP's or SSH's to never increases a process ID.
<ccooke>
Bish: Ah, I see
<bhaak>
TheBrayn: I don't think we need to dig that up. nonet systems haven't aged well
<Bish>
delsol: yet, if system or %x() returns you willo have a exit status of ssh locally
shinnya has joined #ruby
<Bish>
and depending on the cmdline to ssh, ssh might want a terminal
braincrash has joined #ruby
<delsol>
Bish: the script basically SSH's and runs scripts on the other machine.
<delsol>
if I have ruby do EACH LINE separately... it works fine using system command
<Bish>
yeah and when the script wants a terminal, because ssh wants a terminal
<ccooke>
delsol: Does the script execute the ssh command, or a ruby SSH library?
<Bish>
ccooke: sounds like the first
<ccooke>
Bish: it does, just wanted to check.
<delsol>
system("ssh root@client /u/scripts/dosomeshit") works fine
<ccooke>
delsol: Right. So, after you run that command, you *absolutely will* have a return code of the ssh command, whether it worked or not.
<Bish>
well, a) don't do it b) it is because of stdin/stdout nonexistence
conta1 has quit [Quit: conta1]
<delsol>
but a single script that has multiple commands in it DOESNT work.
<delsol>
and doesn't SSH even a single time
<Bish>
well, what does the script do besides ssh then?
<delsol>
SCP over a file, and then SSH's 5 times.
<delsol>
thats it.
<Bish>
scp is ssh with benefits
<ccooke>
delsol: when you say "a single scipt that has multiple commands", what do you mean? Is that a long ssh line with multiple commands or an ssh command that runs a multi-line file
<Bish>
it might want stdin/stdout
venomenalny has joined #ruby
<delsol>
shell script with 1 SCP and 5 SSH commands, 1 line each.
<Bish>
thats why it works with system("") because system gives your shellscript stdin/stdout of your ruby program
apparition47 has quit [Quit: Bye]
za1b1tsu has quit [Quit: WeeChat 2.1]
<delsol>
running the shell script in ruby doesn't work. Doing the 6 lines separately work fine in ruby.
<ccooke>
delsol: so, you run "ssh user@host script_file" and the script_file contains an scp and 5 ssh commands?
<delsol>
ccooke: no
<Bish>
why are you ignoring me
<delsol>
doing the script that does it all at the command line works fine. Doing it in ruby does not..... until I break the script down, and do each line in ruby separately.
<ccooke>
delsol: how do you run multiple commands in one line? Give us an example
nowhere_man has joined #ruby
venomenalny has quit [Read error: Connection reset by peer]
Venomen has quit [Ping timeout: 268 seconds]
<ccooke>
... if you're scp'ing a file to the server, and then running it with "ssh user@host filename"... do you make sure the file is executable first?
<delsol>
ccooke: the whole script: LINE1: scp over SSH keys package LINE2: install SSH keys package. LINE3: run hostname script with given hostname. LINE4: change lilo config and run lilo script with given hostname LINE5: change IP address in inet1.conf script.
<delsol>
system("runwholescript" doesn't work.
<ccooke>
so, you're trying a multiline string in system()?
Fr4n has quit [Read error: Connection reset by peer]
chouhoulis has quit [Ping timeout: 265 seconds]
Fr4n has joined #ruby
mikecmpb_ has quit [Quit: inabit. zz.]
[Butch] has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
bijan_ has joined #ruby
lxsameer has quit [Ping timeout: 268 seconds]
bijan_ has quit [Read error: Connection reset by peer]
amar_ has joined #ruby
amar_ has quit [Remote host closed the connection]
amar_ has joined #ruby
vyorkin has joined #ruby
lxsameer has joined #ruby
Beams has quit [Quit: .]
claudiuinberlin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
amar_ has quit [Ping timeout: 260 seconds]
<theRoUS>
rails 5. i put a file in app/validators/balancer_validator.rb, but no longer need it. but if i delete it, rails blows up because it can't find it. i can't find any references to it anywhere; is it marshalled into a cache or something?
jottr_ has joined #ruby
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
EvilJStoker has quit [Ping timeout: 240 seconds]
bijan_ has joined #ruby
<theRoUS>
never mind, PEBKAC
bijan_ has quit [Read error: Connection reset by peer]
anjen has joined #ruby
EvilJStoker has joined #ruby
claudiuinberlin has joined #ruby
mostlybadfly has quit [Quit: Connection closed for inactivity]
eckhardt has joined #ruby
BloopMonster has joined #ruby
lxsameer has quit [Ping timeout: 276 seconds]
lxsameer has joined #ruby
bijan_ has joined #ruby
moei has quit [Quit: Leaving...]
bijan_ has quit [Read error: Connection reset by peer]
jottr_ has quit [Ping timeout: 260 seconds]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
dr3w_ has joined #ruby
p4p0l0 has quit [Remote host closed the connection]
Venomen has joined #ruby
maiz has joined #ruby
maiz has quit [Max SendQ exceeded]
vyorkin has quit [Quit: WeeChat 2.1]
drale2k_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bijan_ has joined #ruby
Venomen has quit [Ping timeout: 260 seconds]
chouhoulis has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
bijan_ has joined #ruby
shinnya has quit [Ping timeout: 245 seconds]
bijan_ has quit [Read error: Connection reset by peer]
lxsameer has quit [Ping timeout: 264 seconds]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
mikecmpbll has joined #ruby
bijan_ has joined #ruby
clemens3_ has quit [Ping timeout: 265 seconds]
bijan_ has quit [Read error: Connection reset by peer]
GodFather has quit [Ping timeout: 256 seconds]
SeepingN has joined #ruby
tty has joined #ruby
amar_ has joined #ruby
claudiuinberlin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
SanguineAnomaly has quit [Read error: Connection reset by peer]
jottr_ has joined #ruby
schleppel has quit [Quit: Konversation terminated!]
bijan_ has joined #ruby
SanguineAnomaly has joined #ruby
sameerynho has joined #ruby
workmad3 has quit [Ping timeout: 276 seconds]
bijan_ has quit [Read error: Connection reset by peer]
SanguineAnomaly is now known as XII
r29v has joined #ruby
schleppel has joined #ruby
jottr_ has quit [Ping timeout: 256 seconds]
tty has quit [Ping timeout: 245 seconds]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
guille-moe has quit [Remote host closed the connection]
lxsameer has joined #ruby
moei has joined #ruby
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
BloopMonster has quit [Ping timeout: 268 seconds]
guille-moe has joined #ruby
cagomez has quit [Read error: Connection reset by peer]
cagomez has joined #ruby
lxsameer has quit [Ping timeout: 240 seconds]
cagomez has quit [Remote host closed the connection]
lxsameer has joined #ruby
cagomez has joined #ruby
lytol has joined #ruby
bijan_ has joined #ruby
wontruefree has quit [Quit: bye]
bijan_ has quit [Read error: Connection reset by peer]
delsol has quit [Remote host closed the connection]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
guille-moe has quit [Ping timeout: 265 seconds]
sauvin has quit [Read error: Connection reset by peer]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
drale2k_ has joined #ruby
lxsameer has quit [Ping timeout: 256 seconds]
anisha_ has quit [Quit: This computer has gone to sleep]
lxsameer has joined #ruby
discopatrick has quit [Quit: Connection closed for inactivity]
<cthu|>
I'm starting to love ===, but I know it's wrong
<cthu|>
it's a drug. It'll have consequences.
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
jottr_ has joined #ruby
bijan_ has joined #ruby
anjen has quit [Quit: anjen]
bijan_ has quit [Read error: Connection reset by peer]
crankharder has quit [Remote host closed the connection]
lxsameer has quit [Ping timeout: 264 seconds]
drale2k_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jottr_ has quit [Ping timeout: 264 seconds]
crankharder has joined #ruby
drale2k_ has joined #ruby
p4p0l0 has joined #ruby
anjen has joined #ruby
jabowa has joined #ruby
p4p0l0 has quit [Remote host closed the connection]
<tycoon177>
where can i effectively learn OO ruby? I have been working with rails for over 2 years now and i have learned a lot (i think) of ruby, but i stumble greatly when it comes to modules vs classes and things like that
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
dviola has joined #ruby
<tycoon177>
i guess now that i'm thinking about it, specifying OO was redundant
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
drale2k_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
za1b1tsu has joined #ruby
orbyt_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
zachk has joined #ruby
rcs has joined #ruby
zachk has quit [Changing host]
zachk has joined #ruby
p4p0l0 has joined #ruby
stairmast0r has quit [Quit: bye]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
synthroid has joined #ruby
bijan_ has joined #ruby
lxsameer has joined #ruby
jenrzzz has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
stairmast0r has joined #ruby
bijan_ has joined #ruby
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bijan_ has quit [Read error: Connection reset by peer]
synthroi_ has joined #ruby
wontruefree has joined #ruby
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
<cthu|>
hell === is black magic!
fmcgeough has quit [Quit: fmcgeough]
<cthu|>
it matches if an ip is in the subnet!
<cthu|>
crazy af
suukim has quit [Quit: Konversation terminated!]
clemens3_ has joined #ruby
ellcs has joined #ruby
synthroid has quit [Ping timeout: 265 seconds]
kryptoz has quit []
jottr has joined #ruby
lxsameer has quit [Ping timeout: 240 seconds]
jenrzzz has quit [Ping timeout: 264 seconds]
JamJam_kid has joined #ruby
ellcs has quit [Remote host closed the connection]
bijan_ has joined #ruby
ellcs has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
oncall-pokemon has joined #ruby
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
bijan_ has joined #ruby
maiz has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
apeiros_ has joined #ruby
daemonwrangler has quit [Ping timeout: 245 seconds]
t0xik has joined #ruby
jabowa has quit [Ping timeout: 260 seconds]
webhat has quit [Read error: Connection reset by peer]
daemonwrangler has joined #ruby
webhat has joined #ruby
jenrzzz has joined #ruby
DeepIO has joined #ruby
DeepIO has quit [Max SendQ exceeded]
Guest57744 has quit [Read error: Connection reset by peer]
Nicmavr has joined #ruby
Nicmavr is now known as Guest28198
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
p4p0l0 has quit [Remote host closed the connection]
jenrzzz has quit [Ping timeout: 268 seconds]
bijan_ has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
Venomen has joined #ruby
bijan_ has joined #ruby
alem0lars has joined #ruby
bijan_ has quit [Read error: Connection reset by peer]
lxsameer has joined #ruby
Venomen has quit [Ping timeout: 248 seconds]
doesntbyte has quit [Quit: Connection closed for inactivity]
orbyt_ has joined #ruby
cagomez has quit [Remote host closed the connection]
cagomez has joined #ruby
GodFather has joined #ruby
shinnya has joined #ruby
cagomez has quit [Ping timeout: 260 seconds]
workmad3 has joined #ruby
mike11 has joined #ruby
bijan_ has joined #ruby
jabowa has joined #ruby
bijan_ has quit [Ping timeout: 245 seconds]
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
sphenxes has quit [Quit: Leaving]
Puffball has joined #ruby
roamingdog has quit [Remote host closed the connection]
lxsameer has quit [Ping timeout: 265 seconds]
karapetyan has quit [Remote host closed the connection]
eckhardt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
lxsameer has quit [Ping timeout: 260 seconds]
lxsameer has joined #ruby
synthroi_ has quit []
lxsameer has quit [Ping timeout: 245 seconds]
jottr has quit [Ping timeout: 260 seconds]
dviola has quit [Quit: WeeChat 2.1]
cyberg has quit [Ping timeout: 245 seconds]
samosaphile has joined #ruby
cyberg has joined #ruby
quobo has joined #ruby
ur5us has joined #ruby
orbyt_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
samosaphile has quit [Quit: Page closed]
Dounx has joined #ruby
ur5us_ has joined #ruby
ur5us has quit [Read error: Connection reset by peer]
ur5us_ has quit [Client Quit]
ur5us has joined #ruby
mike11 has quit [Quit: Leaving.]
Venomen has joined #ruby
gbenussi has joined #ruby
leitz has quit [Quit: Nappy time]
jabowa has quit [Quit: Page closed]
crankharder has joined #ruby
Venomen has quit [Ping timeout: 245 seconds]
orbyt_ has joined #ruby
<jenrzzz>
if I know the path to a ruby file, is it possible to find out what constants it defines from another ruby script? i'm thinking no, but wondered if y'all have any ideas
<apeiros_>
with limitations
apeiros_ is now known as apeiros
gbenussi has quit [Ping timeout: 264 seconds]
<apeiros>
if you can run the file (i.e. are willing to accept potential side effects) you can map existing constants before and after and then diff
<apeiros>
jenrzzz: what probblem are you trying to solve?
<jenrzzz>
apeiros: cool, yeah I'm fine with requiring it. is there a quick way to get the list of defined constants or do I need to do ObjectSpace.each_object(Module)?
<apeiros>
ObjectSpace is the way
r29v has joined #ruby
<jenrzzz>
apeiros: nothing useful... my friend asked me how to copy all the method names for a class in vim and I wondered if there was a nice one-liner to load the file, find the module it defines, and call #methods on it. just a really roundabout way to avoid writing :g/def \v.+/y A
<apeiros>
jenrzzz: if you run yard on installations, you could query its index
<jenrzzz>
oooh that's a good idea
schleppel has quit [Quit: Konversation terminated!]
lxsameer has joined #ruby
amar_ has quit [Remote host closed the connection]