tristanp has quit [Remote host closed the connection]
JeanCarloMachado has quit [Ping timeout: 260 seconds]
Madplatypus has joined #ruby
JakFrist[WVU] has joined #ruby
JeanCarloMachado has joined #ruby
nankyokusei has quit [Ping timeout: 244 seconds]
csk has joined #ruby
LoneHerm_ has joined #ruby
zeroDi has quit [Quit: WeeChat 1.5]
wingwalker has quit [Ping timeout: 272 seconds]
Channel6 has joined #ruby
csk has quit [Quit: ZZZzzz…]
LoneHerm_ has quit [Remote host closed the connection]
wingwalker has joined #ruby
PhishPhood has quit [Ping timeout: 250 seconds]
leea has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Ropeney has joined #ruby
NetSage has quit [Remote host closed the connection]
dtscode has joined #ruby
wisn has quit [Ping timeout: 244 seconds]
c355e3b has quit [Quit: Connection closed for inactivity]
djbkd has joined #ruby
P1ro has joined #ruby
crdpink has joined #ruby
crdpink has quit [Remote host closed the connection]
crdpink has joined #ruby
<zenspider>
getxsick: minitest is packaged as a real gem in newer ruby's, not a fake gem that is copied into /lib. But you should still get rdoc generated just fine when it is installed unless you're using something hacky/bad like rvm
<zenspider>
you can try `gem rdoc minitest` to fix
JeanCarloMachado has quit [Ping timeout: 272 seconds]
pratch has joined #ruby
l4v2 has joined #ruby
threh has joined #ruby
<zenspider>
drbrain: halp. I probably asked you this exact same question this time last year... my cert expired on minitest. What do I need to do besides bump version and repackage? `gem cert --help` is not helpful in knowing the steps
LuckyABA has joined #ruby
chouhoulis has quit [Remote host closed the connection]
rsampaio_ has joined #ruby
<getxsick>
zenspider: well, i'm new to ruby, so google doesn't help when you don't know some stuff and presents mainly results from ruby-docs
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
horst has quit [Quit: horst]
keith_ has quit [Quit: Leaving]
afisher has quit [Ping timeout: 240 seconds]
warmchizrhints has joined #ruby
thomas1 has quit [Quit: leaving]
thomas has joined #ruby
astrobunny has quit [Remote host closed the connection]
jidar_ is now known as jidar
17SAADNYV has joined #ruby
lxsameer has joined #ruby
jackjackdripper has joined #ruby
astrobunny has joined #ruby
firstdayonthejob has joined #ruby
vdamewood has quit [Quit: Life beckons.]
17SAADNYV has quit [Ping timeout: 264 seconds]
NTrash has joined #ruby
ledestin has joined #ruby
blackmesa has joined #ruby
warmchizrhints has quit [Ping timeout: 252 seconds]
marchelzo has joined #ruby
aurelien` is now known as aurelien
aurelien has quit [Changing host]
aurelien has joined #ruby
antru has joined #ruby
conta has joined #ruby
firstdayonthejob has quit [Ping timeout: 252 seconds]
A_Drone has quit [Remote host closed the connection]
ramfjord has joined #ruby
marchelzo has quit [Ping timeout: 264 seconds]
A_Drone has joined #ruby
craigp_ has quit [Quit: WeeChat 1.5]
craigp has joined #ruby
hahuang62 has joined #ruby
rnda has joined #ruby
ramfjord has quit [Ping timeout: 260 seconds]
Cohedrin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
steveh7 has joined #ruby
rnda has quit [Max SendQ exceeded]
rnda has joined #ruby
rnda has quit [Max SendQ exceeded]
rnda has joined #ruby
pokalyis has joined #ruby
Madplatypus has quit [Quit: Connection closed for inactivity]
hahuang62 has quit [Ping timeout: 265 seconds]
Guest89142 has quit [Quit: WeeChat 1.5]
Luna_Moonfang has joined #ruby
Ropeney has quit [Ping timeout: 260 seconds]
_sfiguser has quit [Ping timeout: 244 seconds]
pokalyis has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
prawnzy has quit [Remote host closed the connection]
blaxter has joined #ruby
pokalyis has joined #ruby
TomyWork has joined #ruby
nankyokusei has joined #ruby
pokalyis has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
emlee has joined #ruby
Ropeney has joined #ruby
anisha has joined #ruby
nankyokusei has quit [Ping timeout: 265 seconds]
vqrs has quit [Ping timeout: 240 seconds]
submitnine has joined #ruby
existensil has quit [Quit: WeeChat 0.4.2]
vqrs has joined #ruby
_sfiguser has joined #ruby
the_drow has joined #ruby
existensil has joined #ruby
biberu has joined #ruby
bsrd has joined #ruby
Pumukel has joined #ruby
aidalgol has joined #ruby
tonini has joined #ruby
pwnd_nsfw has quit [Quit: Leaving]
frozengeek has joined #ruby
symm- has joined #ruby
andikr has joined #ruby
joconcepts has quit [Remote host closed the connection]
blaxter has quit [Quit: foo]
alfiemax has joined #ruby
aganov has joined #ruby
joconcepts has joined #ruby
pwnd_nsfw has joined #ruby
pandaant has joined #ruby
claudiuinberlin has joined #ruby
djbkd has quit [Quit: My people need me...]
<devil_tux>
mornin
<pokui>
good morning
joconcepts_ has joined #ruby
alfiemax has quit [Remote host closed the connection]
pokalyis has joined #ruby
A_Drone has quit [Remote host closed the connection]
pandaant has quit [Ping timeout: 265 seconds]
joconcepts has quit [Ping timeout: 264 seconds]
wugy has joined #ruby
pandaant has joined #ruby
paha80 has joined #ruby
jonyijoe has quit [Remote host closed the connection]
dionysus69 has joined #ruby
codelogix has joined #ruby
reaVer_ has quit [Ping timeout: 250 seconds]
last_staff has quit [Excess Flood]
jonyijoe has joined #ruby
jshjsh has joined #ruby
last_staff has joined #ruby
mark_66 has joined #ruby
djbkd has joined #ruby
JoshS has quit [Ping timeout: 264 seconds]
JoshS has joined #ruby
codelogix has quit [Ping timeout: 264 seconds]
jshjsh has quit [Disconnected by services]
jonyijoe has quit [Ping timeout: 272 seconds]
leea has joined #ruby
frozengeek has quit [Quit: frozengeek]
aufi has joined #ruby
leea has quit [Client Quit]
marchelzo has joined #ruby
ishe has joined #ruby
vondruch has joined #ruby
ishe has quit [Client Quit]
Snickers has joined #ruby
bweston92 has quit [Quit: Leaving]
bweston92_ is now known as bweston92
sandelius has joined #ruby
oddmunds1 is now known as oddmunds
marchelzo has quit [Ping timeout: 240 seconds]
NTrash has quit [Quit: Konversation terminated!]
submitnine has quit []
Silthias has joined #ruby
joconcepts has joined #ruby
submitnine has joined #ruby
turbo64 has joined #ruby
antgel has joined #ruby
<turbo64>
how do you call a method inside a heredoc block
NTrash_ has joined #ruby
<turbo64>
like i know you can "escape" a variable with #{foo} but is there a way to do that with a method call?
nofxx has quit [Ping timeout: 265 seconds]
<turbo64>
when i put the call in #{} it calls the method before the heredoc for some reason
<Snickers>
Could someone tell me how to set source IP address int TCP/UDP socket?
NTrash_ has quit [Client Quit]
blackmesa has quit [Ping timeout: 252 seconds]
bsrd has quit [Quit: WeeChat 1.5]
Silthias1 has joined #ruby
NTrash_ has joined #ruby
<dminuoso>
Snickers: sock.addr ?
joconcepts_ has quit [Ping timeout: 244 seconds]
<pokui>
turbo64: the way string interpolation works is all the #{} are "run" then the final string created with the output plus the "constant" text unless I'm missing something.
<dminuoso>
Snickers: i.e. IPSocket#addr
Silthias has quit [Ping timeout: 252 seconds]
reaVer has joined #ruby
<Snickers>
dminuoso thx, that's it
<dminuoso>
Snickers: Or even the straight Socket#accept returns a socket/addrinfo pair that you can use directly.
<turbo64>
pokui is there a way to make it "run" within the block
<elomatreb>
turbo64: Sounds like what you want is a lambda
<Snickers>
wait, IPSocket#addr will return source IP addres, but i want to set it
<dminuoso>
Snickers: You want to... "set" it?
A_Drone has joined #ruby
<dminuoso>
Snickers: What exactly are you trying to do?
<dminuoso>
Snickers: Client opens a connection, server accepts it. You don't "change" the existing connection to have it point somewhere else.
leea has joined #ruby
jshjsh has joined #ruby
<Snickers>
I have, multiple ip address on server and I want to specify what address should be used
<dminuoso>
Snickers: You mean the bind address?
A_Drone has quit [Remote host closed the connection]
<Snickers>
bind is rather for serever to listen on address
tvw has joined #ruby
<Snickers>
i want to sent packet with specific source address
A_Drone has joined #ruby
<dminuoso>
Snickers: What?
<dminuoso>
09:51 < dminuoso> Snickers: What exactly are you trying to do?
<dminuoso>
?xy
<ruby[bot]>
it seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
<turbo64>
when i use the lambda its still outputting before the containing string
<dminuoso>
Snickers: If you want to send with a specific source address, bind your socket to it, and have your client connect to that. That is how sockets work.
<dminuoso>
You don't "fake" source IP addresses, it simply will not work.
JoshS has quit [Ping timeout: 244 seconds]
<Snickers>
dminuoso it would work eq IP spoofing
<Snickers>
but this is only part of problem
<dminuoso>
Snickers: No it would not.
<dminuoso>
09:51 < dminuoso> Snickers: What exactly are you trying to do?
<Snickers>
dminuoso you now how IP header look?
<dminuoso>
Snickers: Do you know how TCP works?
wingwalker has quit [Ping timeout: 255 seconds]
djbkd has quit [Quit: Leaving...]
alfiemax has joined #ruby
<dminuoso>
Snickers: Are you trying to do a MITM?
ur5us has joined #ruby
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
<Snickers>
dminuoso I know, I don't want to do MITM.
<Snickers>
I have computer with several ip addreses
<Snickers>
I want to specyfie what adres will be used to open connection to server
mikecmpbll has joined #ruby
<Snickers>
or do IP spoofing, whatever, just wana know how to set this source address in socket
aspiers_ is now known as aspiers
weckl has joined #ruby
rsampaio_ has quit [Ping timeout: 255 seconds]
_main_ has joined #ruby
A_Drone has quit [Remote host closed the connection]
unforgiven512 has joined #ruby
erlingur has quit [Ping timeout: 264 seconds]
__main__ has quit [Ping timeout: 250 seconds]
marr has joined #ruby
roamingdog has quit []
_main_ is now known as __main__
A_Drone has joined #ruby
ocbtec has joined #ruby
Shmulik has joined #ruby
<Shmulik>
hi, i wondered how to deal with line with string structure that i get from read file,
ferr has joined #ruby
__main__ has quit [Read error: Connection reset by peer]
<Shmulik>
the line include 10 parameters without spaces like any sign and then the date creation etc
Burgestrand has joined #ruby
__main__ has joined #ruby
<Shmulik>
i want to build any structure that will get the file and place each parameter in right place, so i can work with params
Burgestrand has quit [Client Quit]
dionysus69 has quit [Remote host closed the connection]
Burgestrand has joined #ruby
whiteline has quit [Remote host closed the connection]
dionysus69 has joined #ruby
priodev has quit [Ping timeout: 276 seconds]
whiteline has joined #ruby
<turbo64>
whats a good way to print a list of all of an object's attributes
<sandelius>
turbo64 what kind of attributes? instance variables?
priodev has joined #ruby
<turbo64>
yes
salut has joined #ruby
<sandelius>
turbo64 easy as object.instance_variables # => []
Dimik has quit [Ping timeout: 260 seconds]
<elomatreb>
Alternatively, you can use Kernel#p for debugging, or dump the object as YAML if it's too long
jsrn_ has joined #ruby
<turbo64>
im trying to print cgi environment variables
teclator has quit [Remote host closed the connection]
<elomatreb>
You could `require "yaml"`, then `puts ENV.to_yaml`
<turbo64>
on the cgi page on ruby-doc it says the environmental variables are available as read-only attributes of the cgi object
<turbo64>
and im not sure how to access read-only attributes
aryaching has quit [Read error: Connection reset by peer]
senayar has joined #ruby
<elomatreb>
Just like regular attributes, you just can't set them
gingray has joined #ruby
<turbo64>
for example cgi.REMOTE_ADDR doesn't work
Hobogrammer has quit [Ping timeout: 244 seconds]
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Burgestrand has joined #ruby
Hobogrammer has joined #ruby
<pokui>
turbo64: sorry was afk. I think I understand your original problem wrt to here-docs. http://pastebin.com/wuWbfuQR if I understand correctly.
<ruby[bot]>
pokui: pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
jaruga___ has joined #ruby
<turbo64>
what about codepad?
<turbo64>
is that one ok
<turbo64>
i dont believe it has ads
<pokui>
turbo64: not sure. but the gist the bot created has the code I wanted to show anyway.
emlee has quit [Ping timeout: 265 seconds]
<turbo64>
ok ill try that and see what happens
<turbo64>
alright cool
<turbo64>
yeah i didnt think about returning
<turbo64>
i was just printing it within the method
killuminati has joined #ruby
aryaching has joined #ruby
marchelzo has joined #ruby
<killuminati>
Killuminati ! Banish secret societies like illuminati !!!!! Psychiatry is a FRAUD !!!!!!!!! Israel terrorist state want put me in psychiatric yard!!!!!! Come and destroy this country now!!!!!!!!!
pawnbox has quit [Remote host closed the connection]
LoneHermit has joined #ruby
rnda has quit [Ping timeout: 276 seconds]
pawnbox has joined #ruby
jackjackdripper has quit [Quit: Leaving.]
nando293921 has joined #ruby
A_Drone has joined #ruby
workmad3 has joined #ruby
zotherst1 has joined #ruby
zotherstupidguy has quit [Ping timeout: 244 seconds]
LoneHermit has quit [Ping timeout: 260 seconds]
pawnbox has quit [Ping timeout: 265 seconds]
Ropeney has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
nando293921 has quit [Quit: Lost terminal]
zotherst1 has quit [Quit: WeeChat 1.5]
paha80 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
A_Drone has quit [Remote host closed the connection]
ardian has quit [Quit: WeeChat 1.4]
killuminati has joined #ruby
troulouliou_div2 has quit [Ping timeout: 276 seconds]
<killuminati>
Killuminati ! Banish secret societies like illuminati !!!!! Psychiatry is a FRAUD !!!!!!!!! Israel terrorist state want put me in psychiatric yard!!!!!! Come and destroy this country now!!!!!!!!!
A_Drone has joined #ruby
jonyijoe has joined #ruby
Ropeney has joined #ruby
<pokui>
sigh. then killuminati shows up with another IP in itally.
A_Drone has quit [Remote host closed the connection]
nando293921 has joined #ruby
<pokui>
sorry s/itally/israel/
araujo has joined #ruby
<elomatreb>
The other IP was from Isreal too
<pokui>
elomatreb: yeah.
codelogix has joined #ruby
araujo has quit [Max SendQ exceeded]
<killuminati>
I was in traffic
<elomatreb>
Not a bot :O
<hirvi>
lol
paha80 has joined #ruby
blackmesa has joined #ruby
araujo has joined #ruby
<killuminati>
Hey... Very bad beer...here!!!
flying has joined #ruby
* pokui
ignores
<killuminati>
I buy a Carlsberg..byt i think is not authentic.
<killuminati>
They falsified many here!!! Vodka, beer...many thinks.
araujo has quit [Max SendQ exceeded]
<elomatreb>
Maybe you should find a channel other than one focusing on a specific programming language?
conta has joined #ruby
araujo has joined #ruby
codelogix has quit [Ping timeout: 240 seconds]
<pokui>
hmm. immutable strings by default. time to dig up the last script i wrote to see if it'll be "cleaner" to use string.new or rewrite anything that builds a string with += or <<
<apeiros>
killuminati: #ruby-offtopic is the channel for random noise.
araujo has quit [Max SendQ exceeded]
_sfiguser has quit [Remote host closed the connection]
nadir has quit [Quit: Connection closed for inactivity]
araujo has joined #ruby
NTrash_ has quit [Quit: Konversation terminated!]
Pumukel has quit [Ping timeout: 272 seconds]
jaguarmagenta has quit [Remote host closed the connection]
<pokui>
Shmulik: you'd have to paste a gist of what the line looks like. if there are no separators how do you tell where the records are? number of characters?
troulouliou_div2 has joined #ruby
blackwind_123 has quit [Ping timeout: 260 seconds]
JeanCarloMachado has quit [Ping timeout: 265 seconds]
blackwind_123 has joined #ruby
Pumukel has joined #ruby
jshjsh has joined #ruby
JeanCarloMachado has joined #ruby
ur5us has quit [Remote host closed the connection]
ashZ has quit [Quit: Leaving]
JoshS has quit [Ping timeout: 244 seconds]
<turbo64>
[03:40] <killuminati> Killuminati ! Banish secret societies like illuminati !!!!! Psychiatry is a FRAUD !!!!!!!!! Israel terrorist state want put me in psychiatric yard!!!!!! Come and destroy this country now!!!!!!!!!
<turbo64>
where did this guy come from
<elomatreb>
The Wonderful World of Random Dudes in IRC
AnoHito_ has quit [Ping timeout: 252 seconds]
stamina has joined #ruby
JeanCarloMachado has quit [Ping timeout: 265 seconds]
JeanCarloMachado has joined #ruby
Snowy has joined #ruby
webus has joined #ruby
<pokui>
hmm. I wonder if the row[] objects from 'csv' will also be immutable. I tend to do a lot of "".gsub! there :(
marchelzo has joined #ruby
koooge has quit [Quit: Leaving...]
killuminati has joined #ruby
<killuminati>
Killuminati ! Banish secret societies like illuminati !!!!! Psychiatry is a FRAUD !!!!!!!!! Israel terrorist state want put me in psychiatric yard!!!!!! Come and destroy this country now!!!!!!!!!
killuminati has quit [Client Quit]
leitz has joined #ruby
pragmaticus has joined #ruby
jonyijoe_ has joined #ruby
LoneHerm_ has joined #ruby
jonyijoe has quit [Ping timeout: 265 seconds]
jonyijoe_ has quit [Remote host closed the connection]
minimalism has quit [Quit: minimalism]
jonyijoe has joined #ruby
eizua has quit [Quit: Leaving]
blackmesa has quit [Ping timeout: 260 seconds]
jonyijoe has quit [Ping timeout: 255 seconds]
DaniG2k has joined #ruby
gregf_ has joined #ruby
aidalgol has quit [Quit: zZzZzzzzz]
<devil_tux>
what a retard this guy killuminati is
killuminati has joined #ruby
<devil_tux>
killuminati: f.. off
Yagger has joined #ruby
<Yagger>
Hello, what is the gem / module I need to use within ruby to access the locate database file created by updatedb on Linux systems?
<elomatreb>
devil_tux: Who can ban in this channel?
<devil_tux>
can someone from op IP ban this bot
c355e3b has joined #ruby
tlaxkit has joined #ruby
symm- has quit [Quit: Leaving...]
astrobunny has quit [Remote host closed the connection]
<oblique>
i found that i need to do it with &method(:foo)
daemonwrangler has quit []
<ghr>
because Array doesn't have a method called foo
<oblique>
but i don't understand why
<ciawal>
&:foo means, call the foo method on the object
<ciawal>
not call the foo method *with* the object
<ciawal>
so it's '1'.to_i, '1'.foo
connor_g1odwolf is now known as connor_goodwolf
nankyokusei has quit [Ping timeout: 265 seconds]
<oblique>
i see, so what is changed with method()?
<apeiros>
?dontwork turbo64 /cc dminuoso
<ruby[bot]>
turbo64: we charge $120/h to figure out what you mean by "does not work". alternatively you can give us a proper explanation of what you expected to happen, and what happened instead, including the full exception if one occurred.
Nahra` has quit [Quit: ERC (IRC client for Emacs 24.5.1)]
<getxsick>
dminuoso: this is due to the fact operations on symbols are based on hash-values?
Robtop__ has joined #ruby
<jeffreylevesque>
is there a difference between: output = `ls`, and system = "ls"?
claudiuinberlin has quit [Remote host closed the connection]
bob434 has joined #ruby
<apeiros>
jeffreylevesque: try it
<dminuoso>
getxsick: No. Symbols are just numbers.
pawnbox has quit [Ping timeout: 244 seconds]
hightower4 has quit [Ping timeout: 250 seconds]
hahuang62 has quit [Ping timeout: 255 seconds]
<dminuoso>
getxsick: The basic idea is this: The Ruby VM has a lot of places where it must compare whether a == b, such as method names. With strings, that has a complexity of O(n), whereas an integer can be compared in O(1). So Symbols were added as a middleground.
pwnd_nsfw` has quit [Ping timeout: 272 seconds]
binaryplease has joined #ruby
<jeffreylevesque>
ls: cannot open directory .: Operation not permitted
binaryplease has quit [Client Quit]
<dminuoso>
getxsick: The symbol gets immediately transformed into a numbed, so that comparisons with it can be done in a single instruction. :-)
<dminuoso>
*number
<jeffreylevesque>
i just want to know the best way to store the output of a shell commadn to a variable
<dminuoso>
jeffreylevesque: What is "the output" ?
<ciawal>
system = "ls" is just assigning a string
<jeffreylevesque>
system "type -p wbinfo > /dev/null 2>&1"
<dminuoso>
jeffreylevesque: The closest thing *I* would understand as output is the return value.
<getxsick>
dminuoso: but still somehow transformation has to be done, i bet it's by hash function
<dminuoso>
getxsick: Oh yeah. :)
<jeffreylevesque>
output = system "type -p wbinfo > /dev/null 2>&1"
<jeffreylevesque>
yeah i want output/return
<jeffreylevesque>
not the exit code
<getxsick>
dminuoso: kewl :)
<dminuoso>
getxsick: actually let me think about this.
<dminuoso>
getxsick: Im not entirely sure. I think it's much simpler.
tk__ has joined #ruby
<getxsick>
ok, but ruby3.0 is providing immutable strings, then a difference between symbols and strings will be much much smaller. i guess only performance
claudiuinberlin has joined #ruby
<dminuoso>
getxsick: No, they are not comparable.
<dminuoso>
They are different things for different purposes.
<dminuoso>
It's like comparing 1 with "1" - sure, they look similar, but they are simply different.
webus has quit [Ping timeout: 265 seconds]
<dminuoso>
And you can convert one into the other, but they are still fundamentally different.
pawnbox has joined #ruby
ramortegui has joined #ruby
nankyokusei has joined #ruby
LoneHerm_ has joined #ruby
shinnya has joined #ruby
headius_ is now known as headius
jonyijoe has quit [Remote host closed the connection]
<jeffreylevesque>
the syntax seems it should be really short and simple
<canton7>
adac, use '.', like you did with 'HTTParty.get'?
jonyijoe has quit [Ping timeout: 265 seconds]
<adac>
canton7, oh right that works too :)
<adac>
thank you!
cdg has joined #ruby
braincrash has quit [Ping timeout: 244 seconds]
ta_ has joined #ruby
aegis3121 has joined #ruby
boshhead_ is now known as boshhead
<dminuoso>
adac: :: is commonly only used to access constants inside namespaces.
braincrash has joined #ruby
cdg has quit [Ping timeout: 255 seconds]
<jeffreylevesque>
why can't ruby run the `type` shell command?
JoshS has quit [Ping timeout: 265 seconds]
cdg has joined #ruby
dionysus69 has joined #ruby
Snickers has quit [Ping timeout: 276 seconds]
<dminuoso>
jeffreylevesque: because "type" is a shell builtin.
<jeffreylevesque>
can i run shell, or is there an alternative syntax?
<dminuoso>
?xy
<ruby[bot]>
it seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
<dminuoso>
jeffreylevesque: What are you trying to do?
<jeffreylevesque>
i want to run `if type -p wbinfo > /dev/null 2>&1; then if wbinfo -p > /dev/null 2>&1; then echo "true"; else echo "false"; fi; else echo "false"; fi`
gingray has joined #ruby
<jeffreylevesque>
the bash is not the best, and probably can be reduced
<ruby[bot]>
workerbeetwo: 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
<fbt>
But some questions will still be weird, as I'm still trying to wrap my head around the OOP model .-.
a7d7p has quit [Client Quit]
tk__ has quit [Quit: ばいばい]
marchelzo has joined #ruby
pawnbox has quit [Remote host closed the connection]
<apeiros>
fbt: sure. that's the advantage of irc, it's interactive.
scorphus has quit [Changing host]
scorphus has joined #ruby
JakFrist[WVU] has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
vqrs has quit [Ping timeout: 265 seconds]
pawnbox has joined #ruby
JakFrist[WVU] has joined #ruby
<apeiros>
workerbeetwo: your code contains line numbers?
pawnbox has quit [Remote host closed the connection]
<apeiros>
and just for the record, I'll not open another pastebin.
pawnbox has joined #ruby
mjuszczak has joined #ruby
dminuoso has joined #ruby
joast has joined #ruby
<apeiros>
dminuoso: _ at the end of a variable name? what's the intended meaning?
zacts has joined #ruby
<dminuoso>
apeiros: Originally this came as a mixin, so I used it to prevent potential conflicts.
<apeiros>
interesting code, relations for PORO :)
<dminuoso>
Yeah.
<apeiros>
somehow I thought tenderlove had already done something for that
vqrs has joined #ruby
<apeiros>
dminuoso: ah, I see. I usually "namespace" such mixin variables (if I can't avoid them altogether), e.g. @mylib_foovariable
pawnbox has quit [Ping timeout: 252 seconds]
<dminuoso>
apeiros: Next step is to fake reflections, so that the integration into various rails things is much nicer.
jphase has joined #ruby
_whitelogger has joined #ruby
<apeiros>
certainly looks like something which can be serious fun (but might also be pain… let's hope it stays at fun :D)
theRoUS has quit [Changing host]
theRoUS has joined #ruby
jphase has quit [Ping timeout: 240 seconds]
dionysus69 has quit [Ping timeout: 265 seconds]
asal has quit [Ping timeout: 244 seconds]
tvw has quit [Read error: Connection reset by peer]
<dminuoso>
apeiros: The real pain is looking at those gists, and wondering wtf vim is doing - I dont understand why I still have tabs in my files.
jokester has quit [Ping timeout: 265 seconds]
hahuang62 has joined #ruby
<apeiros>
dminuoso: heh. I use sublime text. it sometimes detects 3, 5 or even 8 spaces for indent. I have no effing clue how it comes to that conclusion.
<dminuoso>
jeffreylevesque: I think Puppet problems belong to #puppet
hahuang62 has quit [Ping timeout: 255 seconds]
<dminuoso>
jeffreylevesque: I barely know anything about puppet, so I cant even say whether anything what you are doing is sensible. Perhaps puppet has facilities to do any of that for you
<jeffreylevesque>
no problem
<jeffreylevesque>
yeah, i'm a noob in both fields
<jeffreylevesque>
this is like my first ruby script
<dminuoso>
jeffreylevesque: You can use this general chart as a guideline.
<jeffreylevesque>
thank you very much
<jeffreylevesque>
and sorry to bother this morning
a7d7p has joined #ruby
jackhill_ is now known as jackhill
wingwalker has joined #ruby
tdy has joined #ruby
habitullence has quit [Quit: habitullence]
LoneHerm_ has joined #ruby
<OnyxRaven>
I’m getting a ruby crash when using sqlite3 after forking (eg, in spring, or even in a spec) - It started when upgrading to osx sierra - https://gist.github.com/onyxraven/ce190bc4c9f31db07ec3c27578d33641 - There were a bunch of notes about troubles python had with the sierra bundled libsqlite3. has anyone run across this?
hobodave has joined #ruby
polishdub has joined #ruby
last_staff has quit [Quit: runs]
codelogix has joined #ruby
gregf_ has joined #ruby
malcolmva has quit [Ping timeout: 272 seconds]
Jardayn has quit [Read error: Connection reset by peer]
aegis3121 has quit [Ping timeout: 265 seconds]
threh has joined #ruby
redpants has joined #ruby
sumobob has joined #ruby
TvL2386 has quit [Remote host closed the connection]
LoneHerm_ has quit [Ping timeout: 276 seconds]
nankyokusei has joined #ruby
jonyijoe has joined #ruby
fredlinhares1 has joined #ruby
NTrash has joined #ruby
JeanCarloMachado has quit [Ping timeout: 244 seconds]
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<dminuoso>
OnyxRaven: Stack traces please.
<OnyxRaven>
the gist above is from the osx crash log. Do you want the ruby side as well?
_whitelogger_ has joined #ruby
_whitelogger has quit [Remote host closed the connection]
malcolmva has joined #ruby
LuckyABA has joined #ruby
[k-_ has quit [Read error: Connection reset by peer]
[k- has joined #ruby
<apeiros>
OnyxRaven: if you compiled against system sqlite3 - did you recompile?
<OnyxRaven>
I have, yeah
truenito has joined #ruby
<OnyxRaven>
full gem pristine
tyang has joined #ruby
<OnyxRaven>
i’ve also tried to get it to compile against homebrew but I cant seem to get it to do so
truenito has quit [Remote host closed the connection]
truenito has joined #ruby
truenito has quit [Remote host closed the connection]
mikecmpb_ has joined #ruby
jphase_ is now known as jphase
truenito has joined #ruby
mikecmpbll has quit [Ping timeout: 260 seconds]
kevinvw has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
aryaching has quit [Quit: Bye]
aryaching has joined #ruby
fullofcaffeine has quit [Remote host closed the connection]
fullofcaffeine has joined #ruby
ferr has quit [Quit: WeeChat 1.5]
Johne has joined #ruby
aganov has quit [Quit: Leaving]
bmurt has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<Johne>
whats the best way to go about converting time zones? date string I have is '2016-09-26T22:00:00Z'
miqlas-H has quit [Quit: Vision[0.9.7-H-20140108]: i've been blurred!]
sumobob has quit [Ping timeout: 255 seconds]
the_drow has joined #ruby
bsrd has joined #ruby
the_drow has quit [Read error: Connection reset by peer]
Guest21 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ur5us has joined #ruby
Rutix has quit []
the_drow has joined #ruby
kingkong_ has quit [Quit: No Ping reply in 180 seconds.]
aswen has quit [Quit: WeeChat 1.5]
kingkong- has joined #ruby
platzhirsch has quit [Quit: WeeChat 1.4]
prawnzy has joined #ruby
Guest5325 is now known as sami
sergio_101 has joined #ruby
JakFrist[WVU] has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
aegis312_ has quit [Ping timeout: 276 seconds]
LyndsySimon has joined #ruby
soulisson has joined #ruby
sami has left #ruby [#ruby]
stamina has joined #ruby
the_drow has quit [Read error: Connection reset by peer]
elifoster has joined #ruby
the_drow has joined #ruby
LuckyABA has joined #ruby
hobodave has quit [Quit: Computer has gone to sleep.]
aegis3121 has joined #ruby
zacstewart has quit [Ping timeout: 250 seconds]
Devalo has joined #ruby
zacstewart has joined #ruby
jaguarmagenta has joined #ruby
the_drow has quit [Read error: Connection reset by peer]
ponga has quit [Quit: Connection closed for inactivity]
jaguarmagenta has quit [Ping timeout: 265 seconds]
cdg has joined #ruby
truenito has quit [Ping timeout: 265 seconds]
Pupeno has quit [Remote host closed the connection]
the_drow has joined #ruby
tomphp has quit [Read error: Connection reset by peer]
bob434 has joined #ruby
LuckyABA has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
replay has quit [Ping timeout: 244 seconds]
soulisson has quit [Quit: Quitte]
fullofcaffeine has quit [Remote host closed the connection]
Guest43 has joined #ruby
Guest43 has joined #ruby
Guest43 has quit [Changing host]
Guest43 is now known as Rufus
fullofcaffeine has joined #ruby
futilegames has joined #ruby
GreatSUN has quit [Quit: Page closed]
tyang has quit [Ping timeout: 255 seconds]
codelogix has quit [Ping timeout: 276 seconds]
<fbt>
So. I want my mainloop in a script to wait for data input from threads. What is the best way to do that? So far I have a script that just checks a global hash all the time, but that's obviously far from ideal
<Johne>
how do i determine if a hash exists or not? .empty? isnt doing it for me
whathapp_ has joined #ruby
bauruine has joined #ruby
<toertore>
Johne: provide more context
<Johne>
Hash["a" => 100, "b" => 200].empty?
whathappens has quit [Ping timeout: 240 seconds]
<Johne>
returns false
<aegis3121>
Seems...correct?
<dminuoso>
Johne: What exactly are you trying to do?
<Johne>
so lets say i do this Hash["a" => 100, "b" => 200][0].empty?
<Johne>
I get an error
<dminuoso>
?xy
<ruby[bot]>
it seems like you are asking for a specific solution to a problem, instead of asking about your problem. This often leads to bad solutions and increases frustration for you and those trying to help you. More: http://meta.stackexchange.com/a/66378
Rajamaa has quit [Quit: Konversation terminated!]
<dminuoso>
Johne: Provide more context still.
<dminuoso>
Or gist the whole thing.
<aegis3121>
A gist of your console after trying all of these would probably be most helpful.
vqrs has quit [Ping timeout: 265 seconds]
nankyokusei has joined #ruby
_mross has quit [Read error: Connection reset by peer]
postmodern has joined #ruby
vqrs has joined #ruby
SeepingN has quit [Quit: The system is going down for reboot NOW!]
<baweaver>
Now what happens when Hash can't find a key?
<matthewd>
Also #to_proc
<Radar>
It'll find the default value.
<baweaver>
which is a block
<Radar>
matthewd: #touche
<baweaver>
Now what happens if someone were to put a lambda in there?
<Radar>
Hey I accented that e!
artisangoose has joined #ruby
Guest38 has joined #ruby
<baweaver>
Check that gist, and be afraid
beauby has quit [Read error: Connection reset by peer]
<baweaver>
matthewd: you too, it's fun
bronson has quit [Ping timeout: 252 seconds]
horst has joined #ruby
redpants has joined #ruby
<baweaver>
I'll probably make another version that treats it like a tree search, returning a hash with only matching nodes
fullofcaffeine has quit [Remote host closed the connection]
Jon30 has joined #ruby
minimalism has joined #ruby
<Radar>
neat as
polishdub has quit [Quit: Leaving]
<Jon30>
hey guys, i have a string with this unicode hexidecimal 0x2013 which is basically a non default dash character, but when it tries to output it in html file, it gives me some weird characters –
<Jon30>
how can I correct it so it display the dash?
fullofcaffeine has joined #ruby
<Jon30>
--instead of the strange characters
<matthewd>
Jon30: What's actually in the string? And what are you doing with it at the moment?
<elomatreb>
Jon30: Check if your web server serves the HTML file with the correct encoding
<ruby[bot]>
baweaver: # => stack level too deep (SystemStackError) ...check link for more (https://eval.in/650463)
beauby has joined #ruby
<baweaver>
later it is then
<elomatreb>
heh
<Jon30>
elomatreb: I am saving it as a file, and then also saving it to MySQL database, Rails API then outputs it as those weird characters
jackjackdripper has joined #ruby
<elomatreb>
Jon30: These "weird characters" are your Unicode dash, just interpreted as a different character encoding (Most likely something like ISO8859-*)
<elomatreb>
You have to ensure that the encoding of your database, your file, and the transport are correct
<Jon30>
hmm I found this htmlentities gem, hopefully it will resolve it.
rnda has quit [Ping timeout: 260 seconds]
bronson has joined #ruby
<elomatreb>
That's another solution, but if you have encoding errors, you really should look into what causes them, as it can be hard to fix if your data gets corrupted
Bellthoven has joined #ruby
ur5us has quit [Read error: No route to host]
ur5us has joined #ruby
cschneid_ has quit [Remote host closed the connection]
Bellthoven has quit [Client Quit]
<Jon30>
elomatreb: I am fetching this text from another API - a very old one
<Jon30>
htmlentities doesn't seem to be fixing the problem with those specific characters
beauby has quit [Read error: Connection reset by peer]
<elomatreb>
Assuming it's a HTTP API, take a look at the headers sent by the API and check the Content-Type header
theery has joined #ruby
pragmaticus has quit [Ping timeout: 265 seconds]
Bellthoven has joined #ruby
<elomatreb>
Maybe you can transcode to get proper UTF8 on your side
the_drow_ has joined #ruby
the_drow has quit [Read error: Connection reset by peer]
bronson_ has joined #ruby
bronson has quit [Ping timeout: 252 seconds]
fnovd has joined #ruby
maloik has quit [Remote host closed the connection]
maloik has joined #ruby
OnyxRaven has quit [Quit: OnyxRaven]
AlphaAtom has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
fnovd has quit [Client Quit]
beauby has joined #ruby
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
LuckyABA has joined #ruby
craigp has quit [Ping timeout: 264 seconds]
nankyokusei has joined #ruby
blackmesa has quit [Ping timeout: 255 seconds]
JakFrist[WVU] has joined #ruby
prawnzy has quit [Remote host closed the connection]
ur5us has quit [Ping timeout: 265 seconds]
bronson_ has quit [Ping timeout: 252 seconds]
gnufied has quit [Quit: Leaving]
theery has quit [Remote host closed the connection]
nankyokusei has quit [Ping timeout: 252 seconds]
elastix has joined #ruby
bronson has joined #ruby
LoneHerm_ has joined #ruby
theery has joined #ruby
brendan- has joined #ruby
elastix has quit [Client Quit]
bronson has quit [Ping timeout: 252 seconds]
arnonhongklay has joined #ruby
prawnzy has joined #ruby
LoneHerm_ has quit [Ping timeout: 252 seconds]
icarus has quit [Read error: Connection reset by peer]
AnarchyAo has quit [Ping timeout: 265 seconds]
bronson has joined #ruby
bob434 has joined #ruby
the_drow_ has quit [Quit: This computer has gone to sleep]
maddmaxx_ has quit [Quit: Going offline, see ya! (www.adiirc.com)]
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
coolboy has quit [Ping timeout: 260 seconds]
hutch34 has joined #ruby
Guest87605 has quit [Quit: Quit]
D9 has joined #ruby
tubuliferous has joined #ruby
nofxx has joined #ruby
bronson has quit [Ping timeout: 252 seconds]
bronson_ has joined #ruby
Guest38 has quit [Read error: Connection reset by peer]
JeanCarloMachado has quit [Ping timeout: 260 seconds]
beauby has quit [Read error: Connection reset by peer]
beauby has joined #ruby
antru has joined #ruby
a7d7p has quit [Quit: a7d7p]
bronson_ has quit [Read error: Connection reset by peer]
bronson has joined #ruby
hutch34 has quit [Ping timeout: 255 seconds]
<fbt>
Well. I have a working panel with two basic modules
<fbt>
Yay
replay has joined #ruby
craigp has joined #ruby
sadin has quit [Remote host closed the connection]
rose__ has joined #ruby
bronson has quit [Ping timeout: 252 seconds]
bronson has joined #ruby
JakFrist[WVU] has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<rose__>
Hi. I'm trying to use Mechanize to download some images from a website, but this website is protected by CloudFlare, and in the Mechanize::get, I always get 503... Someone knows how can I stablish and maintain the connection?
duderono_ has joined #ruby
theery has quit [Remote host closed the connection]
duderonomy has quit [Ping timeout: 272 seconds]
Yzguy has quit [Quit: Zzz...]
ur5us has joined #ruby
demophoon has quit [Disconnected by services]
bronson has quit [Read error: Connection reset by peer]
bronson has joined #ruby
FernandoBasso has quit [Ping timeout: 272 seconds]
beauby has quit [Read error: Connection reset by peer]
beauby has joined #ruby
nitric has quit [Ping timeout: 252 seconds]
nando293921 has quit [Ping timeout: 276 seconds]
bronson has quit [Read error: Connection reset by peer]
bronson has joined #ruby
cdg has quit [Remote host closed the connection]
JeanCarloMachado has joined #ruby
AlexxNica has joined #ruby
koooge has joined #ruby
marxarelli is now known as marxarelli|afk
bronson has quit [Ping timeout: 252 seconds]
bronson_ has joined #ruby
<duderono_>
Trying to run watir-webdriver. When this line runs: browser = Watir::Browser.new
<duderono_>
,it never seems to return. This is first time to run any scripted browser on this macOS computer. So clearly something need to be set up (or dialed down, like security settings or something). Firefox just launches, white page, and nothing. Any specific ideas as to what I could search and read?
A_Drone has joined #ruby
JakFrist[WVU] has joined #ruby
A_Drone has quit [Remote host closed the connection]
nando293921 has joined #ruby
bronson has joined #ruby
bronson_ has quit [Read error: Connection reset by peer]
Robtop__ has joined #ruby
A_Drone has joined #ruby
<rose__>
Hi. I'm trying to use Mechanize to download some images from a website, but this website is protected by CloudFlare, and in the Mechanize::get, I always get 503... Someone knows how can I stablish and maintain the connection?
wldcordeiro has quit [Ping timeout: 244 seconds]
<SeepingN>
duderono_: well it appears to be for browser based testing, so I'd assume you have to feed it a page to load and then directions on what to do