Guest29 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rrutkowski has joined #ruby
arashb has joined #ruby
guacamole has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rrutkowski has quit [Remote host closed the connection]
Dimik has quit [Ping timeout: 248 seconds]
rrutkowski has joined #ruby
apeiros_ has joined #ruby
jottr_ has joined #ruby
jottr has quit [Ping timeout: 248 seconds]
Sina has quit [Quit: Connection closed for inactivity]
_aeris_ has quit [Remote host closed the connection]
nowhereman_ has quit [Ping timeout: 260 seconds]
_aeris_ has joined #ruby
nowhereman_ has joined #ruby
Guest29 has joined #ruby
hahuang61 has quit [Quit: WeeChat 2.0.1]
alfiemax has joined #ruby
jottr_ has quit [Ping timeout: 248 seconds]
PaulCape_ has quit [Ping timeout: 268 seconds]
alfiemax has quit [Ping timeout: 248 seconds]
drewmcmillan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
guacamole has joined #ruby
guacamole has joined #ruby
guacamole has quit [Changing host]
arashb has quit [Ping timeout: 248 seconds]
guacamole has quit [Client Quit]
jnollette has joined #ruby
bmurt has joined #ruby
war_pigs_ has joined #ruby
war_pigs has quit [Ping timeout: 248 seconds]
jtdoncas_ has joined #ruby
PaulCapestany has joined #ruby
arashb has joined #ruby
bronson has joined #ruby
jtdoncas_ has quit [Ping timeout: 240 seconds]
orbyt_ has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
pastorin_ has quit [Remote host closed the connection]
war_pigs_ has quit [Quit: later... computer is sleeping]
bronson has quit [Ping timeout: 256 seconds]
rrutkowski has quit [Ping timeout: 240 seconds]
jtdoncas_ has joined #ruby
guacamole has joined #ruby
guacamole has joined #ruby
guacamole has quit [Changing host]
cdg has joined #ruby
Guest29 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
hahuang65 has quit [Quit: WeeChat 2.0.1]
cdg_ has quit [Ping timeout: 248 seconds]
cdg__ has joined #ruby
cdg has quit [Ping timeout: 248 seconds]
Xiti has quit [Quit: Xiti]
workmad3 has joined #ruby
mtkd has quit [Ping timeout: 240 seconds]
mtkd has joined #ruby
cdg__ has quit [Ping timeout: 248 seconds]
leitz has quit [Quit: Nappy time]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
workmad3 has quit [Ping timeout: 240 seconds]
Xiti has joined #ruby
nahra has joined #ruby
jenrzzz has quit [Ping timeout: 256 seconds]
guacamole has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Ardivaba has joined #ruby
<Ardivaba>
Hi.
Neptu_ has quit [Ping timeout: 268 seconds]
<havenwood>
Ardivaba: hi
<havenwood>
Welcome!
<Ardivaba>
Thanks.
arashb has quit [Ping timeout: 256 seconds]
Neptu has joined #ruby
jottr_ has joined #ruby
<Ardivaba>
As a former C# developer i just want to say that Ruby is absolutely amazing and i wish i'd known it 10 years ago. Also the community around Ruby seems to be very vibrant, so here i am.
<baweaver>
Alo
<Ardivaba>
Anyone knows if there any tools to help with code reading like SourceTrail for Ruby?
jenrzzz has joined #ruby
jottr_ has quit [Ping timeout: 256 seconds]
hahuang65 has joined #ruby
cdg has joined #ruby
randomstrangerb has quit [Ping timeout: 264 seconds]
randomstrangerb has joined #ruby
bmurt has joined #ruby
arashb has joined #ruby
<Ardivaba>
code-explorer gem seems to be close enough.
cdg has quit [Ping timeout: 240 seconds]
osvico has joined #ruby
darkhanb has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
marr has quit [Ping timeout: 240 seconds]
zigzig has quit [Ping timeout: 255 seconds]
Chronocity has joined #ruby
kies has quit [Ping timeout: 240 seconds]
zigzig has joined #ruby
thinkpad has quit [Quit: lawl]
osvico has quit [Ping timeout: 240 seconds]
<Success>
lols sass wants ffi and ffi requires < 2.5; but i have 2.5.0
<Success>
what should i do?
cdg has joined #ruby
thinkpad has joined #ruby
bronson has joined #ruby
cdg has quit [Ping timeout: 240 seconds]
vutral|kali_ has joined #ruby
jenrzzz has quit [Ping timeout: 264 seconds]
ramfjord has joined #ruby
vutral|kali has quit [Ping timeout: 240 seconds]
CrazyEddy has quit [Ping timeout: 264 seconds]
cagmz has quit [Quit: Leaving]
drewmcmillan has joined #ruby
vutral|kali_ has quit [Ping timeout: 240 seconds]
arashb has quit [Ping timeout: 240 seconds]
vutral|kali has joined #ruby
vutral|kali has joined #ruby
vutral|kali has quit [Changing host]
jottr_ has joined #ruby
exchgr has joined #ruby
x77686d has quit [Quit: x77686d]
jottr_ has quit [Ping timeout: 240 seconds]
Failure has joined #ruby
arashb has joined #ruby
cdg has joined #ruby
Psybur has quit [Ping timeout: 256 seconds]
SeepingN has quit [Remote host closed the connection]
x77686d has joined #ruby
jottr_ has joined #ruby
hahuang65 has quit [Quit: WeeChat 2.0.1]
Success has quit [Ping timeout: 240 seconds]
nertzy has quit [Read error: Connection reset by peer]
sameerynho has quit [Ping timeout: 256 seconds]
randomstrangerb has quit [Ping timeout: 248 seconds]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
randomstrangerb has joined #ruby
John_Ivan has joined #ruby
jottr_ has quit [Ping timeout: 264 seconds]
John_Ivan has quit [Read error: Connection reset by peer]
yaiyaichu has joined #ruby
dman777 has joined #ruby
<dman777>
has anyone ever mixed rvm with n or nvm in the same shell enviroment? would there be any issues?
bmurt has joined #ruby
<havenwood>
dman777: I'm not sure why there'd be any issue.
<havenwood>
dman777: They shouldn't conflict in any way.
<dman777>
there's alot going on the shell with all that
elphe has quit [Ping timeout: 240 seconds]
alfiemax has joined #ruby
kies has joined #ruby
CrazyEddy has joined #ruby
nowhere_man has joined #ruby
alfiemax has quit [Ping timeout: 260 seconds]
x77686d has quit [Quit: x77686d]
nowhereman_ has quit [Ping timeout: 256 seconds]
bronson has quit [Ping timeout: 268 seconds]
elphe has joined #ruby
garyserj has quit []
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mistym has joined #ruby
Lyubo1 has joined #ruby
bmurt has joined #ruby
gizmore has joined #ruby
meesles has quit [Ping timeout: 256 seconds]
arashb has quit [Ping timeout: 240 seconds]
bmurt has quit [Client Quit]
Psybur has joined #ruby
gizmore|2 has quit [Ping timeout: 260 seconds]
x77686d has joined #ruby
arescorpio has joined #ruby
elphe has quit [Ping timeout: 240 seconds]
jtdoncas_ has quit [Ping timeout: 240 seconds]
bmurt has joined #ruby
Psybur has quit [Ping timeout: 256 seconds]
Freshnuts has quit [Quit: Leaving]
ikopico has quit [Ping timeout: 265 seconds]
elphe has joined #ruby
ldv__ has joined #ruby
ldv has quit [Read error: Connection reset by peer]
ikopico has joined #ruby
eckhardt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
schneide_ has joined #ruby
ldv__ has quit [Remote host closed the connection]
jottr_ has joined #ruby
ta_ has quit [Remote host closed the connection]
ta_ has joined #ruby
ta_ has quit [Remote host closed the connection]
ta_ has joined #ruby
ta_ has quit [Remote host closed the connection]
ta_ has joined #ruby
schneide_ has quit [Ping timeout: 256 seconds]
arashb has joined #ruby
ta_ has quit [Remote host closed the connection]
ta_ has joined #ruby
jottr_ has quit [Ping timeout: 240 seconds]
ta_ has quit [Remote host closed the connection]
cadillac_ has quit [Quit: I quit]
Chronocity has quit [Remote host closed the connection]
cadillac_ has joined #ruby
workmad3 has joined #ruby
sspreitz has quit [Ping timeout: 240 seconds]
sspreitz has joined #ruby
ramfjord has quit [Ping timeout: 240 seconds]
osvico has joined #ruby
workmad3 has quit [Ping timeout: 256 seconds]
yaiyaichu has quit [Quit: Lost terminal]
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
orbyt_ has joined #ruby
Defenestrate has joined #ruby
mistym has quit [Ping timeout: 240 seconds]
mistym has joined #ruby
mistym has joined #ruby
mistym has quit [Changing host]
uptime has quit [Ping timeout: 255 seconds]
dogweather has quit [Ping timeout: 256 seconds]
bronson has joined #ruby
arashb has quit [Ping timeout: 248 seconds]
Defenestrate has quit [Quit: Leaving]
dogweather has joined #ruby
uptime has joined #ruby
bronson has quit [Ping timeout: 240 seconds]
nathani has quit [Quit: WeeChat 1.8]
drowze has joined #ruby
arashb has joined #ruby
ta_ has joined #ruby
drowze has quit [Client Quit]
drowze has joined #ruby
drowze has quit [Client Quit]
darkhanb has joined #ruby
govg has joined #ruby
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
hahuang65 has joined #ruby
quobo has quit [Quit: Connection closed for inactivity]
jottr_ has joined #ruby
nathani has joined #ruby
konsolebox has quit [Ping timeout: 240 seconds]
arescorpio has quit [Excess Flood]
konsolebox has joined #ruby
jottr_ has quit [Ping timeout: 248 seconds]
cdg has quit [Remote host closed the connection]
cdg has joined #ruby
exchgr has quit [Ping timeout: 256 seconds]
konsolebox has quit [Ping timeout: 256 seconds]
Ardivaba has quit [Quit: Page closed]
konsolebox has joined #ruby
AJA4350 has quit [Quit: AJA4350]
cdg has quit [Ping timeout: 240 seconds]
exchgr has joined #ruby
arashb has quit [Ping timeout: 248 seconds]
mtkd has quit [Ping timeout: 240 seconds]
ta_ has quit [Ping timeout: 248 seconds]
mtkd has joined #ruby
hahuang65 has quit [Quit: WeeChat 2.0.1]
segy has quit [Ping timeout: 248 seconds]
arashb has joined #ruby
ta_ has joined #ruby
segy has joined #ruby
alex`` has joined #ruby
gothicsouth has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
hahuang65 has joined #ruby
trautwein has quit [Quit: ZNC 1.6.5 - http://znc.in]
arashb has quit [Remote host closed the connection]
elphe has quit [Ping timeout: 240 seconds]
bronson has quit [Ping timeout: 264 seconds]
aintno_sunshine has joined #ruby
Azure has quit [Read error: Connection reset by peer]
jottr_ has joined #ruby
ephemera_ has quit [Quit: No Ping reply in 180 seconds.]
ephemera_ has joined #ruby
jottr_ has quit [Ping timeout: 256 seconds]
Azure has joined #ruby
oleo has joined #ruby
<dogweather>
Anyone use RubyMine? Does it really work for you?
<dogweather>
I've never gotten it to fully function as promised. Thinking about trying again
nicesignal has quit [Remote host closed the connection]
nicesignal has joined #ruby
jenrzzz has quit [Ping timeout: 248 seconds]
jenrzzz has joined #ruby
gothicsouth has joined #ruby
rrichardsr3 has joined #ruby
jenrzzz has quit [Ping timeout: 248 seconds]
rrichard_ has joined #ruby
elphe has joined #ruby
mjolnird has quit [Ping timeout: 252 seconds]
avocadotoast has joined #ruby
ta_ has quit [Ping timeout: 240 seconds]
<avocadotoast>
hey all, I'm a bit confused about something. I tried doing something like "a = 1; a++" in irb, and that works. a = 2 after that code runs
rrichardsr3 has quit [Ping timeout: 248 seconds]
ldv has joined #ruby
<avocadotoast>
but if I try to do this inside a ruby function, I get an error
<avocadotoast>
why is that?
jenrzzz has joined #ruby
oleo has quit [Remote host closed the connection]
mjolnird has joined #ruby
ldv has quit [Remote host closed the connection]
Failure has quit [Ping timeout: 240 seconds]
ldv has joined #ruby
jenrzzz has quit [Ping timeout: 256 seconds]
<havenwood>
avocadotoast: Ruby doesn't have the ++ operator.
workmad3 has joined #ruby
<havenwood>
avocadotoast: That second plus is being treated as a unary operator.
ur5us has quit [Remote host closed the connection]
ramfjord has joined #ruby
tvw has joined #ruby
bronson has quit [Ping timeout: 268 seconds]
ramfjord has quit [Ping timeout: 240 seconds]
randomstrangerb has quit [Ping timeout: 260 seconds]
randomstrangerb has joined #ruby
goatish has joined #ruby
kapil___ has joined #ruby
tomphp has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
venmx has quit [Ping timeout: 240 seconds]
dionysus69 has joined #ruby
venmx has joined #ruby
BlackPioter has quit [Quit: Peace.]
nicesignal has quit [Remote host closed the connection]
Azure has quit [Read error: Connection reset by peer]
nicesignal has joined #ruby
Azure has joined #ruby
qba73 has joined #ruby
deadnull has joined #ruby
alfiemax_ has quit [Remote host closed the connection]
ldnunes has joined #ruby
jaruga has joined #ruby
alfiemax has joined #ruby
qba73 has quit [Remote host closed the connection]
deadnull has quit [Quit: deadnull]
schneide_ has quit [Remote host closed the connection]
alfiemax has quit [Ping timeout: 240 seconds]
Snowy_ has joined #ruby
terens has joined #ruby
<terens>
how to convince coworker to not do this
<terens>
data: JSON.parse(data.to_json) ?
Snowy has quit [Read error: Connection reset by peer]
<Burgestrand>
terens why are they doing it?
jnyw has quit [Quit: WeeChat 2.0.1]
<terens>
I dont know
<al2o3-cr>
terens: can you not ask them?
InfinityFye has joined #ruby
jottr_ has joined #ruby
<terens>
I will ask again
<adaedra>
Maybe because they come from JS where this is the way to clone objects?
<terens>
I don't know what is the answer now but the last answer I got is to ensure validity.
<terens>
however data is going to be converted again to json automatically
InfinityFye has left #ruby [#ruby]
<terens>
data -> json -> hash -> json
Ishido has quit [Ping timeout: 246 seconds]
qba73 has joined #ruby
Psybur has joined #ruby
jottr_ has quit [Ping timeout: 240 seconds]
jottr_ has joined #ruby
cadillac_ has quit [Ping timeout: 248 seconds]
al2o3-cr has quit [Ping timeout: 240 seconds]
qba73 has quit [Remote host closed the connection]
qba73 has joined #ruby
jottr_ has quit [Ping timeout: 256 seconds]
tomphp has joined #ruby
cadillac_ has joined #ruby
tomphp has quit [Client Quit]
qba73 has quit [Ping timeout: 240 seconds]
apeiros_ has joined #ruby
qba73 has joined #ruby
tomphp has joined #ruby
Ishido has joined #ruby
roshanavand has quit [Ping timeout: 256 seconds]
workmad3 has joined #ruby
schneide_ has joined #ruby
schneide_ has quit [Remote host closed the connection]
schneide_ has joined #ruby
workmad3 has quit [Ping timeout: 264 seconds]
Psybur has quit [Ping timeout: 240 seconds]
dionysus69 has quit [Remote host closed the connection]
dionysus69 has joined #ruby
mozzarel1 has joined #ruby
mozzarella has quit [Ping timeout: 248 seconds]
mozzarel1 is now known as mozzarella
apparition has joined #ruby
quobo has joined #ruby
yohji has quit [Ping timeout: 240 seconds]
jottr_ has joined #ruby
yohji has joined #ruby
jottr_ has quit [Ping timeout: 256 seconds]
wsmoak has quit [Quit: Connection closed for inactivity]
Ishido has quit [Ping timeout: 240 seconds]
cdg has joined #ruby
nadir has quit [Quit: Connection closed for inactivity]
<heftig>
sounds like it shouldn't be converted automatically
Psybur has joined #ruby
Psybur has joined #ruby
Psybur has quit [Changing host]
workmad3 has joined #ruby
tcopeland has quit [Quit: tcopeland]
mjolnird has quit [Quit: Leaving]
mjolnird has joined #ruby
Psybur_ has joined #ruby
dinfuehr has quit [Ping timeout: 248 seconds]
Psybur has quit [Ping timeout: 240 seconds]
Gnukpd has joined #ruby
mtkd has quit [Ping timeout: 248 seconds]
dinfuehr has joined #ruby
apparition has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
amatas_ has joined #ruby
mtkd has joined #ruby
Ishido has joined #ruby
tomphp has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
aces1up has joined #ruby
<aces1up>
why does a Datetime object return weird years like -4713 ?
jottr_ has joined #ruby
apparition has joined #ruby
shinnya has joined #ruby
Guest29 has joined #ruby
cdg has quit [Remote host closed the connection]
cdg has joined #ruby
gr33n7007h has joined #ruby
gr33n7007h is now known as al2o3-cr
cdg has quit [Ping timeout: 252 seconds]
Gnukpd has quit [Quit: Leaving]
<apeiros_>
aces1up: because you constructed the instance with that year
apeiros_ is now known as apeiros
* apeiros
guesses Date.new instead of Date.today
k0mpa has joined #ruby
elphe has quit [Ping timeout: 240 seconds]
locsmif has joined #ruby
Mike11 has joined #ruby
Dimik has joined #ruby
dionysus69 has quit [Ping timeout: 252 seconds]
karapetyan has joined #ruby
govg has quit [Ping timeout: 264 seconds]
roshanavand has joined #ruby
roshanavand has left #ruby [#ruby]
govg has joined #ruby
kapil___ has quit [Quit: Connection closed for inactivity]
InfinityFye has joined #ruby
govg has quit [Ping timeout: 248 seconds]
tomphp has joined #ruby
amatas_ has quit [Quit: amatas_]
tomphp has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
InfinityFye has quit [Ping timeout: 256 seconds]
jeffreylevesque has quit [Ping timeout: 268 seconds]
Guest29 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tomphp has joined #ruby
sundhell is now known as sundhell_away
sundhell_away is now known as sundhell
jottr_ has quit [Ping timeout: 268 seconds]
vondruch has quit [Ping timeout: 248 seconds]
tomphp has quit [Client Quit]
qba73 has quit [Ping timeout: 240 seconds]
drakko has joined #ruby
elphe has joined #ruby
jottr_ has joined #ruby
desperek has quit [Ping timeout: 276 seconds]
martin__ has joined #ruby
Doow has joined #ruby
InfinityFye has joined #ruby
martin__ is now known as mongag
mongag has quit [Changing host]
mongag has joined #ruby
synthroid has joined #ruby
soniya29 has joined #ruby
soniya29_ has joined #ruby
jottr_ has quit [Quit: WeeChat 2.0.1]
zautomata1 has joined #ruby
rwb has quit [Ping timeout: 240 seconds]
zautomata has quit [Ping timeout: 264 seconds]
goatish has quit [Quit: Hibernating]
goatish has joined #ruby
guille-moe has quit [Ping timeout: 255 seconds]
jeffreylevesque has joined #ruby
roshanavand has joined #ruby
AJA4350 has joined #ruby
jeffreylevesque_ has joined #ruby
jeffreylevesque has quit [Ping timeout: 264 seconds]
bmurt has joined #ruby
govg has joined #ruby
guille-moe has joined #ruby
elphe has quit [Ping timeout: 248 seconds]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
bmurt has joined #ruby
drewmcmillan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
sylario has joined #ruby
amatas_ has joined #ruby
alfiemax has joined #ruby
John_Ivan has joined #ruby
John_Ivan has joined #ruby
John_Ivan has quit [Changing host]
andikr has quit [Remote host closed the connection]
qba73 has joined #ruby
aces1up has quit []
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tcopeland has joined #ruby
bmurt has joined #ruby
cdg has joined #ruby
konos5 has joined #ruby
konos5 has quit [Client Quit]
devil_tux has quit [Quit: leaving]
elphe has joined #ruby
qba73 has quit [Remote host closed the connection]
qba73 has joined #ruby
terens has quit [Remote host closed the connection]
drewmcmillan has joined #ruby
Ishido has quit [Ping timeout: 256 seconds]
mikecmpb_ has joined #ruby
mikecmpbll has quit [Ping timeout: 256 seconds]
stormpack has joined #ruby
shinnya has quit [Ping timeout: 260 seconds]
nowhereman_ has joined #ruby
TomyWork has quit [Ping timeout: 240 seconds]
nowhere_man has quit [Ping timeout: 248 seconds]
vondruch has joined #ruby
<Doow>
I'm having a problem with reading stdout and stderr from a process that I'm launching from inside ruby. I'm using the following code https://gist.github.com/KarlWerf/d3d08c67235b105841706871c049aa71 and sometimes the other process gets stuck trying to flush at the same time that ruby gets stuck in either out.eof?() or err.eof?(). Is there a better way to write this?
elphe has quit [Ping timeout: 256 seconds]
<apeiros>
Doow: IO.select to test where data is ready to be read
<apeiros>
also some low hanging fruits: name your gists with .rb to get syntax highlight, use 2 spaces for indent, use `until` instead of `while not`, don't use double negation (not != in line 28)
<apeiros>
oh, there's an and. I blame lack of highlight :-p
<apeiros>
also not sure throw is a good idea to transport error messages.
<apeiros>
(raise is ruby's way to raise an exception, throw is not meant for exceptions)
<Doow>
Wow, lots of good feedback at once :)
Mike11 has quit [Quit: Leaving.]
<Doow>
unfortunately I think I got all except the select part. Should I use select instead of the eof?()'s or is that for reading as well? (never used select, except in c for a socket about 16 years ago..)
elphe has joined #ruby
TomyLobo has joined #ruby
<apeiros>
select only tells you that data is ready. it's instead of .eof?. that way you ensure that you only read from where data is actually ready. using readline() it may still get stuck, though. you may want to read nonblocking (i.e. as much as is available without waiting for a specific character to appear)
<apeiros>
quite possible that there are better techniques.
<Doow>
reading nonblocking sounds like a really good idea :)
apparition has quit [Quit: Bye]
<Doow>
to tell the truth I'm getting pretty confused by ruby, there seems to be many different ways of doing the same thing and no good overview of when to use what.
jrafanie has joined #ruby
<apeiros>
if you still want to emit line by line it means you have to do your own buffering, though
<Doow>
I think I can handle that.
<apeiros>
regarding IO that's certainly the case. I remember having been confused by that too and I'm still not always entirely sure what's the proper way and why.
<apeiros>
(and I do use ruby for quite some time now… way over a decade…)
arne has joined #ruby
randomstrangerb has quit [Ping timeout: 260 seconds]
<arne>
if i want some sort of "supercheap" oauth
<arne>
could i sign a link with a timestamp with a private key?
<arne>
or is that somehow insecure
randomstrangerb has joined #ruby
<apeiros>
cheap and security usually doesn't mix
karapetyan has quit [Remote host closed the connection]
<Doow>
apeiros, a silly thing is that it's also pretty hard to google since many of the function names are less than 3 characters or the characters are non-alphabetic
sundhell is now known as sundhell_away
<adaedra>
if you want cheap oauth, you use a library which implements it already
<arne>
well i don't want to invest that much time :/
<adaedra>
what is it you want to do?
drakko has quit [Quit: xoxo]
<apeiros>
Doow: browsing the docs helps more than googling IMO
<Doow>
apeiros, I'll give it a try and see what I understand :)
Snowy_ has quit [Remote host closed the connection]
<apeiros>
generally you'll want read_nonblock I think ;-)
<arne>
apeiros: give someone a link which is valid for 10 minutes
<arne>
without writing anything to the database
<apeiros>
s/apeiros/adaedra/
karapetyan has joined #ruby
<arne>
same thing :p
<arne>
sorry
<apeiros>
signing a link with a key might blow max url length
<adaedra>
well you can have a link with just an id, and in the database an expiration timestamp
<adaedra>
i don't see where oauth comes into play
<adaedra>
ah, without writing to the db
tomphp has joined #ruby
<adaedra>
well yeah, you can just encrypt the timestamp + link to make a new link, but as apeiros said, you may get a too long link
karapetyan has quit [Remote host closed the connection]
<arne>
okay
<adaedra>
but that seems overkill imo
pastorinni has joined #ruby
* arne
agress
<adaedra>
i'd just have a db with expiration times, easier to manage
<adaedra>
security-wise, I guess it's as secure as your encription algorith is
<adaedra>
encryption
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
tomphp has quit [Client Quit]
<apeiros>
you can do some kind of crypto signature of the link which is shorter. but hand-rolled crypto is usually broken in at least one way.
<Doow>
I agree, database is probably both easier and more secure.
<apeiros>
and I lack the expertise to see in which ways it would be broken
<arne>
what's a good password generator in rubygems?
ramfjord has joined #ruby
ramfjord has quit [Ping timeout: 240 seconds]
bmurt has joined #ruby
<c-c>
Sharing links for access? You want a table with entries pointing to the access credinteals, with ids pointing to another table, which contains salted public, world-shared hashes
<c-c>
But unless you understand exactly why and what each word means, your secu will fail
dionysus69 has joined #ruby
rippa has joined #ruby
<arne>
i don't see how a cryptographicially link wouldn't be as secure
schneide_ has quit [Remote host closed the connection]
<arne>
but simply signing with rsa.. won't do the trick
<c-c>
arne: maybe you can google rainbow tables
<apeiros>
the big issue with crypto is - you usually don't see how your stuff is broken :-|
schneide_ has joined #ruby
<arne>
maybe google prime factorization
<arne>
has nothing to do with rainbowtables
<apeiros>
else I'd say something like a shared secret + hashing the link including the timestamp & shared secret and then add that hash to the link would suffice.
<c-c>
seems experience has yet to teach many
<apeiros>
but as said - it's easy enough to fuck up and never know.
<c-c>
8)
schneide_ has quit [Read error: Connection reset by peer]
<arne>
... i take random data + timestamp + sign
<c-c>
Ah well, even the best systems get broken in sometimes
<arne>
you gotta explain to me, how a rainbowtable would help there
<arne>
or even if a timestamp that is only signed by me
schneide_ has joined #ruby
<c-c>
It wouldn't "help", it is what you have to work "around"
vondruch has quit [Ping timeout: 248 seconds]
<arne>
bs
<c-c>
Also, random isn't random. Even that enables an attack
<arne>
...
<c-c>
Seems to me you'd benefit from reading a basic book on this topic.
<c-c>
Good luck!
<arne>
seems you'd benefit from talking less
<c-c>
thats what people often say, before getting pwned
<apeiros>
arne: that's been uncalled for. please refrain from that kind of behavior.
<arne>
like the subtext of his arrogance was more polite
<apeiros>
yeah, pointing fingers saying "he first" doesn't make it better.
<c-c>
So because I shared with you these commonly known professional details, I'm now "arrogant"
<arne>
apeiros: true
John_Ivan has quit [Ping timeout: 240 seconds]
<apeiros>
arne: but yes, I agree, c-c could have phrased the book part in a less condescending way.
<arne>
c-c: putting out not helpful facts like "random isn't secure" while i was talking about randonmly signed data
<arne>
doesn't help at all
<arne>
even if the random isn't random because there is no random.. as you would like to say, while there is sufficently random, you would still not be able to crack my rsa key from that
<WA9ACE>
what is the use case for the password generator?
schneide_ has quit [Ping timeout: 240 seconds]
<arne>
WA9ACE: generating passwords :o
<WA9ACE>
that can help us determine attack vector and answer appropriately
<Doow>
It all depends on the entire usecase, I'm still not sure exactly what you're trying to do.
<WA9ACE>
I mean the end goal
<arne>
no, the password-gen was for a different topic
<arne>
Doow: basicially i want an answer to the question is a link created with "randomdata+timestamp+rsa-sign"
<arne>
practiable for sort of a login token
<arne>
that isn't a word, deosn't matter u catch my drift
<arne>
but it's most likely a link that's too long.. too bad.
oleo has joined #ruby
<c-c>
arne: you must be a young guy
<Doow>
arne, ok, I still thing the randomdata part is enough and then keep the timestamp in a local db, but I'm no security expert (and I can't help with the other part)
<apeiros>
c-c: really, you too. please don't go ad-hominem.
cschneid has quit [Remote host closed the connection]
<WA9ACE>
Is there a reason not to use vetted security related gems already out there for authentication?
<c-c>
young guys often cut corners, when it comes to secu. One thinks one knows, because one cannot know all the things invented to circumvent stuff.
<apeiros>
you've arguments, present them. it's up to arne to put them to good use or ignore them.
<WA9ACE>
Omniauth which implements oauth2 is certainly safer and faster than rolling your own
<arne>
c-c: try to be helpful
<arne>
instead
soniya29_ has quit [Ping timeout: 246 seconds]
soniya29 has quit [Ping timeout: 256 seconds]
<c-c>
well I tried, since you asked why a link wouldn't be as secure.
<arne>
you didn't say why it isn't
<c-c>
I did, because things like predictable pseudorandomness and attacks like rainbow tables.
Burgestrand has quit [Quit: Closing time!]
<c-c>
started to, anyway.
<arne>
.. that doesn't explain how you crack my rsa-sign
<arne>
and also assume my randomness is background noise from big bang
<c-c>
I know it isn't.
elphe has quit [Ping timeout: 256 seconds]
<c-c>
I can also tell I'd have to do a lecture and I am not a secu lecturer. In fact, I'll just ignore the rest of this convo, now.
* apeiros
thinks SecureRandom should provide sensible enough randomness
<arne>
apeiros: it does.. but it wouldn't help
<WA9ACE>
^
<arne>
c-c: please do so
schneide_ has joined #ruby
<apeiros>
(and if it doesn't, it's a bug in securerandom and not your code - misusing it not withstanding of course)
k0mpa has quit [Ping timeout: 255 seconds]
<c-c>
Well, its not necessarily a bug, but in the premise about securerandom
conta has joined #ruby
InfinityFye has quit [Ping timeout: 246 seconds]
soniya29 has joined #ruby
soniya29_ has joined #ruby
InfinityFye has joined #ruby
<al2o3-cr>
when requiring securerandom in pry it lets you call a private_method a one off?
<al2o3-cr>
namely SecureRandom.gen_random
jrafanie has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<apeiros>
that's not due to pry
jrafanie has joined #ruby
<apeiros>
do `$ SecureRandom.gen_random` in pry before calling it
<apeiros>
then call it and do it again :)
<apeiros>
that's weird…
<al2o3-cr>
whats happening?
<apeiros>
well, it redefines itself on the first call
<al2o3-cr>
oic, but why do this
mongag has quit [Quit: BitchX-1.2.1 -- just do it.]
<apeiros>
not sure where the "turns private" comes from
<al2o3-cr>
yeah, weird, me neither.
<apeiros>
oh
<apeiros>
I see
k0mpa has joined #ruby
<apeiros>
because it replaces the original with an alias to a method which is private
<al2o3-cr>
ah, yes.
<apeiros>
so first call works because it happens in the public method (it calls it for you after doing the replacement), and after that, it no longer works
<apeiros>
IMO a bug
<apeiros>
#bytes will always work
<apeiros>
or ::bytes rather
<al2o3-cr>
does seem like it.
mtkd has quit [Ping timeout: 265 seconds]
mtkd has joined #ruby
<c-c>
Is the ruby implementation of securerandom a specific rng implementation or is it like in java, a kind of wrapper?
<apeiros>
it's a wrapper afais
<apeiros>
openssl, /dev/urandom and (no idea what specifically that is) win32
drakko has joined #ruby
qba73 has quit [Remote host closed the connection]
<c-c>
I've never used the ruby one, but the java one needs special instantiation and seeding implementation to be random, too
qba73 has joined #ruby
marr123 has joined #ruby
<apeiros>
unlike Kernel#rand, I don't know how to seed SecureRandom. it's not necessary to do so, but I don't know how I'd do it to create reproducible examples.
<al2o3-cr>
apeiros: invoking Process.argv0 in pry either segfaults or returns random memory junk. is this a fault of pry?
marr has quit [Ping timeout: 240 seconds]
<apeiros>
al2o3-cr: no idea
<al2o3-cr>
apeiros: are you using 2.5?
<apeiros>
yes
desperek has quit [Ping timeout: 260 seconds]
<al2o3-cr>
could you just check please?
jtdoncas_ has joined #ruby
<apeiros>
works for me™
<al2o3-cr>
hmm.. you on linux, windows or osx?
<apeiros>
osx, high sierra
<al2o3-cr>
hmm..
<al2o3-cr>
must be just linux then.
<apeiros>
I'd put my money on it being a ruby bug. I don't see why pry would meddle with Process.argv0
drakko has quit [Quit: xoxo]
<al2o3-cr>
well it works in irb and ruby from the command line. just not in pry.
desperek has joined #ruby
<al2o3-cr>
i think havenwood said he was seeing this same behaviour (not sure what he uses though)
<elomatreb>
It returns a raw call to the format method for me Oo
<elomatreb>
As in, a string
<al2o3-cr>
elomatreb: yeah, it get be a random anything.
<elomatreb>
It seems to be history lines
<apeiros>
oh
<apeiros>
al2o3-cr: it *looked* correct. it's not.
<apeiros>
random string here too
<al2o3-cr>
ah.
tomphp has joined #ruby
<elomatreb>
Seems to be something pry is doing because both irb and ruby -e don't do it
<al2o3-cr>
aye, i agree.
<al2o3-cr>
/usr/lib/ruby/2.5.0/pp.rb:152: [BUG] Segmentation fault at 0x0000000000000018 that's what i get sometimes.
tomphp has quit [Read error: Connection reset by peer]
tomphp_ has joined #ruby
<al2o3-cr>
have to ping banister to take a look at this.
quobo has quit [Quit: Connection closed for inactivity]
<elomatreb>
Yep got a segfault too (but at 0x0)
cschneid has joined #ruby
tomphp_ has quit [Client Quit]
DaniG2k has joined #ruby
schneide_ has quit [Read error: Connection reset by peer]
karapetyan has joined #ruby
* al2o3-cr
is afk for 10
schneide_ has joined #ruby
k0mpa has quit [Remote host closed the connection]
jrafanie has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<ruby[bot]>
c-c: we in #ruby do not like pastebin.com, it loads slowly for most, has ads which are distracting and has terrible formatting. Please use https://gist.github.com
soniya29 has quit [Ping timeout: 240 seconds]
soniya29_ has quit [Ping timeout: 240 seconds]
jtdoncas_ has quit [Ping timeout: 248 seconds]
mordof has quit [Remote host closed the connection]
s2013 has joined #ruby
sepp2k has joined #ruby
marr123 has quit [Remote host closed the connection]
marr has joined #ruby
soniya29 has joined #ruby
soniya29_ has joined #ruby
apeiros__ has joined #ruby
John_Ivan has joined #ruby
apeiros__ has quit [Remote host closed the connection]
mark_66 has quit [Remote host closed the connection]
schneide_ has quit [Remote host closed the connection]
schneide_ has joined #ruby
aupadhye has quit [Ping timeout: 240 seconds]
apeiros has quit [Read error: Connection reset by peer]
Success has joined #ruby
synthroid has quit [Remote host closed the connection]
schneide_ has quit [Ping timeout: 240 seconds]
qba73 has quit [Remote host closed the connection]
aufi has quit [Quit: Leaving]
qba73 has joined #ruby
conta has quit [Ping timeout: 252 seconds]
orbyt_ has joined #ruby
naftilos76 has joined #ruby
stormpack has quit [Quit: Leaving]
Fusselgesicht has joined #ruby
synthroid has joined #ruby
soniya29_ has quit [Remote host closed the connection]
soniya29 has quit [Remote host closed the connection]
soniya29 has joined #ruby
soniya29_ has joined #ruby
euge has joined #ruby
x77686d has joined #ruby
alveric has joined #ruby
euge has left #ruby [#ruby]
schneide_ has joined #ruby
gnufied has joined #ruby
ivanskie has joined #ruby
ivanskie has quit [Remote host closed the connection]
konsolebox has quit [Ping timeout: 248 seconds]
karapetyan has joined #ruby
Fusselgesicht has quit [Quit: leaving]
konsolebox has joined #ruby
apeiros has joined #ruby
tomphp has joined #ruby
sammi` has quit [Quit: Changing server]
soniya29_ has quit [Ping timeout: 240 seconds]
soniya29 has quit [Ping timeout: 240 seconds]
schneide_ has quit [Remote host closed the connection]
karapetyan has quit [Remote host closed the connection]
karapetyan has joined #ruby
karapetyan has quit [Remote host closed the connection]
<adaedra>
c-c: stop throwing oil on the fire, please.
<Success>
i love throwwing oil on the fire tho
Fusselgesicht has joined #ruby
sammi` has joined #ruby
tomphp has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
yohji has quit [Remote host closed the connection]
qba73 has quit [Remote host closed the connection]
jaruga has quit [Quit: jaruga]
qba73 has joined #ruby
<za1b1tsu>
Any way I can access an instance variable without a setter? Like instance_of_class.send :@instance_var?
guacamole has joined #ruby
guacamole has joined #ruby
guacamole has quit [Changing host]
<apeiros>
za1b1tsu: see Object's instance_variable_* methods
<adaedra>
there's instance_variable_get/set
conta has joined #ruby
<adaedra>
too slow
sammi` has quit [Quit: Changing server]
sammi` has joined #ruby
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sammi` has quit [Client Quit]
krystianbajno has joined #ruby
drakko has quit [Ping timeout: 240 seconds]
conta has quit [Ping timeout: 240 seconds]
krystianbajno has left #ruby ["Leaving"]
ldv has joined #ruby
gothicsouth has quit [Ping timeout: 240 seconds]
moei has joined #ruby
s2013 has joined #ruby
kapil___ has joined #ruby
soniya29 has joined #ruby
soniya29_ has joined #ruby
<kapil___>
i cannot call method defined in require(' ...rb') file. plz help
ldv has quit [Remote host closed the connection]
<apeiros>
what do you mean you can't call?
soniya29_ has quit [Remote host closed the connection]
soniya29 has quit [Remote host closed the connection]
ciscam has joined #ruby
<apeiros>
kapil___: ^
randomstrangerb has quit [Ping timeout: 260 seconds]
<apeiros>
that doesn't really make things clearer. what happens when you try to call the method? how is the method defined in commonQuery.rb? also, please use gist.
ClearsTheScreen has left #ruby [#ruby]
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<kapil___>
thanks I am using rails generator: when i give the Query Class Module Name. it gives me errors. I want to use same modules in a generator.
<za1b1tsu>
thanks aperios
Vapez has joined #ruby
<apeiros>
?tabnick za1b1tsu
<ruby[bot]>
za1b1tsu: pro-tip - use tab completion for nicks. avoids typos in nicks.
<apeiros>
kapil___: "when i give the Query Class Module Name" I don't know what that means
cek has joined #ruby
<kapil___>
apeiros: doing this not working: class AllmodelsGenerator::Query
<apeiros>
"not working" is not a useful problem description
<apeiros>
again, *what happens*?
<apeiros>
and potentially, *what did you expect instead*?
resnik has joined #ruby
vutral|kali has quit [Ping timeout: 255 seconds]
<kapil___>
then it can't give proper error. instead tells : `Could not find generator 'allmodels'. Maybe you meant 'model', 'assets' or 'channel' so entire generator not runs.
<resnik>
How do I supply custom LDFLAGS to an extension being built via gem install? I see the build flags option, but I'm not sure how to use it.
<kapil___>
I want to define subclass in current class. so all method of parent class are available to subclass.
<apeiros>
kapil___: I'm sorry, I don't understand what you're doing
<kapil___>
apeiros I have : class AllmodelsGenerator < Rails::Generators::NamedBase ....
<kapil___>
I want Query class below AllmodelsGenerator
<apeiros>
ok. variant 1: ensure your allmodelsgenerator is loaded when executing `class AllmodelsGenerator::Query`
<apeiros>
variant 2: be explicit by defining it fully `class AllmodelsGenerator < Rails::Generators::NamedBase; class Query; …; end; end`
<kapil___>
apeiros: do i write require_relative('commonQuery.rb') inside class AllmodelsGenerator::Query
<apeiros>
note that variant 2 can cause issues with rails' autoloading
sanscoeur has joined #ruby
sanscoeur has quit [Remote host closed the connection]
qba73 has quit [Ping timeout: 256 seconds]
<kapil___>
sorry inside class AllmodelsGenerator < ...
<apeiros>
kapil___: if that's where you defined AllmodelsGenerator, then yes. but that means you're badly violating naming conventions
sanscoeur has joined #ruby
<apeiros>
kapil___: you should have a file allmodels_generator.rb, which defineds the class AllmodelsGenerator
<apeiros>
you then should have a file allmodels_generator/query.rb, which defines class AllmodelsGenerator::Query
<apeiros>
and in that file (allmodels_generator/query.rb) you should require 'allmodels_generator'
vutral|kali has joined #ruby
vutral|kali has joined #ruby
vutral|kali has quit [Changing host]
nc_ has joined #ruby
<kapil___>
apeiros: trying it
Beams has quit [Quit: .]
drcode has quit [Ping timeout: 248 seconds]
<kapil___>
its not working. tell that entire generator is not availble. i should move class in the file allmodels_generator.rb and in class AllmodelsGenerator < Rails::Generators::NamedBase class. i think
<kapil___>
apeiros: thanks your variant 2 is working. thanks
Azure|dc has joined #ruby
Azure has quit [Read error: Connection reset by peer]
synthroid has quit [Remote host closed the connection]
guille-moe has quit [Remote host closed the connection]
qba73 has joined #ruby
guille-moe has joined #ruby
<kapil___>
apeiros: I still not able to access @yamlConfig variable from class AllmodelsGenerator . how to access methods and variables from parent class?
karapetyan has joined #ruby
chouhoulis has joined #ruby
<apeiros>
kapil___: @instance_variables don't belong to a class. they belong to an object. only the same object can access the same instance variables.
synthroid has joined #ruby
<kapil___>
apeiros: thanks.
<apeiros>
a = Foo.new; b = Foo.new # a and b will have a separate set of instance variables. all methods invoked on a will use a's instance variables
<ciscam>
Can somebody help me end this decade-long trial and error to find the right regex? I have an input string like ")word {abbr.eviation.))" and want to split it to [), word, {, abbr.eviation., ), )], matching \s and [^\w\.] as a zero-width assertion but i neither want to lookahead, nor lookbehind
<ciscam>
with my best attempt /(?=[^\w\.])\s*/ I get [)word, {abbr.eviation., ), )]
rabajaj has quit [Quit: Leaving]
qba73 has quit [Ping timeout: 252 seconds]
<kapil___>
apeiros: how i use a's methods in b when b < a
vutral|kali has quit [Ping timeout: 248 seconds]
<apeiros>
you just call them
karapetyan has quit [Ping timeout: 248 seconds]
<apeiros>
honestly, this is introduction level stuff and you should IMO read a book / online learning material and come here for things you don't understand about it
<adaedra>
ciscam: tried with #scan and two groups, one for \w and one for [^\w\s]?
<kapil___>
apeiros: ok thanks
<ciscam>
will do adaedra , brb:)
_aeris_ has quit [Remote host closed the connection]
amatas_ has quit [Remote host closed the connection]
<apeiros>
ciscam: I'm slightly tied up atm, adaedra can probably explain
<Joeb12>
adaedra whats going on
<ciscam>
As far as I understand i tell scan to match single special characters (though that should actually include whitespaces) and groups made out of alphanumeric characters and dots
<ciscam>
Thanks apeiros, you're the best
<adaedra>
ciscam: well no, you tell here to match everything except alphanums and . (`[^\w\.]`) _then_ any number of alphanum/dot (`[\w\.]+`). If you want to test _either_, you need a `|`.
guille-moe has quit [Ping timeout: 248 seconds]
<adaedra>
ciscam: Even if it doesn't do ruby specifics, I think https://www.debuggex.com/ is wonderful to see what's really happening, give it a try
<resnik>
I can get the file by a simple find, but there should be some what to craft that path precisely.
<resnik>
some *way
<adaedra>
If you're from the context of the gem you're looking the extension for, you can probably craft the path from __dir__
<adaedra>
Otherwise I don't know, didn't really go this way in Ruby
alfiemax has joined #ruby
clemens3 has quit [Ping timeout: 265 seconds]
dumblonde has quit [Quit: Leaving]
ElianasBigToe has quit [Quit: Leaving]
<resnik>
I see rubygem code is probing that location when looking for a gem, allegedly tyring to load a binary ext, so there should be some code that crafts it.
Mike11 has joined #ruby
nc_ has joined #ruby
claudiuinberlin has joined #ruby
ldv__ has joined #ruby
ldv__ has quit [Remote host closed the connection]
mjolnird has quit [Remote host closed the connection]
<kapil___>
gist updated
x77686d has quit [Quit: x77686d]
mjolnird has joined #ruby
FrostCandy has joined #ruby
jenrzzz has joined #ruby
vutral|kali has joined #ruby
vutral|kali has joined #ruby
vutral|kali has quit [Changing host]
alex`` has joined #ruby
justicefries has joined #ruby
x77686d has joined #ruby
aintno_sunshine has joined #ruby
jordanm has quit [Remote host closed the connection]
vutral|kali has quit [Ping timeout: 240 seconds]
Vapez has joined #ruby
vutral|kali has joined #ruby
vutral|kali has joined #ruby
vutral|kali has quit [Changing host]
<kapil___>
please reply i must have to do this
randomstrangerb has quit [Ping timeout: 248 seconds]
randomstrangerb has joined #ruby
ur5us has joined #ruby
aintno_sunshine has quit [Remote host closed the connection]
<adaedra>
You never called `a_method`, so @a and @b are never set
<adaedra>
maybe you're wishing to make an initializer?
rrichardsr3 has quit [Quit: Apparantly my attempt to stay awake has failed...]
<adaedra>
also, just passing through, for best results when asking a question, provide a real code example, an example of expected and actual results, and be patient as people are not always behind their computer
<kapil___>
gist updated
matz_no_I_wish has joined #ruby
matz_no_I_wish has left #ruby [#ruby]
vutral|kali has quit [Ping timeout: 260 seconds]
matz_no_I_wish has joined #ruby
matz_no_I_wish has left #ruby [#ruby]
jenrzzz has quit [Ping timeout: 248 seconds]
<adaedra>
yeah, please make it a real, runnable example which does something when executed.
Vapez has quit [Read error: Connection reset by peer]
<adaedra>
ah, got reupdated
vutral|kali has joined #ruby
vutral|kali has joined #ruby
vutral|kali has quit [Changing host]
<adaedra>
so you have two instances here, one where you call `a_method` on it, so it will have @a and @b, and one where you don't, so you don't have instance variables
ltt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<adaedra>
@variables are not shared between different instances
jenrzzz has joined #ruby
<kapil___>
do i use @@
<adaedra>
no, avoid that
<adaedra>
i feel like you're just throwing things at random until it works instead of understanding what is happening here
<adaedra>
can you explain the code you wrote here?
Slinky_Pete has joined #ruby
<kapil___>
whats the solution? i have 15 instance variables . the ParentClass has only one object. I am making a rails generator. its so big so i have to write some code in its own class
<Slinky_Pete>
question about rspec, in my spec_helper.rb i set config.order = :random but even after it still always runs in order and produces no seed data
<adaedra>
kapil___: the solution is to step back and try to understand what you're doing here
nowhereman_ has joined #ruby
nowhere_man has quit [Ping timeout: 256 seconds]
vutral|kali has quit [Ping timeout: 240 seconds]
jenrzzz has quit [Ping timeout: 240 seconds]
goatish has joined #ruby
ltt has joined #ruby
<kapil___>
adaedra: I am setting some global setting variables when first time generator run. and use it in all methods and want to use in subclasses
<adaedra>
kapil___: here it seems that you're confused about classes, instances, and @variables. Maybe look again about these?
rrichardsr3 has joined #ruby
ePolice has joined #ruby
ePolice has left #ruby [#ruby]
<kapil___>
adaedra: sure. thanks
<sparr>
if $versionlocks {clabs::template { '/etc/yum/pluginconf.d/versionlock.list': } }
ldv has joined #ruby
x77686d has quit [Quit: x77686d]
<sparr>
I have that code. It works. I want to insert before the template call a call to notify{} similar to the `notify{"The value is: ${yourvar}": }` except that I want to see the nicely formatted $versionlocks.inspect
<sparr>
I cannot figure out the appropriate syntax :/
venmx has quit [Ping timeout: 252 seconds]
<adaedra>
tbf that syntax looks already incorrect. What is this from?
roshanavand has quit [Read error: No route to host]
jaequery has joined #ruby
roshanavand has joined #ruby
<Slinky_Pete>
question about rspec, in my spec_helper.rb i set config.order = :random but even after it still always runs in order and produces no seed data
Guest29 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
guacamole has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jenrzzz has joined #ruby
vutral|kali has quit [Ping timeout: 240 seconds]
<Mike11>
hello all :)
cek has quit [Quit: Connection closed for inactivity]
<Mike11>
I am using bundler to create a gem, by default it creates a Rakefile that contains "task :default => :spec" . I don't know what does that actually mean
<Mike11>
but rubocop complains about it using the old hash syntax
<lupine>
it means when you run `rake` with no arguments, it will run the specs for you
<lupine>
you can change it to `task default: :spec` or remove it entirely
<Mike11>
lupine: so, is task a Hash?
<lupine>
no, task is a method that takes a hash
<lupine>
rake messes with the toplevel namespace quite horribly
<Mike11>
if it was a method, shouldn't it be written like task {:default => :spec}
<Mike11>
>
<Mike11>
?*
jenrzzz has quit [Ping timeout: 240 seconds]
guacamole has joined #ruby
guacamole has joined #ruby
guacamole has quit [Changing host]
drcode has joined #ruby
Tristan-Speccy has joined #ruby
<Mike11>
lupine: or is okay to omit braces in this case?
knight33 has quit [Ping timeout: 240 seconds]
drcode has quit [Remote host closed the connection]
Tristan-Speccy is now known as Guest70560
<baweaver>
Mike11: task default: :spec
vutral|kali has joined #ruby
vutral|kali has joined #ruby
vutral|kali has quit [Changing host]
drcode has joined #ruby
<lupine>
you can omit the parens and the braces
<lupine>
it could be send(:task, {:default => :spec})
<Mike11>
lupine: thank you very much, that was really helpful :)
<lupine>
ruby doesn't care much :)
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
schneide_ has joined #ruby
Mike11 has quit [Ping timeout: 240 seconds]
guacamole has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jenrzzz has quit [Ping timeout: 240 seconds]
pastorinni has joined #ruby
elphe has joined #ruby
pastorinni has quit [Remote host closed the connection]
guacamole has joined #ruby
guacamole has joined #ruby
guacamole has quit [Changing host]
jeffreylevesque has joined #ruby
nowhere_man has joined #ruby
jeffreylevesque_ has quit [Ping timeout: 256 seconds]
guacamole has quit [Client Quit]
nowhereman_ has quit [Ping timeout: 256 seconds]
<Doow>
What does IO.select() actually return? From the documentation it seems to be the streams that are actually readable. But when I try it, it seems to be something else.
Slinky_Pete has quit []
karapetyan has quit [Remote host closed the connection]