arubin has quit [Quit: Computer has gone to sleep.]
dingus_khan has quit [Remote host closed the connection]
sush24 has joined #ruby-lang
nathanstitt has joined #ruby-lang
havenwood has quit [Remote host closed the connection]
nathanstitt has quit [Client Quit]
redbaritone has quit [Quit: redbaritone]
apeiros has joined #ruby-lang
krohrbaugh has joined #ruby-lang
apeiros has quit [Ping timeout: 264 seconds]
krohrbaugh has quit [Ping timeout: 264 seconds]
havenwood has joined #ruby-lang
hogeo has joined #ruby-lang
<zzak>
S7278d4n/wi 7
<zzak>
mt
zzak has quit [Quit: leaving]
zzak has joined #ruby-lang
ryez has joined #ruby-lang
jsullivandigs has quit [Remote host closed the connection]
jsullivandigs has joined #ruby-lang
<Rakko>
wat
<zzak>
i dont know how to use a computer
<matti>
zzak: God dammit
<matti>
zzak: Stop being such a fan boy on twiter and go get some nice sushi ;p
xxaM has quit [Ping timeout: 256 seconds]
jsullivandigs has quit [Ping timeout: 248 seconds]
hogeo has quit [Read error: Connection reset by peer]
hogeo has joined #ruby-lang
Rakko has quit [Quit: Bye]
wallerdev has quit [Quit: wallerdev]
DomKM has quit [Quit: Leaving.]
krohrbaugh has joined #ruby-lang
bugg has joined #ruby-lang
justinmb_ has quit [Remote host closed the connection]
kristofferrr has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 264 seconds]
cordax has quit [Quit: Computer has gone to sleep.]
<zzak>
?
<erikh>
hello
<zzak>
hi
<erikh>
trying out ubuntu desktop so I can do more with docker
<erikh>
this is ... actually not bad at all
<erikh>
I could totally use this full-time
alex_ has joined #ruby-lang
<erikh>
13.04 that is
<erikh>
fonts are better than on my mac, which is a feat unto itself.
alex_ has quit [Client Quit]
alex_ has joined #ruby-lang
alex_ has left #ruby-lang [#ruby-lang]
Guest85414_ has quit [*.net *.split]
PaulePanter has quit [*.net *.split]
vgoff has quit [*.net *.split]
danrabinowitz_ has quit [*.net *.split]
znz_v has quit [*.net *.split]
kke has quit [*.net *.split]
snk has quit [*.net *.split]
nirix has quit [*.net *.split]
bri has quit [*.net *.split]
droptone has quit [*.net *.split]
whitequark has quit [*.net *.split]
Y_Ichiro has quit [*.net *.split]
tarruda has quit [*.net *.split]
justinmcp_ has quit [*.net *.split]
_ko10 has quit [*.net *.split]
foca has quit [*.net *.split]
cyndis has quit [*.net *.split]
cout has quit [*.net *.split]
Mellett68 has quit [*.net *.split]
fumduq- has quit [*.net *.split]
tris has quit [*.net *.split]
Y_Ichiro has joined #ruby-lang
Y_Ichiro has quit [Changing host]
Y_Ichiro has joined #ruby-lang
justinmcp has joined #ruby-lang
cyndis has joined #ruby-lang
whitequark has joined #ruby-lang
_ko1 has joined #ruby-lang
fumduq has joined #ruby-lang
tris has joined #ruby-lang
tarruda has joined #ruby-lang
rippa has joined #ruby-lang
<rue>
Fonts schmonts. Retina
danrabinowitz has joined #ruby-lang
foca has joined #ruby-lang
kke has joined #ruby-lang
cout has joined #ruby-lang
snk has joined #ruby-lang
rickyrickyrice has joined #ruby-lang
vgoff has joined #ruby-lang
bri has joined #ruby-lang
Senjai has quit [Ping timeout: 245 seconds]
Mellett68 has joined #ruby-lang
Mellett68 has quit [Read error: Operation timed out]
Mellett68_ has joined #ruby-lang
sush24 has quit [Quit: This computer has gone to sleep]
jsullivandigs has joined #ruby-lang
teleological has joined #ruby-lang
nirix has joined #ruby-lang
zmike has joined #ruby-lang
rafeed has quit [Quit: Leaving.]
rickyrickyrice has quit [Remote host closed the connection]
anildigital_work has quit [Quit: Connection closed for inactivity]
Mon_Ouie has quit [Quit: WeeChat 0.4.0]
Mon_Ouie has joined #ruby-lang
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby-lang
tdy has quit [Read error: Connection reset by peer]
tdy has joined #ruby-lang
nirix has quit [*.net *.split]
krohrbaugh has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 264 seconds]
cordax has joined #ruby-lang
nirix has joined #ruby-lang
_ko1 has quit [Quit: Quit Nadoka 0.8.4+git(v0.8.3-5-g0ae819a-dt)]
L0rdShrek____ has quit [Quit: Connection closed for inactivity]
_ko1 has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 252 seconds]
nathanstitt has joined #ruby-lang
hhatch has joined #ruby-lang
nathanstitt has quit [Ping timeout: 256 seconds]
sush24 has joined #ruby-lang
setmeaway has quit [Read error: Connection reset by peer]
xxaM has joined #ruby-lang
vlad_starkov has joined #ruby-lang
barttenbrinke has joined #ruby-lang
jbsan has quit [Quit: jbsan]
solars has joined #ruby-lang
bastilian has joined #ruby-lang
vlad_starkov has quit [Remote host closed the connection]
vlad_starkov has joined #ruby-lang
barttenbrinke has quit [Ping timeout: 256 seconds]
krohrbaugh has joined #ruby-lang
scholar01 has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 264 seconds]
<scholar01>
When packaging datafiles in a gem, what directory do I put them in and how am I supposed to reference them? I've read several things online, all cursory and contradictory.
<whitequark>
I do /data/ and File.expand_path('../../data', __FILE__)
<whitequark>
foolproof way
tomzx_mac has quit [Ping timeout: 256 seconds]
<scholar01>
Since I've seen that on one of the webpages and it makes the most sense, I'll go with that. Thanks, wq.
pipework has quit [Remote host closed the connection]
knu0 has quit [Read error: Connection reset by peer]
epus has joined #ruby-lang
cordax has quit [Quit: Computer has gone to sleep.]
lsegal has quit [Quit: Quit: Quit: Quit: Stack Overflow.]
teleolog_ has quit [Remote host closed the connection]
setmeaway has joined #ruby-lang
vlad_starkov has quit [Remote host closed the connection]
dhruvasagar has quit [Read error: Operation timed out]
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
krohrbaugh has joined #ruby-lang
jbsan has quit [Quit: jbsan]
henrikhodne has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 264 seconds]
jbsan has joined #ruby-lang
mistym has quit [Remote host closed the connection]
cofin has quit [Quit: cofin]
mistym has joined #ruby-lang
mistym has quit [Changing host]
mistym has joined #ruby-lang
cofin has joined #ruby-lang
jsullivandigs has quit [Remote host closed the connection]
jsullivandigs has joined #ruby-lang
mistym has quit [Remote host closed the connection]
jsullivandigs has quit [Ping timeout: 245 seconds]
pskosinski has joined #ruby-lang
geson has joined #ruby-lang
jbsan has quit [Quit: jbsan]
teleological has joined #ruby-lang
jbsan has joined #ruby-lang
vlad_starkov has joined #ruby-lang
jbsan has quit [Client Quit]
nathanstitt has joined #ruby-lang
teleological has quit [Ping timeout: 252 seconds]
vlad_starkov has quit [Read error: Connection reset by peer]
vlad_sta_ has joined #ruby-lang
faces has quit [Read error: Connection reset by peer]
Nisstyre-laptop has quit [Quit: Leaving]
vlad_sta_ has quit [Read error: Connection reset by peer]
nathanstitt has quit [Ping timeout: 264 seconds]
vlad_starkov has joined #ruby-lang
vlad_sta_ has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 264 seconds]
zommi has joined #ruby-lang
ruurd has joined #ruby-lang
epus has joined #ruby-lang
mikewintermute has joined #ruby-lang
face has joined #ruby-lang
krohrbaugh has joined #ruby-lang
mikewintermute has quit [Quit: mikewintermute]
benanne has joined #ruby-lang
PaulePanter has joined #ruby-lang
face has quit []
krohrbaugh has quit [Ping timeout: 264 seconds]
dc5ala has joined #ruby-lang
nathanstitt has joined #ruby-lang
barttenbrinke has joined #ruby-lang
nathanstitt has quit [Client Quit]
srji has joined #ruby-lang
retro|cz has joined #ruby-lang
<manveru>
postmodern: any idea how to make optional arguments for cinch-commands? also how's the order of the arguments done, or do you rely on the insertion order?
knu0 has joined #ruby-lang
<postmodern>
manveru, hmm i could hack in optional arguments
<postmodern>
manveru, argument order is determined by the order in which you define them
<postmodern>
manveru, i could do arg: [:integer, :optional] ?
Criztian has quit [Remote host closed the connection]
<postmodern>
manveru, in >= 1.9 hash order is preserved
symm- has joined #ruby-lang
<manveru>
yeah, i know
<manveru>
but it may change in 2.0+
<manveru>
just wondering why it's not an array like [:integer, :text]
<manveru>
since you throw the keys away anyway
<manveru>
except for the help, that is ^^;
<manveru>
i guess i should get some coffee first
<postmodern>
yeah will have to come back to cinch-commands
<manveru>
anw, it works well enough for now, i just need optional args
workmad3 has joined #ruby-lang
teleological has joined #ruby-lang
Xzyx987X has joined #ruby-lang
Xzyx987X_ has quit [Ping timeout: 256 seconds]
ruurd has joined #ruby-lang
zmike has quit [Quit: Выходжу]
ruby-lang487 has joined #ruby-lang
ruurd has quit [Client Quit]
teleological has quit [Ping timeout: 276 seconds]
Xzyx987X has quit [Ping timeout: 276 seconds]
Xzyx987X has joined #ruby-lang
ruby-lang487 has quit [Ping timeout: 250 seconds]
epus has quit [Quit: epus]
epus has joined #ruby-lang
Xzyx987X_ has joined #ruby-lang
<whitequark>
manveru: wait wait
<whitequark>
hash iteration order IS guaranteed since 1.9
<manveru>
is it part of the spec?
<whitequark>
"spec"
<whitequark>
since there is no comprehensive spec for 1.9+
<whitequark>
and rubyspec cannot capture this behavior
<whitequark>
but, to my best knowledge, it is
<postmodern>
whitequark, actually it might be in rubyspec
<manveru>
ok, i've avoided it in the past because it led to nasty bugs in 1.8 :)
apeiros has joined #ruby-lang
<whitequark>
postmodern: it doesn't matter if it is
<whitequark>
there are things which an executable "specification" cannot guarantee
Xzyx987X has quit [Ping timeout: 248 seconds]
<whitequark>
hash iteration order is one of them
GeissT has joined #ruby-lang
<postmodern>
whitequark, believe it tests #to_a
<whitequark>
because: 1) it might be an implementation detail, 2) things may just happen so that tests pass on test data
<whitequark>
but in reality this behavior isn't even an implementation guarantee.
dhruvasagar has joined #ruby-lang
<whitequark>
rubyspec should've been named "rubytest" :)
Xzyx987X_ has quit [Read error: Connection reset by peer]
Xzyx987X has joined #ruby-lang
<manveru>
it checks that #to_a returns an array in the same order as #each
<postmodern>
speaking of which, when is that standards group in Japan going to publish a new ISO spec for 1.9
<manveru>
in 4-5 years?
<manveru>
unfortunately Hash#each doesn't test the order
<manveru>
so yeah, not sure i'd trust the new behaviour with my life :P
<__carlos>
hey guys, quick question about garbage collection… I'm just starting out reading about interpreted languages. I know Ruby's garbage collection is stop-the-world and I'm wondering why this is exactly
<__carlos>
or, perhaps some resource you want to recommend :P
<postmodern>
__carlos, i believe ruby uss mark & sweep GC
<__carlos>
I'm probably slicing through too many problems, but also what about inline caching? like.. how would something like def stringify(obj); return obj.to_s; end get resolved by the runtime?
<whitequark>
postmodern: not sure if ever
setmeaway has quit [Ping timeout: 256 seconds]
<postmodern>
__carlos, it has to stop the VM and count all the references between objects to find the orphaned ones
<whitequark>
the existing ISO spec is compatible with 1.9
<__carlos>
postmodern: thanks for the ref =D
<whitequark>
it is mainly useful for industrial embedded applications
<whitequark>
the ISO spec, that is.
<postmodern>
whitequark, they only spec 1.8 syntax i think, mainly so they could use Ruby for government contracts
<whitequark>
matz&co don't seem to care enough to make an actual language specification.
<whitequark>
postmodern: no
therod has joined #ruby-lang
<postmodern>
whitequark, no what?
<__carlos>
whitequark: I've read that they don't care about that, yes… in fact while you're learning jruby I believe that's one of the first things they tell you… people just base themselves on MRI
<__carlos>
anyway guys, about inline caching, if anyone can enlighten me… I would be so thankful ^^ .. I have to go but I 'll read whatever you guys post when I come back heh
<postmodern>
it's not that ruby-core doesn't care, it's that they don't have the resources to write a spec and maintain it
<postmodern>
imho
Xzyx987X_ has joined #ruby-lang
krskrft has joined #ruby-lang
sush24 has quit [Quit: This computer has gone to sleep]
Xzyx987X has quit [Ping timeout: 264 seconds]
krskrft has quit [Client Quit]
krohrbaugh has joined #ruby-lang
Johz has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 256 seconds]
<whitequark>
it's comexpressly compatible with both syntxaxes, to my best knowledge
krskrft has joined #ruby-lang
<whitequark>
postmodern: re resources: true.
<dominikh>
that last sentence is quite butchered
<whitequark>
dominikh: oh
<whitequark>
mosh screwed it up, together with a disconnect
krohrbaugh has quit [Ping timeout: 264 seconds]
krskrft has quit [Client Quit]
krskrft has joined #ruby-lang
ajack has joined #ruby-lang
vlad_sta_ has joined #ruby-lang
ajack has quit [Client Quit]
<Mon_Ouie>
manveru: Hash iteration order is documented in Hash though
ajack has joined #ruby-lang
vlad_sta_ has quit [Remote host closed the connection]
ruurd has quit [Quit: Leaving...]
vlad_sta_ has joined #ruby-lang
<dominikh>
if they changed the order a lot of code would break :)
vlad_starkov has quit [Ping timeout: 245 seconds]
workmad3 has quit [Ping timeout: 246 seconds]
<manveru>
postmodern: i just figured out how to do the optional args based on your help example
<kke>
what's the use of buffer in StringIO#read(length, buffer) ?
<kke>
the default seems to be String.new for buffer
<Mon_Ouie>
Instead of creating a new string object to store the result, it stores it in #buffer
<Mon_Ouie>
in buffer* I mean
<kke>
what method does it call on the buffer?
<Mon_Ouie>
It calls no method, it just manipulates the string directly
<kke>
it must call some methods on it :)
jbsan has joined #ruby-lang
<kke>
like string.clear, string.concat(data) or something like that
<Mon_Ouie>
No, just like puts doesn't need to call a method
<kke>
puts doesn't set anything
<Mon_Ouie>
It just accesses the internal representation directly
DomKM has joined #ruby-lang
<kke>
hmm ok then
arubin has joined #ruby-lang
<Mon_Ouie>
StringIO is not written in Ruby (if we're talking about the YARV version)
<kke>
okok
<kke>
so, buffer = String.new until infile.eof? infile.read buffer_size, buffer outfile.write buffer end should be efficient and not create unnecessary objs
<kke>
or better yet, String.new.tap do
<Mon_Ouie>
No, it replaces the content of the string every time you call #read
<Mon_Ouie>
So you'd have two strings: one for the buffer and another one for the whole output
nathanstitt has joined #ruby-lang
<Mon_Ouie>
I'm not sure that would actually save any time
<Mon_Ouie>
Oh, I misread your code, sorry
workmad3 has joined #ruby-lang
teleological has joined #ruby-lang
dhruvasagar has quit [Ping timeout: 245 seconds]
jxie has joined #ruby-lang
teleological has quit [Remote host closed the connection]
madb055 has quit [Ping timeout: 260 seconds]
madb055 has joined #ruby-lang
epus has joined #ruby-lang
rickyrickyrice has joined #ruby-lang
teleological has joined #ruby-lang
sush24 has joined #ruby-lang
knu0 has joined #ruby-lang
ruby-lang821 has joined #ruby-lang
teleological has quit [Remote host closed the connection]
teleological has joined #ruby-lang
teleological has quit [Remote host closed the connection]
mytrile has joined #ruby-lang
postmodern has quit [Quit: Leaving]
KillerFox has quit [Ping timeout: 248 seconds]
<yorickpeterse>
Github down
<yorickpeterse>
of course HN starts red herring about it
KillerFox has joined #ruby-lang
<yorickpeterse>
"OMMMGGGG WHY NOT USE MORE DATABASE SERVERS???"
krohrbaugh has joined #ruby-lang
<whitequark>
mongodb
<yorickpeterse>
I should really stop reading that god awful website
<kuja>
web scale
<andrewvos>
WEHB SKAYL
krohrbaugh has quit [Ping timeout: 264 seconds]
Mon_Ouie has quit [Ping timeout: 246 seconds]
teleological has joined #ruby-lang
mbj has quit [Ping timeout: 256 seconds]
<andrewvos>
if !(_ok)
KillerFox has quit [Ping timeout: 248 seconds]
rickyrickyrice has quit [Remote host closed the connection]
KillerFox has joined #ruby-lang
<yorickpeterse>
Github should use Math.random for webscale
<yorickpeterse>
it's proven technology, MongoDB's Java driver uses it
<andrewvos>
Enterprise
<andrewvos>
"Show HN: How we solved scaling problems with Math.random"
vlad_starkov has quit [Remote host closed the connection]
<yorickpeterse>
Ask HN: do you use Math.random for roflscale?
<yorickpeterse>
Then the first comment:
vlad_starkov has joined #ruby-lang
<yorickpeterse>
"I appreciate you guys using Math.random but I thought everybody knew to use Math.urandom instead. We at Some Small Meanlingless Startup LTD. use this and it works very well for us."
ruurd has joined #ruby-lang
<andrewvos>
Yeah I don't even see humour in that comment. That is exactly what would happen.
verto has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rickyric_ has joined #ruby-lang
eponymi has joined #ruby-lang
pskosinski_ has joined #ruby-lang
pskosinski has quit [Remote host closed the connection]
pskosinski_ is now known as pskosinski
ruurd has quit [Quit: Leaving...]
LinkedoT has joined #ruby-lang
<PaulePanter>
whitequark: When I have `on_send(node)` for to filter for `puts "hello"`, how do I know that this is the `puts` command?
rickyric_ has quit [Remote host closed the connection]
ruurd has joined #ruby-lang
rickyric_ has joined #ruby-lang
<yorickpeterse>
man, stacks are probably both the easiest and most useful data structure evah
<yorickpeterse>
well, that and linked lists
jsullivandigs has joined #ruby-lang
verto has joined #ruby-lang
<PaulePanter>
I need to get that cscope going, as I cannot find where in node.src the src method is defined.
cordax has joined #ruby-lang
<yorickpeterse>
PaulePanter: you'd have to extract it yourself from the node's children
<PaulePanter>
(send nil :puts
<PaulePanter>
Ok. I thought same line, then it belongs to that node.
<yorickpeterse>
node.children[1] gives you the name
<PaulePanter>
yorickpeterse: Thanks. I am going to try that.
<yorickpeterse>
hahaha wtf
<yorickpeterse>
I tweeted a Github Haiku and now I'm followed by "Haiku_in_Englis"
<yorickpeterse>
hm, some spam account it seems
krohrbaugh has joined #ruby-lang
<erikh>
ya'll is chatty clucker
<erikh>
s
ruurd has quit [Quit: Leaving...]
vlad_sta_ has joined #ruby-lang
<andrewvos>
Is Sierra Nevada PA a thing in the US?
<erikh>
it's everywhere, if that's what you're asking
<erikh>
especially on the west coast.
Qwak has quit []
<erikh>
it's kind of like lagunitas and deschutes, very well distributes
<erikh>
distributed
<erikh>
only I like lagunitas and deschutes
vlad_starkov has quit [Ping timeout: 256 seconds]
krohrbaugh has quit [Ping timeout: 264 seconds]
<andrewvos>
what are these words I have no idea
<erikh>
most bars have a few staples, your bud/coors, stella artois, guinness, SNPA, and usually a lagunitas and deschutes beer (ipa and black butte porter usually). then if the bar is any good they have some additional craft beers
<andrewvos>
Well I guess I could work it out
<erikh>
they're breweries
<andrewvos>
Oh is it mainstream?
<andrewvos>
SNPA I mean
<erikh>
significantly
<erikh>
yesp
<andrewvos>
Oh ok
<erikh>
but... that's kind of the cool thing
<andrewvos>
Well it's kinda popular here too which says something
<erikh>
in the last decade a lot of decent beers have gained a lot of traction
<erikh>
doesn't mean they're bad, just well distributed
<andrewvos>
Yeah
<erikh>
like, we get fuller's in a lot of spots over here
<erikh>
I love that stuff.
<andrewvos>
Oh yeah that honey one is good
<erikh>
the london pride is my fav
<erikh>
not sure if that's the one you're talking about o rnot
<andrewvos>
ergh don't like that one
<andrewvos>
Nahh I think it's called Honey Dew or something
<andrewvos>
Actually just googled it and I was thinking of something else
<erikh>
ah
<andrewvos>
My russian friend has a pile of London PRide bottle caps next to his monitor on his desk at work
<erikh>
but yeah -- especially on the west coast, craft beers are king
<erikh>
haha
<erikh>
so russian.
tomzx_mac has joined #ruby-lang
<andrewvos>
hah
<erikh>
well he could be irish too
<andrewvos>
Not sure why Russians get a bad rap for drinking though, the English drink a lot
<erikh>
yeah, hence my statement
<whitequark>
yorickpeterse: PaulePanter: no, not really.
rafeed has quit [Remote host closed the connection]
Jinie is now known as jinie_
jinie_ is now known as jinie
<eponymi>
this is probably (definitely) a stupid question, but can i use multiple SecureRandom.hex in the same file and expect different values to be generated?
jinie has quit [Client Quit]
<apeiros>
yes
<apeiros>
and: why didn't you just try?
<eponymi>
apeiros umm…
<eponymi>
i got nothing.
<eponymi>
thank you though!
mbj has left #ruby-lang [#ruby-lang]
Gaelan has joined #ruby-lang
jinie has joined #ruby-lang
jinie has quit [Remote host closed the connection]
benanne has quit [Quit: kbai]
jinie has joined #ruby-lang
epus has joined #ruby-lang
krohrbaugh has joined #ruby-lang
asahi has joined #ruby-lang
<eponymi>
actually one more dumb question. can i dynamically declare a class based on a property of another class? e.g. new_var = old_var['new_var_type'].new(param1, param2)? i'd imagine there's a better way to handle this...
ahmdrefa_ has quit [Ping timeout: 256 seconds]
benlovel1 has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 264 seconds]
jxie_ has joined #ruby-lang
threedaymonk has joined #ruby-lang
threedaymonk has quit [Client Quit]
threedaymonk has joined #ruby-lang
[1]tangy has joined #ruby-lang
threedaymonk has quit [Client Quit]
jxie has quit [Ping timeout: 256 seconds]
threedaymonk has joined #ruby-lang
threedaymonk has quit [Client Quit]
pkrnj has quit [Ping timeout: 245 seconds]
dhruvasagar has joined #ruby-lang
<canton7>
eponymi, Object.const_get('Array').ne
<canton7>
*new
madb055 has quit [Ping timeout: 248 seconds]
teleological has quit [Remote host closed the connection]
benlovel1 has quit [Ping timeout: 256 seconds]
<[1]tangy>
hello
<erikh>
hi
<erikh>
!
<[1]tangy>
i recently learnt scripting in ruby and had a begginer's doubt regarding TDD
<erikh>
I'm not particularly fond of it myself.
<erikh>
but, you should try it. lots of people swear by it.
<[1]tangy>
but i dont know how should i go about it i tried it once and i saw it cluttering my script
<canton7>
your tests shouldn't go in your main script...
epus has quit [Quit: epus]
<erikh>
you should probably build a rakefile and a test/ or spec/ dir in your project directory to put your tests.
<erikh>
depending on if you prefer somethign like minitest or rspec
<[1]tangy>
no i kept it in a separate directory
<canton7>
how is it cluttering up your script, then?
epus has joined #ruby-lang
<[1]tangy>
well i was trying harder to pass the test asap
<[1]tangy>
and in getting it to start i wrote cluttered code
dhruvasagar has quit [Ping timeout: 264 seconds]
<canton7>
TDD doesn't mean "rush to get the test to pass asap". you still need to apply common sense :)
<eponymi>
psh, TDD is so passe. get with the BDD
<[1]tangy>
shud i be even applying it on begginer level scripts or shud i implement once i am better at scripting and writing more complicated scripts
<workmad3>
canton7: depends on how you view the TDD 'red-green-refactor' cycle
tbuehlmann has joined #ruby-lang
<workmad3>
canton7: a lot of people say you should get from red to green as fast as possible, then clean up in the refactoring, so you have as short a time as possible without a passing test suite
<eponymi>
[1]tangy: as someone who's learning TDD in another language now, way after i started learning the language itself, i'd recommend practicing TDD as soon as you know syntax if that's the philosophy you want to follow
<[1]tangy>
and should i use rspec/test-unit testing suite/or some other
<manveru>
bacon of course :P
<manveru>
shameless promotion, tho it's not from me
<[1]tangy>
okay will read up some documentation on bacon thanks
<eponymi>
[1]tangy: you shouldn't just use one test tool
<[1]tangy>
multiple? but after i get better or from now itself
<eponymi>
manveru: yes, sometimes we have to read things
<eponymi>
[1]tangy: i'd say now, as long as you know syntax and constructs of language you want to use.
<eponymi>
easier to develop the habits now than later on.
<manveru>
"5.2.1. Planning [Kan99:c12; Per95:c19; Pfl01:c8s7.6] (IEEE829-98:s4; IEEE1008-87:s1-s3)" how do you read that?
<apeiros>
I don't
<[1]tangy>
thanks everyone
<eponymi>
manveru: i don't read all of the spec names, because i never use them.
<eponymi>
but i read that paragraphs underneath that outline the principles.
<eponymi>
that's just me though; i know a lot of people who don't like running tests at all, much less tdd
teleological has joined #ruby-lang
<manveru>
i can't work well without any tests
<manveru>
but testing everything and the kitchen sink is also not productive
<eponymi>
but don't you want that shiny 100% rcov badge?
<manveru>
no
<eponymi>
facetious...
<manveru>
lol
<manveru>
sorry, but that is really very rarely worth the effort
<eponymi>
even though it's somewhat pretentious and aesthetic, gherkin has helped me a lot with managing client expectations.
epus has quit [Quit: epus]
<eponymi>
and gettin' paaaaaid.
<manveru>
of course it depends on what you build... but for your average user-facing application your tests will never anticipate the creativity of abuse it will have to face
vlad_sta_ has quit [Remote host closed the connection]
<manveru>
so i tend to do regression testing to build a stable foundation to build future changes on
vlad_starkov has joined #ruby-lang
<manveru>
even 100% coverage doesn't mean the libraries you use are covered by that
<manveru>
ruby itself being buggy at times
teleological has quit [Remote host closed the connection]
<manveru>
you have hardware failures, full disks, network issues, permission insanity, memory leaks...
vlad_sta_ has joined #ruby-lang
<eponymi>
thats what nagios is for.
<eponymi>
well, the first three at least
<manveru>
hopefully, yeah
<manveru>
but that's only if it's running on a server
vlad_starkov has quit [Ping timeout: 264 seconds]
epus has joined #ruby-lang
vlad_sta_ has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 264 seconds]
krohrbaugh has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 240 seconds]
<darix>
manveru & eponymi: you could also build in some kind of graceful degradation in your library/app. so it handles partial failures of your infrastructure less noticable for your user.
benanne has joined #ruby-lang
<eponymi>
darix: example, preferably that a child could understand?
<matti>
manveru: ;]
<darix>
eponymi: if e.g. one subservice is missing render the rest of the page.
<manveru>
if your app doesn't have network conn, don't show a spinner forever :P
<darix>
that too
<manveru>
sometimes you can't show much more, but at least let people know what's wrong
<eponymi>
as a user, that's my favorite, though. i waited like 20 minutes for qz.com to load once, bc i heard it was so awesome.
<eponymi>
darix: so i'm not a ruby person, and this will probably sound wrong, but it sounds like all you're talking about is proper exception handling
Gaelan has quit [Remote host closed the connection]
Gaelan has joined #ruby-lang
voker57 has joined #ruby-lang
voker57 has quit [Changing host]
voker57 has joined #ruby-lang
nignaztic has joined #ruby-lang
poga_ has quit [Remote host closed the connection]
bri has joined #ruby-lang
poga has joined #ruby-lang
nazty has quit [Ping timeout: 248 seconds]
alessio_rocco has joined #ruby-lang
alessio_rocco has quit [Remote host closed the connection]
poga_ has joined #ruby-lang
poga_ has quit [Remote host closed the connection]
poga_ has joined #ruby-lang
poga has quit [Ping timeout: 256 seconds]
amerine has quit [Quit: Computer has gone to sleep.]
poga has joined #ruby-lang
ruurd has quit [Quit: Leaving...]
teleological has quit [Remote host closed the connection]
ruurd has joined #ruby-lang
poga_ has quit [Ping timeout: 256 seconds]
teleological has joined #ruby-lang
__carlos has joined #ruby-lang
Kabaka has quit [Read error: Connection reset by peer]
mhanne_ has quit [Quit: Lost terminal]
Nisstyre-laptop has joined #ruby-lang
epus has quit [Quit: epus]
rikai has quit [Ping timeout: 260 seconds]
krohrbaugh has joined #ruby-lang
ia___ has quit [Quit: ia___]
Kabaka has joined #ruby-lang
krombr has joined #ruby-lang
lguardiola has joined #ruby-lang
krohrbaugh has quit [Ping timeout: 260 seconds]
verto has quit [Read error: Connection reset by peer]
wmoxam has joined #ruby-lang
solars has quit [Ping timeout: 256 seconds]
teleological has quit [Remote host closed the connection]
Gaelan has quit [Ping timeout: 256 seconds]
teleological has joined #ruby-lang
rickhull1 has quit [Ping timeout: 240 seconds]
epus has joined #ruby-lang
mucker has joined #ruby-lang
rickhull has joined #ruby-lang
Squarepy has joined #ruby-lang
scholar01 has joined #ruby-lang
scholar01 has joined #ruby-lang
techdood has joined #ruby-lang
<techdood>
how is ruby as a first language?
<erikh>
there's a 'learn to program' book
<erikh>
I hear good things about rails bridge and code academy
<erikh>
corundum: learn to program?
<corundum>
A good Ruby tutorial for newbies to programming: http://pine.fm/LearnToProgram/. NOTE: For linux installation section (in Chapter 0), the filename presented is just a example.
Aria has quit [Read error: Connection reset by peer]
techdood has quit [Quit: Leaving]
Aria has joined #ruby-lang
vlad_starkov has joined #ruby-lang
vlad_starkov has quit [Ping timeout: 260 seconds]
nathanstitt has quit [Quit: I growing sleepy]
ikrima has joined #ruby-lang
<andrewvos>
an example*
epus has quit [Quit: epus]
workmad3 has quit [Ping timeout: 256 seconds]
LinkedoT has quit [Ping timeout: 256 seconds]
wmoxam has quit [Ping timeout: 264 seconds]
mucker has quit [Quit: leaving]
krohrbaugh has joined #ruby-lang
scholar01 has quit [Quit: Leaving.]
krohrbaugh has quit [Ping timeout: 260 seconds]
Gaelan has joined #ruby-lang
apeiros has quit [Remote host closed the connection]
krombr has quit [Quit: krombr]
krombr has joined #ruby-lang
Gaelan has quit [Ping timeout: 256 seconds]
rikai has joined #ruby-lang
Gaelan has joined #ruby-lang
symm- has quit [Ping timeout: 276 seconds]
hogeo_ has joined #ruby-lang
Wardrop has joined #ruby-lang
hogeo has quit [Ping timeout: 256 seconds]
dingus_khan has joined #ruby-lang
<Wardrop>
Hey guys. Can anyone suggest how to specify an optional dependancy in a gemspec file? I have "mongo" as a dependancy, but want to install "bson_ext" only if it's available for the current platform. It's not required, but it improves performance. Does anyone if that's possible?
Gaelan has quit [Ping timeout: 264 seconds]
<whitequark>
in a gemspec, there isn't a way.
<whitequark>
you can do it with a Gemfile.
<whitequark>
(but that will not work for a gem)
<whitequark>
or, you can avoid adding it as a dependency, but try to require it (or alternatives), and fall back if you catch LoadError.
ahmdrefat has quit [Remote host closed the connection]
<Wardrop>
whitequard: I believe the mongo gem will automatically try to require it, and silently fall back otherwise. Out of curiosity, how would you do it with a Gemfile?
vlad_starkov has joined #ruby-lang
ruurd has quit [Quit: Leaving...]
<Wardrop>
whitequark: That was meant to be at you
tbuehlmann has quit [Remote host closed the connection]
wmoxam has joined #ruby-lang
fosky has joined #ruby-lang
dingus_khan has quit [Remote host closed the connection]
vlad_starkov has quit [Ping timeout: 248 seconds]
pkrnj has joined #ruby-lang
<whitequark>
gem :foo, platform: [:mri_19]
sepp2k has quit [Quit: Leaving.]
<Wardrop>
oh yeah
ahmdrefat has joined #ruby-lang
Squarepy has quit [Quit: Leaving]
pskosinski has quit [Quit: pskosinski]
deception has quit [Quit: Goodbye]
teleological has quit [Remote host closed the connection]
benanne has quit [Quit: kbai]
hogeo_ has quit [Remote host closed the connection]
hogeo has joined #ruby-lang
northelks_ has quit [Quit: ...]
cHarNe2 has joined #ruby-lang
teleological has joined #ruby-lang
hogeo has quit [Ping timeout: 240 seconds]
JoelMcCracken has joined #ruby-lang
wmoxam has quit [Ping timeout: 264 seconds]
krohrbaugh has joined #ruby-lang
cordax has quit [Quit: Computer has gone to sleep.]
krohrbaugh has quit [Read error: Operation timed out]
nathanstitt has joined #ruby-lang
bzalasky has joined #ruby-lang
JoelMcCracken has quit [Ping timeout: 248 seconds]
ahmdrefa_ has joined #ruby-lang
Nisstyre-laptop has quit [Quit: Leaving]
xxaM has joined #ruby-lang
jsullivandigs has quit [Remote host closed the connection]
ahmdrefat has quit [Ping timeout: 264 seconds]
rikai has quit [Read error: Connection reset by peer]