gyre007 has quit [Remote host closed the connection]
emmanuelux has joined #ruby
jurbat has joined #ruby
robert_ has joined #ruby
robert_ has joined #ruby
robert_ has quit [Changing host]
robottinosino has quit [Quit: WeeChat 0.4.0]
lkba has quit [Read error: Operation timed out]
SirRamonGabriel has quit [Remote host closed the connection]
mahmoudi_ has joined #ruby
mahmoudimus has quit [Read error: Connection reset by peer]
mahmoudi_ is now known as mahmoudimus
jlast has quit [Ping timeout: 240 seconds]
shanlar has joined #ruby
emmanuelux has quit [Ping timeout: 256 seconds]
emmanuelux has joined #ruby
jnoob22 has quit [Read error: Connection reset by peer]
gyre007 has joined #ruby
gyre007 has quit [Read error: Connection reset by peer]
gyre007 has joined #ruby
sepp2k has quit [Remote host closed the connection]
ogr has quit [Ping timeout: 248 seconds]
jnoob22 has joined #ruby
darthdeus has quit [Quit: Leaving...]
mixel has joined #ruby
_if_ has joined #ruby
apalmblad has quit [Quit: apalmblad]
_if has quit [Read error: Connection reset by peer]
JZTech101 has joined #ruby
nfk has quit [Quit: yawn]
isern has joined #ruby
benlieb has quit [Quit: benlieb]
stewart_ has quit [Ping timeout: 264 seconds]
stewart_ has joined #ruby
ipalaus has quit [Ping timeout: 276 seconds]
isern is now known as ipalaus
ipalaus has quit [Changing host]
ipalaus has joined #ruby
djwonk has quit [Quit: djwonk]
emmanuelux has quit [Ping timeout: 256 seconds]
emmanuelux has joined #ruby
nopolitica has joined #ruby
robottinosino has joined #ruby
viszu has joined #ruby
Heero has quit [Ping timeout: 245 seconds]
emmanuelux has quit [Remote host closed the connection]
brianpWins has quit [Quit: brianpWins]
lkba has joined #ruby
devoldmx3 has joined #ruby
nettoweb has quit [Quit: nettoweb]
Z_Mass_ has quit [Ping timeout: 256 seconds]
justsee has quit [Ping timeout: 248 seconds]
Z_Mass has quit [Ping timeout: 256 seconds]
daniel_- has quit [Ping timeout: 276 seconds]
devoldmx has quit [Ping timeout: 264 seconds]
bigkm has joined #ruby
beilabs has quit [Ping timeout: 256 seconds]
mattbl has joined #ruby
mikepack has joined #ruby
lewis has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
Cache_Money has quit [Ping timeout: 248 seconds]
arya has quit [Ping timeout: 264 seconds]
ogr has joined #ruby
rubarlion has quit [Remote host closed the connection]
HecAtic has joined #ruby
astomp has joined #ruby
arya has joined #ruby
tylersmith has quit [Remote host closed the connection]
rubarlion has joined #ruby
mercwithamouth has joined #ruby
lyanchih has joined #ruby
Z_Mass has joined #ruby
Z_Mass_ has joined #ruby
beilabs has joined #ruby
DanKnox is now known as DanKnox_away
LennyLinux has quit [Remote host closed the connection]
gyre007 has quit [Remote host closed the connection]
djwonk has joined #ruby
kofno has quit [Remote host closed the connection]
rubarlion has quit [Remote host closed the connection]
rubarlion has joined #ruby
rubarlion has quit [Remote host closed the connection]
blandflakes has quit [Ping timeout: 240 seconds]
blandflakes has joined #ruby
yshh has joined #ruby
krz has joined #ruby
Gooder``` has joined #ruby
bigkm has quit [Quit: Computer has gone to sleep.]
pcarrier_ has quit [Ping timeout: 276 seconds]
Heero has joined #ruby
Heero has joined #ruby
Heero has quit [Changing host]
bigkm has joined #ruby
Gooder`` has quit [Ping timeout: 256 seconds]
beilabs has quit [Ping timeout: 256 seconds]
mikepack has quit [Remote host closed the connection]
pcarrier_ has joined #ruby
ogr has quit [Ping timeout: 248 seconds]
shinobi_one_ has joined #ruby
Kricir has quit [Remote host closed the connection]
pcarrier_ has quit [Client Quit]
shinobi_one_ has left #ruby [#ruby]
banjara has quit [Quit: Leaving.]
DanKnox_away is now known as DanKnox
niklasb has quit [Read error: Operation timed out]
pcarrier_ has joined #ruby
arya has quit [Ping timeout: 252 seconds]
tomsthumb has quit [Quit: Leaving.]
zastern has quit [Remote host closed the connection]
markalanevans has quit [Ping timeout: 264 seconds]
rockets has joined #ruby
osvico has joined #ruby
mattbl has quit [Quit: This computer has gone to sleep]
arya has joined #ruby
fermion has quit [Quit: Computer has gone to sleep.]
DanKnox is now known as DanKnox_away
pcarrier_ has quit [Ping timeout: 264 seconds]
yashshah has joined #ruby
rmillerx has joined #ruby
JZTech101 has quit [Ping timeout: 256 seconds]
bigkm has quit [Quit: Computer has gone to sleep.]
mattbl has joined #ruby
codesoda has quit [Remote host closed the connection]
nopolitica has quit [Quit: Lost terminal]
snearch has quit [Quit: Verlassend]
mercwithamouth has quit [Ping timeout: 240 seconds]
bigkm has joined #ruby
beilabs has joined #ruby
kofno has joined #ruby
tylersmith has joined #ruby
jlast has joined #ruby
mercwithamouth has joined #ruby
prk has joined #ruby
notVert has quit [Read error: Connection reset by peer]
HecAtic has quit [Quit: ³ª°¨]
GeissT has joined #ruby
Hanmac2 has joined #ruby
momomomomo has joined #ruby
r0bgleeson has quit [Ping timeout: 245 seconds]
Hanmac1 has quit [Ping timeout: 256 seconds]
mahmoudimus has quit [Ping timeout: 256 seconds]
tylersmith has quit [Ping timeout: 252 seconds]
jlast has quit [Ping timeout: 256 seconds]
mercwithamouth has quit [Ping timeout: 256 seconds]
nazty has quit [Read error: Connection reset by peer]
Michael_ has quit [Remote host closed the connection]
Vert has joined #ruby
Michael_ has joined #ruby
nignaztic has joined #ruby
fivethreeo has joined #ruby
ogr has joined #ruby
viszu has quit [Quit: Leaving.]
beilabs has quit [Ping timeout: 256 seconds]
Michael_ has quit [Remote host closed the connection]
ttt has joined #ruby
Michael_ has joined #ruby
fivethre1o has quit [Ping timeout: 248 seconds]
chandankumar has joined #ruby
Michael_ has quit [Remote host closed the connection]
johnmilton has quit [Ping timeout: 256 seconds]
Michael_ has joined #ruby
Michael_ has quit [Remote host closed the connection]
Michael_ has joined #ruby
SpUtN1k has joined #ruby
mahmoudimus has joined #ruby
prk has quit [Ping timeout: 276 seconds]
ogr has quit [Ping timeout: 248 seconds]
beilabs has joined #ruby
Michael_ has quit [Remote host closed the connection]
bigkm has quit [Quit: Computer has gone to sleep.]
Michael_ has joined #ruby
mixel has quit [Quit: mixel]
erutan has joined #ruby
<erutan>
join #rdiscount
felixjet_ has joined #ruby
rockets has quit [Remote host closed the connection]
zastern has joined #ruby
erutan has quit [Client Quit]
rubarlion has joined #ruby
pcarrier_ has joined #ruby
tomzx_mac_ has joined #ruby
riddled has joined #ruby
tomzx_mac has quit [Ping timeout: 248 seconds]
tomzx_mac_ is now known as tomzx_mac
Davey has joined #ruby
felixjet has quit [Ping timeout: 248 seconds]
Kudos has quit [Ping timeout: 248 seconds]
nari has joined #ruby
brennanMKE has quit [Remote host closed the connection]
brianherman has joined #ruby
Kudos has joined #ruby
Spooner has quit [Remote host closed the connection]
beilabs has quit [Ping timeout: 256 seconds]
huoxito has quit [Read error: Connection reset by peer]
rypervenche has joined #ruby
SpUtN1k has quit []
<rypervenche>
Are there any modules like Python's SimpleHTTPServer or http.server that can create a small instance of a web server with your current working directory as an index?
riddled has quit [Quit: Leaving]
riddled has joined #ruby
ioNull has quit [Quit: Computer has gone to sleep.]
riddled has quit [Remote host closed the connection]
Ortuna has quit [Quit: Computer has gone to sleep.]
huoxito has joined #ruby
Michael_ has quit [Read error: Connection reset by peer]
Ortuna has joined #ruby
Michael_ has joined #ruby
bionhart has quit [Remote host closed the connection]
Michael_ has quit [Remote host closed the connection]
momomomomo has quit [Quit: momomomomo]
Michael_ has joined #ruby
tomsthumb has joined #ruby
bigkm has joined #ruby
Akuma has quit [Quit: So long sukkas!]
robottinosino has quit [Quit: WeeChat 0.4.0]
prk has joined #ruby
banisterfiend is now known as banister`sleep
Akuma has joined #ruby
Michael_ has quit [Remote host closed the connection]
<_numbers>
someone said i might have to monkey patch to overwrite run_options method of the git provider code (2nd link)
cj3kim has joined #ruby
bradhe has joined #ruby
tylersmith has joined #ruby
AgentWillyWonka has joined #ruby
tylersmith has quit [Ping timeout: 264 seconds]
AgentWillyWonka has quit [Client Quit]
jlast has joined #ruby
carwin has joined #ruby
Ortuna has quit [Quit: Computer has gone to sleep.]
ariedler has quit [Remote host closed the connection]
kofno has quit [Remote host closed the connection]
osvico has quit [Ping timeout: 264 seconds]
djwonk has quit [Quit: djwonk]
timkohrumel has quit [Remote host closed the connection]
Deece has joined #ruby
bradhe has quit [Remote host closed the connection]
<Deece>
I'm using ruby-build to compile ruby 1.9.3 from source. Is there an easy way to package up this build so that others can use it? (on the same architecture & OS)
jlast has quit [Ping timeout: 256 seconds]
hamakn_ has quit [Read error: Connection reset by peer]
hamakn has joined #ruby
bradhe has joined #ruby
lyanchih has quit [Quit: lyanchih]
Myconix has quit [Ping timeout: 248 seconds]
bradhe has quit [Remote host closed the connection]
Z_Mass_ has quit [Ping timeout: 276 seconds]
Z_Mass has quit [Ping timeout: 276 seconds]
_baba_ has quit [Quit: WeeChat 0.4.0]
arya has quit [Ping timeout: 256 seconds]
kobain has quit [Quit: l'unica verità.. è la morte stessa!]
mahmoudimus has quit [Ping timeout: 256 seconds]
dmiller has joined #ruby
Banistergalaxy has quit [Ping timeout: 248 seconds]
arya has joined #ruby
dhruvasagar has joined #ruby
rockets has quit [Ping timeout: 256 seconds]
Banistergalaxy has joined #ruby
zastern has joined #ruby
Z_Mass has joined #ruby
Z_Mass_ has joined #ruby
darkapex has quit [Ping timeout: 240 seconds]
dmiller has quit [Ping timeout: 264 seconds]
SleepLex is now known as Quadlex
virth has quit [Read error: Operation timed out]
darkapex has joined #ruby
iamjarvo has joined #ruby
iamjarvo has quit [Client Quit]
Nimsical has joined #ruby
codesoda has quit [Remote host closed the connection]
<apeiros>
do the union only once and store it if you match against it multiple times
<apeiros>
oh, and the "do something" would obviously be an `if …then`
<relix>
Soliah: thanks, but a construct like that is overkill already, I just need to know if it matches at least one, the #any? method would fit better in that case :)
ARCADIVS has quit [Quit: WeeChat 0.3.8]
<relix>
apeiros: perfect, thanks!
icole has quit [Remote host closed the connection]
elkclone has quit [Ping timeout: 248 seconds]
cha1tanya has quit [Ping timeout: 264 seconds]
pkh has joined #ruby
Spami has quit [Quit: This computer has gone to sleep]
carwin is now known as carwin|afk
lkba has joined #ruby
Coffers has joined #ruby
tonini has quit [Ping timeout: 248 seconds]
dhruvasagar has joined #ruby
bjeanes has joined #ruby
thomasl__ has joined #ruby
workmad3 has joined #ruby
gtuckerkellogg has quit [Ping timeout: 256 seconds]
Inside has joined #ruby
<Sp4rKy>
hi
ephemerian has joined #ruby
ybart has joined #ruby
<Sp4rKy>
which unit test/code coverage tools would you recommend for ruby 1.9(.2) ?
<Sp4rKy>
if it can produce rcov format result, it's even better :)
rburton- has quit [Quit: Leaving...]
<apeiros>
simplecov pretty much replaces rcov
Animawish has quit [Quit: Animawish]
<Sp4rKy>
ok, was my first though
<Sp4rKy>
t
jgrevich has quit [Remote host closed the connection]
dhruvasagar has quit [Ping timeout: 256 seconds]
zigomir has quit [Quit: zigomir]
troessner has joined #ruby
freerobby has joined #ruby
obs has joined #ruby
jlast has joined #ruby
browndawg has quit [Ping timeout: 256 seconds]
Iszak has joined #ruby
freerobby has quit [Ping timeout: 256 seconds]
Kar- has joined #ruby
tonini has joined #ruby
Apocalypse has joined #ruby
ntus1017 has quit [Remote host closed the connection]
bionhart has joined #ruby
senayar has joined #ruby
Apocalypse has quit [Quit: Input/Output Error]
jlast has quit [Ping timeout: 264 seconds]
chandankumar has quit [Ping timeout: 276 seconds]
akells` has joined #ruby
cj3kim has joined #ruby
icole has joined #ruby
LennyLinux has joined #ruby
Apocalypse has joined #ruby
ritek has joined #ruby
elaptics`away is now known as elaptics
zeade has quit [Quit: Leaving.]
dfdf has quit [Remote host closed the connection]
rdark has joined #ruby
akells` has quit [Ping timeout: 264 seconds]
thomasl__ has quit [Ping timeout: 248 seconds]
thomaslee has quit [Ping timeout: 248 seconds]
daniel_- has joined #ruby
dfdf has joined #ruby
slainer68 has joined #ruby
cj3kim has quit [Ping timeout: 264 seconds]
Guest83992 has joined #ruby
slainer6_ has joined #ruby
workmad3 has quit [Ping timeout: 256 seconds]
paranoidsp has joined #ruby
snearch has joined #ruby
gasbakid has joined #ruby
sayan has joined #ruby
bamdad has quit [Quit: bamdad]
icole has quit [Ping timeout: 276 seconds]
slainer68 has quit [Ping timeout: 256 seconds]
thomasle_ has joined #ruby
Guest83992 has quit [Quit: leaving]
dhruvasa1ar has joined #ruby
lkba has quit [Ping timeout: 264 seconds]
stonevil has joined #ruby
dhruvasa1ar has quit [Client Quit]
camilasan has joined #ruby
dhruvasagar has joined #ruby
fixl has joined #ruby
cibs has joined #ruby
chandankumar has joined #ruby
Jackneill has joined #ruby
joonty has joined #ruby
thomaslee_ has joined #ruby
emergion has joined #ruby
tvw has joined #ruby
lkba has joined #ruby
anderson has joined #ruby
pkrzywicki has joined #ruby
bamdad has joined #ruby
Zeeraw has joined #ruby
tylersmith has joined #ruby
khushildep has joined #ruby
dhruvasagar has quit [Remote host closed the connection]
marr has joined #ruby
dhruvasagar has joined #ruby
vlad_sta_ has quit [Remote host closed the connection]
johnkary has quit [Quit: @johnkary]
tylersmith has quit [Ping timeout: 248 seconds]
vlad_starkov has joined #ruby
tonini has quit [Ping timeout: 248 seconds]
DaniG2k1 has joined #ruby
vlad_sta_ has joined #ruby
ckrailo has quit [Quit: Computer has gone to sleep.]
dhruvasagar has quit [Quit: leaving]
Cultofmetatron has quit [Remote host closed the connection]
vlad_starkov has quit [Ping timeout: 256 seconds]
Guest21359 has joined #ruby
ia___ has quit [Quit: ia___]
timmow has joined #ruby
davetherat has quit [Remote host closed the connection]
davetherat has joined #ruby
geordiejim has joined #ruby
lyanchih has quit [Quit: lyanchih]
b0oh has joined #ruby
umren has joined #ruby
aspiers_ has joined #ruby
kil0byte has quit [Remote host closed the connection]
freerobby has joined #ruby
Guest21359 has quit [Quit: leaving]
dhruvasagar has joined #ruby
sleetdrop has joined #ruby
freerobby has quit [Ping timeout: 264 seconds]
stonevil has quit [Remote host closed the connection]
baba has quit [Quit: WeeChat 0.4.0]
yusup has joined #ruby
niceguyjames has joined #ruby
chandankumar has quit [Ping timeout: 256 seconds]
jlast has joined #ruby
Inside has quit [Ping timeout: 240 seconds]
roadt has joined #ruby
mikecmpbll has joined #ruby
lkba has quit [Ping timeout: 264 seconds]
tonini has joined #ruby
<roadt>
hi, is it right to say that " $@, $!, they only can be used in rescue clause" ?
stonevil has joined #ruby
camilasan has quit [Remote host closed the connection]
geordiejim has quit []
camilasan has joined #ruby
Neomex has joined #ruby
Elhu has joined #ruby
<dawkirst>
hi, how can I make an instance of Fixnum negative (i.e. prepend it with a minus symbol)?
<roadt>
dawkirst, yes.
<roadt>
dawkirst, a=1; puts a.class; puts -a
nomenkun has joined #ruby
<dawkirst>
roadt, ok, thanks :)
eploko has joined #ruby
<roadt>
dawkirst, np
Neomex has quit [Client Quit]
jlast has quit [Ping timeout: 264 seconds]
bionhart has quit [Remote host closed the connection]
brtdv has quit [Quit: brtdv]
browndawg has joined #ruby
brtdv has joined #ruby
brtdv has quit [Remote host closed the connection]
brtdv has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
bhaak has quit [Read error: Operation timed out]
icole has joined #ruby
lyanchih has joined #ruby
Heero` has quit [Ping timeout: 256 seconds]
SeySayux has quit [Read error: Connection reset by peer]
Villadelfia has quit [Read error: Connection reset by peer]
rickruby has quit [Remote host closed the connection]
dfdf has quit [Remote host closed the connection]
bhaak has joined #ruby
icole has quit [Ping timeout: 256 seconds]
dfdf has joined #ruby
Spami has joined #ruby
samuel02 has joined #ruby
nari has quit [Ping timeout: 240 seconds]
SeySayux has joined #ruby
Villadelfia has joined #ruby
jurbat has quit [Quit: Computer has gone to sleep.]
yacks has quit [Read error: Operation timed out]
horsey has quit [Read error: Operation timed out]
darthdeus has joined #ruby
umren has quit [Ping timeout: 252 seconds]
tylersmith has joined #ruby
paranoidsp has quit [Read error: Connection reset by peer]
paranoidsp has joined #ruby
sayan has quit [Ping timeout: 264 seconds]
skattyadz has joined #ruby
workmad3 has joined #ruby
tylersmith has quit [Ping timeout: 252 seconds]
Criztian has joined #ruby
tonini has quit [Ping timeout: 248 seconds]
yusup has quit [Quit: Leaving...]
razi has joined #ruby
maasha has joined #ruby
osvico has joined #ruby
MrZYX|off is now known as MrZYX
mjburgess has quit [Ping timeout: 256 seconds]
<maasha>
Funny little problem. I have a script sitting in mydir and the script needs a module mydir/lib/mymodule - I would like to require it by requre 'lib/mymodule', but lib is not in the ruby path?
<maasha>
messing with $: gives problems since I am invoking the script via a symlink.
<bnagy>
maasha: require_relative
Guedes0 has quit [Ping timeout: 246 seconds]
<bnagy>
roadt: no
miclen has quit [Ping timeout: 276 seconds]
<maasha>
bnagy: thanks. just the thing!
<maasha>
funny its not recognized by vim syntax hilight
LBRapid has quit [Ping timeout: 260 seconds]
LBRapid has joined #ruby
<bnagy>
yeah it's 'new', so some old syntax defs don't have it
<bnagy>
you can edit them
dhruvasa1ar has joined #ruby
ananthakumaran1 has joined #ruby
nari has joined #ruby
ananthakumaran1 has quit [Read error: Connection reset by peer]
ananthakumaran1 has joined #ruby
yacks has joined #ruby
<maasha>
bnagy: I know. I'll wait for update though - fiddling with vim syntax is a whole programming language in its own (been there, done that, never again).
DrCode has quit [Ping timeout: 240 seconds]
monkegjinni has joined #ruby
fermion has joined #ruby
freerobby has joined #ruby
ananthakumaran has quit [Ping timeout: 256 seconds]
dhruvasagar has quit [Ping timeout: 264 seconds]
horsey has joined #ruby
swex_ has quit [Read error: Connection reset by peer]
swex has joined #ruby
DrCode has joined #ruby
lkba has joined #ruby
freerobby has quit [Ping timeout: 256 seconds]
rockets has joined #ruby
ggordan has quit [Remote host closed the connection]
zastern has quit [Ping timeout: 276 seconds]
baba has joined #ruby
lyanchih has quit [Ping timeout: 276 seconds]
joshmyers has joined #ruby
Zai00 has joined #ruby
jlast has joined #ruby
[[mandrix]] has quit [Ping timeout: 264 seconds]
b0oh has quit [Quit: Leaving.]
lyanchih has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
`brendan has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
Michae___ has joined #ruby
dhruvasa1ar has quit [Quit: leaving]
dhruvasagar has joined #ruby
icole has joined #ruby
Criztian_ has joined #ruby
chase-work has joined #ruby
Criztian has quit [Read error: Connection reset by peer]
havenwood has quit [Read error: Connection reset by peer]
havenwood has joined #ruby
JohnBat26 has joined #ruby
jlast has quit [Ping timeout: 256 seconds]
Criztian_ has quit [Read error: Connection reset by peer]
Criztian has joined #ruby
havenwood has quit [Read error: Connection reset by peer]
havenwood has joined #ruby
<tvw>
ruby-mode on emacs 24.3: it does not seem to work properly, at least syntax highlighting is broken. With 23.3 it is ok. Any idea or suggestion? And what about ruby 2.0 compatibility (eg. new hash key syntax)?
blaxter_ is now known as blaxter
icole has quit [Ping timeout: 264 seconds]
<Iszak>
tvw ruby 2.0 has new hash key syntax?!
<apeiros>
no, 1.9 has
<tvw>
I mean {hello: "World"}
zigomir has joined #ruby
<apeiros>
yupp, that's 1.9 and years old ;-)
<tvw>
I see.
<Iszak>
Yeah, my linter in sublime text still kicks up a fuss about the new syntax.
davetherat has quit [Remote host closed the connection]
davetherat has joined #ruby
<MrZYX>
however 2.0 uses the same syntax for keyword arguments
mercwithamouth has joined #ruby
<tvw>
For me ruby 1.9 was always the development version for ruby 2.0 ;-)
<MrZYX>
Iszak: try SublimeLinter, that just invokes ruby -wc so it's always up to date
<MrZYX>
2.0 has more experimental stuff than 1.9
gasbakid_ has joined #ruby
<Iszak>
MrZYX problem is, my system ruby is 1.8.x
lyanchih has quit [Quit: lyanchih]
<MrZYX>
time to upgrade
<Iszak>
MrZYX it's mac.
lemonsparrow has quit [Quit: Page closed]
<MrZYX>
so?
<MrZYX>
there are tons of solutions to get a newer ruby on every system there is
<Iszak>
I can't upgrade the system ruby, I have 1.9 but it's prefixed like ruby1.9
<tvw>
But anyway: do you have issues with emacs 24.3 and ruby-mode?
<skroon>
when writing a gem, I would like to open up a file for reading, however when including this gem into my rails project for example, I've got a feeling that it's trying to read it from the PWD of the application server.
lkba has quit [Ping timeout: 264 seconds]
<krnflake>
the gem is just a wrapper
lewis has joined #ruby
<skroon>
is there a way to always open up files for reading, from their correct GEM_PATH dir?
<apeiros>
skroon: Gem.data_dir can help, iirc
SeySayux has quit [Ping timeout: 252 seconds]
pcarrier_ has joined #ruby
<skroon>
apeiros: thanks
roadt_ is now known as roadt
lushious has quit [Quit: "#YOLOLO"]
sailias has joined #ruby
aboudreault has joined #ruby
chandankumar has joined #ruby
kil0byte has joined #ruby
icole has quit [Ping timeout: 264 seconds]
<roadt>
bnagy, i just com back. tks for the short answer. i have several try with coding test and finally got the point..
kiri has quit [Ping timeout: 240 seconds]
Zeeraw has quit [Quit: Computer has gone to sleep.]
paranoidsp has quit [Remote host closed the connection]
<joshu>
this is one method. does it make sense to move the tiff2pdf conversion to its own method even though I only do the conversion within this one method fax_sent? also maybe move the json bit to its own method as I do almost the same json loading in another method called fax_failed with one or two differences?
<apeiros>
joshu: use more methods
arya has quit [Ping timeout: 264 seconds]
locriani has quit [Remote host closed the connection]
<apeiros>
e.g. throw the subprocess call into a separate method
<apeiros>
throw the mail sending into its own method
monkegjinni has joined #ruby
<apeiros>
abstract from where you get the mail data (should not access ENV in library level code)
<joonty>
yep, agreed with apeiros
<joonty>
come up with a personal max number of lines for a method, e.g. 5 or 6 lines
lyanchih has quit [Quit: lyanchih]
<apeiros>
place that in-code comment either above the method (so it becomes method documentation) or remove it
<joonty>
then split up logically related code into methods
<apeiros>
or put it into an external doc file
thomasle_ has quit [Remote host closed the connection]
<apeiros>
(referring to the "Mail to process" comment, sorry)
sailias has joined #ruby
<joshu>
ok lots of things here. let me ask about each of your comments for clarification
DaniG2k has quit [Read error: No route to host]
<apeiros>
joshu: also you can rewrite the tiff2pdf call to not use a tempfile
DaniG2k has joined #ruby
<joshu>
so methods should in general be very short, e.g. 5-6 lines?
<joonty>
joshu: it makes it easier for the reader
<apeiros>
methods should do one thing
<joonty>
if you give them human-readable names, then you can see what they do without having to read the code
<apeiros>
I'm no fan of the "must be less than X lines", but it can help as a raised flag
<joshu>
I see. Good advice apeiros joonty!
sambao21 has joined #ruby
<apeiros>
i.e., a long method probably does more than one thing
<joonty>
apeiros: yeh I agree, should be a guideline not a law
<apeiros>
agreed
<apeiros>
blerp, bundler being superslow today…
* apeiros
wonders whether our proxy, rubygems.org or bundler itself is at fault…
<joshu>
so even if a method such as the tiff conversion is only used throughout my ruby script once, e.g within fax_sent you still move it for clarity and one-thing mind-set
<apeiros>
joshu: yes
<apeiros>
it makes it easier to a) test your code, b) read your code, and c) reason about your code
<joshu>
apeiros how can I rewrite the conversion not to use a temp file? I tried passing stdin, but tiff2pdf apparently needs to be passed the file path
Myconix has joined #ruby
<apeiros>
joshu: most tools accept '-' as file param, which makes them use stdin
<Myconix>
DOes anyone have experience making VSTs with Ruby?
MrZYX|off is now known as MrZYX
arya has joined #ruby
<apeiros>
Myconix: very large telescopes?
<apeiros>
sure
<apeiros>
I made *lots* of them
<Myconix>
VST, not VLT
<Myconix>
Virtual Studio Technology
<apeiros>
meh, my fault
<joshu>
hehe
<Myconix>
i think
<apeiros>
I meant VLT Survey Telesopes
<joonty>
apeiros: bundler seems fine for me, using rubygems.org
Neomex has joined #ruby
<Myconix>
yeah, that's it
aspiers has quit [Ping timeout: 252 seconds]
<joshu>
so apeiros I would call tiff2pdf -STDIN ? let me try that on the terminal
<Myconix>
anyone have experience with them in Ruby>
<apeiros>
joshu: no, just -
<apeiros>
tiff2pdf -
<joshu>
apeiros ok testing now
<joonty>
gotta love ruby
ldnunes has joined #ruby
fridim_ has joined #ruby
Raboo has quit [Ping timeout: 264 seconds]
kiri has joined #ruby
Raboo has joined #ruby
Xeago has quit [Remote host closed the connection]
<joshu>
apeiros doesn't seem to work
lkba has joined #ruby
Neomex has quit [Client Quit]
<joshu>
apeiros TIFFOpen: -: No such file or directory.
<joshu>
tiff2pdf: Can't open input file - for reading.
fridim_ has quit [Remote host closed the connection]
<joshu>
I don't think that tiff2pdf has this functionality
<apeiros>
evil
Raboo has quit [Client Quit]
Elhu has quit [Quit: Computer has gone to sleep.]
<apeiros>
and/or lame
<apeiros>
I opt for 'and'
tylersmith has joined #ruby
<apeiros>
I'd probably file that as a bug :)
<joshu>
so I have to use temp file for the conversion
<joshu>
hehe
<apeiros>
might still be able to use the filedescriptor of a pipe. but that's already a lot uglier.
<MrZYX>
or find a ruby binding to a lib that does it
krz has quit [Quit: krz]
<joshu>
I'll just leave that as it is but move it into its own method.
<joshu>
apeiros you said "throw the mail sending into its own method" you mean the whole mail = Mail.new do block including mail.deliver? If so I understand that you shouldn't repeat yourself. In my case I have 4 methods that have a similar mail sending block, but all the parameters within are very different. Some are set directly as in body "hello body" whereas others are read from local variables. So what I'm getting at is not much I can do not to
<joshu>
have 4 new mail sending methods that vary slighty, correct?
ttt_ has quit [Remote host closed the connection]
lkba has quit [Ping timeout: 264 seconds]
<mercwithamouth>
hi, what would you say would be the best framework for JUST writing a web based API?
tylersmith has quit [Ping timeout: 256 seconds]
<mercwithamouth>
i'm looking at rails-api, sinatra and grape
<apeiros>
joshu: you don't repeat yourself
shevy has joined #ruby
<shevy>
hey
<apeiros>
but it shows you what information you should want to store in your object
bamdad has quit [Quit: bamdad]
rippa has joined #ruby
<apeiros>
and it might tell you where you want classes
<joonty>
mercwithamouth: depends on your needs
sambao21 has quit [Quit: Computer has gone to sleep.]
<apeiros>
and no, you'd have 1 mail sending method which takes values from self (ivars) and/or arguments
niceguyjames has joined #ruby
<joonty>
if you're going to have lots of entry points for your api then rails is a good choice
<mercwithamouth>
hrmm joonty i'm notsure...a web based api...i have absolutely no need for templating, etc...i'm doing that 100% with angularjs
samuel02 has quit [Remote host closed the connection]
<joonty>
if it's going to be pretty small in scope then sinatra
<mercwithamouth>
hmmm how so?
ntus1017 has joined #ruby
<joonty>
rails has a convention for splitting out controllers and actions, which you can map to api actions
samuel02 has joined #ruby
pagios has joined #ruby
<joonty>
plus so many people use it that you're more likely to find help
<mercwithamouth>
i suppose i'm much more familiar with rails opposed to sinatra...
horsey has quit [Read error: Connection reset by peer]
samuel02 has quit [Read error: Connection reset by peer]
horsey_ has joined #ruby
DaniG2k has quit [Quit: Leaving.]
<joonty>
and rails actually does a lot for you security wise, header processing, routing, blah blah
<mercwithamouth>
rails-api gem it is....i was leaning that way. I'll do the opposite of what i usually do and cut my 'pondering' to two minutes
<joshu>
apeiros ok this is getting complicated. You also wrote "abstract from where you get the mail data (should not access ENV in library level code)" the reason i'm using a dotenv file is so that those email addresses etc are not used within the code and can be changed easily if needed.
samuel02 has joined #ruby
<mercwithamouth>
joonty: that's true...
<mercwithamouth>
rails-api...
<joonty>
mercwithamouth: cool
<joonty>
good luck
machuga|away is now known as machuga
<apeiros>
joshu: give me a minute.
<apeiros>
bundler is slow today, so you're lucky :-p
<joshu>
apeiros hehe no worries
daniel_- has quit [Ping timeout: 252 seconds]
LanaDelRey has joined #ruby
nettoweb has quit [Read error: Connection reset by peer]
iamjarvo has joined #ruby
Michae___ has joined #ruby
nettoweb has joined #ruby
dr_bob has quit [Quit: Leaving.]
persand_ has joined #ruby
samuel02 has quit [Ping timeout: 248 seconds]
Zeeraw has joined #ruby
huoxito has joined #ruby
Mattx has joined #ruby
mikecmpbll has joined #ruby
zastern has joined #ruby
snuglepuss has joined #ruby
persand has quit [Ping timeout: 264 seconds]
persand_ is now known as persand
<pagios>
hello, is this code enough to generate warning messages in a ruby script? do i need to initialize it or that is enough? http://pastebin.com/M18cFgRY
heftig has quit [Quit: Quitting]
<MrZYX>
what's "generate a warning message"?
heftig has joined #ruby
Michae___ has quit [Ping timeout: 264 seconds]
<shevy>
bundler is only slow today?
Zai00 has joined #ruby
Matip has quit [Ping timeout: 252 seconds]
<pagios>
MrZYX: i mean wiill that code write to the log.txt if any warnings are encountered when code is executed?
<MrZYX>
like warning from ruby?
<MrZYX>
for example if you assign a value to a constant a second time?
wallerdev has joined #ruby
rockets has quit [Ping timeout: 256 seconds]
jtza8 has joined #ruby
<pagios>
yes any kind of warnings
horsey_ has quit [Ping timeout: 248 seconds]
<MrZYX>
no
<apeiros>
joshu: hm, your method name is misleading… "fax_sent" - why that name?
<pagios>
what is missiing?
yalue has joined #ruby
<MrZYX>
it's not even remotely related to that, your code opens/creates log.txt, ensures that only calls to log.warn would be written to it, if there would be any, and then exists
<MrZYX>
*exits
<joshu>
apeiros right so my ruby script deals with 4 types of incoming emails, processes them according to their type and creates new emails which are sent off. the four types of email are fax_send, fax_sent, fax_failed, fax_received
<pagios>
ok so the missing part is to catch the rror and write it to the log
<MrZYX>
(well, and calls to log.error and log.fatal)
<joshu>
apeiros I've just named them that way cause it made sense to me as fax_send means user is sending a fax. fax_sent, fax_failed and fax_received are 3 different notifications from the fax system indicating as their names suggest what has happened
ipalaus has quit [Ping timeout: 252 seconds]
<shevy>
http://pastie.org/pastes/7973947/text <-- is there a way to call the parent method, when it has the same name, without putting it into a module?
freerobby has joined #ruby
<MrZYX>
pagios: I guess you want to reopen $stderr
devoldmx has joined #ruby
pcarrier_ has quit [Quit: Computer has gone to sleep.]
<MrZYX>
but that'll catch errors too
rton has joined #ruby
<pagios>
MrZYX: what i am experiencing is when i run a ruby script from command line it works fine, if i run it in crontab @reboot time it fails, i would like to catch the source of this failure and store it in a logfile so i check it once the system boots up
<MrZYX>
I'd just redirect stdout and stderr then
<MrZYX>
ruby bla.rb 2>&1 > /tmp/bla.log
<pagios>
exactly, it doesnt output anything, tried that ruby myapp &> /tmp/log.txt
<joshu>
aperios wow that's a whole different level from my code
<apeiros>
MrZYX: Kernel methods should be private too
heftig has joined #ruby
<apeiros>
also, all methods in Kernel should be module_function's
<shevy>
MrZYX: problem is, if I put it into a module, I need to include that module. given that I use this tiny method in like 50 different .rb files that seems extra work
<apeiros>
any non-private "global" method belongs into Object
<apeiros>
shevy: see module_function
<joshu>
I'm don't have the ruby knowledge at this time to refactor my code like that.
persand has quit [Read error: Connection reset by peer]
<MrZYX>
pagios: yup, you create a logger object and just don't use it
<pagios>
running it from command line it works fine
<MrZYX>
if you install htop and turn on the tree view it's more obvious
Elhu has joined #ruby
<MrZYX>
guess root's path $PATH isn't properly set up
rippa has quit [Ping timeout: 240 seconds]
<MrZYX>
running ruby apps as root is scary anyway
umren has joined #ruby
<MrZYX>
especially for things that listen for network connections
<pagios>
MrZYX: you mean $PATH didnt have the time to load when running the cronjob?
HelenCrowley has joined #ruby
<MrZYX>
no
<MrZYX>
I mean it's just missing the directory where ifconfig resides
<pagios>
ok
jtza8 has quit [Ping timeout: 264 seconds]
<pagios>
i will try to include the full path
`brendan has joined #ruby
samuel02 has joined #ruby
zetaspartan2552 has joined #ruby
HelenCrowley has quit [Client Quit]
jtza8 has joined #ruby
<MrZYX>
joshu: methods have an implicit begin at the start, so you can just use rescue and ensure at the end
pyro111 has quit [Quit: Leaving]
pcarrier_ has joined #ruby
JustinAiken has joined #ruby
<joshu>
MrZYX ok thanks ;)
LanaDelRey has quit [Ping timeout: 252 seconds]
jlast has quit [Ping timeout: 248 seconds]
rippa has joined #ruby
<MrZYX>
apeiros: but wouldn't it fail in this case if the command already fails and file_to_convert is never created?
samuel02 has quit [Remote host closed the connection]
Doc_X_ has quit [Remote host closed the connection]
ybart_ has joined #ruby
ybart has quit [Ping timeout: 264 seconds]
ybart_ is now known as ybart
tomzx_mac has joined #ruby
whitedawg has joined #ruby
ybart has quit [Read error: Connection reset by peer]
milestone has joined #ruby
bamdad has joined #ruby
DaniG2k has joined #ruby
jlast has joined #ruby
tylersmith has joined #ruby
DestinyAwaits has joined #ruby
daniel_- has joined #ruby
ybart has joined #ruby
DaniG2k has quit [Client Quit]
dhruvasagar has quit [Ping timeout: 248 seconds]
ayaz has joined #ruby
wallerdev has quit [Quit: wallerdev]
Zai00 has quit [Read error: Connection reset by peer]
pcarrier_ has quit [Ping timeout: 256 seconds]
Cyrus has quit [Quit: Cyrus.sleep()]
DaniG2k has joined #ruby
tylersmith has quit [Ping timeout: 256 seconds]
jlast has quit [Ping timeout: 276 seconds]
arya has quit [Ping timeout: 276 seconds]
riddled has joined #ruby
Doc_X has joined #ruby
Doc_X has quit [Remote host closed the connection]
Zai00 has joined #ruby
Doc_X has joined #ruby
pcarrier_ has joined #ruby
<joshu>
MrZYX really odd but if I skip the begin I get an error within sublime text editor as well as in the terminal when I run the code."syntax error, unexpected keyword_end, expecting end-of-input"
<joshu>
as soon as I add begin it works
<MrZYX>
inside a method?
yacks has joined #ruby
<MrZYX>
also do not duplicate the end
<MrZYX>
def rescue ensure end
adkron_ has quit [Read error: Connection reset by peer]
<joshu>
in the method which apeiros wrote tiff2pdf. one sec let me gist it
<MrZYX>
not def rescue end ensure end end or something like that
mr_pause has joined #ruby
<mr_pause>
Hello
Hanmac has quit [Read error: Connection reset by peer]
<pagios>
ok so if i execute a command in a fork and dont exit properly, that could create that zombie?
<ericwood>
yes
<ericwood>
the only way to kill it will be to decapitate it
<joonty>
the parent process should wait for the child to exit, to stop this happening
Uranio has joined #ruby
<hoelzro>
a zombie process occurs if you don't wait() for a process or have SIGCHLD = ignore handler
beilabs has quit [Ping timeout: 256 seconds]
matchaw has joined #ruby
cofin has quit [Client Quit]
shevy has quit [Remote host closed the connection]
<ericwood>
tl;dr you have to try pretty hard to shoot yourself in the foot on that one :)
cofin has joined #ruby
blaxter has quit [Ping timeout: 276 seconds]
milestone has quit [Quit: milestone]
tommyvyo has joined #ruby
miclen has joined #ruby
bal has joined #ruby
devoldmx has quit [Read error: Connection reset by peer]
devoldmx has joined #ruby
ayaz has quit [Ping timeout: 264 seconds]
ffio_ has quit [Quit: WeeChat 0.4.0]
jtza8 has quit [Ping timeout: 252 seconds]
locriani has joined #ruby
rgrinberg has quit [Quit: WeeChat 0.4.0]
locriani has quit [Remote host closed the connection]
locriani has joined #ruby
Coolhand has quit [Read error: Connection reset by peer]
davetherat has quit [Ping timeout: 252 seconds]
ipalaus has joined #ruby
icole has joined #ruby
splittingred has joined #ruby
jtza8 has joined #ruby
yshh has joined #ruby
arya has quit [Ping timeout: 276 seconds]
locriani has quit [Remote host closed the connection]
drodicus has left #ruby [#ruby]
sebastiansier has joined #ruby
locriani has joined #ruby
threesome has quit [Ping timeout: 264 seconds]
rgrinberg has joined #ruby
jgarvey has joined #ruby
awarner has joined #ruby
jnoob22 has quit [Remote host closed the connection]
Coolhand has joined #ruby
beilabs has joined #ruby
<apeiros>
MrZYX: yes, it would fail in that case
generalissimo has joined #ruby
arya has joined #ruby
<apeiros>
MrZYX: but the only lines which could fail are `cmd = %W[tiff2pdf -p A4 -c FFM -t #{@timestamp}]` and `file_to_convert = Tempfile.new('ffm')`
<MrZYX>
yeah
<apeiros>
i.e., none which should be able to fail at runtime
<MrZYX>
just curious: why did you use both class << self and def self ?
<apeiros>
class << self because I can't use attr_* without
icole has quit [Ping timeout: 256 seconds]
<apeiros>
and def self because that's how I do it otherwise. easier to grep for self.
<MrZYX>
hmkay
codecop_ has quit [Remote host closed the connection]
Lubinski has joined #ruby
<apeiros>
I'd love if ruby had class_attr_* for that
<MrZYX>
I'd argue you have to grep for << self anyway but personal preference I guess
locriani has quit [Read error: Connection reset by peer]
<apeiros>
then I could get rid of pretty much 100% of all `class << self` in my code
locriani has joined #ruby
jtharris has joined #ruby
<apeiros>
um, grepping for << self won't be of much use
<apeiros>
since the line containing it is unlikely to also contain the definition
ananthakumaran1 has quit [Quit: Leaving.]
<joonty>
MrZYX: grep -r "def self.a_method" .
aspiers has joined #ruby
pipework has joined #ruby
freerobby has joined #ruby
<MrZYX>
oh, I thought the point being finding all class methods or something like that
<apeiros>
the point is to find a specific class method
<MrZYX>
kk
<DestinyAwaits>
a recursive search that is what -r is
<apeiros>
though, granted, nowadays I usually open pry and do `$ foo.name`
rickruby has joined #ruby
<MrZYX>
joonty: DestinyAwaits I know, I even have an alias on -rin ;)
jlast has joined #ruby
<DestinyAwaits>
ah ok
<DestinyAwaits>
:)
<joonty>
i like grep with -a and -b as well, get some context
<DestinyAwaits>
joonty: -c ?
locriani has quit [Remote host closed the connection]
<joonty>
DestinyAwaits: indeed!
<DestinyAwaits>
:)
<DestinyAwaits>
I like -c better somwtimes
riddled has quit [Quit: Leaving]
alanp_ has joined #ruby
<pagios>
-/join #linux
<joonty>
i guess this should all go in #grepappreciation
milestone has joined #ruby
alanp_ has quit [Remote host closed the connection]
<DestinyAwaits>
hehe
banister`sleep has joined #ruby
gaahrdner has joined #ruby
arya_ has joined #ruby
umren has quit [Ping timeout: 276 seconds]
pkh has quit [Quit: Leaving]
aspiers has quit [Ping timeout: 240 seconds]
mad_hatter_ has joined #ruby
l33 has joined #ruby
arya has quit [Ping timeout: 248 seconds]
jnoob22 has joined #ruby
Macaveli has quit [Ping timeout: 250 seconds]
ariedler has joined #ruby
milestone has quit [Ping timeout: 256 seconds]
rickruby has quit [Remote host closed the connection]
icole has joined #ruby
tundrax has joined #ruby
paul_ has quit [Quit: leaving]
banister`sleep has quit [Remote host closed the connection]
browndawg has quit [Quit: Leaving.]
adkron_ has joined #ruby
solidoodlesuppor has joined #ruby
rickruby has joined #ruby
hogeo has quit [Remote host closed the connection]
aspiers has joined #ruby
threesome has joined #ruby
adkron has quit [Ping timeout: 256 seconds]
tylersmith has joined #ruby
phantasm66 has joined #ruby
phantasm66 has quit [Changing host]
phantasm66 has joined #ruby
tomzx_mac has quit [Ping timeout: 264 seconds]
nezumi has quit [Ping timeout: 240 seconds]
viszu has quit [Ping timeout: 276 seconds]
Azulinho has joined #ruby
jtza8 has quit [Ping timeout: 248 seconds]
adkron has joined #ruby
wolcanus has joined #ruby
jtza8 has joined #ruby
ybart_ has joined #ruby
ybart has quit [Ping timeout: 256 seconds]
ybart_ is now known as ybart
tylersmith has quit [Ping timeout: 240 seconds]
jtza8 has quit [Client Quit]
adkron_ has quit [Ping timeout: 256 seconds]
kil0byte has quit [Remote host closed the connection]
sayan has quit [Read error: Connection reset by peer]
beilabs has quit [Ping timeout: 248 seconds]
banister`sleep has joined #ruby
akells` has joined #ruby
anonymuse has joined #ruby
banister`sleep is now known as banisterfiend
banisterfiend is now known as banister`shop
monkegji_ has joined #ruby
Yakko has joined #ruby
monkegj__ has joined #ruby
baroquebobcat has joined #ruby
ffranz has joined #ruby
monkegjinni has quit [Read error: Connection reset by peer]
nettoweb has quit [Read error: Connection reset by peer]
staafl has quit [Read error: Connection reset by peer]
Hanmac has joined #ruby
miclen has quit [Ping timeout: 256 seconds]
whitedawg has quit [Read error: Connection reset by peer]
Hanmac2 has quit [Ping timeout: 264 seconds]
staafl has joined #ruby
krawchyk_ has quit [Remote host closed the connection]
ioNull has quit [Quit: Computer has gone to sleep.]
_nitti has joined #ruby
staafl has quit [Read error: Connection reset by peer]
whitedawg has joined #ruby
krawchyk has joined #ruby
whitedawg has quit [Client Quit]
staafl has joined #ruby
staafl has quit [Read error: Connection reset by peer]
staafl has joined #ruby
ephemerian has quit [Ping timeout: 248 seconds]
aspiers has quit [Read error: Connection reset by peer]
adkron has joined #ruby
beilabs has quit [Ping timeout: 256 seconds]
monkegjinni has joined #ruby
philcrissman has quit [Remote host closed the connection]
mvangala_ has joined #ruby
ia___ has joined #ruby
jlast_ has joined #ruby
wallerdev_ has joined #ruby
Zolo_ has joined #ruby
Doc_X_ has joined #ruby
marcgg_ has joined #ruby
slainer68 has joined #ruby
fivethre1o has joined #ruby
monkegj__ has quit [Ping timeout: 256 seconds]
Spaceghost|work has joined #ruby
nettoweb_ has joined #ruby
momomomomo has joined #ruby
nettoweb has quit [Ping timeout: 264 seconds]
nettoweb_ is now known as nettoweb
Z_Mass has joined #ruby
Spaceghost|work is now known as pipework_
pcarrier_ has joined #ruby
mad_hatter_ has quit [Quit: Leaving.]
pipework has quit [Disconnected by services]
pipework_ is now known as pipework
roadt has quit [Ping timeout: 256 seconds]
Z_Mass_ has joined #ruby
n1x has joined #ruby
Azulinho_ has joined #ruby
airtonix_ has joined #ruby
jayne has quit [Write error: Connection reset by peer]
jlast has quit [Write error: Connection reset by peer]
wallerdev has quit [Write error: Connection reset by peer]
mvangala has quit [Write error: Connection reset by peer]
wallerdev_ is now known as wallerdev
jayne| has joined #ruby
iaj has quit [Write error: Connection reset by peer]
Doc_X has quit [Write error: Connection reset by peer]
carloslopes has quit [Remote host closed the connection]
jurbat has quit [Ping timeout: 249 seconds]
Azulinho has quit [Ping timeout: 249 seconds]
maz-dev has quit [Ping timeout: 249 seconds]
slainer6_ has quit [Ping timeout: 249 seconds]
yacks has quit [Ping timeout: 249 seconds]
rgardh has quit [Ping timeout: 249 seconds]
error404_ has joined #ruby
brtdv has quit [Ping timeout: 249 seconds]
sivoais has quit [Ping timeout: 249 seconds]
nhhagen has quit [Ping timeout: 249 seconds]
tedwards_ has quit [Ping timeout: 249 seconds]
fivethreeo has quit [Ping timeout: 249 seconds]
ziprar has quit [Ping timeout: 249 seconds]
blandflakes has quit [Ping timeout: 249 seconds]
caveat- has quit [Ping timeout: 249 seconds]
marcgg has quit [Ping timeout: 249 seconds]
cyrus_mc_ has quit [Ping timeout: 249 seconds]
Zolo has quit [Ping timeout: 249 seconds]
filipe has quit [Ping timeout: 249 seconds]
guilleiguaran_ has quit [Ping timeout: 249 seconds]
crazedpsyc has quit [Ping timeout: 249 seconds]
QKO has quit [Ping timeout: 249 seconds]
error404 has quit [Ping timeout: 249 seconds]
Nom- has quit [Ping timeout: 249 seconds]
thejoecarroll has quit [Ping timeout: 249 seconds]
cespare has quit [Ping timeout: 249 seconds]
classix has quit [Ping timeout: 249 seconds]
TheMoonMaster has quit [Ping timeout: 249 seconds]
airtonix has quit [Ping timeout: 249 seconds]
dv_ has quit [Ping timeout: 249 seconds]
andrewh has quit [Ping timeout: 249 seconds]
monomyth has quit [Ping timeout: 249 seconds]
Anarch has quit [Ping timeout: 249 seconds]
halfie has quit [Ping timeout: 249 seconds]
nick_h_ has quit [Ping timeout: 249 seconds]
maz-dev_ has joined #ruby
nick_h has joined #ruby
Anarch has joined #ruby
blandflakes has joined #ruby
filipe has joined #ruby
ziprar has joined #ruby
thejoecarroll has joined #ruby
cyrus_mc_ has joined #ruby
monomyth has joined #ruby
andrewh has joined #ruby
Nom- has joined #ruby
noname001 has quit [Excess Flood]
ziprar has quit [Changing host]
ziprar has joined #ruby
crazed- has joined #ruby
pkrzywicki has quit [Excess Flood]
tedwards1 has joined #ruby
cespare_ has joined #ruby
guilleiguaran_ has joined #ruby
nhhagen has joined #ruby
yacks has joined #ruby
sambieri has joined #ruby
QKO has joined #ruby
caveat-_ has joined #ruby
classix has joined #ruby
axekwn has joined #ruby
roadt has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
caveat-_ is now known as caveat-
halfie has joined #ruby
rickruby has quit [Remote host closed the connection]
sivoais has joined #ruby
dv_ has joined #ruby
ananthakumaran has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
TheMoonMaster_ has joined #ruby
crazed- is now known as crazedpsyc
LaPetiteFromage has joined #ruby
LaPetiteFromage has quit [Client Quit]
noname001 has joined #ruby
theRoUS has joined #ruby
theRoUS has joined #ruby
wesside has joined #ruby
banghouse2 has joined #ruby
platzhirsch has quit [Read error: Connection reset by peer]
timkohrumel has joined #ruby
ogr has quit [Ping timeout: 248 seconds]
emptymag00 has joined #ruby
RORgasm_ has joined #ruby
RORgasm has quit [Read error: Connection reset by peer]
<mercwithamouth>
has anyone tried running turn and minitest with ruby 2.0?
atzkey has joined #ruby
iaj has joined #ruby
<mercwithamouth>
i'm getting what seems to be a common turn error complaining about minitest being out of date DESPITE including 'gem "minitest"' in my bundler file
Kar- has quit [Remote host closed the connection]
lkba has joined #ruby
banghouse2 is now known as banghouse
cmarques has joined #ruby
monkegjinni has quit [Read error: No route to host]
monkegji_ has joined #ruby
rhys_ has joined #ruby
timkohrumel has quit [Remote host closed the connection]
beilabs has joined #ruby
devoldmx has quit [Read error: Connection reset by peer]
zigomir has quit [Quit: zigomir]
devoldmx has joined #ruby
pkrzy837 has joined #ruby
spike|spiegel has joined #ruby
velus has joined #ruby
<velus>
hello all if i want to add a php in a rhtml file can i ??
<velus>
or do you have a ruby function to display a current year like the date("Y") function in php
lkba has quit [Ping timeout: 260 seconds]
<velus>
im not a rubi worker but need to for my hosting site
zetaspartan2552 has quit [Quit: leaving]
v0n has joined #ruby
dfdf has joined #ruby
sambieri has quit [Quit: sambieri]
ArchBeOS has joined #ruby
devdazed has quit [Quit: Bye]
ioNull has joined #ruby
ioNull has quit [Max SendQ exceeded]
aspiers has joined #ruby
tagrudev has quit [Remote host closed the connection]
braoru has quit [Quit: Leaving]
ioNull has joined #ruby
seejohnrun has joined #ruby
mikepack has joined #ruby
tomsthumb has quit [Quit: Leaving.]
_nitti_ has joined #ruby
atzkey has quit [Ping timeout: 252 seconds]
devdazed has joined #ruby
snearch has quit [Quit: Verlassend]
ffio has joined #ruby
djwonk has joined #ruby
snearch has joined #ruby
Heero has joined #ruby
Heero has joined #ruby
Heero has quit [Changing host]
ffio has quit [Client Quit]
senayar has quit [Read error: Operation timed out]
nettoweb_ has joined #ruby
nettoweb has quit [Read error: Connection reset by peer]
nettoweb_ is now known as nettoweb
ffio has joined #ruby
Hanmac2 has joined #ruby
johnmilton has joined #ruby
_nitti has quit [Ping timeout: 264 seconds]
ffio has quit [Client Quit]
Todd has joined #ruby
rblackwe has quit [Remote host closed the connection]
megha has joined #ruby
senayar has joined #ruby
rblackwe has joined #ruby
Hanmac has quit [Ping timeout: 264 seconds]
axl__ has quit [Quit: axl__]
freeayu__ has quit [Remote host closed the connection]
cmarques has quit [Ping timeout: 256 seconds]
daniel_- has joined #ruby
beilabs has quit [Ping timeout: 256 seconds]
axl_ has joined #ruby
forrest has joined #ruby
persand has quit [Quit: persand]
axl_ has quit [Client Quit]
noop has quit [Ping timeout: 240 seconds]
coreinfo99 has joined #ruby
timkohrumel has joined #ruby
awarner has quit [Remote host closed the connection]
failshell has joined #ruby
robscomputer has joined #ruby
<velus>
hello is there a date function like the one in php date("Y")so i can have the year of current date put in a rhtml document
lkba has joined #ruby
ogr has joined #ruby
devoldmx has quit [Read error: Connection reset by peer]
devoldmx has joined #ruby
monkegji_ has quit [Read error: Connection reset by peer]
<dpt89>
ok, I will go check the docs, I knew I'd get back in the road soon
Kricir has joined #ruby
dpt89 has quit [Read error: Connection reset by peer]
dpt89 has joined #ruby
RORgasm_ has quit [Read error: Connection reset by peer]
RORgasm has joined #ruby
_nitti has joined #ruby
iaj has quit [Quit: leaving]
iaj has joined #ruby
iaj has quit [Client Quit]
<codex>
apeiros: interesting enough, on the system that it's failing - while it has ruby 2.0, the first one picked up by path/env is "ruby 1.8.7" - so there's my problem
beilabs has joined #ruby
Beoran__ has quit [Read error: Operation timed out]
alekst has joined #ruby
<apeiros>
blöpp…
<MrZYX>
#lines returns an enumerator on < 2.0
<apeiros>
how can I delete a file from a gist?
dr_bob has quit [Read error: Connection reset by peer]
<codex>
already gone :)
<MrZYX>
apeiros: blue x in the filename input
nettoweb has quit [Quit: nettoweb]
_nitti_ has quit [Read error: No route to host]
<codex>
apeiros: thank you
_nitti_ has joined #ruby
<apeiros>
MrZYX: aaah!
WanderingGlitch has quit [Changing host]
WanderingGlitch has joined #ruby
<apeiros>
thanks
<apeiros>
whyTF is it blue? o0
<MrZYX>
also git clone; git rm; git push :P
vlad_starkov has quit [Remote host closed the connection]
<apeiros>
pfff
iaj has joined #ruby
<codex>
heh
vlad_starkov has joined #ruby
<apeiros>
my postgres trigger based generic table historization is almost working
gyre008 has joined #ruby
<apeiros>
well, it is working, but table & sequence name are currently hardcoded into the trigger
<apeiros>
anyway, shopping & going home before completing that :)
zigomir has joined #ruby
mikewintermute has joined #ruby
Cultofmetatron has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
apeiros has quit []
gkunno has quit [Excess Flood]
robscomputer has quit [Read error: Connection reset by peer]
cofin has quit [Quit: cofin]
_nitti has quit [Ping timeout: 252 seconds]
robscomputer has joined #ruby
gyre007 has quit [Read error: Operation timed out]
ipalaus has quit [Ping timeout: 256 seconds]
mercwithamouth has quit [Ping timeout: 256 seconds]
dfdf has quit [Remote host closed the connection]
beilabs has quit [Ping timeout: 256 seconds]
gkunno has joined #ruby
robscomputer_ has joined #ruby
ogr has joined #ruby
dhruvasagar has joined #ruby
kiwnix has joined #ruby
rsimecek has quit [Remote host closed the connection]
timkohrumel has quit [Remote host closed the connection]
Cultofmetatron has quit [Remote host closed the connection]
_nitti_ has quit [Remote host closed the connection]
tjbiddle has quit [Ping timeout: 256 seconds]
tjbiddle_ is now known as tjbiddle
<Za9>
Alguem saberia como solucionar esse problema? rvm install ruby-1.9.3-p194
<havenwood>
Za9: Try manually installing the port package for RVM? Which package is failing (check the log the error points you towards)?
<apeiros>
Za9: this channel is english. there are language specific ruby channels
daniel_- has joined #ruby
chandankumar has quit [Max SendQ exceeded]
dnyy has joined #ruby
chandankumar has joined #ruby
<joshu>
question about using logger to log a scripts progress. At the moment I'm just logging strings with info like this @log.info "Sending fax sent notification to #{to}"
LennyLinux has joined #ruby
saarinen has joined #ruby
<apeiros>
I'd assume you want #ruby-es
niklasb has quit [Ping timeout: 260 seconds]
dhruvasagar has joined #ruby
<joshu>
I'm wondering if I should use some more to the point but perhaps less human readable format like this @log.info "[fax_sent] src=#{from} dest=#{to}"
<joshu>
if I was later interested in getting some statistics from the log file maybe the latter example is more suitable?
dhruvasagar has quit [Read error: Connection reset by peer]
_nitti has joined #ruby
dhruvasagar has joined #ruby
teclator has quit [Ping timeout: 276 seconds]
fcoury__ has joined #ruby
l33 has joined #ruby
chandankumar has quit [Max SendQ exceeded]
l33 has quit [Read error: Connection reset by peer]
<Za9>
thanks
Za9 has quit [Quit: Page closed]
l33 has joined #ruby
chandankumar has joined #ruby
_nitti has quit [Remote host closed the connection]
io_syl has quit [Ping timeout: 252 seconds]
wallerdev has quit [Quit: wallerdev]
rubycode_ has joined #ruby
_rgn has joined #ruby
Naeblis|XChat has quit [Ping timeout: 248 seconds]
niftylettuce has joined #ruby
kaichanvong has joined #ruby
guilleiguaran_ has joined #ruby
saarinen has quit [Quit: saarinen]
rads has joined #ruby
DestinyAwaits has quit [Ping timeout: 264 seconds]
rwz_ has joined #ruby
cool has joined #ruby
io_syl has joined #ruby
beilabs has quit [Ping timeout: 248 seconds]
generali_ has joined #ruby
mahmoudimus has joined #ruby
rcsheets_ has joined #ruby
patricksroberts_ has joined #ruby
Proshot has joined #ruby
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
davidboy has joined #ruby
mark_locklear has joined #ruby
Zeeraw has joined #ruby
cek has quit [Quit: жопа диридай диридиридай]
NimeshNeema has joined #ruby
octarine has joined #ruby
generalissimo has quit [Ping timeout: 248 seconds]
druonysus has joined #ruby
druonysus has quit [Changing host]
druonysus has joined #ruby
camilasan has quit [Remote host closed the connection]
xerxas has joined #ruby
tundrax has quit [Remote host closed the connection]
lectrick has joined #ruby
strax has joined #ruby
IrishGringo has joined #ruby
devoldmx3 has joined #ruby
c0rn has joined #ruby
thejefflarson__ has joined #ruby
keelerm has joined #ruby
troessner has quit [Ping timeout: 256 seconds]
akhet has joined #ruby
akhet has joined #ruby
devoldmx has quit [Ping timeout: 256 seconds]
devoldmx has joined #ruby
mahmoudimus has quit [Remote host closed the connection]
ziyadb has joined #ruby
beilabs has joined #ruby
SeanTAllen has joined #ruby
LucidDreamZzZz has quit [Remote host closed the connection]
devoldmx3 has quit [Ping timeout: 246 seconds]
LucidDreamZzZz has joined #ruby
IrishGringo has quit [Quit: ChatZilla 0.9.90 [Firefox 21.0/20130511120803]]
cmarques has joined #ruby
kirun has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
forrest has joined #ruby
Spaceghost|cloud has joined #ruby
jbpros has quit [Quit: jbpros]
notbrent_ has joined #ruby
LanaDelRey has joined #ruby
devoldmx3 has joined #ruby
sambao21 has joined #ruby
tbrock_ has joined #ruby
im0b has joined #ruby
<ArchBeOS>
any good resource on database creation via rake (sans rails)?
<canton7>
depends on what library you're using
<apeiros>
task :create_db do …code to create db… end
<apeiros>
dunno what more you want
randym_ has joined #ruby
akells` has joined #ruby
vlad_starkov has joined #ruby
akells` has quit [Read error: Connection reset by peer]
akells` has joined #ruby
devoldmx has quit [Ping timeout: 248 seconds]
horsey has joined #ruby
<ArchBeOS>
jsut some guidance that isnt rails related. kinda new to rake tbh. im using sequel as my ORM
browndawg1 has quit [Quit: Leaving.]
<ArchBeOS>
just need to be able to create and populate dev data.
<canton7>
google for "rake sequel". there's plenty of stuff out there
mahmoudimus has joined #ruby
<apeiros>
ArchBeOS: there isn't much to it. you define a task by doing `task :taskname do …code… end`
akhet has left #ruby ["none"]
<canton7>
it's more a matter of what sequel methods to call in that rake task
<apeiros>
you add a description by putting `desc "Some text"` in front of it
<ArchBeOS>
cool. i was worried that it be more like ant
<apeiros>
you can make much more. but for the moment that's probably all you will need.
bionhart has joined #ruby
viszu has quit [Quit: Leaving.]
<ArchBeOS>
cool. thanks apeiros
<ArchBeOS>
and canton7
<ArchBeOS>
:)
cofin has joined #ruby
tonini has joined #ruby
cam` has joined #ruby
mark_locklear has quit [Ping timeout: 248 seconds]
jds_ has joined #ruby
vlad_starkov has quit [Ping timeout: 252 seconds]
karnowski has joined #ruby
interactionjaxsn has quit [Remote host closed the connection]
chrishough has joined #ruby
interactionjaxsn has joined #ruby
krombr has quit [Remote host closed the connection]
mahmoudimus has quit [Client Quit]
vlad_starkov has joined #ruby
<ariedler>
in Rails ActionView pipeline; I have a controller V2::FooController; but I want it to use templates in foo/action_name ; what is the easy way to override this behavious?
foghsho has joined #ruby
yeban has joined #ruby
pagios has quit [Ping timeout: 256 seconds]
mnaser has quit [Excess Flood]
<ariedler>
err wrong channel lol
mattbl has joined #ruby
stkowski has quit [Quit: stkowski]
felixjet_ has quit [Read error: Connection reset by peer]
alex__c2022 has quit [Ping timeout: 248 seconds]
alex__c2022 has joined #ruby
mnaser has joined #ruby
johnrlive has joined #ruby
obs has quit [Quit: Konversation terminated!]
interactionjaxsn has quit [Ping timeout: 248 seconds]
pagios has joined #ruby
girija has joined #ruby
arya_ has joined #ruby
stkowski has joined #ruby
Hanmac has joined #ruby
krawchyk_ has joined #ruby
gaahrdner has joined #ruby
Hanmac1 has quit [Ping timeout: 252 seconds]
[0x1a] has joined #ruby
mercwithamouth has quit [Ping timeout: 260 seconds]
Naeblis has joined #ruby
jonathanwallace has joined #ruby
krawchyk has quit [Ping timeout: 264 seconds]
keyvan has joined #ruby
velus has joined #ruby
dhruvasagar has quit [Ping timeout: 260 seconds]
zmike123 has joined #ruby
mark_locklear has joined #ruby
zmike123 has quit [Read error: Connection reset by peer]
velus has left #ruby ["so loong suckers"]
RORgasm has joined #ruby
RORgasm_ has quit [Read error: Connection reset by peer]
krawchyk_ has quit [Remote host closed the connection]
wallerdev has joined #ruby
niklasb has joined #ruby
devoldmx3 has quit [Quit: Bye]
pagios has quit [Ping timeout: 248 seconds]
devoldmx has joined #ruby
zigomir_ has joined #ruby
Banistergalaxy has quit [Ping timeout: 248 seconds]
kf8a has quit [Quit: Computer has gone to sleep.]
tundrax has joined #ruby
taqutor has joined #ruby
girija has quit [Remote host closed the connection]
Zeeraw has quit [Quit: Computer has gone to sleep.]
jokke1 has joined #ruby
balr0g_ has joined #ruby
[Neurotic] has joined #ruby
BizarreCake has quit [Ping timeout: 256 seconds]
kpshek has joined #ruby
ipalaus has quit [Quit: Computer has gone to sleep.]
jonathanwallace has quit [Ping timeout: 260 seconds]
browndawg has joined #ruby
ia___ has joined #ruby
zigomir_ has quit [Quit: zigomir_]
girija has joined #ruby
cantonic_ has joined #ruby
nettoweb has quit [Quit: nettoweb]
ramblex has quit [Remote host closed the connection]
cantonic has quit [Ping timeout: 256 seconds]
cantonic_ is now known as cantonic
lolmaus has joined #ruby
<lolmaus>
Hi!
brtdv has quit [Ping timeout: 248 seconds]
wargasm has joined #ruby
tundrax has quit [Ping timeout: 276 seconds]
graydot has joined #ruby
kpshek has quit []
shadewind has joined #ruby
cj3kim has quit [Remote host closed the connection]
<shadewind>
are ruby references atomic for assignment?
ToApolytoXaos has joined #ruby
shevy has joined #ruby
mtlatif__ has joined #ruby
<shevy>
test
rdark has quit [Quit: leaving]
markalanevans has joined #ruby
kpshek has joined #ruby
Cultofmetatron has quit [Read error: Connection reset by peer]
mattbl has quit [Quit: This computer has gone to sleep]
kpshek has quit [Client Quit]
Cultofmetatron has joined #ruby
axekwn has quit [Remote host closed the connection]
arya_ has quit [Ping timeout: 248 seconds]
icole has quit [Remote host closed the connection]
phasma has joined #ruby
Hanmac1 has joined #ruby
miclen has joined #ruby
johnrlive has quit [Remote host closed the connection]
kpshek has joined #ruby
<shadewind>
that is, can I do this: Thread.new { puts "hello" while run }
<shadewind>
and then do: run = false
<shadewind>
to end the thread
<lolmaus>
shadewind, can you try to tell?
<lolmaus>
I mean, try to execute that and see if it works
<apeiros>
shadewind: you can, but you should not.
Hanmac has quit [Ping timeout: 260 seconds]
<apeiros>
lolmaus: "try if it works" is a rather bad advice with regards to threaded code.
<shadewind>
lolmaus: that's the thing with threading, that it works once say absolutely nothing
keelerm has left #ruby [#ruby]
l33 has quit [Remote host closed the connection]
<shadewind>
says*
<lolmaus>
Oh
Zai00 has quit [Quit: Zai00]
nettoweb has joined #ruby
JoeTheGuest has joined #ruby
<shadewind>
apeiros: what's the idiomatic way to gracefully end a loop in ruby then?
jnoob22_ has joined #ruby
vlad_sta_ has joined #ruby
<shevy>
shadewind you could do: thread = Thread.new {}; thread.join and thread ... kill
<lolmaus>
apeiros, shadewind, but in this very case, wouldn't it either work or not?
<apeiros>
shadewind: in your simplified example it would work, since you have no race condition
Cultofmetatron has quit [Remote host closed the connection]
<shevy>
shadewind if you can control it, do: loop { fetch_user_input = $stdin.gets.chomp; check_against_menu(fetch_user_input); exit if fetch_user_input == 'q' } # or better, move it all into a case/when menu
l33 has joined #ruby
<apeiros>
shadewind: but if you have things which can either set run to true again and/or test run's state too, you'll have a problem
jnoob22 has quit [Read error: Operation timed out]
Cultofmetatron has joined #ruby
arya_ has joined #ruby
<apeiros>
shadewind: use a thread-safe construct. See Mutex, Queue and Monitor
deadalus has joined #ruby
<shadewind>
apeiros: I have a lot of experience with threading so general threading issues is something I'm aware of
<shevy>
Hanmac1 I use mIRC now, through wine :\
<shadewind>
apeiros: my question is more regarding ruby specific issues
<apeiros>
shadewind: in that case: assume nothing to be atomic except explicitly stated otherwise.
l33 has quit [Remote host closed the connection]
cj3kim has joined #ruby
vlad_starkov has quit [Ping timeout: 248 seconds]
beilabs has quit [Ping timeout: 248 seconds]
<apeiros>
and: assume nothing to be thread-safe except explicitly stated otherwise.
<shadewind>
apeiros: of course
eploko has joined #ruby
<shadewind>
apeiros: just wondering if you could explicitly state if references are atomic for assignment and reading ;)
<apeiros>
shevy: wtf, stop that. use your own channel for stupid test messages.
<shadewind>
you cannot test atomicness
jonathanwallace has joined #ruby
<shadewind>
you can only test that it's not, in practice
<shadewind>
that is, if it ever fails, it's not atomic
l33 has joined #ruby
<apeiros>
shadewind: assume assignment and reading to be not atomic. ruby implementations may differ in actual implementation.
<shevy>
apeiros wow, something in your ass or something?
mjburgess has quit [Remote host closed the connection]
<shadewind>
apeiros: I see. so I should protect my condition variable with something then
mjburgess has joined #ruby
<apeiros>
shevy: yes. your silly test messages. if it works, you'll see on your first message. or as said, use some other channel, preferably one of your own.
Norrin has left #ruby [#ruby]
<shevy>
alright, alright
heftig has quit [Read error: Connection reset by peer]
* Spitfire
puts something in apeiros' arse.
heftig_ has joined #ruby
Cultofmetatron has quit [Ping timeout: 276 seconds]
alekst has quit [Ping timeout: 252 seconds]
workmad3 has joined #ruby
devoldmx has quit [Read error: Connection reset by peer]
devoldmx has joined #ruby
chase-work has joined #ruby
<shevy>
shadewind: you working on a ruby project?
cj3kim has quit [Remote host closed the connection]
mahmoudimus has joined #ruby
cespare_ has quit [Quit: WeeChat 0.3.7]
<shadewind>
shevy: of course
cespare has joined #ruby
ivanoats has joined #ruby
Kricir has joined #ruby
skroon has joined #ruby
pkrnj has joined #ruby
w400z has joined #ruby
deadalus has quit [Changing host]
deadalus has joined #ruby
mattbl has joined #ruby
johnmike has joined #ruby
johnmike has quit [Client Quit]
Sirupsen has joined #ruby
Todd has quit [Remote host closed the connection]
dik_dak has joined #ruby
dankest has joined #ruby
aedorn has quit [Remote host closed the connection]
tbrock_ has quit [Quit: Computer has gone to sleep.]
codecop has joined #ruby
Todd has joined #ruby
LennyLinux has quit [Remote host closed the connection]
jbpros has joined #ruby
johnrlive has joined #ruby
altamic has joined #ruby
altamic has left #ruby [#ruby]
workmad3 has quit [Ping timeout: 248 seconds]
mmitchel_ has joined #ruby
niceguyjames has joined #ruby
niceguyjames has quit [Client Quit]
nomenkun has joined #ruby
arya_ has quit [Ping timeout: 248 seconds]
Elhu has joined #ruby
Banistergalaxy has joined #ruby
axl_ has quit [Quit: axl_]
zubov has joined #ruby
arya_ has joined #ruby
mmitchell has quit [Ping timeout: 256 seconds]
mattbl has quit [Quit: Leaving]
kpshek has quit []
LanaDelRey has quit [Changing host]
LanaDelRey has joined #ruby
banjara has quit [Ping timeout: 252 seconds]
stonevil has quit [Remote host closed the connection]
monkegjinni has quit [Remote host closed the connection]
Elhu has quit [Client Quit]
wargasm1 has joined #ruby
l33 has quit [Remote host closed the connection]
generali_ has quit [Remote host closed the connection]
zastern__ has joined #ruby
zastern__ has quit [Read error: Connection reset by peer]
wargasm has quit [Ping timeout: 260 seconds]
zastern__ has joined #ruby
rcsheets_ is now known as rcsheets
aces1up23 has quit []
skaflem has quit [Quit: This computer has gone to sleep]
callmeivan has joined #ruby
<lolmaus>
I've got a string with linebreaks. I would like to return the first line of that string. What's the simpliest way to do that?
zastern_ has quit [Ping timeout: 252 seconds]
aedorn has joined #ruby
zubov has quit [Ping timeout: 248 seconds]
banjara has joined #ruby
<apeiros>
.each_line.first
<callmeivan>
does somebody know how to declare a signed reg in verilog (for use with veriwell?
<callmeivan>
reg signed [7:0] why; does not work "c.v: L18: error: syntax error, unexpected IDENTIFIER, expecting ',' or ';"
<lolmaus>
apeiros, thx
seejohnr1n has joined #ruby
rton has left #ruby [#ruby]
seejohnrun has quit [Ping timeout: 252 seconds]
nomenkun has quit [Remote host closed the connection]
brennanMKE has joined #ruby
zubov has joined #ruby
chrishough has quit [Quit: chrishough]
sayan has joined #ruby
tundrax has joined #ruby
brennanM_ has joined #ruby
brotatos has joined #ruby
tundrax has quit [Remote host closed the connection]
skroon has quit [Ping timeout: 252 seconds]
seejohnr1n has quit [Ping timeout: 276 seconds]
skroon has joined #ruby
w400z has quit []
bionhart has quit [Remote host closed the connection]
chrishough has joined #ruby
_bart has quit [Quit: _bart]
ioNull has quit [Read error: Connection reset by peer]
brennanMKE has quit [Ping timeout: 246 seconds]
yacks has quit [Quit: Leaving]
<epitron>
apeiros: is setting Thread-local variables atomic?
brotatos has quit [Client Quit]
yacks has joined #ruby
<epitron>
err, threadsafe? :)
stoic_squirrel has joined #ruby
brotatos has joined #ruby
<apeiros>
repeat after me: nothing is, unless stated explicitly otherwise
mmitchel_ has quit [Ping timeout: 252 seconds]
<epitron>
apeiros: is setting Thread-local variables explicitly stated atomic or otherwise?
<apeiros>
I'd have to use ri or the browser all the same as you
AndChat| has joined #ruby
<epitron>
"i don't know" :)
brotatos has quit [Client Quit]
<apeiros>
"look it up"
<epitron>
hahah
<epitron>
"i cannot admit that i am wrong"
<apeiros>
o0
<epitron>
s/wrong/lacking knowledge/
emmanuelux has joined #ruby
<apeiros>
better :-p
<apeiros>
I think I just admitted that I don't know that…
mmitchell has joined #ruby
<AndChat|>
Tipton
zastern__ is now known as zastern_
<AndChat|>
Epitron eppy!
<r0bgleeson>
epitron: I'd say its not because of Thread.current[:foo].
zastern has quit [Disconnected by services]
zastern_ is now known as zastern
st_iron has quit [Quit: Lost terminal]
<epitron>
the C source has no locking
rockets has joined #ruby
Banistergalaxy has quit [Ping timeout: 252 seconds]
<apeiros>
in general, the assumption "it's not thread-safe" is a quite good bet in ruby.
reset has joined #ruby
JZTech101 has joined #ruby
cmarques has quit [Ping timeout: 248 seconds]
robbyoconnor has joined #ruby
kpshek has joined #ruby
ioNull has joined #ruby
wolcanus has quit [Remote host closed the connection]
pcarrier_ has quit [Ping timeout: 252 seconds]
LanaDelRey has quit [Quit: LS/MFT, LS/MFT, smoking's cool fuckya! Hope I get larynx cancer tomorrow! :)]
jfelchner has joined #ruby
Zeeraw has joined #ruby
arya_ has quit [Ping timeout: 248 seconds]
<epitron>
wow, the difference between thread locals and fiber locals is confusing
<epitron>
thread locals look like ivars on the thread object
<epitron>
while fiber locals call rb_thread_local_aref
<epitron>
o_O
shadewind has quit [Quit: Lost terminal]
<epitron>
so thread locals are actually ivars, and fiber locals are actually thread locals
wargasm1 has quit [Ping timeout: 276 seconds]
pcarrier_ has joined #ruby
<epitron>
:D
jokke1 has quit [Ping timeout: 252 seconds]
<shevy>
fibers sound confusing
<aedorn>
oh neat, there's an Iperf 3! Which has nothing to do with anything here, but I wanted to state my excitement.
ananthakumaran has quit [Quit: Leaving.]
cmarques has joined #ruby
<epitron>
Fibers/Threads feel like a hack, compared to the rest of ruby
<nightfly>
sounds right
jailbirdzentest has joined #ruby
robbyoconnor has quit [Read error: Connection reset by peer]
johnrlive has quit [Remote host closed the connection]
danslo has joined #ruby
<epitron>
:)
nfk has quit [Quit: yawn]
ferdev has quit [Quit: ferdev]
tvw has quit []
<jailbirdzentest>
I'm trying to check if a string is equal to a ISO8601 date, but the original string I pass in is some how losing it's value. I've created a gist with the code and log output. Is this a bug? https://gist.github.com/jcblitz/5665374
browndawg has left #ruby [#ruby]
umren has joined #ruby
<apeiros>
jailbirdzentest: ew, seems like Date.iso8601 mutated the argument
<apeiros>
I'd report that as a bug. pass in tag.dup as a work-around.
<jailbirdzentest>
I'll give it a try, thanks
kf8a has joined #ruby
generalissimo has joined #ruby
<apeiros>
jailbirdzentest: what ruby version? ruby 2.0 no longer seems to destroy the argument…
Eaven has quit [Read error: Connection reset by peer]
<apeiros>
neither 1.9.3
<jailbirdzentest>
ruby-1.9.3-p429
zubov has quit [Remote host closed the connection]
camilasan has joined #ruby
Eaven has joined #ruby
<apeiros>
ok. odd.
akells` has quit [Remote host closed the connection]
viszu has joined #ruby
Eaven has quit [Remote host closed the connection]
<apeiros>
what you describe does not happen here.
<epitron>
iso8601 is the best date format
<jailbirdzentest>
what's weird is it's only happening on one of my servers
<apeiros>
and make sure you do it in a shell where it happens
<apeiros>
check that on the server where it happens
<apeiros>
I'd bet that something overrides the iso8601 method
<apeiros>
but he's gone… so… well… whatever
jacktrick has quit [Quit: Leaving]
gasbakid has quit [Read error: Connection reset by peer]
workmad3 has joined #ruby
danslo has quit [Quit: danslo]
jokke1 has joined #ruby
slainer68 has joined #ruby
seejohnrun has joined #ruby
camilasan has quit [Ping timeout: 257 seconds]
carlyle has quit [Remote host closed the connection]
ctp has quit [Quit: Leaving...]
mmitchell has quit [Ping timeout: 246 seconds]
mjburgess has joined #ruby
chrishough has joined #ruby
mmitchell has joined #ruby
morgajel_ has quit [Quit: leaving]
danslo has joined #ruby
ivanoats has quit [Remote host closed the connection]
Davey has quit [Quit: Computer has gone to sleep.]
benlieb has joined #ruby
miclen has quit [Ping timeout: 248 seconds]
benlieb has quit [Client Quit]
icole has joined #ruby
Davey has joined #ruby
_nitti has joined #ruby
MrZYX is now known as MrZYX|off
happycrappy has joined #ruby
rh1n0 has joined #ruby
cmarques has joined #ruby
machuga is now known as machuga|away
arya_ has joined #ruby
Animawish has joined #ruby
pipework has quit [Remote host closed the connection]
mahmoudimus has quit [Read error: Connection reset by peer]
pipework has joined #ruby
<happycrappy>
hi all...got a quick question (i know this can be avoided, but asking out of curiosity) is there anyway to disambiguate between local variable & a _private_ instance method inside another instance method? ie. class Moo; def baa; end; private_method :baa; def run; baa = 42; self.baa # wrong!; end; end
icole has quit [Read error: Operation timed out]
generali_ has joined #ruby
mahmoudimus has joined #ruby
akells` has joined #ruby
Vert has quit [Ping timeout: 252 seconds]
tbrock_ has joined #ruby
JZTech101 has quit [Remote host closed the connection]
rh1n0 has quit [Quit: -- I'm out --]
<apeiros>
happycrappy: baa()
apod has joined #ruby
arya_ has quit [Ping timeout: 276 seconds]
mityaz has quit [Quit: See ya!]
<apeiros>
and this can not only be avoided, it absolutely should be. don't shadow methods with lvars.
mmitchell has quit [Ping timeout: 252 seconds]
ntus1017 has quit [Remote host closed the connection]
generalissimo has quit [Ping timeout: 276 seconds]
tbrock_ has quit [Client Quit]
kf8a has quit [Quit: Computer has gone to sleep.]
nomenkun has joined #ruby
Michae___ has joined #ruby
mmitchell has joined #ruby
bionhart has joined #ruby
<happycrappy>
apeiros: fair enough, was just curious
<happycrappy>
apeiros: thanks
jnoob22_ has quit [Remote host closed the connection]
wolcanus has joined #ruby
d2dchat has joined #ruby
jnoob22 has joined #ruby
roadt has quit [Ping timeout: 256 seconds]
<apeiros>
happycrappy: also providing arguments (whether with or without parens) unambiguously identifies a method
bionhart_ has joined #ruby
girija has quit [Ping timeout: 276 seconds]
carlyle has joined #ruby
ferdev has joined #ruby
kf8a has joined #ruby
<happycrappy>
apeiros: thats pretty interesting, i should probably look thru the parser to check out all the pains it goes thru to support all the optional syntax esoterics
superscott[8] has joined #ruby
cmarques has quit [Ping timeout: 260 seconds]
saarinen has joined #ruby
kofno has quit [Remote host closed the connection]
bionhart_ has quit [Read error: Connection reset by peer]
workmad3 has quit [Ping timeout: 276 seconds]
theRoUS has quit [Ping timeout: 276 seconds]
bionhart has quit [Ping timeout: 252 seconds]
kinginky has joined #ruby
forrest has quit [Quit: Leaving]
arya_ has joined #ruby
devoldmx has quit [Read error: Connection reset by peer]
postmodern has joined #ruby
<kinginky>
howdy everyone. im working w/ the Sequel gem/MySQL... I have an association setup (let's say Person is one_to_many Pets)... i need a query to select a Person w/ >0 Pets
<kinginky>
for the life of me, can't figure this out. any ideas?
mmitchell has quit [Ping timeout: 252 seconds]
apeiros has quit [Remote host closed the connection]
devoldmx has joined #ruby
wolcanus has quit [Read error: Connection reset by peer]
apeiros has joined #ruby
wolcanus has joined #ruby
apeiros has quit [Read error: Connection reset by peer]
devoldmx has quit [Read error: Connection reset by peer]
Cultofmetatron has joined #ruby
apeiros has joined #ruby
<happycrappy>
kinginky: i haven't used sequel, but in sql I would do a group by "SELECT person.* FROM person JOIN pets ON pets.person_id = persion.id GROUP BY person.id HAVING COUNT(pets.id) > 0.
stonevil has joined #ruby
<apeiros>
kinginky: with an exists subselect
<kinginky>
happycrappy: i figured it may have something to do with JOIN
<kinginky>
apeiros: i think i see what u mean. let me try some things out in irb
bionhart has joined #ruby
radic has quit [Remote host closed the connection]
<apeiros>
e.g. `select ppl.* from people ppl where exists (select 1 from pets where owner_id=ppl.id)`
<happycrappy>
join on subselect would probably perform better if people have lots of pets
<kinginky>
the people have thousands upon thousands of pets... crazy cat women, they are.
machuga|away has quit [Excess Flood]
mmitchell has joined #ruby
<kinginky>
apeiros, thanks, ill give that a shot
<happycrappy>
but i would against the subselect
arya_ has quit [Ping timeout: 252 seconds]
<happycrappy>
*i would join against the subselect
machuga has joined #ruby
robscomputer has quit [Read error: Connection reset by peer]
nomenkun has quit [Remote host closed the connection]
devoldmx has joined #ruby
cmarques has joined #ruby
blaxter has quit [Ping timeout: 256 seconds]
<happycrappy>
select person * from person join (select distinct pets.person_id as person_id from pets) as owners on owners.person_id = person.id
<apeiros>
I doubt that a join would be faster
<happycrappy>
)
zastern has quit [Remote host closed the connection]
arya_ has joined #ruby
robscomputer_ has joined #ruby
devoldmx has quit [Read error: Connection reset by peer]
crazymykl has quit [Remote host closed the connection]
jfelchner has quit [Ping timeout: 252 seconds]
devoldmx has joined #ruby
<happycrappy>
apeiros: i guess it depends on what indexes are available & how expensive seeks are ... but im talking outta my butt at this point :)
bionhart_ has joined #ruby
zastern has joined #ruby
n1x has joined #ruby
crazymykl has joined #ruby
vlad_sta_ has quit [Read error: Connection reset by peer]
cmarques has quit [Ping timeout: 245 seconds]
bionhart has quit [Ping timeout: 252 seconds]
tvw has joined #ruby
danslo has quit [Quit: danslo]
aedorn has quit [Quit: Leaving]
c0rn has quit [Quit: Computer has gone to sleep.]
bionhart has joined #ruby
c0rn has joined #ruby
marcgg_ has quit [Read error: No route to host]
ivanoats has joined #ruby
cmarques has joined #ruby
ivanoats has quit [Remote host closed the connection]
marcgg has joined #ruby
tundrax has joined #ruby
ToApolytoXaos has quit [Quit: Leaving]
mahmoudimus has quit [Remote host closed the connection]
pitzips has quit [Ping timeout: 248 seconds]
_veer has joined #ruby
_veer has quit [Changing host]
_veer has joined #ruby
bionhart_ has quit [Ping timeout: 245 seconds]
huoxito has quit [Quit: Leaving]
JZTech101 has joined #ruby
Z_Mass has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
yalue has quit [Read error: Connection reset by peer]
Z_Mass_ has joined #ruby
whowantstolivef1 has joined #ruby
mahmoudimus has joined #ruby
<zphobic>
So I'm trying to install the tiny_tds gem, but it dies because it can't find iconv_open(), even though the iconv dylib is clearly installed in /usr/lib.
<zphobic>
Specifying the lib (--with-iconv-lib=/usr/lib/libiconv.dylib) doesn't seem to have an effect either.
sambao21 has joined #ruby
JZTech101 has quit [Remote host closed the connection]
tundrax has quit [Ping timeout: 252 seconds]
darkapex has quit [Ping timeout: 256 seconds]
cj3kim has quit [Remote host closed the connection]
bionhart_ has joined #ruby
paissad has joined #ruby
darkapex has joined #ruby
jtharris has quit [Quit: WeeChat 0.4.0]
radic has joined #ruby
monkegjinni has joined #ruby
apod has quit [Quit: apod]
bionhart has quit [Ping timeout: 276 seconds]
apod has joined #ruby
mocfive has joined #ruby
n1x has quit [Ping timeout: 245 seconds]
djwonk has quit [Quit: djwonk]
bionhart_ has quit [Read error: Connection reset by peer]
jfelchner has joined #ruby
cmarques has quit [Ping timeout: 245 seconds]
djwonk has joined #ruby
Michae___ has quit [Remote host closed the connection]
tjbiddle_ has joined #ruby
darkapex has quit [Ping timeout: 245 seconds]
bionhart has joined #ruby
ivanoats has joined #ruby
geekbri has quit [Remote host closed the connection]
darkapex has joined #ruby
darkapex has quit [Changing host]
darkapex has joined #ruby
supergiantrobot has quit [Quit: supergiantrobot]
tjbiddle has quit [Ping timeout: 252 seconds]
tjbiddle_ is now known as tjbiddle
miclen has joined #ruby
chandankumar has quit [Quit: Leaving]
<happycrappy>
zphobic: not sure if this would be useful, but i've noticed that rvm installs its own copy of iconv, i would guess that the system one has issues
baroquebobcat has quit [Read error: Operation timed out]
<happycrappy>
zphobic: also, the --with-iconv-lib flags usually want the lib dir ie. --with-iconv-lib=/usr/lib
saarinen has quit [Quit: saarinen]
bionhart_ has joined #ruby
darkapex has quit [Ping timeout: 264 seconds]
saarinen has joined #ruby
darkapex has joined #ruby
callmeivan has quit [Quit: callmeivan]
rippa has quit [Ping timeout: 240 seconds]
carloslopes has quit [Remote host closed the connection]
bionhart has quit [Ping timeout: 248 seconds]
brianpWins has quit [Quit: brianpWins]
Animawish has quit [Quit: Animawish]
heftig_ is now known as heftig
tonini has quit [Quit: Lost terminal]
RORgasm has quit [Read error: Connection reset by peer]
jdunck has quit [Quit: Computer has gone to sleep.]
RORgasm has joined #ruby
mmitchell has quit [Remote host closed the connection]
Michae___ has joined #ruby
wesside has quit [Ping timeout: 252 seconds]
mmitchell has joined #ruby
supergiantrobot has joined #ruby
bionhart_ has quit [Read error: Connection reset by peer]
darkapex has quit [Ping timeout: 240 seconds]
Z_Mass_ has quit [Quit: Leaving]
baroquebobcat has joined #ruby
darkapex has joined #ruby
simon__ has joined #ruby
bionhart has joined #ruby
<simon__>
Hello, im new to ruby. in the irb, how can I get information about a required package? Like path to it etc.
<simon__>
In ipython i can do "import blablabla; blablabla?" to get information about blablabla
<apeiros>
the argument to require is a string which is the name of a file
sayan has quit [Quit: Leaving]
<apeiros>
the file may contain anything. require does not provide any means of getting information about what has been added through the evaluation of the file.
nomenkun has joined #ruby
bionhart has joined #ruby
icole has joined #ruby
horsey has quit [Ping timeout: 246 seconds]
jokke1 has quit [Ping timeout: 260 seconds]
<zphobic>
happycrappy: Hey, thanks for the response. rvm installs an 'iconv,' but AFAICT it's just a Ruby extension that interfaces with the lib itself. Also, all the src iconv tests pass without error.
darkapex has quit [Ping timeout: 264 seconds]
radic has quit [Remote host closed the connection]
<zphobic>
happycrappy: As far as the argument to --with-iconvlib, I can see it looking for iconv_open in -l/usr/lib or -l/usr/lib/libiconv.dylib; neither works.
ipalaus has joined #ruby
sailias has quit [Ping timeout: 256 seconds]
Zai00 has joined #ruby
nomenkun has quit [Remote host closed the connection]
darkapex has joined #ruby
bionhart_ has quit [Ping timeout: 245 seconds]
Cultofmetatron has quit [Remote host closed the connection]
relix has quit [Quit: relix]
Spami has quit [Ping timeout: 253 seconds]
nomenkun has joined #ruby
pitzips has joined #ruby
Lubinski has quit [Quit: Leaving]
ALBANIA has joined #ruby
marcgg has quit [Read error: No route to host]
freezey has quit [Remote host closed the connection]
marcgg has joined #ruby
SirSkids|Zzz is now known as SirSkidmore
machuga is now known as machuga|away
bionhart_ has joined #ruby
darkapex has quit [Ping timeout: 245 seconds]
jnoob22 has quit [Remote host closed the connection]
mark_locklear has quit [Quit: Leaving]
nomenkun has quit [Remote host closed the connection]
ivanoats has quit [Remote host closed the connection]
<seejohnrun>
lewis: .to_f
<lewis>
seejohnrun: no it's ok. i
<seejohnrun>
ok
platzhirsch has joined #ruby
<lewis>
seejohnrun: i see what you mean but not that. apparently there's something else - a bug- i should be able to spot
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
instinkt has quit [Client Quit]
instinkt has joined #ruby
forrest has joined #ruby
<apeiros>
lewis: it usually helps to say what fails.
<lewis>
apeiros: in this instance i dont know apeiros. im solving problems here
<apeiros>
lewis: obviously you do know
<platzhirsch>
what would be a concise statement to fetch a value of a hash (which is an array) and push something new onto it?
<apeiros>
otherwise you weren't here saying that something fails
PaulePanter has joined #ruby
<lewis>
apeiros: tchip
<platzhirsch>
hash[key] = hash[key] << key ?
<seejohnrun>
platzhirsch: h[:key] << hi
<lewis>
im solving a set of question. I am supposed to find the bug
pipework has quit [Remote host closed the connection]
foghsho has quit []
<seejohnrun>
platzhirsch: you don't need the assignment
beilabs has joined #ruby
darkapex has quit [Ping timeout: 245 seconds]
<apeiros>
lewis: so… homework?
zastern_ has joined #ruby
ArchBeOS has quit [Remote host closed the connection]
<lewis>
no
<platzhirsch>
seejohnrun: I thought that had to effect, let me recheck
<lewis>
you know what never mind
apalmblad has quit [Quit: apalmblad]
freerobby has quit [Quit: Leaving.]
jdunck has joined #ruby
<apeiros>
that's an awesome idea
<platzhirsch>
seejohnrun: seems like that value does not stay. The thing is, the hash is empty, created with Hash.new [], so an empty array is the default
instinkt has quit [Client Quit]
<seejohnrun>
hash = Hash.new { |h, k| h[k] = [] }
instinkt has joined #ruby
darkapex has joined #ruby
kinginky has quit [Quit: Leaving]
<seejohnrun>
or if you don't have power over the creation
<seejohnrun>
then
<seejohnrun>
hash[key] ||= []
<seejohnrun>
hash[key] << val
jblack has joined #ruby
<seejohnrun>
(hash[key] ||= []) << val
<apeiros>
platzhirsch: Hash.new [] # creates a hash which will always return *the same* array by default
c0rn has joined #ruby
ALBANIA is now known as WorLd
kofno has joined #ruby
<platzhirsch>
seejohnrun: ah that's some sweet syntax sugar, thanks!
instinkt has quit [Remote host closed the connection]
<platzhirsch>
apeiros: yes, I total forgot about the syntax, and I had the very side effect you described
<zphobic>
No one has mentioned the possible Divide By Zero error in lewis's average code.
<apeiros>
what seejohnrun for the rest
instinkt has joined #ruby
Jack_DanieL`s has left #ruby [#ruby]
chipotle_ has joined #ruby
<seejohnrun>
i like creating the hash with a block like: hash = Hash.new { |h, k| h[k] = [] }
<seejohnrun>
and then you can just always do hash[key] << val
milestone has joined #ruby
aedorn has joined #ruby
instinkt has quit [Client Quit]
<apeiros>
I do that only if there's a clear building phase
instinkt has joined #ruby
<apeiros>
where I can set the default to nil after
<seejohnrun>
yes
instinkt has quit [Remote host closed the connection]
cmarques has joined #ruby
ivanoats has joined #ruby
devoldmx3 has joined #ruby
<zphobic>
seejohnrun: Yeah, except one has to be careful not to set it up as Hash.new([]), because that sets the default for every new kv pair TO THE SAME ARRAY.
<zphobic>
I've been bitten by that before, heh.
sambao21 has quit [Quit: Computer has gone to sleep.]
<seejohnrun>
zphobic: yes
robscomputer_ has quit [Read error: Connection reset by peer]
darkapex has quit [Ping timeout: 245 seconds]
evenix has quit [Remote host closed the connection]
devoldmx has quit [Read error: Connection reset by peer]
vlad_starkov has joined #ruby
brennanM_ has quit [Ping timeout: 246 seconds]
evenix has joined #ruby
sambao21 has joined #ruby
kofno has quit [Ping timeout: 248 seconds]
darkapex has joined #ruby
saarinen has quit [Quit: saarinen]
robscomputer_ has joined #ruby
DrCode has quit [Ping timeout: 240 seconds]
saarinen has joined #ruby
DrCode has joined #ruby
icole has quit [Remote host closed the connection]
<aedorn>
hmmm, iperf 3 API library is pretty neat. I could see a Ruby gem out of it now.
threesome has quit [Ping timeout: 256 seconds]
jds_ has quit [Remote host closed the connection]
threesome has joined #ruby
mnaser has quit [Excess Flood]
codecop has quit [Remote host closed the connection]
darkapex has quit [Ping timeout: 264 seconds]
stonevil has joined #ruby
darkapex has joined #ruby
icole has joined #ruby
mnaser has joined #ruby
benlieb has joined #ruby
<apeiros>
mikewintermute: assigning to a local variable does not change the array
<apeiros>
people.each won't mutate the array either
<jkline__>
is there a common way to use a README.md as spec.description in a gemspec file? Those are such general terms I'm having trouble finding relevant documentation with google
robscomputer_ has quit [Ping timeout: 264 seconds]
<apeiros>
mikewintermute: a version which you probably understand easily: people.each_index do |index| people[index] = "Bob" if people[index].nil? end
robscomputer has joined #ruby
<apeiros>
mikewintermute: and the idiomatic version: people.map! do |person| person || "Bob" end
<Spooner>
jkline__, spec.description is usually massively shorter than a decent readme though.
<zphobic>
mikewintermute: people.map! { |p| p || "Bob" }
<tjbiddle>
Has anyone used Thor for CLI parsing before? I'm trying to have a command both be able to take in arguments, as well as have subcommands (./cli arg1 or ./cli subcommand arg1)
jayne| is now known as jayne
nettoweb has quit [Quit: nettoweb]
arya_ has quit [Ping timeout: 252 seconds]
<jkline__>
Spooner: ah, so those are typically not combined?
<aedorn>
I think GitHub spoiled me ... I actually hate seeing projects on code.google.com now.
<Spooner>
jkline__, I've not seen it done, no. The summary is usually a line or two and the description a paragraph.
darkapex has quit [Ping timeout: 260 seconds]
ybart has joined #ruby
<Spooner>
*paragraph or two.
johnrlive has joined #ruby
<mikewintermute>
apeiros: thanks - so does map mutate elements of the array?
brennanMKE has quit [Ping timeout: 240 seconds]
mahmoudimus has joined #ruby
<apeiros>
mikewintermute: no
<apeiros>
mikewintermute: map! mutates the *array*
<apeiros>
it does not touch the elements
johnrlive has left #ruby [#ruby]
<apeiros>
also note that there's both, map and map!, the former does not mutate the array either. it creates a new array which contains the changes.
brennanMKE has joined #ruby
<jkline__>
Spooner: thanks
<mikewintermute>
ah. thanks. clearly need to read up on the docs.
mixel has joined #ruby
Michae___ has quit [Remote host closed the connection]
nettoweb has joined #ruby
phantasm66 has quit [Quit: *sleeeep….]
Michael_ has joined #ruby
<apeiros>
you can mutate the elements of an array in any kind of loop. but for that you'd have to use a mutating method on the object. and there's no way to make nil become a string (ruby is a strongly typed language)
<apeiros>
>> people = ["foo", "bar", "baz"]; people.each do |person| person.upcase! end; people
Appineer has quit [Remote host closed the connection]
<apeiros>
note that the array did *not* change. the object in the array changed. the array still points to the same objects as before (same object_id)
Eaven has quit [Read error: Connection reset by peer]
Azulinho_ has quit [Ping timeout: 256 seconds]
manutter has joined #ruby
boxmein has quit [Quit: CCTV]
brtdv has joined #ruby
rburton- has joined #ruby
brtdv has quit [Max SendQ exceeded]
johnmilton has quit [Remote host closed the connection]
maycon has quit [Quit: Saindo]
Eaven has joined #ruby
RORgasm has quit [Read error: Connection reset by peer]
pcarrier_ has quit [Read error: Operation timed out]
RORgasm_ has joined #ruby
peta_ has joined #ruby
dash_ has quit [Quit: Time to beer :)]
wargasm has joined #ruby
peta_ has quit [Client Quit]
peta_ has joined #ruby
mmitchell has quit [Ping timeout: 248 seconds]
gaahrdner has quit [Remote host closed the connection]
Michael_ has quit [Remote host closed the connection]
wesside has quit [Quit: Computer has gone to sleep.]
Michael_ has joined #ruby
Zeeraw has quit [Quit: Computer has gone to sleep.]
alexwh has left #ruby [#ruby]
gaahrdner has joined #ruby
arya_ has joined #ruby
gaahrdner has quit [Remote host closed the connection]
gaahrdner has joined #ruby
khushildep has quit [Ping timeout: 248 seconds]
bionhart has joined #ruby
jdunck has quit [Quit: Computer has gone to sleep.]
JZTech101 has joined #ruby
brennanM_ has joined #ruby
wolcanus has quit [Ping timeout: 252 seconds]
brennanMKE has quit [Ping timeout: 260 seconds]
Kricir has joined #ruby
ivanoats has quit [Remote host closed the connection]
arya_ has quit [Ping timeout: 257 seconds]
kpshek has quit []
<Veejay>
Hi guys. I have a question for you. In some of my code, I'm making a request to an API. That call might result in either a success or a failure. In the case of a failure there are about two dozens types of errrors that might arise. What I'm getting in case of failure is a Hash containing four fields (error code, description, etc)
gaahrdner has quit [Ping timeout: 245 seconds]
robottinosino has joined #ruby
<Veejay>
What do you think is the best design to have a clean error handling mechanism? From my average level, I think a case/when will do the trick but I'd like to not get bit in the ass down the line
akells` has quit [Remote host closed the connection]
<Veejay>
Any advice for me?
generalissimo has joined #ruby
gasbakid has joined #ruby
<Veejay>
DISCLAIMER: I understand that this question is rather vague and not exactly the most on topic but there are specifics of the programming in Ruby that enforce particular ways of dealing with problems that I hope you excellent gentlemen would shed some light on for me
<Spooner>
Really depends how you want to manage them. If they can be grouped up a bit, then case; when a, b, c, d; when e, f, g, h might do you.
mixel has quit [Quit: mixel]
<Veejay>
(wrt/ special design patterns or whatnot)
<Veejay>
Spooner: I guess I'll be able to do some grouping yes
<Spooner>
Or you could just raise them as exceptions (but then you again have the option of how to group them up in that case).
<Veejay>
Spooner: So basically, it's down to case/when for things like this eh?
<Spooner>
Can't think of a reasonable alternative.
darkapex has joined #ruby
darkapex has quit [Changing host]
darkapex has joined #ruby
generali_ has quit [Ping timeout: 252 seconds]
<Veejay>
It's happened in the past on this here channel that some dude would come up with some magical solution involving a nicely crafted design pattern with some criss-cross inheritance or some stuff heh
jerius has quit [Ping timeout: 252 seconds]
<apeiros>
Veejay: does error handling mean you raise exceptions in your code?
<apeiros>
then I have nothing to add over what Spooner said
<Veejay>
So you've got all sorts of shennanigans
<Veejay>
Fraud suspected and the likes
_nitti has quit [Ping timeout: 276 seconds]
<Veejay>
And depending we act or we don't
mixel has joined #ruby
includex has quit [Quit: Leaving...]
fuzzyhorns has quit [Remote host closed the connection]
Ortuna has joined #ruby
<Veejay>
I already have an object to wrap the response from the API, should make it easy
<Veejay>
Thanks guys
sambao21 has quit [Quit: Computer has gone to sleep.]
chrisja has quit [Quit: leaving]
darkapex has quit [Ping timeout: 245 seconds]
breakingthings has quit [Quit: breakingthings]
teclator has joined #ruby
`brendan has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
solidoodlesuppor has quit [Remote host closed the connection]
huttan has quit [Read error: Operation timed out]
nomenkun has joined #ruby
bionhart has quit [Ping timeout: 240 seconds]
brennanM_ has quit [Read error: Connection reset by peer]
darkapex has joined #ruby
Zeeraw has joined #ruby
TheFuzzball has joined #ruby
LennyLinux has joined #ruby
beilabs has quit [Ping timeout: 248 seconds]
nomenkun has quit [Read error: Operation timed out]
chile_andes has joined #ruby
sambao21 has joined #ruby
huttan has joined #ruby
darkapex has quit [Ping timeout: 245 seconds]
tenaglia has joined #ruby
<tenaglia>
hi guys
darkapex has joined #ruby
tundrax has joined #ruby
apod has quit [Quit: apod]
ariedler has quit [Remote host closed the connection]
buscon has joined #ruby
_Amaan has quit [Quit: _Amaan]
interactionjaxsn has quit [Remote host closed the connection]
interactionjaxsn has joined #ruby
buscon has quit [Remote host closed the connection]
<sebastianb>
hi
<tenaglia>
I have a loop over an array of hostnames, and I want to run commands on each of them. It works, but now let's say I want to spawn 5 SSH connections in parallel, what would be the best option to do that?
cmarques has quit [Ping timeout: 245 seconds]
apeiros has quit [Ping timeout: 260 seconds]
tjbiddle_ has joined #ruby
bean has quit [Quit: Computer has gone to sleep.]
_bart has quit [Read error: Operation timed out]
<tenaglia>
of course the best would be to "group" stdout/stderr for each host and output them together when each session ends.
tjbiddle has quit [Read error: Operation timed out]
tjbiddle_ is now known as tjbiddle
devoldmx3 has quit [Ping timeout: 248 seconds]
carlyle has quit [Remote host closed the connection]
MarioEIU has joined #ruby
splittingred has quit [Quit: splittingred]
tundrax has quit [Ping timeout: 240 seconds]
monkegjinni has quit [Remote host closed the connection]
Z_Mass has joined #ruby
pipework has joined #ruby
xardas has quit [Ping timeout: 252 seconds]
interactionjaxsn has quit [Ping timeout: 248 seconds]
mikewintermute has quit [Quit: mikewintermute]
alex__c2022 has quit [Quit: alex__c2022]
pipework has quit [Remote host closed the connection]
ipalaus has quit [Ping timeout: 260 seconds]
Kricir has quit [Remote host closed the connection]
failshell has quit [Remote host closed the connection]
beilabs has joined #ruby
ipalaus has joined #ruby
<seejohnrun>
tenaglia: check out csshx
ipalaus has left #ruby [#ruby]
forrest has quit [Quit: Leaving]
<tenaglia>
seejohnrun: thanks I'll have a look.
<seejohnrun>
your mind will blow apart
devoldmx has joined #ruby
benlieb has quit [Quit: benlieb]
<seejohnrun>
tenaglia: and if you want something more automated, it may be worth looking into capistrano
saarinen has quit [Quit: saarinen]
<tenaglia>
seejohnrun: I need to use it on a management server, and from the output of mcollective which I use to get the hosts. For automation I have the puppet stack in place.
chile_andes has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
azuri has joined #ruby
<tenaglia>
so since I can get the mcollective filtering with ruby I was thinking about directly implementing a "parallel ssh" in there
Michael_ has quit [Remote host closed the connection]
gyre007 has quit [Remote host closed the connection]
Michael_ has joined #ruby
tundrax has joined #ruby
dik_dak has quit [Ping timeout: 276 seconds]
dik_dak has joined #ruby
milestone has quit [Quit: milestone]
slash_nick has quit [Ping timeout: 248 seconds]
<tjbiddle>
Is there a native way to check if I'm at the file system root, but on Windows? (eg: / on *nix - but SOME_DRIVE:\ on windows)
<tjbiddle>
Without knowing the Drive letter
johnnyfuchs has quit [Ping timeout: 260 seconds]
wmoxam has quit [Ping timeout: 252 seconds]
teclator has quit [Ping timeout: 276 seconds]
djwonk has joined #ruby
Zai00 has quit [Quit: Zai00]
apod has joined #ruby
teclator has joined #ruby
emergion has joined #ruby
seejohnrun has quit [Ping timeout: 252 seconds]
ia___ has quit [Quit: ia___]
robert_ has quit [Read error: Connection reset by peer]
kiwnix has quit [Ping timeout: 256 seconds]
umren has quit [Ping timeout: 260 seconds]
emergion has quit [Client Quit]
julian-delphiki has quit [Quit: Leaving]
<tjbiddle>
Never mind - regex is my friend here :p
emergion has joined #ruby
sailias has joined #ruby
krombr has joined #ruby
bionhart has joined #ruby
bean has joined #ruby
bean has quit [Max SendQ exceeded]
aedorn has quit [Ping timeout: 264 seconds]
bean has joined #ruby
pcarrier_ has joined #ruby
saarinen has joined #ruby
ybart has quit [Quit: ybart]
troessner has joined #ruby
bionhart has quit [Remote host closed the connection]
dik_dak has quit [Quit: Leaving]
jnoob22 has joined #ruby
<shevy>
tjbiddle there is a constant called PLATFORM
azuri has quit [Quit: Leaving]
<shevy>
ah
zastern_ has quit [Remote host closed the connection]
<shevy>
dunno... perhaps Dir.pwd == '/' ?
aedorn has joined #ruby
zastern has joined #ruby
* tommylommykins
waves
<tommylommykins>
does anyone know what netbeans support for ruby is like atm?
<kenneth>
so… i though everything in ruby was an expression?
<kenneth>
is `module Something; end` not an expression that evaluates to that module?
gaahrdner has joined #ruby
tomsthumb has quit [Quit: Leaving.]
<sam113101>
no
mahmoudimus has quit [Ping timeout: 276 seconds]
obs has quit [Ping timeout: 240 seconds]
RORgasm_ has quit [Read error: Connection reset by peer]
RORgasm_ has joined #ruby
shadoi has joined #ruby
nezumi has quit [Ping timeout: 256 seconds]
kiwnix has joined #ruby
d2dchat has quit [Remote host closed the connection]
mixel has quit [Quit: mixel]
<sam113101>
kenneth: it returns the last evaluated expression I believe, like blocks
<sam113101>
like most* blocks
jgarvey has quit [Quit: Leaving]
<kenneth>
is there a way to create a non-anonymous module in an expression
<sam113101>
what do you mean?
tundrax has quit [Remote host closed the connection]
<sam113101>
kenneth: if you want the module block to return the module, add "self" at the end
<kenneth>
i'd like to give it a name, but still create it inline
<kenneth>
oh wait really?
<kenneth>
wow, neat
<sam113101>
module Test; self end
pitzips has quit [Quit: Leaving]
teclator has quit [Ping timeout: 276 seconds]
angelixd_ is now known as angelixd
ariedler has joined #ruby
skattyadz has quit [Quit: skattyadz]
obs has joined #ruby
momomomomo has quit [Quit: momomomomo]
mmitchell has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
matchaw has quit [Remote host closed the connection]
monkegjinni has quit [Ping timeout: 252 seconds]
Ortuna has quit [Quit: Computer has gone to sleep.]
LucidDreamZzZz has quit [Remote host closed the connection]
anonymuse has quit [Quit: Leaving...]
LucidDreamZzZz has joined #ruby
Ortuna has joined #ruby
Davey has quit [Quit: Computer has gone to sleep.]
robscomputer has quit [Remote host closed the connection]
akells` has quit [Ping timeout: 260 seconds]
epta has quit [Ping timeout: 248 seconds]
robscomputer has joined #ruby
huoxito has joined #ruby
tundrax has joined #ruby
bmn has joined #ruby
Proshot has joined #ruby
jlast_ has quit [Read error: Connection reset by peer]
rhys_ has quit [Quit: Leaving]
robscomputer has quit [Ping timeout: 276 seconds]
apod has quit [Quit: apod]
jlast has joined #ruby
rypervenche has left #ruby ["WeeChat 0.4.0"]
graydot has quit [Read error: Connection reset by peer]
decentrality has quit [Read error: Connection reset by peer]
Eaven has quit [Remote host closed the connection]
graydot has joined #ruby
krainboltgreene has joined #ruby
decentrality has joined #ruby
johnnyfuchs has quit [Remote host closed the connection]
Eaven has joined #ruby
Spami has quit [Quit: Leaving]
`p has joined #ruby
c0rn has quit [Ping timeout: 264 seconds]
eka has quit [Ping timeout: 264 seconds]
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
epta has joined #ruby
mjburgess has quit [Ping timeout: 246 seconds]
c0rn has joined #ruby
eka has joined #ruby
generali_ has joined #ruby
baroquebobcat has quit [Quit: baroquebobcat]
GeissT has joined #ruby
IceDragon has joined #ruby
jfelchner has quit [Ping timeout: 252 seconds]
epta has quit [Ping timeout: 276 seconds]
prophile_ is now known as prophile
devoldmx has quit [Ping timeout: 260 seconds]
prophile has quit [Changing host]
prophile has joined #ruby
jonathanwallace has quit [Ping timeout: 252 seconds]
epta has joined #ruby
arya_ has joined #ruby
gaahrdner has quit [Remote host closed the connection]
generalissimo has quit [Ping timeout: 276 seconds]
pinpin404 has quit [Quit: Screw you guys i'm going home ! KMP ! WeeChat 0.3.9.2]
bradhe has quit [Remote host closed the connection]
devoldmx has joined #ruby
mikepack has quit [Remote host closed the connection]
tundrax has quit [Remote host closed the connection]
Z_Mass has quit [Ping timeout: 260 seconds]
momomomomo has joined #ruby
wsterling has quit [Remote host closed the connection]
epta has quit [Ping timeout: 252 seconds]
epta has joined #ruby
benlieb has joined #ruby
aetaric has quit [Read error: Operation timed out]
devoldmx has quit [Ping timeout: 260 seconds]
danslo has joined #ruby
pskosinski has quit [Remote host closed the connection]
predator117 has joined #ruby
jonathanwallace has joined #ruby
adeponte has joined #ruby
aetaric has joined #ruby
io_syl has quit [Ping timeout: 252 seconds]
epta has quit [Remote host closed the connection]
predator217 has quit [Ping timeout: 256 seconds]
epta has joined #ruby
tjbiddle_ has joined #ruby
bionhart has joined #ruby
johnrlive has joined #ruby
devoldmx has joined #ruby
JZTech101 has quit [Remote host closed the connection]
djbkd has quit [Quit: Leaving]
stkowski has quit [Quit: stkowski]
tjbiddle has quit [Ping timeout: 248 seconds]
tjbiddle_ is now known as tjbiddle
tvw has quit [Ping timeout: 252 seconds]
timkohrumel has quit [Remote host closed the connection]
devoldmx3 has joined #ruby
mnaser has quit [Excess Flood]
machuga|away is now known as machuga
emergion has joined #ruby
arya_ has quit [Ping timeout: 276 seconds]
leonidlm has quit [Read error: Operation timed out]
johnnyfuchs has joined #ruby
mnaser has joined #ruby
emmanuelux has quit [Ping timeout: 276 seconds]
devoldmx has quit [Ping timeout: 260 seconds]
epta has quit [Ping timeout: 260 seconds]
epta has joined #ruby
tomzx_mac has joined #ruby
girija has joined #ruby
arya_ has joined #ruby
LennyLinux has quit [Remote host closed the connection]
LennyLinux has joined #ruby
mahmoudimus has quit [Remote host closed the connection]
khushildep has joined #ruby
bionhart has quit [Remote host closed the connection]
ariedler has quit [Remote host closed the connection]
digitalcake has joined #ruby
<digitalcake>
practicing to write an ruby by making an api gem. Only using spec right now. Where is the best place to put a stub api/client key for testing when building a gem.
LennyLinux has quit [Ping timeout: 252 seconds]
gasbakid has quit [Remote host closed the connection]
bionhart has joined #ruby
jlast has quit [Remote host closed the connection]
tchebb has joined #ruby
bradhe has joined #ruby
Eaven has quit [Read error: Connection reset by peer]
Eaven has joined #ruby
momomomomo has quit [Quit: momomomomo]
mahmoudimus has joined #ruby
<joshu>
digitalcake haven't built a gem myself but are you looking ro keep the api key outside your code, e.g. environment variable?