<Nilium>
I'm telling you it's CSV, it's little-used, nobody has developed an idiomatic way to handle that specific case
<Nilium>
So do what sounds like it's practical and least likely to be clumsy or poorly understood and go with it.
pen has joined #ruby
nilved has joined #ruby
pencilcheck has joined #ruby
<prsn>
i am at work and have no time to argue with you. my question is about the functionality of a standard ruby class, and in particular where i might find an example of its use. If no one knows, I will figure something out or try somewhere else.
DropsOfSerenity has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
pen has quit [Read error: Connection reset by peer]
mneorr has joined #ruby
RORgasm has quit [Remote host closed the connection]
<Nilium>
It's not a standard Ruby class, it's part of the stdlib, which is full of terrible, awful things.
<ccooke>
prsn: the problem is that the CSV format doesn't actually distinguish hrows at all
<ccooke>
prsn: s/hrows/headers from rows/
terrellt_ has joined #ruby
<bricker>
I can't imagine why `nil.empty?` doesn't exist.
einarj has quit [Ping timeout: 272 seconds]
DonRichie has quit [Ping timeout: 245 seconds]
DonRichie has joined #ruby
<Nilium>
Probably 'cause nil isn't empty.
<Nilium>
Nor is it full. It's just nil.
<ccooke>
prsn: so you have to parse the file, which populates your rows. If you happen to know that the first row is headers, you can then patch it from there.
SilverKey has joined #ruby
<bricker>
nil is empty, like /dev/null
<bricker>
empty
<Nilium>
I'll have you know that my /dev/null is a very fulfilled person.
terrellt has quit [Ping timeout: 264 seconds]
<Nilium>
It is not in any way empty.
<prsn>
ccooke: there's an option to the constructor, :headers => :first_row
<bricker>
Nilium: is there a method shared by enumerable and nil that I could use? So I don't have to go `v.nil? || v.empty?`
<prsn>
ccooke: so it's pretty clear that this is an intended use case
<Nilium>
I don't think so.
RichardBaker has joined #ruby
<bricker>
oh well
iceden has quit [Read error: Connection reset by peer]
<ccooke>
prsn: sure, but even then you can't know what the headers are until you parse the file
<prsn>
ccooke: obviously. but it seems like the intent is to be able to parse the headers, and then iterate over the rest while being able to index by them
<Nilium>
You could do !!v | v.empty?
<Nilium>
The single pipe is intentional there
<Nilium>
Though that'd probably still throw an exception, so || might be necessary there..
<Nilium>
*raise an exception
ffranz has joined #ruby
<Nilium>
So !nil || nil.empty? might be sufficient? O_o
peterhu has joined #ruby
<Nilium>
Ok my brain is hurting and I need a demorgan somewhere.
terrellt_ has quit [Ping timeout: 264 seconds]
axl_ has quit [Quit: axl_]
<Nilium>
Could also probably just define empty? for NilClass.
Aloysius1 has quit [Remote host closed the connection]
axl_ has joined #ruby
regaining33 has quit [Quit: regaining33]
petey_ has quit [Ping timeout: 272 seconds]
b00stfr3ak has quit [Ping timeout: 259 seconds]
axl_ has quit [Client Quit]
vlad_starkov has quit [Remote host closed the connection]
andredublin has joined #ruby
aspires has joined #ruby
andredublin has quit [Remote host closed the connection]
lfox has quit [Quit: ZZZzzz…]
andredublin has joined #ruby
AaronCong has joined #ruby
ehc has quit [Quit: ehc]
Spami has quit [Read error: Connection timed out]
julweber has quit [Remote host closed the connection]
tharindu has joined #ruby
mixel has joined #ruby
<ccooke>
prsn: the intent is to accept that there are headers and to provide them as metadata.
andredublin has left #ruby [#ruby]
Spami has joined #ruby
smoothbutta has quit [Remote host closed the connection]
julweber has joined #ruby
shadoi has joined #ruby
_dma has joined #ruby
astrobunny has quit [Ping timeout: 260 seconds]
nilved_ has joined #ruby
matti has quit [Ping timeout: 272 seconds]
pragmatism has quit [Quit: Peace]
pragmatism has joined #ruby
nilved has quit [Disconnected by services]
nilved_ has left #ruby [#ruby]
sergicles has joined #ruby
nilved has joined #ruby
tatsuya_o has quit [Remote host closed the connection]
mrsolo has quit [Quit: This computer has gone to sleep]
tatsuya_o has joined #ruby
<ccooke>
prsn: given what you've said, it looks like what you want is to call object = CSV.new(filename), then object.headers to get the headers, and finally object.each to process the rows sequentiallyu
kevind has quit [Quit: kevind]
julweber has quit [Ping timeout: 260 seconds]
Monie has joined #ruby
simoz has quit [Ping timeout: 272 seconds]
astrobunny has joined #ruby
dllama has joined #ruby
randomnick_ has quit [Remote host closed the connection]
Faris has quit [Ping timeout: 245 seconds]
blischalk has joined #ruby
ffranz has quit [Quit: Leaving]
RichardBaker has quit [Quit: RichardBaker]
matti has joined #ruby
tatsuya_o has quit [Ping timeout: 245 seconds]
freezey has joined #ruby
bklane has quit [Remote host closed the connection]
maletor has quit [Quit: Computer has gone to sleep.]
saarinen has quit [Quit: saarinen]
<dllama>
hi guys. i dont know if this is the correct room to be asking but i'm having some difficulty with a rails4 app and mongo/mongoid. I can't really wrap my head around whether i'm doing something in my code or its an issue with mongoid/rails or the combination of the 2. but even though i'm doing an includes() call, it still makes a query every time i call Model.association in view.
jonathanwallace has quit [Read error: Connection reset by peer]
Volsus has joined #ruby
<burlyscudd>
dllama: #rubyonrails
jonathanwallace has joined #ruby
rickmasta has joined #ruby
<dllama>
burlyscudd, im in there and I asked, as well as in mongoid, but to no avail
<dllama>
so i'm expanding my research
<burlyscudd>
ahh
sergicles has quit [Ping timeout: 265 seconds]
lukec has quit [Quit: lukec]
Skylab has quit [Quit: Skylab]
ldnunes has quit [Ping timeout: 265 seconds]
kevinykchan has joined #ruby
shevy has quit [Ping timeout: 245 seconds]
c0rn has quit [Quit: Computer has gone to sleep.]
xk_id has quit [Quit:
Ahti333_ has joined #ruby
tkuchiki has quit [Remote host closed the connection]
AaronCong has left #ruby [#ruby]
tkuchiki has joined #ruby
coderhs has quit [Ping timeout: 240 seconds]
AaronCong has joined #ruby
brennanMKE has quit [Remote host closed the connection]
sailias has joined #ruby
matti has quit [Ping timeout: 245 seconds]
Ahti333 has quit [Ping timeout: 272 seconds]
Ahti333_ is now known as Ahti333
ldnunes has joined #ruby
nfk has quit [Quit: yawn]
stringoO has joined #ruby
mlpinit has quit [Remote host closed the connection]
Jetchisel has joined #ruby
DropsOfSerenity has joined #ruby
carif has joined #ruby
DropsOfSerenity has quit [Max SendQ exceeded]
mlpinit has joined #ruby
nkts has quit [Quit: x]
tkuchiki has quit [Ping timeout: 265 seconds]
Faris has joined #ruby
DropsOfSerenity has joined #ruby
freezey has quit [Remote host closed the connection]
mrsolo has joined #ruby
vlad_starkov has joined #ruby
mlpinit has quit [Ping timeout: 245 seconds]
jrhe has quit [Quit: jrhe]
lukec has joined #ruby
zz_tsykoduk is now known as tsykoduk
Es0teric has joined #ruby
jrhe has joined #ruby
Es0teric has quit [Max SendQ exceeded]
kitak has joined #ruby
julweber has joined #ruby
shevy has joined #ruby
vlad_sta_ has joined #ruby
Es0teric has joined #ruby
funburn has joined #ruby
Es0teric has quit [Max SendQ exceeded]
Xeago has joined #ruby
Skylab has joined #ruby
headius has joined #ruby
ce_afk is now known as cescalante
astrobunny has quit [Ping timeout: 245 seconds]
Es0teric has joined #ruby
Catie has quit [Ping timeout: 240 seconds]
vlad_starkov has quit [Ping timeout: 272 seconds]
tatsuya_o has joined #ruby
burlyscudd has quit [Quit: Leaving.]
fuhgeddaboudit has quit [Ping timeout: 260 seconds]
dllama has left #ruby [#ruby]
mneorr has quit [Remote host closed the connection]
<bnagy>
basically a Module is a 'bag of code' that can be used in a few ways, some of which get misused by people who aren't writing rubyish ruby
yfeldblum has joined #ruby
jrhe has joined #ruby
vlad_starkov has quit [Ping timeout: 272 seconds]
<kurt21>
A module is a basic namespace for functions. Aka "a bag of code". That makes sense. Why would you have to do a mixin inheritance (include) to use it?
funburn has quit [Quit: funburn]
<bnagy>
you don't - eg the Base64 example
shevy has quit [Read error: Operation timed out]
<bnagy>
it just depends on the module / API etc
sevenseacat has joined #ruby
<bnagy>
by default, module Foo; def my_magic ...; end; end; will not expose my_magic
<bnagy>
because of the way visibility and modules work in general
<bnagy>
to be able to do Foo.my_magic there are options
<bnagy>
I prefer module Foo; def self.my_magic but you can also use class << self, module_function :my_magic or extend self
falood has joined #ruby
Guest83586 has quit [Ping timeout: 272 seconds]
huttan has quit [Ping timeout: 260 seconds]
<bnagy>
you could also grub about in Foo's guts and just find it
devoldmx has quit [Ping timeout: 272 seconds]
petey_ has joined #ruby
nari has quit [Ping timeout: 260 seconds]
toastynerd has quit [Remote host closed the connection]
marcdel has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<bnagy>
so, there's our bar method, but it's an instance method ( same as it would be for a class )
amacgregor has joined #ruby
<bnagy>
but modules can't be instantiated, so we can't get at that method without dirty trick
<kurt21>
why would a module have instance methods if it's just a namespace that can't be instantiated?
<bnagy>
whereas Foo.methods(false) shows us the methods we can actually call on Foo ( the module itself ) which aren't from the normal inheritance chain
<bnagy>
because it makes everything consistent
<bnagy>
a Class in ruby is actually a special kind of module
STONECOLDDEVIN is now known as stonecolddevin
<bnagy>
one of the special behaviours being that you can instantiate it
<kurt21>
It would seem that classes should have only instance methods and no static/class methods. and modules should have static/module methods but no instance methods
DanKnox_away is now known as DanKnox
ngpestelos has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
havenwood has quit [Remote host closed the connection]
<bnagy>
right, but we don't do that, because of the 'everything is an object' ethos
havenwood has joined #ruby
<bnagy>
you can add methods to pretty much anything, even random string instances
<kurt21>
ok, I'm slowly understanding. thanks for the patient explanation.
shevy has joined #ruby
funburn has quit [Quit: funburn]
<bnagy>
so somewhere around here is the big 'turtles all the way down and .. yep my head just exploded' moment
havenwood has quit [Ping timeout: 245 seconds]
Domon has joined #ruby
Catie has joined #ruby
gyre007 has quit [Ping timeout: 240 seconds]
DanKnox is now known as DanKnox_away
patricklamoreux has joined #ruby
Guest66606 has quit [Quit: quit]
whunt has quit [Quit: Computer has gone to sleep.]
krz has joined #ruby
Domon__ has joined #ruby
Domon has quit [Ping timeout: 240 seconds]
toastynerd has joined #ruby
rafacv has joined #ruby
mmitchell has joined #ruby
lukec has quit [Quit: lukec]
mmitchel_ has joined #ruby
toastynerd has quit [Read error: No route to host]
camilasan has quit [Read error: Connection reset by peer]
paolooo has joined #ruby
gauloises has joined #ruby
pushpak has joined #ruby
kil0byte_ has joined #ruby
capicue has quit [Ping timeout: 272 seconds]
hogeo has quit [Remote host closed the connection]
astrobunny has quit [Ping timeout: 272 seconds]
hogeo has joined #ruby
<lxsameer>
how can i remove any duplication in an array
flops has joined #ruby
<tobiasvl>
uniq
<apeiros>
lxsameer: see Array#uniq
julweber has joined #ruby
<lxsameer>
thanks
kil0byte has quit [Ping timeout: 272 seconds]
mneorr has joined #ruby
freerobby has joined #ruby
nomenkun has joined #ruby
shevy has joined #ruby
astrobunny has joined #ruby
dhruvasagar has quit [Ping timeout: 272 seconds]
michael_mbp is now known as zz_michael_mbp
hogeo has quit [Ping timeout: 272 seconds]
sayan has joined #ruby
ramblex has joined #ruby
Astralum has joined #ruby
sayan has quit [Read error: Connection reset by peer]
mneorr has quit [Ping timeout: 240 seconds]
rahulkmr1 has joined #ruby
zz_michael_mbp is now known as michael_mbp
huttan has joined #ruby
freerobby has quit [Ping timeout: 272 seconds]
rahulkmr has quit [Ping timeout: 272 seconds]
Bofu2U has joined #ruby
paolooo has quit [Quit: Page closed]
amacgregor_ has joined #ruby
Macaveli has quit [Ping timeout: 245 seconds]
timonv has joined #ruby
huttan has quit [Remote host closed the connection]
mercwithamouth has joined #ruby
mansi has joined #ruby
Bofu2U has quit [Quit: I outta here.]
kraljev2 has left #ruby [#ruby]
fella5s has quit [Ping timeout: 245 seconds]
TMM has quit [Quit: Ex-Chat]
akemrir has quit [Quit: WeeChat 0.4.2]
Bofu2U has joined #ruby
theRoUS has joined #ruby
theRoUS has joined #ruby
theRoUS has quit [Changing host]
amacgregor_ has quit [Ping timeout: 245 seconds]
kil0byte has joined #ruby
polaco_zZz is now known as polaco
TMM has joined #ruby
rahulkmr1 has quit [Ping timeout: 240 seconds]
stunthamster has joined #ruby
kil0byte_ has quit [Ping timeout: 240 seconds]
mark_locklear has joined #ruby
flops has quit [Ping timeout: 240 seconds]
rgbdev has joined #ruby
mklappstuhl has quit [Remote host closed the connection]
sayan has joined #ruby
sayan has quit [Read error: Connection reset by peer]
ewnd9 has joined #ruby
bluenemo has joined #ruby
larissa has joined #ruby
petey_ has joined #ruby
fella5s has joined #ruby
ravster has quit [Quit: Leaving.]
jkamenik has joined #ruby
pleal has joined #ruby
flower-pot has quit [Ping timeout: 272 seconds]
elux has quit [Quit: Leaving...]
kvirani has joined #ruby
dv__ has joined #ruby
vpretzel has joined #ruby
lurch_ has left #ruby [#ruby]
stringoO has joined #ruby
pleal has quit [Remote host closed the connection]
dv_ has quit [Ping timeout: 260 seconds]
svector has quit [Ping timeout: 265 seconds]
tharindu has quit [Quit: Leaving...]
pleal has joined #ruby
lyanchih has joined #ruby
rgbdev has quit [Quit: rgbdev]
petey_ has quit [Remote host closed the connection]
zoee has quit [Quit: zoee]
kvirani has quit [Ping timeout: 272 seconds]
maz-dev has quit [Read error: Connection reset by peer]
maz-dev has joined #ruby
vpretzel has quit [Ping timeout: 272 seconds]
tylersmith has joined #ruby
pleal has quit [Ping timeout: 245 seconds]
Xeago has quit [Read error: Connection reset by peer]
mklappstuhl has joined #ruby
Astralum has quit [Ping timeout: 240 seconds]
Xeago has joined #ruby
nextdropping has quit [Read error: Operation timed out]
burlyscudd has joined #ruby
brennanMKE has joined #ruby
maz-dev has quit [Remote host closed the connection]
tylersmith has quit [Ping timeout: 240 seconds]
maz-dev has joined #ruby
burlyscudd has quit [Client Quit]
burlyscudd has joined #ruby
rahulkmr has joined #ruby
rahulkmr has quit [Max SendQ exceeded]
Elhu has joined #ruby
pen has joined #ruby
krz has joined #ruby
rahulkmr has joined #ruby
nextdropping has joined #ruby
timonv has quit [Remote host closed the connection]
sambao21 has joined #ruby
timonv has joined #ruby
carif has joined #ruby
brennanMKE has quit [Ping timeout: 272 seconds]
mansi has quit [Read error: Connection reset by peer]
mansi has joined #ruby
timonv_ has joined #ruby
maz-dev has quit [Ping timeout: 272 seconds]
shevy has quit [Ping timeout: 272 seconds]
includex has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
timonv has quit [Read error: Connection reset by peer]
graydot has quit [Quit: graydot]
g0bl1n has joined #ruby
kil0byte_ has joined #ruby
kaldrenon has joined #ruby
dukz has quit [Remote host closed the connection]
vpretzel has joined #ruby
dukz has joined #ruby
dukz has quit [Remote host closed the connection]
cody-- has joined #ruby
raphaelivan has quit [Quit: Leaving.]
dukz has joined #ruby
kil0byte has quit [Ping timeout: 265 seconds]
z3p has joined #ruby
d4heyDU has joined #ruby
jlast has joined #ruby
dukz has quit [Ping timeout: 245 seconds]
capicue has joined #ruby
capicue has quit [Read error: Connection reset by peer]
mklappstuhl has quit [Remote host closed the connection]
yvemath has quit [Read error: Connection reset by peer]
elux has joined #ruby
shevy has joined #ruby
mmitchell has joined #ruby
ngpestelos has quit [Ping timeout: 245 seconds]
kil0byte has joined #ruby
julweber has quit [Remote host closed the connection]
Chryson has joined #ruby
Chryson has quit [Client Quit]
lxsameer has quit [Quit: Leaving]
julweber has joined #ruby
Macaveli has joined #ruby
vlad_sta_ has quit [Remote host closed the connection]
cody-- has quit [Quit: derp]
yvemath has joined #ruby
robbyoconnor has quit [Read error: Operation timed out]
kil0byte_ has quit [Ping timeout: 272 seconds]
Vivekananda_ has quit [Ping timeout: 272 seconds]
bodwin has quit [Remote host closed the connection]
samsonasu has joined #ruby
gja has quit [Quit: This computer has gone to sleep]
mneorr has joined #ruby
xk_id has quit [Quit:
sayan has joined #ruby
freerobby has joined #ruby
julweber has quit [Ping timeout: 245 seconds]
akemrir has joined #ruby
pixelgremlins has joined #ruby
AlSquirrel has joined #ruby
kurt21 has quit [Ping timeout: 272 seconds]
kaspergr_ has quit [Read error: Operation timed out]
julweber has joined #ruby
brahman has joined #ruby
nutella has joined #ruby
tomzx_mac has joined #ruby
nutella is now known as Guest82351
Kneferilis has quit [Quit: Leaving]
mneorr has quit [Ping timeout: 272 seconds]
Xeago has quit [Remote host closed the connection]
freerobby has quit [Ping timeout: 272 seconds]
<brahman>
Hi, I would like to create a multi-dimentional hash like I use in Perl. http://pastebin.com/xLKQrnmA does not work. Does ruby not create the multi-dim hash automatically?
kpshek has joined #ruby
kaspergrubbe has joined #ruby
fgo has quit [Remote host closed the connection]
Kneferilis has joined #ruby
<hoelzro>
brahman: it does not
<hoelzro>
Ruby doesn't autovivify
<hoelzro>
you can use Hash.new(&block) for that behavior
breakingthings has joined #ruby
tkuchiki has joined #ruby
<brahman>
hoelzro: ah ok. can I hash = hash.new; hash[eric] = {:age => 18,:sex => male} instead?
<hoelzro>
you could do that if you wanted
relix has joined #ruby
<brahman>
hoelzro: seems to work.
<brahman>
ah yes. thanks.
ValicekB has quit [Remote host closed the connection]
* brahman
likes ruby more and more
boxmein has joined #ruby
<brahman>
:)
guns has joined #ruby
kazuuu has joined #ruby
ngpestelos has joined #ruby
rickmasta has joined #ruby
devdazed has quit [Quit: Bye]
Jetchisel has left #ruby ["Unfortunately time is always against us -- *Morpheus*"]
zz_polaco has joined #ruby
jonathanwallace has joined #ruby
fixl has quit [Remote host closed the connection]
AlSquirikou has joined #ruby
<banister`sleep>
anyone here upgraded to osx mavericks?
snovak has joined #ruby
AlSquirrel has quit [Read error: Connection reset by peer]
hamakn_ has quit [Remote host closed the connection]
<jkamenik>
banister`sleep: not yet, had a hard time with mountain lion and ruby/rails last time
zz_polaco has quit [Client Quit]
hamakn has joined #ruby
<FastestMilkman>
yes, and my rbenv seems intact
Skylab has joined #ruby
kil0byte_ has joined #ruby
nomenkun has quit [Remote host closed the connection]
ValicekB has quit [Remote host closed the connection]
pleal has quit [Remote host closed the connection]
<TMM>
d4heyDU, oh no, I've picked a parser this is purely about how to split out the application
mklappstuhl has quit [Remote host closed the connection]
sayan has quit [Ping timeout: 272 seconds]
jerius has joined #ruby
<TMM>
I'll come up with something, thanks :)
Nisstyre-laptop has joined #ruby
maz-dev has quit [Remote host closed the connection]
iamjarvo_ has joined #ruby
gregorg has quit [Ping timeout: 245 seconds]
maz-dev has joined #ruby
s2013 has joined #ruby
cibs_ has joined #ruby
robbyoconnor has quit [Read error: Connection reset by peer]
RORgasm has joined #ruby
Faris has joined #ruby
dhruvasagar has joined #ruby
<workmad3>
TMM: structure? a very thin script in bin/ that loads the CLI class and passes in ARGV, etc, the rest in lib/
<workmad3>
TMM: ideally, your CLI class will also be very thin and mostly exist to bind some arguments into some standard ways to use your library :)
carif has quit [Ping timeout: 240 seconds]
freezey has joined #ruby
annath has joined #ruby
bean__ has joined #ruby
iamjarvo has quit [Ping timeout: 272 seconds]
cibs has quit [Ping timeout: 256 seconds]
axl__ has joined #ruby
dv_ has joined #ruby
iamjarvo_ has quit [Ping timeout: 272 seconds]
jcromart_ has joined #ruby
jdenen has joined #ruby
robbyoconnor has joined #ruby
maz-dev has quit [Ping timeout: 272 seconds]
<TMM>
workmad3, ok, that is more or less what I was planning on doing, thank you
shevy has quit [Ping timeout: 240 seconds]
hamakn has joined #ruby
Shidash has quit [Ping timeout: 265 seconds]
zigomir has joined #ruby
<annath>
Hey all. I'm working on a ruby script to manage a system where we're using socat to forward a serial device to a TCP port. My issue is that whenever I use ruby to start socat, socat becomes extremely slow and times out after a few attempts to communicate. I can run the exact command in the terminal and it works fine. I'm using the line `pid = Process.fork{exec "#{cmd}"}` to start the process. Does anyone have any ideas what could be causing t
<annath>
his?
_maes_ has joined #ruby
tonni has quit [Remote host closed the connection]
jprovazn has quit [Quit: Leaving]
kil0byte has quit [Remote host closed the connection]
Monie has joined #ruby
tcort has joined #ruby
johnnyfuchs has joined #ruby
kaspergrubbe has quit [Remote host closed the connection]
<tcort>
is this a good place to ask beginner questions about ruby or is there a better channel/forum?
interactionjaxsn has joined #ruby
includex has joined #ruby
<breakingthings>
tcort: nothing stopping you from asking them here.
hamakn has quit [Ping timeout: 273 seconds]
petey_ has quit [Ping timeout: 240 seconds]
mklappstuhl has joined #ruby
rickmasta has quit [Quit: Leaving...]
<tcort>
what's the best way to initialize an array to all zeros? a 'for' loop or something like this "some_number.times {|n| array[n] = 0}" or is there a better way?
tylersmith has joined #ruby
<workmad3>
tcort: Array.new(size, 0)
<workmad3>
tcort: or [0] * size
<tcort>
awesome, thanks workmad3 :)
mr_red has quit [Ping timeout: 264 seconds]
<workmad3>
tcort: if it's something like a hash, you should use Array.new(size) { make_object_here }
<workmad3>
otherwise you get (probably) undesirable behaviour :)
ngpestelos has joined #ruby
cozby has joined #ruby
<tcort>
okay
mr_red has joined #ruby
<cozby>
anyone else getting SSL cert verification errors from RubyGems?
<cozby>
I was doing gem installs all yesterday without issue and now today I'm getting SSL cannot be verified
<workmad3>
#fail
<cozby>
... kinda sketchy
<cozby>
considering RubyGems was previously hacked...
gregorg_taf has joined #ruby
gregorg_taf has quit [Changing host]
gregorg_taf is now known as gregorg
dash_ has quit [Quit: dash_]
<workmad3>
cozby: browser reckons their SSL cert is fine
brennanMKE has joined #ruby
rickmasta has joined #ruby
sayan has joined #ruby
<cozby>
strange.
kil0byte has joined #ruby
<workmad3>
cozby: same machine?
tylersmith has quit [Ping timeout: 260 seconds]
petey_ has joined #ruby
petey_ has quit [Remote host closed the connection]
chrisja has joined #ruby
Monie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jhaals has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
petey_ has joined #ruby
baordog_ has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
heftig has quit [Quit: Quitting]
burlyscudd has quit [Quit: Leaving.]
<workmad3>
cozby: btw, the rubygems hack was somewhat different from a failed SSL verification :)
shevy has joined #ruby
petey_ has quit [Read error: Connection reset by peer]
tcort has left #ruby [#ruby]
vaudeville18 has quit [Ping timeout: 272 seconds]
petey_ has joined #ruby
<cozby>
workmad3: yep, same box
<cozby>
workmad3: yeah, I know it was the YAML parsing exploit
<workmad3>
cozby: what's the error exactly?
somama has joined #ruby
<daxroc>
Hi all
ValicekB has joined #ruby
_bart has joined #ruby
<cozby>
Bundler::Fetcher::CertificateFailureError: Could not verify the SSL certificate for https://rubygems.org/.
<cozby>
There is a chance you are experiencing a man-in-the-middle attack, but most likely your system doesn't have the CA certificates needed for verification. For information about OpenSSL certificates, see bit.ly/ruby-ssl. To connect without using SSL, edit your Gemfile sources and change 'https' to 'http'.
kaspergrubbe has quit [Read error: Operation timed out]
sambao21 has quit [Quit: Computer has gone to sleep.]
Biohazard has quit [Ping timeout: 245 seconds]
mojjojo has joined #ruby
Monie has joined #ruby
pleal has joined #ruby
daxroc has quit [Quit: Leaving.]
julweber has quit [Remote host closed the connection]
<dawkirst>
Hi, I want to understand something fundamental: do I need to test exceptions?
geekbri has joined #ruby
mmitchel_ has joined #ruby
zigomir has quit [Quit: zigomir]
julweber has joined #ruby
sambao21 has joined #ruby
fmcgeough has joined #ruby
machuga is now known as machuga|away
DonRichie has joined #ruby
kaspergrubbe has joined #ruby
mmitchel_ has quit [Read error: Connection reset by peer]
mmitchel_ has joined #ruby
<TMM>
has anyone here used the 'escort' gem to make CLIs?
kil0byte has joined #ruby
<TMM>
It seems the only one that has the features I need, and the syntax is nice, it kind of behaves a little weird if you tell it to require options though
mmitchell has quit [Ping timeout: 272 seconds]
<ghr>
dawkirst I'm assuming you mean test that they are raised?
jcromart_ has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Xeago has quit [Remote host closed the connection]
rahulkmr has joined #ruby
rahulkmr has quit [Max SendQ exceeded]
rahulkmr has joined #ruby
rahulkmr has quit [Max SendQ exceeded]
Guest48002 has quit [Ping timeout: 240 seconds]
rahulkmr has joined #ruby
rahulkmr has quit [Max SendQ exceeded]
joonty has quit [Ping timeout: 272 seconds]
benweint has joined #ruby
gauloises has quit [Read error: Connection reset by peer]
benweint has quit [Client Quit]
Nogbit has joined #ruby
Nogbit has left #ruby [#ruby]
rahulkmr has joined #ruby
k610 has joined #ruby
rahulkmr has quit [Max SendQ exceeded]
gauloises has joined #ruby
joonty has joined #ruby
rahulkmr has joined #ruby
benweint has joined #ruby
whunt has joined #ruby
apeiros has quit [Remote host closed the connection]
julweber has joined #ruby
dhruvasagar has joined #ruby
ghr has quit [Quit: Computer has gone to sleep.]
i_s has joined #ruby
cozby has joined #ruby
zarubin has joined #ruby
klaut has quit [Remote host closed the connection]
amigo99 has joined #ruby
toastynerd has joined #ruby
_if has joined #ruby
camilasa_ has quit [Remote host closed the connection]
havenwood has joined #ruby
julweber has quit [Ping timeout: 245 seconds]
spider-mario has joined #ruby
barratt has quit [Ping timeout: 272 seconds]
larissa has quit [Quit: Leaving]
kurt21 has quit [Ping timeout: 272 seconds]
blackmesa has joined #ruby
ValicekB has left #ruby [#ruby]
nkts has joined #ruby
nkts has quit [Remote host closed the connection]
shredding has quit [Quit: shredding]
dennus has quit []
snovak has quit [Remote host closed the connection]
larissa has joined #ruby
Elhu has quit [Quit: Computer has gone to sleep.]
noname001 has quit [Ping timeout: 272 seconds]
larissa has quit [Client Quit]
<zipper>
sticky_afk: Learning ruby using the koans. This is such a foreighn way of learning programming.
<zipper>
Learning ruby using the koans. This is such a foreighn way of learning programming.
micho has joined #ruby
rickmasta has quit [Read error: Connection reset by peer]
snovak has joined #ruby
<banisterfiend>
zipper if u don't like it, there's plenty of other ways to learn
coderhs has joined #ruby
<micho>
hello. Is there an elegant solution, to check if request to db returned nil or not, and then make some operations on that object? Like - User.first.name.downcase, which wouldn't fail when User.first == nil
astrobun_ has quit [Ping timeout: 268 seconds]
avril14th has joined #ruby
burlyscudd has quit [Quit: Leaving.]
ValicekB has joined #ruby
adeponte has joined #ruby
swordsmanz has quit [Read error: Connection reset by peer]
<sorbo_>
they abandoned the big cat paradigm for some reason
<apeiros>
sorbo_: out of big cats
<shevy>
it writes... "Power to the desktop"
headius has joined #ruby
<shevy>
does that mean the versions before lacked power???
<sorbo_>
apeiros: pick new cats! e.g. nyancat
<lectrick>
shevy: so a rewrite pretty much. sigh
<havenwood>
sorbo_: A very good reason. But I was indeed looking forward to Saber Tooth Tiger and Common House Cat so they stole that from me.
<sorbo_>
I would probably upgrade to OS X NyanCat
jhaals has joined #ruby
<havenwood>
OS X HelloKitty
<apeiros>
havenwood: oooh, right @ M&S friendly GC in 2.0 - gotta try how well forking works now
<shevy>
lectrick perhaps the project is too big! in my pseudo shell, I have a mysterious bug, in where it feedbacks all aliases before it outputs the specific error. I haven't traced it down yet but I was also too lazy to chase it down... it's a semi-stable heisenbug
yfeldblum has quit [Remote host closed the connection]
pleal has quit [Read error: Connection reset by peer]
<apeiros>
havenwood: lol @ OS X HelloKitty
<havenwood>
FORK ALL THE THINGS \o/
rien has quit [Ping timeout: 246 seconds]
<shevy>
OS X HellKitty
pleal has joined #ruby
blackmes1 has joined #ruby
<apeiros>
FailKitty
brennanMKE has quit [Ping timeout: 252 seconds]
<shevy>
hehe
<apeiros>
srsly, I hope some of 10.8's bugs vanish with mavericks.
<apeiros>
at least it seems like they took their time to polish this one.
as-cii has joined #ruby
Squarepy has quit [Quit: Leaving]
zetaspartan2552 has joined #ruby
<havenwood>
yeah, been really quite polished for the last months
<havenwood>
month*
<shevy>
good
iamjarvo has quit [Read error: Connection reset by peer]
Ox6abe has joined #ruby
<shevy>
you applers
as-cii has left #ruby [#ruby]
rahulkmr1 has joined #ruby
<havenwood>
shevy: ships with 2.0.0-247 :)
<havenwood>
p247
rahulkmr has quit [Ping timeout: 248 seconds]
<shevy>
linux forever, everything compiled from the source!!!
iamjarvo has joined #ruby
<sorbo_>
havenwood: so they skipped 1.9 entirely? last I saw they were shipping 1.8.7
blackmesa has quit [Ping timeout: 240 seconds]
<havenwood>
sorbo_: skipped, Mavericks was the Dev-love update though, so they gave latest
<sorbo_>
havenwood: yeah, makes sense
<havenwood>
sorbo_: ships with 2.0 default and 1.8 available
<sorbo_>
nice
gyre007 has quit [Ping timeout: 272 seconds]
dhruvasagar has joined #ruby
mlpinit has quit [Ping timeout: 268 seconds]
<havenwood>
My one big complaint is they didn't bump to bash 4. I'm a zsh user but causes headache for tools like chruby to have to put up with OS X users who don't zsh or brew a modern bash.
<apeiros>
and all the ruby version managers still work nicely I'd assume…
<apeiros>
havenwood: weird… bash4 is like years old, no?
kaspergrubbe has quit [Remote host closed the connection]
<havenwood>
apeiros: yup.
<yxhuvud>
isn't it some license issue? Like apple not agreeing with gplv3 oslt?
<havenwood>
apeiros: yeah, to bash 4 being old
<apeiros>
iirc I wondered about that with 10.6 already
<havenwood>
yxhuvud: ah, that must be it
<apeiros>
yxhuvud: ah, that'd explain it
<havenwood>
yxhuvud: because it is not very pleasant
<havenwood>
i'm kinda of the opinion of insisting that OS X bash devs update themselves to 4, i just hate supporting the 3 edgecases when there's already plenty to think about with just zsh/bash/ksh compat.
rien has joined #ruby
mlpinit has joined #ruby
mikecmpbll has joined #ruby
_maes_ has joined #ruby
aagdbl has joined #ruby
Macaveli_ has quit [Remote host closed the connection]
DrCode has quit [Remote host closed the connection]
blackmes1 has quit [Write error: Connection reset by peer]
<havenwood>
apeiros: ruby-install and chruby well tested on Mavericks, i'm assuming RVM and rbenv are totally up to speed as well.
<havenwood>
rvm at least :P
mrsolo has quit [Quit: This computer has gone to sleep]
blackmes1 has joined #ruby
Mitchellvanw has joined #ruby
<havenwood>
yeah, no issues left for rbenv either
aagdbl has quit [Client Quit]
SilverKey has quit [Quit: Cheers]
<havenwood>
Mavericks has really be stable for last two months so no nasty suprizes with gold master.
jkline has joined #ruby
Macaveli has joined #ruby
rdark has quit [Quit: leaving]
nhhagen has joined #ruby
Xeago has joined #ruby
ArchBeOS has quit [Read error: Connection reset by peer]
aspires has quit [Quit: sudo making a sandwich]
Monie has quit [Ping timeout: 272 seconds]
ArchBeOS has joined #ruby
pen has joined #ruby
wildroman has joined #ruby
heftig has quit [Quit: Quitting]
jblack has joined #ruby
brennanMKE has joined #ruby
i_s has quit [Remote host closed the connection]
Skylab has quit [Quit: Skylab]
Guest10007 has quit [Read error: Connection reset by peer]
zz_tsykoduk has joined #ruby
enebo has joined #ruby
Ripp__ has quit []
Banistergalaxy has joined #ruby
mlpinit has quit [Remote host closed the connection]
zetaspartan2552 has quit [Quit: zetaspartan2552]
Azulinho has quit [Ping timeout: 245 seconds]
mlpinit has joined #ruby
Seich has quit [Ping timeout: 248 seconds]
tonni has joined #ruby
Skylab has joined #ruby
lfox has quit [Quit: ZZZzzz…]
AndChat| has quit [Ping timeout: 256 seconds]
m8 has joined #ruby
Macaveli has quit [Remote host closed the connection]
pleal has quit [Remote host closed the connection]
mklappstuhl has joined #ruby
nextdropping has quit [Ping timeout: 245 seconds]
yfeldblum has joined #ruby
yfeldblum has quit [Remote host closed the connection]
DonRichie has quit [Quit: Verlassend]
ValicekB has quit [Remote host closed the connection]
jhaals has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
capicue has joined #ruby
plotter has quit [Quit: Leaving]
yfeldblu_ has joined #ruby
<lectrick>
I'm an Appler, shevy, but I have become a bit enamored of the http://elementaryos.org/ distribution... at least until it stopped loading correctly after Installing All The Things™
AndChat| has joined #ruby
lfox has joined #ruby
alvaro_o has joined #ruby
<lectrick>
Since I am running it in a VM, I am having to Save Image before EVERY install just to figure out what the problem is... Not the greatest user experience. OSX is pretty troublefree
srji has quit [Ping timeout: 260 seconds]
ArchBeOS has quit [Quit: ChatZilla 0.9.90.1 [Firefox 24.0/20130910160258]]
<apeiros>
main reason I use apple - it stays out of my way more than other OSes
zarubin has quit [Ping timeout: 260 seconds]
srji has joined #ruby
<joelteon>
dude, the elementary os ad is *fantastic*
<lectrick>
^ exactly
<joelteon>
it's too bad *no* non-apple entity can design a UI worth shit
<lectrick>
to apeiros
jaimef has quit [Excess Flood]
Banistergalaxy has quit [Ping timeout: 272 seconds]
<apeiros>
joelteon: I remember ~15y ago I had high hopes for linux
<apeiros>
I thought it should be easy to get there in 5-10y
mklappstuhl has quit [Ping timeout: 256 seconds]
tatsuya_o has quit [Remote host closed the connection]
<apeiros>
yet last time I tried linux for the desktop, I was largely disappointed. been ~4y now, though. I might try again.
<lectrick>
Elementary Luna is probably the closest I've seen to realizing that vision. Even if it does feel like an OS X knockoff
picker has quit [Quit: Leaving]
zz_tsykoduk is now known as tsykoduk
<apeiros>
if it feels like an OS X knock-off: great
<apeiros>
great artists copy
tatsuya_o has joined #ruby
<joelteon>
yeah, but it's a shitty knockoff
eph3meral has joined #ruby
<lectrick>
apeiros: I recommend trying it
<joelteon>
i won't be sitting there thinking "hey, this OS looks nice"
<joelteon>
i'll be thinking "hey, OSX does that ui element a lot better"
<lectrick>
joelteon: It's new. Give it time. If I have a terminal, Sublime, and Steam and a few games, and Chrome... I'm a happy camper.
jaimef has joined #ruby
<apeiros>
I don't even need games
<joelteon>
i'd rather someone go in a different direction than windows or osx, to be honest
<apeiros>
that's the one reason I have a windows box for
<joelteon>
last year i ran arch for awhile
<joelteon>
and used i think openbox
elaptics`away is now known as elaptics
<lectrick>
Steam has sort of committed to Linux so I expect Linux to be the future "gaming OS"
<joelteon>
it was a really simple, really flat design
<joelteon>
probably my favorite OS design i've ever used
<apeiros>
funny enough - even though I spend less than 1/20th of my time in windows compared to osx, I still have more to swear about it (and believe me, I have my quibbles with OS X too…)
<lectrick>
joelteon: I agree but people hate change
<joelteon>
uhh, UI design
<joelteon>
whatever
k610 has joined #ruby
Astralum has joined #ruby
rahulkmr1 has quit [Read error: Connection reset by peer]
<lectrick>
apeiros: same here. i did windows admin for a bit in a prior life, oh the horrors.
Sammael has joined #ruby
<joelteon>
OH it was fluxbox
<joelteon>
that's what it was
<apeiros>
lectrick: I love the "Oh look, I installed some updates. I don't care what you're doing right now, I'll just reboot."
ArchBeOS has joined #ruby
<joelteon>
oh, also, the windows were borderless because i was using xmonad
<joelteon>
and unfocused windows were semitransparent
<joelteon>
probably the most beautiful UI i've ever used
<lectrick>
apeiros: Yep. Fuck you and your work, we have security patches to apply NOW!
<lectrick>
At least OS X apps (now) save their state and restore on restart
<apeiros>
lectrick: Fuck you and your online game which is ranked. I'll force-quit you out of it.
grn has joined #ruby
ArchBeOS is now known as RicFlair
tatsuya_o has quit [Ping timeout: 248 seconds]
carlyle has joined #ruby
<apeiros>
(I'm not masochistic enough to do actual work on my windows box)
<sorbo_>
if I remember right, windows is also super fine-grained with user types
<sorbo_>
in terms of who has permission to do what
<sorbo_>
that annoyed me for the seven minutes I did anything on windows ever
<lectrick>
It's funny because Apple used to be made fun of as being a "toy" so Jobs never committed to games on Mac at all. Then they ended up "killing it" with games on iOS, now Steam wants to take the party to Linux. Microsoft languishes.
tonni has quit [Remote host closed the connection]
rahulkmr has joined #ruby
<lectrick>
sorbo_: Windows has a very comprehensive (complex) security model. It works great IF everything is set up correctly (which is nearly impossible, so Windows often ignores its own security protocols).
<sorbo_>
lectrick: I'll buy that
<lectrick>
Most of the troubleshooting I ended up having to do on Windows ended up being a permissions issue since it was so ridiculously comple
<lectrick>
x
<sorbo_>
seriously
DropsOfSerenity has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
prsn has quit [Quit: Lost terminal]
zetaspartan2552 has joined #ruby
<lectrick>
Can you even run a viable Windows install as a "pure" user (no admin rights or only manually-escalated admin rights), yet?
zetaspartan2552 has quit [Client Quit]
Senjai has joined #ruby
Senjai has quit [Changing host]
Senjai has joined #ruby
* lectrick
knows he's probably preaching to the choir here and should probably go troll #windows instead
jmaister has quit [Quit: Reconnecting]
jmaister has joined #ruby
DropsOfSerenity has joined #ruby
bocaneri has quit [Remote host closed the connection]
<sorbo_>
I don't know many debs who use windows, and the ones I _do_ know all work at MSFT, where they've mostly drunk the kool-aid
<sorbo_>
(not that everyone does, but these guys have)
<sorbo_>
they all have zunes and windows phones and it makes me depressed
danshultz has quit [Read error: Connection reset by peer]
<apeiros>
the example sorted the array by the absolute value of the numbers
<daimonic>
oks
<zipper>
apeiros: lol this is all I see:
<daimonic>
not terribly new but it doesnt have to be I guess
<zipper>
" You have not yet reached enlightenment. I sense frustration. Do not be afraid to ask for help. "
danshultz has joined #ruby
wallerdev has joined #ruby
<apeiros>
zipper: there's no part that reads something like "false is not NoMethodError"?
<sweeper>
what, I have to change my window manager AGAIN?
mark_locklear has quit [Ping timeout: 245 seconds]
elux has quit [Quit: Bye!]
ffranz has quit [Quit: Leaving]
<zipper>
apeiros: " Expected "FILL ME IN" to equal NoMethodError "
<apeiros>
there
thirdender has left #ruby ["PONG :sendak.freenode.net"]
vaudeville18 has quit [Remote host closed the connection]
<zipper>
I did try with false at first because that is what I expected but that failed.
<ShellFu>
sweeper, what you usin? Im quite partial to fluxbox
<zipper>
This way of learning a language is weird man.
<ShellFu>
but I love VTs
<zipper>
apeiros: how'd you learn?
<apeiros>
zipper: I wrote code
allaire has joined #ruby
<apeiros>
zipper: that message tells you what it expects
_dma has quit [Remote host closed the connection]
<sweeper>
ShellFu: was a joke re: enlightenment. I use xmonad, used flux a couple years then openbox for a bit, and now I waste no screen space or cycles, it is wunderbar
_dma has joined #ruby
geekbri has quit [Remote host closed the connection]
Mitchellvanw has quit [Quit: Quiting like a baws]
danshult_ has joined #ruby
kevinykchan has joined #ruby
peregrine81 has joined #ruby
benweint has joined #ruby
jmccune has quit [Ping timeout: 256 seconds]
nateberkopec has quit [Quit: Leaving...]
Bira has quit [Remote host closed the connection]
mark_locklear has joined #ruby
tatsuya_o has quit [Remote host closed the connection]
skogis has quit [Read error: Connection reset by peer]
end_guy has joined #ruby
nateberkopec has joined #ruby
danshultz has quit [Ping timeout: 272 seconds]
_dma has quit [Ping timeout: 265 seconds]
havenwood has joined #ruby
theoretick has joined #ruby
pleal has joined #ruby
spider-mario has quit [Quit: No Ping reply in 180 seconds.]
zipper has quit [Quit: leaving]
allsystemsarego has quit [Quit: Leaving]
angusiguess has quit [Ping timeout: 245 seconds]
spider-mario has joined #ruby
mlpinit has joined #ruby
wildroman has quit [Remote host closed the connection]
barratt has joined #ruby
pleal has quit [Remote host closed the connection]
odogg has left #ruby ["Leaving"]
amacgregor_ has joined #ruby
pleal has joined #ruby
<amigo99>
hey guys, just wondering, what Continuous Integration tool do you use for private git repositories?
dash_ has quit [Quit: dash_]
theoretick has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<nobitanobi>
If I have a code that looks like this Timeout.timeout(10) do myvar = getvarvalue(...) end -- How can I make myvar accessible out of the block?
<shevy>
nobitanobi, just store it in an @ivar?
baordog_ has quit [Remote host closed the connection]
<nobitanobi>
hum
<nobitanobi>
shevy: can you point me to why does this happen?
<shevy>
why does what happen :)
mmitchel_ has quit [Remote host closed the connection]
<shevy>
you mean that local variables are local to the block?
sergicles has quit [Quit: sergicles]
ner0x has joined #ruby
<shevy>
that is probably consistent with how local variables are used elsewhere, i.e. if you define one in a method, they are pertaining to that method, and don't exist outside of the method
dkamioka has quit [Ping timeout: 252 seconds]
aspires has quit [Quit: sudo making a sandwich]
orien has joined #ruby
sunnymolini1 has quit [Ping timeout: 245 seconds]
cozby has quit [Ping timeout: 272 seconds]
brennanMKE has quit [Remote host closed the connection]
brennanMKE has joined #ruby
kreeves has joined #ruby
<volty>
trolling scope
<volty>
the wife's agenda is in wife's scope, that of both is in the sleeping room
<Socket->
I was able to resolve that error by installing celt-devel , but now i am getting a new error. Can anyone help me figure out whats going on in this stack trace? http://apaste.info/5T4Y
dcunit3d has quit [Quit: dcunit3d]
zz_taion809 is now known as taion809
<volty>
the family in the kitchen, the public goes in the gardne
<volty>
garden
tvw has quit []
justsee has joined #ruby
amigo99 has quit [Quit: This computer has gone to sleep]
maxmanders has joined #ruby
ngpestelos has quit [Ping timeout: 260 seconds]
robbyoconnor has joined #ruby
marcdel has joined #ruby
marcdel has quit [Max SendQ exceeded]
Seich_ has quit [Quit: Computer has gone to sleep.]
brennanMKE has quit [Ping timeout: 268 seconds]
matti has quit [Ping timeout: 268 seconds]
marcdel has joined #ruby
Seich_ has joined #ruby
mercwithamouth has joined #ruby
newbiehacker has quit [Ping timeout: 248 seconds]
<volty>
Pattern Freak
<volty>
ops! Antipattern Freak!
mansi has joined #ruby
mlpinit has joined #ruby
jerius has joined #ruby
enebo has quit [Quit: enebo]
Seich_ has quit [Read error: Connection reset by peer]
apeiros has quit [Read error: Connection reset by peer]
Seich_ has joined #ruby
apeiros has joined #ruby
brennanMKE has joined #ruby
Ox6abe has quit [Remote host closed the connection]
<shevy>
wat
<shevy>
are you drunk again
<daimonic>
yes!
<daimonic>
hello rather
Tuxist has quit [Read error: Connection reset by peer]
cody-- has quit [Quit: derp]
<bricker>
Is there a better way to do this that doesn't require iterating 3 times?
<volty>
just tired, got the name for the freaks that talk too much about design patterns, it was the title for an essay about one of the antipatterns -- just identified
hadees has quit [Quit: hadees]
jlast has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 240 seconds]
<volty>
bricker: you can only drop the last one, but at the cost of complicating the block of the second, not worth, and wonder why are you thinking about such 'savings'
<bricker>
volty: because it's my job to think about those things
einarj has quit [Remote host closed the connection]
allaire has quit []
<volty>
ok ok, let me hope your are paid more than the clock difference cost :)
<shevy>
hmmm
<shevy>
bricker perhaps you could eliminate the last reverse
aspires has joined #ruby
<shevy>
if you could reverse inside .sort_by
<bricker>
shevy: yes, I could use sort instead of sort_by... I think that'll be faster
petey_ has quit [Remote host closed the connection]
<volty>
without 'perhaps', there's always a mapping to reverse value if there is reverse all
mansi has quit [Remote host closed the connection]
<ShellFu>
shit its 4:30
<ShellFu>
training
petey_ has joined #ruby
<ShellFu>
opps wrong room
ShellFu has quit [Quit: Leaving]
<bricker>
volty: is there reverse value for Time objects?
mansi has joined #ruby
johnnyfuchs has quit [Quit: Leaving.]
burlyscudd has quit [Quit: Leaving.]
yfeldblum has quit [Remote host closed the connection]
<volty>
of course -- in the context of reverse order
marcdel has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<bricker>
volty: I don't know what you're saying
Flashmasterson has joined #ruby
<volty>
you map your values to inverse
amigo99 has joined #ruby
mansi has quit [Read error: Connection reset by peer]
<bricker>
volty: but there is no such thing as a negative date
<bricker>
But I can convert to integer, so I think that's what I'll do
<volty>
just put that to_i
RichardBaker has quit [Quit: RichardBaker]
aspires has quit [Quit: sudo making a sandwich]
<nobitanobi>
shevy: sorry, my dog needed my attention :) - I see, thank you
<apeiros>
bricker: so if today is the year 2000, what year was it 4000 years ago?
<shevy>
teach your dog ruby man
snovak has quit [Remote host closed the connection]
<shevy>
-2000 !!!
ericmathison has joined #ruby
<shevy>
odd... I actually never saw negative years... :\
<volty>
there's a hole
snovak has joined #ruby
<shevy>
hehehe
dcunit3d has joined #ruby
<volty>
they didn't want to go till zero :)
ewnd9 has joined #ruby
mansi has quit [Ping timeout: 272 seconds]
aspires has joined #ruby
mlpinit has quit [Remote host closed the connection]
<apeiros>
date as 'year+month+dayofmonth' is just a representation of "numbers of days since X"
<bricker>
apeiros: Can't tell if you're joking or not
<apeiros>
and negative date is just a matter of what your reference point is
<shevy>
the swiss are always joking
mlpinit has joined #ruby
mary5030 has quit [Ping timeout: 248 seconds]
<apeiros>
bricker: your "there is no such thing as a negative date" is wrong. the above was to make a point.
<volty>
full of sense of humor - much like hal
nisstyre has quit [Quit: Leaving]
<shevy>
oh man, hal was evil
tatsuya_o has quit [Remote host closed the connection]
<apeiros>
volty: hal had a nice sense of humor indeed, so sad he had to die
mansi has joined #ruby
justsee has quit [Ping timeout: 260 seconds]
jerius has quit []
<shevy>
:)
axl_ has joined #ruby
<bricker>
apeiros: eh... I don't feel like getting into a philosophical debate about "What Is Time?" so late in the day
monkegjinni has quit [Remote host closed the connection]
<volty>
yap, but wasn't evil, just executing his duty :)
gyre007 has quit [Ping timeout: 268 seconds]
<apeiros>
bricker: there's nothing philosophical about it. unless you think physics & maths are philosophical.
monkegjinni has joined #ruby
<shevy>
volty hmmm his duty wasn't to murder one of the two crew members!
<shevy>
I am going to find out in what programming language hal was written in
burlyscudd has joined #ruby
snovak has quit [Ping timeout: 265 seconds]
<volty>
yes, like in the wars, i hope you are not one of those pacifists that hate uniforms
brennanMKE has quit [Remote host closed the connection]
chrisja has quit [Quit: leaving]
brennanMKE has joined #ruby
mlpinit has quit [Ping timeout: 268 seconds]
<bricker>
apeiros: What is "December 8th, 2008"? A relative date from an arbitrary other date? What is "Date"? Who decided what a Month is? Were they correct? What is Date 0? The beginning of earth? Beginning of time? Is time linear? Cyclical? How can anybody ever possibly know?
<bricker>
apeiros: there, I got it all out in one message, now I'm done talking about it.
barratt has quit [Quit: Leaving...]
<apeiros>
bricker: "A relative date from an arbitrary other date?" yes.
<volty>
« <bricker> volty: but there is no such thing as a negative date »
<apeiros>
"Who decided what a Month is?" historic
<bricker>
apeiros: Fine, then all I meant was `-Time.now` doesn't work.
<apeiros>
"What is Date 0?" depends on your definition
<bricker>
apeiros: lol
<bricker>
apeiros: Why doesn't -Time.now work, then ?
<apeiros>
bricker: because it's not defined
<volty>
it is day 0 --- much like ground 0 :)
<bricker>
apeiros: Define it.
pleal has quit [Ping timeout: 260 seconds]
elaptics is now known as elaptics`away
<bricker>
apeiros: I want to see how *you* would define it.
<apeiros>
because that's what time internally uses
SHyx0rmZ has quit [Quit: ネウロイを負かさなきゃならないね]
<shevy>
there is day 0 volty!
<shevy>
the world started 1970
i_s has quit [Remote host closed the connection]
monkegjinni has quit [Ping timeout: 240 seconds]
agjacome has quit [Quit: leaving]
<apeiros>
bricker: the point is "arbitrary other date" - yes, *arbitrary*
<volty>
yes, and i was born few years before :)
<bricker>
apeiros: Still incorrect though. That's not a negative time, it's just a negative number of seconds from 1970.
<apeiros>
"date" is an infinite counting up on a linear number
<bricker>
lol
<bricker>
apeiros: I thought I said I wasn't going to talk abou tthis
<apeiros>
bricker: your lol doesn't make what you say any more correct
<daimonic>
tossing client
daimonic has left #ruby [#ruby]
<bricker>
apeiros: yes it does.
i_s has joined #ruby
<apeiros>
bricker: guess why you can express the same date as year-month-day, year-week-weekday, year-yearday - because it's just representation
_if has quit [Quit: leaving]
<apeiros>
representation of a value which is counted up by 1 every day
<volty>
we'd better go with the first mine, just go with a.d. 4000 (well beyond the end of our world) and subtract your days
<bricker>
apeiros: this is the most ridiculous argument I've ever had
popl has quit [Quit: We must make an idol of our fear, and call it God.]
<bricker>
apeiros: Can we argue about the meaning of life next?
<bricker>
See, *I* think life exists to perpetuate other life
<bricker>
But then, where does it end?
<apeiros>
bricker: no. but sadly you seem to lack the ability to understand abstraction.
sambao21 has quit [Quit: Computer has gone to sleep.]
mansi has quit [Remote host closed the connection]
Jake232 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
RichardBaker has joined #ruby
brennanMKE has quit [Ping timeout: 272 seconds]
<shevy>
bricker how did life start if it perpetuates other life?
<volty>
yes, i agree about the last one: it is all about abstraction
mansi has joined #ruby
larissa has joined #ruby
<apeiros>
all it needs for a date to be negative is the definition of where 0 is on that "line" (in the graphical sense - german has a better word for it) of date
<bricker>
oh shit an IRC gang
<volty>
bricker: no, i'm joking
<volty>
i hate gangs
freerobby has quit [Quit: Leaving.]
<shevy>
bricker nah, I don't care about time but you mentioned life!!!
<bricker>
apeiros: you are trying to pick a fight, go do something else.
<apeiros>
bricker: unlike you I've actually implemented a full date library. unlike you, I know what I'm talking about.
ngpestelos has joined #ruby
<apeiros>
I don't need to fight.
<volty>
yes apeiros could better drink an aperol
<Flashmasterson>
there's an instruction in 'the well-grounded rubyist' to create a generic object be means of obj = Object.new but black doesn't specify if it's supposed to be made in ruby, irb, or as a text file. thoughts?
dcunit3d has quit [Quit: dcunit3d]
<Flashmasterson>
*by means
<shevy>
Flashmasterson irb
<bricker>
apeiros: damn, wow! And how big *is* your penis?
<shevy>
not sure what you mean with text file or ruby though
<apeiros>
bricker: dangerous grounds.
<volty>
no no
<shevy>
Flashmasterson you can also use the bot here
<shevy>
I propose to call this the AlmostBasicObject
VTLob has quit [Quit: VTLob]
aspires has joined #ruby
<volty>
an amusing one... they say that orson wells said that switzerland had a centuries of piece, while italy had wars, killings, poisoning etc etc, // but, at the end, italy produced Michlelangelo, Leonardo .... (long) and Switzerland the cuckoo-clock
<apeiros>
bricker: anyway - "provide a negative date": "-1 in unix epoch", there. You can get it via Time.at(-1). you know, there's more than just the gregorian calendar to express a date.
carif has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
<apeiros>
volty: I think those have actually been our northern neighbors (might be wrong, tho)
<shevy>
volty it's true, macciavelli lived in a time when italy was very divided and the rulers fighting one another whereas switzerland was more united in itself
_bart has quit [Remote host closed the connection]
<volty>
true, weren't italians at those times
mansi has joined #ruby
nfk has quit [Quit: yawn]
mansi has quit [Remote host closed the connection]
peterhu has quit [Ping timeout: 264 seconds]
<Flashmasterson>
shevvy: here i'll copy n paste what he says to do, maybe you can help me see the light
<volty>
ah, shevy, btw you should make your own time class if you have to do extensive datetime calculus
<shevy>
oh man, I am going to hate time
agreim has joined #ruby
<shevy>
that thing I am trying to write should have been finished an hour ago!
<volty>
maybe you can find some gem around
Xeago has quit [Remote host closed the connection]
dangerousdave has quit [Ping timeout: 260 seconds]
agreim has quit [Quit: Leaving]
<shevy>
no!
<shevy>
I am writing at.rb
<volty>
to write something like my_date.days += 4
xk_id has joined #ruby
orien has quit [Read error: Connection reset by peer]
Azulinho has joined #ruby
<shevy>
so that I can have an alarm clock when I must wake up
<shevy>
at 07:23:22
ewnd9 has quit [Ping timeout: 272 seconds]
atmosx has joined #ruby
<volty>
oh dear!
Varun__ has quit [Quit: Leaving]
pdtpatrick has quit [Quit: leaving]
jcromart_ has joined #ruby
capicue has joined #ruby
pdtpatrick has joined #ruby
sambao21 has joined #ruby
<volty>
i wrote that one just for a count-down timer mm:ss in (qt gui) // mainly for the coffee that comes out good at slow fire (10 minutes exactly)