<cerulean>
(uses ruby, cinch, sinatra, rack, thin, em-twitter and a lot of other heavy hitting stuff"
ResidentBiscuit has joined #ruby
belmoussaoui has quit [Read error: Connection reset by peer]
patr0clus has quit [Quit: WeeChat 1.4]
belmoussaoui has joined #ruby
LastWhisper____ has joined #ruby
charliesome has joined #ruby
ResidentBiscuit has quit [Ping timeout: 245 seconds]
araujo has quit [Quit: Leaving]
govg has joined #ruby
belmoussaoui has quit [Ping timeout: 268 seconds]
belmoussaoui has joined #ruby
romank has quit [Read error: Connection reset by peer]
Pongles has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
charliesome has joined #ruby
<Pongles>
Hello all! I am currently trying to make a bare-bones commandline server using ruby for a game I am creating, however I am have an issue where lines that I puts/print to the client are held until after I gets a line back from them.
<Pongles>
Here is my code currently: https://pastebin.com/7VeCRBJi the issue mainly happens in the loop after the "authication"
<ruby[bot]>
Pongles: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
<Pongles>
good to know ruby[bot] I will gist in the future
<Pongles>
It sends the "$:>" line with the response to the command instead of before the command
romank has joined #ruby
chopin has quit [Remote host closed the connection]
dionysus69 has joined #ruby
romank has quit [Read error: Connection reset by peer]
romank has joined #ruby
oleo has quit [Quit: irc client terminated!]
romank has quit [Read error: Connection reset by peer]
jgnagy has quit [Remote host closed the connection]
romank has joined #ruby
Mia has quit [Read error: Connection reset by peer]
gothicsouth has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
Mia has joined #ruby
Mia has joined #ruby
Mia has quit [Changing host]
belmoussaoui has quit [Remote host closed the connection]
belmoussaoui has joined #ruby
madhatter has quit [Remote host closed the connection]
madhatter has joined #ruby
JoshS has quit [Ping timeout: 245 seconds]
JoshS has joined #ruby
nofxxx has joined #ruby
nofxxxx has quit [Ping timeout: 260 seconds]
biberu has joined #ruby
dionysus69 has quit [Ping timeout: 245 seconds]
belmoussaoui has quit [Read error: Connection reset by peer]
blackwind_123 has quit [Quit: Some folks are wise, and some otherwise.]
belmoussaoui has joined #ruby
belmoussaoui has quit [Excess Flood]
aupadhye has joined #ruby
uZiel has joined #ruby
belmoussaoui has joined #ruby
ResidentBiscuit has joined #ruby
belmoussaoui has quit [Excess Flood]
eb0t has quit [Read error: Connection reset by peer]
belmoussaoui has joined #ruby
eb0t has joined #ruby
ResidentBiscuit has quit [Ping timeout: 258 seconds]
TomyLobo has joined #ruby
rc48 has joined #ruby
rc48 has quit [Read error: Connection reset by peer]
anisha_ has joined #ruby
belmoussaoui has quit [Remote host closed the connection]
belmoussaoui has joined #ruby
chopin has joined #ruby
ResidentBiscuit has joined #ruby
nunchuck has joined #ruby
chopin has quit [Ping timeout: 246 seconds]
ResidentBiscuit has quit [Ping timeout: 246 seconds]
renchan has joined #ruby
ResidentBiscuit has joined #ruby
eightlimbed has quit [Ping timeout: 260 seconds]
TomyLobo has quit [Ping timeout: 260 seconds]
ResidentBiscuit has quit [Ping timeout: 272 seconds]
Immune_ is now known as Immune
belmoussaoui has quit [Remote host closed the connection]
muelleme has joined #ruby
govg has quit [Ping timeout: 240 seconds]
railswebdev has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
belmoussaoui has joined #ruby
belmoussaoui has quit [Ping timeout: 255 seconds]
bambanx has joined #ruby
ur5us has quit [Remote host closed the connection]
mim1k has joined #ruby
conta has joined #ruby
mikecmpbll has joined #ruby
mim1k has quit [Ping timeout: 255 seconds]
govg has joined #ruby
djbkd has joined #ruby
ResidentBiscuit has joined #ruby
__Yiota has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ResidentBiscuit has quit [Ping timeout: 255 seconds]
ur5us has joined #ruby
Mia has quit [Read error: Connection reset by peer]
ovaltine has quit [Ping timeout: 246 seconds]
axellj has quit [Quit: Lost terminal]
muelleme has quit [Ping timeout: 272 seconds]
Mia has joined #ruby
Mia has joined #ruby
Mia has quit [Changing host]
dionysus69 has joined #ruby
Dimik has quit [Ping timeout: 240 seconds]
ovaltine has joined #ruby
bambanx has quit [Quit: Leaving]
Burgestrand has joined #ruby
tenderlove has quit [Read error: Connection reset by peer]
tenderlo_ has joined #ruby
Gucciferal has joined #ruby
Kug3lis_off is now known as Kug3lis
jgt has joined #ruby
moei has quit [Quit: Leaving...]
enterprisey has quit [Remote host closed the connection]
arescorpio has quit [Quit: Leaving.]
SeepingN has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mark_66 has joined #ruby
cam27 has quit [Quit: cam27]
KeyJoo has joined #ruby
n0vo has joined #ruby
SeepingN has joined #ruby
roamingdog has quit [Remote host closed the connection]
roamingdog has joined #ruby
<n0vo>
Hello, I've written a script which opens a list of URLs in new tabs in firefox, but I was wondering if there is a way to open the next URL without waiting for the other one to finish loading
<n0vo>
I'm using selenium
vondruch has quit [Ping timeout: 255 seconds]
roamingdog has quit [Remote host closed the connection]
roamingdog has joined #ruby
<Gucciferal>
noob here listening
roamingdog has quit [Remote host closed the connection]
roamingdog has joined #ruby
<n0vo>
I can't seem to find this information online
roamingdog has quit [Remote host closed the connection]
roamingdog has joined #ruby
roamingdog has quit [Remote host closed the connection]
andikr has joined #ruby
glejeune has joined #ruby
<pwnd_nsfw>
n0vo, use threads
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby
antgel has joined #ruby
ta_ has quit [Remote host closed the connection]
djbkd has quit [Ping timeout: 245 seconds]
Gucciferal has quit [Ping timeout: 240 seconds]
ur5us has quit [Remote host closed the connection]
aufi has joined #ruby
SaschaVoid has joined #ruby
SaschaVoid is now known as saschavoid
vali has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
vondruch has joined #ruby
uZiel has quit [Ping timeout: 248 seconds]
uZiel has joined #ruby
charliesome has joined #ruby
jaruga________ has joined #ruby
Gucciferal has joined #ruby
n0vo has quit [Quit: leaving]
rc48 has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
moei has joined #ruby
rc48 has quit [Read error: Connection reset by peer]
moei has joined #ruby
mim1k has joined #ruby
teclator has joined #ruby
chopin has joined #ruby
Kug3lis is now known as Kug3lis_off
Kug3lis_off is now known as Kug3lis
cschneid_ has joined #ruby
chopin has quit [Ping timeout: 260 seconds]
Gucciferal has quit [Ping timeout: 240 seconds]
govg has quit [Ping timeout: 240 seconds]
cschneid_ has quit [Ping timeout: 258 seconds]
Kug3lis is now known as Kug3lis_off
romank has quit [Read error: Connection reset by peer]
normie1 has joined #ruby
roamingdog has joined #ruby
doublemalt_ has quit [Ping timeout: 255 seconds]
ResidentBiscuit has joined #ruby
romank has joined #ruby
charliesome has joined #ruby
<dminuoso>
Never not use threads.
<dminuoso>
Because bugs keep your job alive.
ResidentBiscuit has quit [Ping timeout: 246 seconds]
Puffball has quit [Remote host closed the connection]
jenrzzz has quit [Ping timeout: 240 seconds]
pb122 has joined #ruby
Puffball has joined #ruby
pb122-two has quit [Ping timeout: 240 seconds]
Puffball has quit [Remote host closed the connection]
Puffball has joined #ruby
jameser has joined #ruby
<dminuoso>
Arahael: http://i.imgur.com/04Mlrwp.png -> if you define a method you basically define it onto the RClass of Object.
johnny56 has quit [Ping timeout: 264 seconds]
<dminuoso>
Arahael: And as you can see *all* inheritance chains end up with RObject (except BasicObject and classes that derive from BasicObject such as Delegator).
<dminuoso>
Arahael: Scope is not considered during method lookup. It works soley based on the receiver and it's classes ancestory.
pandaant has joined #ruby
<dminuoso>
Which means either the method is not defined yet, it's not defined on that class, or the receiver does not have RObject in its ancestory.
johnny56 has joined #ruby
doublemalt_ has quit [Ping timeout: 240 seconds]
bruce_lee has joined #ruby
bruce_lee has joined #ruby
bruce_lee has quit [Changing host]
yqt has joined #ruby
rc48 has joined #ruby
charliesome has joined #ruby
rc48 has quit [Read error: Connection reset by peer]
marr has quit [Ping timeout: 240 seconds]
mim1k has quit [Read error: Connection reset by peer]
dionysus69 has quit [Ping timeout: 245 seconds]
dionysus69 has joined #ruby
mim1k has joined #ruby
romank has quit [Ping timeout: 260 seconds]
romank has joined #ruby
dgs_ has quit [Ping timeout: 246 seconds]
chopin has joined #ruby
nobitanobi has joined #ruby
mim1k has quit [Ping timeout: 245 seconds]
mim1k has joined #ruby
dgs has joined #ruby
chopin has quit [Ping timeout: 240 seconds]
belmoussaoui has joined #ruby
arquebus has joined #ruby
banisterfiend has joined #ruby
doublemalt_ has joined #ruby
banisterfiend has quit [Client Quit]
belmoussaoui has quit [Ping timeout: 240 seconds]
jgt has quit [Ping timeout: 260 seconds]
last_staff has joined #ruby
mim1k has quit [Ping timeout: 246 seconds]
belmoussaoui has joined #ruby
ResidentBiscuit has joined #ruby
ResidentBiscuit has quit [Ping timeout: 255 seconds]
apparition has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
pandaant has quit [Quit: Lost terminal]
mim1k has joined #ruby
jgt has joined #ruby
jrafanie has joined #ruby
romank has quit [Remote host closed the connection]
romank has joined #ruby
nothingnew has joined #ruby
arquebus has quit [Quit: Leaving]
jrafanie has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jameser has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
doublemalt_ has quit [Ping timeout: 260 seconds]
ResidentBiscuit has joined #ruby
ResidentBiscuit has quit [Ping timeout: 246 seconds]
TomyWork has quit [Remote host closed the connection]
bmurt has joined #ruby
TomyWork has joined #ruby
marr has joined #ruby
tomphp has joined #ruby
Fernando-Basso has joined #ruby
<uZiel>
any good FOSS security projects in ruby out there?
robouk has quit [Remote host closed the connection]
ResidentBiscuit has joined #ruby
govg has quit [Ping timeout: 240 seconds]
ResidentBiscuit has quit [Ping timeout: 258 seconds]
nobitanobi has quit [Remote host closed the connection]
rc48 has joined #ruby
ResidentBiscuit has joined #ruby
tvw has joined #ruby
ResidentBiscuit has quit [Ping timeout: 240 seconds]
bkxd has joined #ruby
bvcosta has joined #ruby
bvcosta has quit [Remote host closed the connection]
rc48 has quit [Read error: Connection reset by peer]
mostlybadfly has joined #ruby
tomphp has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rohitpaulk has joined #ruby
rohitpaulk has quit [Remote host closed the connection]
rohitpaulk has joined #ruby
belmoussaoui has quit [Remote host closed the connection]
belmoussaoui has joined #ruby
<manveru>
uZiel: like metasploit?
roamingdog has joined #ruby
<manveru>
or more like bundle-audit
cdg has joined #ruby
jameser has joined #ruby
govg has joined #ruby
jameser has quit [Read error: Connection reset by peer]
ldnunes has joined #ruby
last_staff has quit [Quit: last_staff]
jameser has joined #ruby
opencw has joined #ruby
chopin has joined #ruby
cschneid_ has joined #ruby
mim1k has quit [Read error: Connection reset by peer]
ur5us has quit [Remote host closed the connection]
chopin has quit [Ping timeout: 260 seconds]
cschneid_ has quit [Ping timeout: 246 seconds]
gigetoo has quit [Read error: No route to host]
gigetoo has joined #ruby
<uZiel>
yeah something like that, I want to contribute to OSS (security) but hate java
<uZiel>
manveru: ^
<dminuoso>
uZiel: metasploit.
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
belmoussaoui has quit [Quit: belmoussaoui]
belmoussaoui has joined #ruby
rc48 has joined #ruby
roamingdog has quit [Ping timeout: 260 seconds]
nobitanobi has joined #ruby
govg has quit [Ping timeout: 240 seconds]
bkxd has quit [Ping timeout: 240 seconds]
rc48 has quit [Read error: Connection reset by peer]
rc48 has joined #ruby
<konsolebox>
i find that you'll only have passion to understand metasploit, if there's something you'd truly want to breach - and there's nothing in the world worth doing it. using it to hack-proof your system is boring.
qba73 has joined #ruby
Seenox has quit [Quit: Page closed]
jane_booty_doe2 has joined #ruby
belmoussaoui has quit [Remote host closed the connection]
<dminuoso>
konsolebox: That applies to most software projects.
<dminuoso>
You contribute because you either love or use the software.
Seenox has joined #ruby
<konsolebox>
yes i'm not saying anything against that
workmad3 has joined #ruby
konsolebox has quit [Quit: Leaving]
ledestin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
pankaj has joined #ruby
doublemalt_ has joined #ruby
cdg has quit [Remote host closed the connection]
dviola has joined #ruby
im0nde has joined #ruby
rc48 has quit [Read error: Connection reset by peer]
iamayam has quit [Ping timeout: 260 seconds]
pankaj has quit [Quit: Leaving]
mdw has joined #ruby
valentin has joined #ruby
vali has quit [Read error: Connection reset by peer]
mim1k has joined #ruby
workmad3 has quit [Ping timeout: 268 seconds]
qba73 has quit [Read error: Connection reset by peer]
andikr has quit [Remote host closed the connection]
rohitpaulk has quit [Ping timeout: 272 seconds]
yqt has quit [Ping timeout: 246 seconds]
iamayam has joined #ruby
kanutux has joined #ruby
Jakaria has joined #ruby
roshanavand has joined #ruby
jane_booty_doe has quit [Quit: Leaving]
jane_booty_doe2 has quit [Quit: Leaving]
rc48 has joined #ruby
Cohedrin has joined #ruby
nobitanobi has quit [Remote host closed the connection]
DLSteve has quit [Quit: All rise, the honorable DLSteve has left the channel.]
valentin has quit [Quit: valentin]
dionysus69 has quit [Ping timeout: 240 seconds]
doublemalt_ has quit [Ping timeout: 240 seconds]
GodFather has joined #ruby
sepp2k has joined #ruby
roshanavand has quit [Quit: Leaving.]
apparition has joined #ruby
spheric has joined #ruby
oleo has joined #ruby
ltem has joined #ruby
rc48 has quit [Read error: Connection reset by peer]
cdg has joined #ruby
mim1k has quit [Ping timeout: 246 seconds]
mim1k has joined #ruby
chopin has joined #ruby
ta_ has quit [Remote host closed the connection]
ur5us has joined #ruby
qba73 has quit [Read error: Connection reset by peer]
qba73 has joined #ruby
DoubleMalt has joined #ruby
ResidentBiscuit has joined #ruby
chopin has quit [Ping timeout: 260 seconds]
ur5us has quit [Ping timeout: 240 seconds]
marr123 has joined #ruby
marr is now known as Guest27094
marr123 is now known as marr
Guest27094 has quit [Killed (verne.freenode.net (Nickname regained by services))]
Cohedrin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Jakaria has quit [Ping timeout: 268 seconds]
ResidentBiscuit has quit [Ping timeout: 245 seconds]
kanutux has quit [Quit: leaving]
jusa has joined #ruby
planigan has quit [Ping timeout: 246 seconds]
marr has quit [Ping timeout: 260 seconds]
aupadhye has quit [Ping timeout: 240 seconds]
oleo has quit [Quit: irc client terminated!]
kanutux has joined #ruby
guardianx has joined #ruby
aufi has quit [Quit: Leaving]
kanutux has quit [Client Quit]
kanutux has joined #ruby
mim1k has quit [Read error: Connection reset by peer]
anisha_ has quit [Quit: This computer has gone to sleep]
kanutux has quit [Client Quit]
kanutux has joined #ruby
guardianx has quit []
kanutux has quit [Client Quit]
Trynemjoel has quit [Quit: Quitting]
kanutux has joined #ruby
jaruga________ has quit [Ping timeout: 246 seconds]
kanutux has quit [Client Quit]
kanutux has joined #ruby
Trynemjoel has joined #ruby
kanutux has quit [Client Quit]
kanutux has joined #ruby
nadir has quit [Quit: Connection closed for inactivity]
kanutux has quit [Client Quit]
Pongles has left #ruby ["Leaving"]
planigan has joined #ruby
j2k has joined #ruby
rc48 has joined #ruby
jaruga________ has joined #ruby
ferr1 has quit [Quit: WeeChat 1.7]
mim1k has joined #ruby
iamayam has quit [Ping timeout: 260 seconds]
nobitanobi has joined #ruby
Dark_Arc has quit [Quit: ZNC 1.6.3+deb1 - http://znc.in]
ResidentBiscuit has joined #ruby
teclator has quit [Remote host closed the connection]
DoubleMalt has quit [Ping timeout: 260 seconds]
ResidentBiscuit has quit [Ping timeout: 245 seconds]
rc48 has quit [Quit: leaving]
<uZiel>
is ruby pass-by-value or pass-by-reference?
mark_66 has left #ruby ["PART #elixir-lang :PART #crystal-lang :QUIT :Leaving."]
<leah2>
pass-by-value, but all non-primitive objects are represented as references :)
<uZiel>
ah okay, that's the glitch
<uZiel>
my array gets modified after returning from the function
quobo has quit [Quit: Connection closed for inactivity]
<leah2>
yes, you need to .dup it if you want to modify it without anyone noticing
mostlybadfly has quit [Quit: Connection closed for inactivity]
<ule>
^ nice
uZiel has quit [Remote host closed the connection]
cschneid_ has joined #ruby
rippa has joined #ruby
iamayam has joined #ruby
roshanavand has joined #ruby
uZiel has joined #ruby
qba73 has quit [Read error: Connection reset by peer]
cschneid_ has quit [Ping timeout: 258 seconds]
hays has joined #ruby
qba73 has joined #ruby
marr has joined #ruby
jrafanie has joined #ruby
shinnya has joined #ruby
BSaboia has joined #ruby
yqt has joined #ruby
kanutux has joined #ruby
ResidentBiscuit has joined #ruby
chalkmonster has joined #ruby
gothicsouth has joined #ruby
<Bish>
i don't remember
<Bish>
was there a method of Hash that retrives the value if the key exists, and returns the key otherwise
ResidentBiscuit has quit [Ping timeout: 245 seconds]
<Bish>
so that {"test"=>3}["test"] == 3
<Bish>
and {"test"=>3}["testx"] == "testx"
apparition has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
roshanavand has quit [Quit: Leaving.]
GodFather has quit [Ping timeout: 240 seconds]
roshanavand has joined #ruby
roshanavand has left #ruby [#ruby]
<go|dfish>
Bish: .fetch() can take a default value e.g. .fetch('testx', 'testx')
vondruch has quit [Quit: vondruch]
__Yiota has joined #ruby
vondruch has joined #ruby
vondruch has quit [Client Quit]
<apeiros>
uZiel: adding to what leah2 said - all those objects which are not represented as references (called "immediates") are immutable and have the same size as what's used to reference objects. i.e. it doesn't matter.
__Yiota has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
vondruch has joined #ruby
<apeiros>
and IMO even though it's technically pass-by-value, you can consider it to be pass-by-reference. as that's how it practically behaves.
brent__ has joined #ruby
__Yiota has joined #ruby
TomyWork has quit [Ping timeout: 240 seconds]
<leah2>
it's not pass-by-reference since def foo(a); a=6; end doesnt work :)
__Yiota has quit [Client Quit]
edgr has quit [Ping timeout: 260 seconds]
qba73 has quit []
<apeiros>
ok, given that that's how languages where the term originates from work - valid point
<apeiros>
but IMO just goes to show how badly those terms fit. depends entirely on what is being referenced.
conta has quit [Ping timeout: 272 seconds]
falcon10 has joined #ruby
falcon10 has left #ruby [#ruby]
aufi has joined #ruby
<havenwood>
When the values you're passing are references the distinction blurs.
<apeiros>
let's phrase it this way: arguments passed around in ruby are not copied (not talking about MRI's implementation there)
edgr has joined #ruby
<havenwood>
Yeah, the question makes a lot more sense in C++.
CacoS has joined #ruby
<havenwood>
Or C.
<havenwood>
"When you pass an object to a method in Ruby, it is an object reference that is passed to the method. It is not the object itself, and it is not a reference to the reference to the object."
<havenwood>
"Another way to say this is that method arguments are passed by value rather than by reference, but that the values passed are object references."
<havenwood>
~ The Ruby Programming Language
<havenwood>
(The Sparrows.)
<havenwood>
uZiel: ^
dionysus69 has joined #ruby
ResidentBiscuit has quit [Ping timeout: 272 seconds]
cdg has quit [Ping timeout: 272 seconds]
<Yxhuvud>
(and then we have the corner case when the value is stored in the reference itself, and hence copied. Values like integers, floats and booleans)
jrafanie has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
djbkd has quit [Ping timeout: 260 seconds]
LastWhisper____ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
cdg has quit [Remote host closed the connection]
saschavoid has quit [Quit: die();]
oleo has quit [Quit: irc client terminated!]
CacoS has quit [Remote host closed the connection]
j2k has quit [Quit: Connection closed for inactivity]
aufi has quit [Quit: Leaving]
gothicsouth has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
mjolnird has joined #ruby
mjolnird has quit [Client Quit]
glejeune has quit [Ping timeout: 260 seconds]
LastWhisper____ has joined #ruby
lxsameer has quit [Quit: WeeChat 1.7]
DLSteve has joined #ruby
chalkmonster has quit [Quit: Daddy's flown, 'cross the ocean.]
<Yxhuvud>
meh
t-recx has joined #ruby
mim1k has joined #ruby
antgel has quit [Ping timeout: 245 seconds]
chopin has joined #ruby
ResidentBiscuit has joined #ruby
mim1k has quit [Ping timeout: 240 seconds]
renchan has quit [Quit: Leaving...]
ResidentBiscuit has quit [Ping timeout: 245 seconds]
Dark_Arc has joined #ruby
gothicsouth has joined #ruby
Emmanuel_Chanel has quit [Ping timeout: 246 seconds]
mim1k has joined #ruby
djbkd has joined #ruby
mim1k has quit [Ping timeout: 255 seconds]
Burgestrand has quit [Quit: Closing time!]
LastWhisper____ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Dimik has joined #ruby
djbkd has quit [Ping timeout: 240 seconds]
ldnunes has quit [Ping timeout: 240 seconds]
mim1k has joined #ruby
eightlimbed has quit [Ping timeout: 240 seconds]
Kug3lis_off is now known as Kug3lis
mim1k has quit [Ping timeout: 245 seconds]
ldnunes has joined #ruby
tvw has quit [Read error: Connection reset by peer]
ResidentBiscuit has joined #ruby
mikkel- has joined #ruby
mikkel- is now known as mjuhl
mim1k has joined #ruby
ResidentBiscuit has quit [Ping timeout: 245 seconds]
uZiel has joined #ruby
hays has quit [Remote host closed the connection]
hays has joined #ruby
hays has joined #ruby
hays has quit [Changing host]
<uZiel>
sorry guys, got disconnected
<uZiel>
thanks leah2 apeiros havenwood
Emmanuel_Chanel has joined #ruby
mim1k has quit [Ping timeout: 260 seconds]
<uZiel>
my array was getting modified after return from the function, I wrote this earlier too, don't know if it got through or not because of the connection :/
<uZiel>
will have to modify all the functions now to make a copy of the argument before operating on them
oleo has joined #ruby
ResidentBiscuit has joined #ruby
mim1k has joined #ruby
cdg has joined #ruby
pb122 has quit [Ping timeout: 258 seconds]
mim1k has quit [Ping timeout: 245 seconds]
cdg has quit [Ping timeout: 246 seconds]
<craysiii>
hello everyone. it's been quite a while since i've used ruby, but im working on a pet project and can't seem to include a certain class inside my main module. https://gist.github.com/craysiii/9b675ff6c8769d9d6933e88ed9cd9e34 i seemingly have no issue including my first plugin class into the same module, but for some reason "Manager" does not want to come
<craysiii>
". any ideas?
<craysiii>
through and I get a "uninitialized constant RolePlayAgent::Manager (NameError)
mim1k has joined #ruby
ldnunes has quit [Ping timeout: 245 seconds]
<dionysus69>
is there a clean way to get script home dir? like Rails.dir ?
<havenwood>
craysiii: It's the same thing if you put the require_relative at the top of the file. It doesn't affect the namespace.
<dionysus69>
so there is none right? I would just call system "pwd" perhaps?
gothicsouth has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
ldnunes has joined #ruby
<havenwood>
dionysus69: There are multiple options, including `__dir__` or `Dir.pwd`.
mim1k has quit [Ping timeout: 240 seconds]
<dionysus69>
oh that's what I was looking for i guess thanks allot :)
<havenwood>
dionysus69: Do you want the current working directory or the directory of the path of the file that's being run?
<havenwood>
dionysus69: No prob.
<dionysus69>
I ll just save Dir.pwd path to some project_root variable
<havenwood>
dionysus69: You probably want __dir__.
<dionysus69>
Dir.pwd and __dir__ would return same path in my case
<dionysus69>
I am dealing with a single file scenario :)
<craysiii>
thanks havenwood, i added the namespace to the Manager class declaration and it;s working now. I was avoiding trying that because my IDE was throwing an error, thought there might have been a different way.
<havenwood>
craysiii: Nice, yeah that's the way to do it: class RolePlayAgent::Manager
<craysiii>
I'm still a little confused though,because i am able to access PingPlugin through "RolePlayAgent::PingPlugin" even though it doesn't have the namespace
Jakaria has joined #ruby
<craysiii>
do you think it could be because Object.get_const is just ignoring the namespace part of the string im passing it?
<havenwood>
If it really is nested it will work with inherit set to false:
<havenwood>
Yerp.
<havenwood>
craysiii: \o/
<craysiii>
Okay... now I must figure out how to get RubyMine to stop complaining about this namespace declared class lol. thanks once again!
LastWhisper____ has joined #ruby
tvw has joined #ruby
gothicsouth has joined #ruby
ur5us has quit [Ping timeout: 245 seconds]
<craysiii>
ah. if i wrap the classes inside the module again instead of declaring it via :: then all is well :D
nobitanobi has joined #ruby
A124 has quit [Quit: '']
ikoma has quit [Remote host closed the connection]
glejeune has joined #ruby
nobitanobi has quit [Ping timeout: 246 seconds]
<dminuoso>
craysiii: Do you also know *why* it is complaining?
<dminuoso>
There's nothing inherently wrong with A::B (and I do it often to avoid silly indention) as long as you know the subtle implications it has.
Jakaria has quit [Ping timeout: 260 seconds]
A124 has joined #ruby
ldnunes has quit [Ping timeout: 240 seconds]
ltem has quit [Ping timeout: 246 seconds]
oliv_____ has joined #ruby
muelleme has joined #ruby
xco has joined #ruby
last_staff has joined #ruby
last_staff has quit [Client Quit]
chopin has quit [Remote host closed the connection]
<xco>
i have an array like this array = %w[my name is em] is there a nice quick way for me to turn it to a hash like this? hashish = { my: 'my', name: 'name', is: 'is', bob: 'bob' }
<xco>
i mean this hashish = { my: 'my', name: 'name', is: 'is', em: 'em' }
<elomatreb>
>> %w[my name is em].map {|w| [w.to_sym, w] }.to_h
<dionysus69>
just realized that everything one does through bash script, is also possible through ruby via system "" calls
<dionysus69>
is ruby generally used in that way?
<dminuoso>
craysiii: When you use A::B then "A" will not be part of the nesting, which means inside that A::B block, trying to use C, ruby will not even attempt to check A::C -> in most cases this is not even a serious issue as ruby will just toss some exception in your face.
<dminuoso>
craysiii: In my opinion this fear of "using module A::B" is quite silly and leads to more indention - which harms readability, which in turns harms maintainability.
<havenwood>
dionysus69: Sure, if the lack of portability is fine for your script, shell out.
cdg has quit [Ping timeout: 258 seconds]
mim1k has quit [Ping timeout: 255 seconds]
<havenwood>
dionysus69: It's fairly common if a POSIX system can be assumed.
<havenwood>
>> Hash[*%w[my name is em]].invert.transform_values(&:to_sym).invert
<ruby[bot]>
havenwood: # => undefined method `transform_values' for {"name"=>"my", "em"=>"is"}:Hash (NoMethodError) ...check link for more (https://eval.in/807232)
<havenwood>
Seems like #transform_keys should be a thing too. I know there's an issue open for it. Seems likely in 2.5.
ResidentBiscuit has joined #ruby
<dionysus69>
havenwood: what do you mean by POSIX?
<dionysus69>
you mean UNIX like systems?
<havenwood>
dionysus69: POSIX "defines a standard operating system interface and environment, including a command interpreter (or “shell”), and common utility programs to support applications portability at the source code level."
<havenwood>
dionysus69: Think BSD, macOS, Linux.
<havenwood>
Windows Subsystem for Linux
<dionysus69>
oh ye
<dionysus69>
trying to support windows in any kind of software means duplicating work
<havenwood>
dionysus69: For example, sh, bash, ksh, zsh, etc are POSIXy while Fish isn't.
<dionysus69>
i've only had whatever experience with bash
chopin has joined #ruby
jenrzzz has joined #ruby
ResidentBiscuit has quit [Remote host closed the connection]
ResidentBiscuit has joined #ruby
ldnunes has quit [Ping timeout: 255 seconds]
gothicsouth has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
jrafanie has joined #ruby
romank has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
mim1k has joined #ruby
<craysiii>
thanks dminuoso i will check it out
mrconfused has joined #ruby
Cohedrin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jason^ has quit [Quit: WeeChat 1.8]
roamingdog has quit [Ping timeout: 255 seconds]
mim1k has quit [Ping timeout: 240 seconds]
xco has quit [Quit: xco]
_sfiguser has joined #ruby
gothicsouth has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
xco has joined #ruby
<xco>
elomatreb: thanks ;)
rkazak has joined #ruby
jaruga________ has quit [Quit: jaruga________]
uZiel has quit [Ping timeout: 248 seconds]
LastWhisper____ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Cohedrin has joined #ruby
mim1k has joined #ruby
ldnunes has joined #ruby
Cohedrin has quit [Client Quit]
eightlimbed has joined #ruby
andrzejku has joined #ruby
Cohedrin has joined #ruby
mim1k has quit [Ping timeout: 240 seconds]
patr0clus has quit [Quit: tempusfugit]
mrconfused has quit [Ping timeout: 246 seconds]
gothicsouth has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
chopin has quit [Remote host closed the connection]
_sfiguser has quit [Ping timeout: 240 seconds]
im0nde has quit [Ping timeout: 260 seconds]
ResidentBiscuit has quit [Remote host closed the connection]
patr0clus has joined #ruby
yqt has joined #ruby
mrconfused has joined #ruby
ldnunes has quit [Ping timeout: 268 seconds]
gizmore|2 has quit [Read error: Connection reset by peer]
TomyLobo2 has joined #ruby
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
_sfiguser has joined #ruby
TomyLobo has quit [Ping timeout: 240 seconds]
jusa has quit [Ping timeout: 240 seconds]
ResidentBiscuit has joined #ruby
gizmore has joined #ruby
jgnagy has joined #ruby
acemo has quit [Quit: Connection closed for inactivity]
ResidentBiscuit has quit [Ping timeout: 255 seconds]
ldnunes has joined #ruby
mim1k has joined #ruby
lxsameer has joined #ruby
gothicsouth has joined #ruby
mim1k has quit [Ping timeout: 240 seconds]
jgnagy has quit []
roamingdog has joined #ruby
zacts has quit [Ping timeout: 245 seconds]
sundhell has joined #ruby
redondos has joined #ruby
rohitpaulk has quit [Ping timeout: 268 seconds]
vuoto has joined #ruby
sundhell has quit [Client Quit]
roamingdog has quit [Ping timeout: 260 seconds]
Danny has joined #ruby
Danny is now known as Guest28552
gothicsouth has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
tvw has quit []
ResidentBiscuit has joined #ruby
ur5us has joined #ruby
quobo has joined #ruby
A124 has quit [Ping timeout: 255 seconds]
rohitpaulk has joined #ruby
lightstalker has quit [Remote host closed the connection]
ur5us has quit [Ping timeout: 240 seconds]
ResidentBiscuit has quit [Ping timeout: 245 seconds]
lightstalker has joined #ruby
robouk has joined #ruby
TomyLobo2 has quit [Ping timeout: 260 seconds]
roshanavand has joined #ruby
opencw has quit [Quit: Leaving]
nobitanobi has joined #ruby
nobitanobi has quit [Ping timeout: 240 seconds]
romank has joined #ruby
nowhere_man has quit [Remote host closed the connection]
chopin has joined #ruby
romank has quit [Read error: Connection reset by peer]
romank has joined #ruby
jgnagy has joined #ruby
chopin has quit [Ping timeout: 258 seconds]
enterprisey has joined #ruby
nowhere_man has joined #ruby
perniciouscaffei has joined #ruby
rippa has quit [Quit: {#`%${%&`+'${`%&NO CARRIER]
mrconfused has quit [Ping timeout: 245 seconds]
mrconfused has joined #ruby
Murda has joined #ruby
vuoto has quit [Remote host closed the connection]
sneakerhax has quit [Ping timeout: 240 seconds]
TomyLobo2 has joined #ruby
kanutux has quit [Quit: leaving]
gothicsouth has joined #ruby
ResidentBiscuit has joined #ruby
jrafanie has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Guest28552 has quit [Remote host closed the connection]
oliv_____ has quit [Remote host closed the connection]
<zenspider>
looks like you're lexing... if so, there are better tools out there
<eightlimbed>
zenspider: very nice :)
milardovich has quit [Remote host closed the connection]
<eightlimbed>
i'm working with a string, something like "88words9morewords10!" and i want to add up all the numbers. In this case I want to return 107, not 26, because consecutive numbers hold
<eightlimbed>
I used .chunk to get that array
<zenspider>
that's way overkill
<zenspider>
"I want to add up all the numbers" ... so add up all the numbers
<zenspider>
say what you want to do, then do it... that's what ruby is for
<eightlimbed>
i haven't learned regular expressions yet.. i guess i should start!
<zenspider>
they're a pain, but very useful
ResidentBiscuit has joined #ruby
<eightlimbed>
zenspider: thank you for your help :)
top4o has joined #ruby
nothingnew has quit [Read error: Connection reset by peer]
milardovich has quit [Remote host closed the connection]
ResidentBiscuit has quit [Ping timeout: 272 seconds]
zacts has joined #ruby
dionysus69 has quit [Ping timeout: 260 seconds]
ledestin has joined #ruby
marr123 has joined #ruby
marr has quit [Ping timeout: 240 seconds]
romank has quit [Ping timeout: 245 seconds]
nowhere_man has quit [Ping timeout: 268 seconds]
millerti has joined #ruby
stormbytes has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
Authenticator has joined #ruby
stormbytes has joined #ruby
<Authenticator>
I'm having trouble with BinData, describing a .zip structure. The hard bit is the variable-length array of "extra" data. The format is NameLen, ExtraLen, Name, [[ID, Len, Data], ...]
mim1k has joined #ruby
<Authenticator>
I can write a record for a File's structure if I treat the extra data like a blob, but I can't figure out how to make an array of structures.
marr123 is now known as marr
claw has quit [Ping timeout: 246 seconds]
Kug3lis is now known as Kug3lis_off
<Authenticator>
Can anyone help me with this BinData Array problem?
mrconfused has joined #ruby
claw has joined #ruby
cisco has joined #ruby
ResidentBiscuit has joined #ruby
nowhere_man has joined #ruby
LastWhisper____ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ResidentBiscuit has quit [Ping timeout: 245 seconds]
vrlogrs has joined #ruby
<vrlogrs>
hi folks .. is there no #rails channel?
<vrlogrs>
or is it invite only? :S
chopin has joined #ruby
<dgs>
#rubyonrails?
<vrlogrs>
ahhh
<vrlogrs>
thanks :)
oliv_____ has joined #ruby
chopin has quit [Ping timeout: 260 seconds]
bvcosta has quit []
ResidentBiscuit has joined #ruby
ol_______ has joined #ruby
roamingdog has joined #ruby
oliv_____ has quit [Ping timeout: 245 seconds]
top4o has quit [Ping timeout: 240 seconds]
ResidentBiscuit has quit [Ping timeout: 255 seconds]
roamingdog has quit [Ping timeout: 260 seconds]
ol_______ has quit [Remote host closed the connection]
olivi____ has joined #ruby
kies has joined #ruby
im0nde has joined #ruby
<Authenticator>
Can anyone help walk me through making a variable-length array of variable-length structure with the BinData gem?
jgt has quit [Ping timeout: 240 seconds]
vrlogrs has left #ruby [#ruby]
Danny has joined #ruby
Danny is now known as Guest95235
cfec0b8d has quit [Remote host closed the connection]
Pongles has joined #ruby
gothicsouth has joined #ruby
<Pongles>
Hey all, I am having trouble with a socket program I am making in ruby. https://gist.github.com/anonymous/5f66266bfec19e9294848088e87f3d8d In the loop after authenication, the "$:>" won't show up until after the user sends a message instead of before like it is in the script