ChanServ changed the topic of #ruby-lang to: Ruby 1.9.3-p125: http://ruby-lang.org | Paste >3 lines of text on http://pastie.org or use a gist
Swimming_Bird has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
phlipper has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
publicvoid_ has joined #ruby-lang
samd_ has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
nofxxx has joined #ruby-lang
jarred has joined #ruby-lang
y3llow has joined #ruby-lang
kvirani has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
shevy has joined #ruby-lang
budward has joined #ruby-lang
Joeysomo has joined #ruby-lang
y3llow has joined #ruby-lang
gsav has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
mistym has joined #ruby-lang
t has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
brianpWins has joined #ruby-lang
yorickpeterse has joined #ruby-lang
y3llow has joined #ruby-lang
jolohaga has joined #ruby-lang
nofxx has joined #ruby-lang
mob` has joined #ruby-lang
y3llow has joined #ruby-lang
Austin__ has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
srbaker has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
ahs3- has joined #ruby-lang
surfprimal has joined #ruby-lang
y3llow has joined #ruby-lang
gnufied has joined #ruby-lang
slimfit has joined #ruby-lang
y3llow has joined #ruby-lang
tomzx has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
Austin__ has quit [#ruby-lang]
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
shtirlic has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
chendo_ has joined #ruby-lang
y3llow has joined #ruby-lang
y3llow has joined #ruby-lang
hagabaka has joined #ruby-lang
gregmore_ has joined #ruby-lang
fayimora has joined #ruby-lang
mistym has joined #ruby-lang
fgomez has joined #ruby-lang
apeiros_ has joined #ruby-lang
Radium_ has joined #ruby-lang
gnufied has joined #ruby-lang
asahi has joined #ruby-lang
kurko_ has joined #ruby-lang
mmlac has joined #ruby-lang
<mmlac> Why does ruby not find my gem? irb 1.9.3p125 :002 > require 'redcarpet' => true but ruby -rubygems -e 'require "redcarpet"' throws `require': cannot load such file -- redcarpet (LoadError)
<mmlac> I use rvm and the versions seem to match
mistym has joined #ruby-lang
banister has joined #ruby-lang
<apeiros_> mmlac: make sure irb uses the same ruby executable as you get when running ruby directly
<apeiros_> mmlac: also, -rubygems is not required anymore with ruby 1.9
<banister> hey frens
<banister> jammi: btw we already have a kind of remote debugging solution that u might think is ok, https://github.com/simulacre/pry-remote-em (EM-based) or https://github.com/mon-ouie/pry-remote (drb-based)
slimfit has joined #ruby-lang
<mmlac> apeiros_: thanks, rvm probably did not use the right rvm. But now my rails Gemfile messes with my script. Is there a way to isolate the ruby instance from that?
<mmlac> did not use the right ruby*
gix has joined #ruby-lang
igotnolegs has joined #ruby-lang
lsegal has joined #ruby-lang
phlipper has joined #ruby-lang
TTilus has joined #ruby-lang
<apeiros_> mmlac: no, bundler does not (can not) influence which ruby executable is used
<mmlac> well, my ruby exec is correct now
<mmlac> But it complains that rake is not found
<mmlac> if I switch outside a directory with a Gemfile, it works
<mmlac> can I isolate the ruby -e call to ingore that Gemfile in the current folder?
Weems has joined #ruby-lang
<apeiros_> o0
<apeiros_> only if you do `bundle exec …`, the gemfile is used
<apeiros_> ruby itself doesn't know nor care about gemfiles
<apeiros_> oh, or of course if you load code that does Bundler.setup
ChloeD_ has joined #ruby-lang
nofxxx has joined #ruby-lang
<mmlac> hm, I don't. sigh.
a3li` has joined #ruby-lang
kinabalu1 has joined #ruby-lang
yeltzooo7 has joined #ruby-lang
Joeysomo has joined #ruby-lang
epitron__ has joined #ruby-lang
epitron__ has joined #ruby-lang
<mmlac> or does redcarpet do Bundle.setup? gotta check that
kalleth has joined #ruby-lang
srbaker has joined #ruby-lang
urbanmonk has joined #ruby-lang
KillerFox has joined #ruby-lang
foca has joined #ruby-lang
jarib has joined #ruby-lang
FACEFOX has joined #ruby-lang
<mmlac> apeiros_: apparently the gem hits bundler somewhere. how annoying -__-
<mmlac> Thanks for the help
nofxx has joined #ruby-lang
io_syl has joined #ruby-lang
senthil has joined #ruby-lang
ryland has joined #ruby-lang
igotnolegs has joined #ruby-lang
tridge has joined #ruby-lang
<tridge> Hi all
<bnagy> morning
<banister> bnagy: sup bnaggitynagx0r
hagabaka has joined #ruby-lang
Clordio has joined #ruby-lang
bryno has joined #ruby-lang
pygmael has joined #ruby-lang
<bnagy> wow...
<bnagy> hax0rbonics
hagabaka has joined #ruby-lang
arooni-mobile has joined #ruby-lang
senthil has quit [#ruby-lang]
jinzhu has joined #ruby-lang
kvirani_ has joined #ruby-lang
igotnolegs has joined #ruby-lang
rippa has joined #ruby-lang
<banister> rippa: hey rippsy
gouthamvel has joined #ruby-lang
senthil has joined #ruby-lang
senthil has quit [#ruby-lang]
rippa has joined #ruby-lang
jstr has joined #ruby-lang
spuk has joined #ruby-lang
kiddorails has joined #ruby-lang
surfprimal has joined #ruby-lang
gouthamvel has quit [#ruby-lang]
slimfit has joined #ruby-lang
piyush_ranjan has joined #ruby-lang
piyush_ranjan has joined #ruby-lang
asahi has joined #ruby-lang
asahi has quit [#ruby-lang]
piyush_ranjan has joined #ruby-lang
piyush_ranjan has joined #ruby-lang
Fullmoon has joined #ruby-lang
piyush_ranjan has joined #ruby-lang
gnufied has joined #ruby-lang
Swimming_Bird has joined #ruby-lang
samd_ has joined #ruby-lang
jinzhu has joined #ruby-lang
a3li has joined #ruby-lang
Joeysomo has joined #ruby-lang
samd_ has quit [#ruby-lang]
gnufied1 has joined #ruby-lang
brianpWins has joined #ruby-lang
jakko has joined #ruby-lang
x0F__ has joined #ruby-lang
yxhuvud has joined #ruby-lang
dr0id has joined #ruby-lang
sandbags has joined #ruby-lang
nahh has joined #ruby-lang
savage- has joined #ruby-lang
jakko has joined #ruby-lang
rdavila has joined #ruby-lang
mint_ has joined #ruby-lang
mint_ has quit [#ruby-lang]
nahhh has joined #ruby-lang
kybik_vlg has joined #ruby-lang
kiddorails has joined #ruby-lang
rolfb has joined #ruby-lang
piyush_ranjan has joined #ruby-lang
jstr has joined #ruby-lang
solars has joined #ruby-lang
chendo_ has joined #ruby-lang
tbuehlmann has joined #ruby-lang
tbuehlmann has joined #ruby-lang
gnufied has joined #ruby-lang
deobald has joined #ruby-lang
Radium_ has joined #ruby-lang
ezkl has joined #ruby-lang
morozovm has joined #ruby-lang
batmanian has joined #ruby-lang
chendo__ has joined #ruby-lang
kiddorails has joined #ruby-lang
bjensen has joined #ruby-lang
apeiros_ has joined #ruby-lang
banisterfiend has joined #ruby-lang
jinzhu has joined #ruby-lang
<banisterfiend> wht's up
* apeiros_ was bored, so he started helping on stackoverflow
<apeiros_> I wonder whether there's people addicted to getting points there :)
ezkl has joined #ruby-lang
<erikh> banisterfiend: apeiros_ hi
<apeiros_> howdy erikh
<erikh> how goes?
<banisterfiend> erikh: sup
<erikh> just got home. drunk.
<apeiros_> besides of some sleep issues, great
<apeiros_> hah, I missed out on that yesterday :(
<erikh> I have a lot of trouble with sleep
<erikh> my mind seemingly likes to work in 20-22 hour blocks of time
<rolfb> :O
<banisterfiend> erikh: what wre u drinking
<apeiros_> my mind likes to work 24/7, but my body fights it heavily. and of course, the body wins most of the time :(
workmad3 has joined #ruby-lang
<rolfb> apeiros_, erikh: as in always thinking explicitly about something?
<rolfb> or deliberately?
<banisterfiend> rolfb: romantic fantasies of nubile women and well-built young men
<rolfb> banisterfiend: that's explicit for sure
<banisterfiend> hehe
<erikh> banisterfiend: just beer
<erikh> good beer, but beer nonetheless.
<erikh> rolfb: implicitly, automated
<erikh> it's an OCD thing I thikn.
<rolfb> oh
<rolfb> good thing you have irc to slow you down then
<erikh> I can't turn off for 8 hours a night, just doesn't happen
<rolfb> :P
<erikh> heh
<apeiros_> rolfb: as in, always exploring something, always chain-reacting
<erikh> more or less, I work until I'm exhausted
<apeiros_> and usually only marginally directed manually
<rolfb> interesting
<banisterfiend> rolfb: it's a form of madnes really, we should pity them
<banisterfiend> :P
<rolfb> i find myself purposefully stopping myself from going down what i call rabbit holes
<rolfb> but i think i would prefer to have the time to visit every one of them
<rolfb> :D
<erikh> oof.
<rolfb> banisterfiend: i prefer envy to pity, always
<rolfb> :P
<banisterfiend> rolfb: a dictionary would probably help u get over that confusion
MDmalLION has joined #ruby-lang
<rolfb> banisterfiend: whoops
anildigital has quit [#ruby-lang]
<erikh> fart
<MDmalLION> I am progressing hella slowly. What should I do?
<erikh> run faster
<rolfb> banisterfiend: what I meant was that I'm always looking for angles which are positive
<apeiros_> MDmalLION: adjust your BAC to reach balmers peak
<erikh> disregard pot, acquire caffeine
<MDmalLION> i just did
<MDmalLION> coffee
<banisterfiend> rolfb: sounds like u r watching too much oprah winfrey on television
<erikh> ofra
<rolfb> banisterfiend: martin seligman's "learned optimism" actually
<MDmalLION> any leet tutorials out there
<banisterfiend> rolfb: u need to read some louis ferdinand celine
<erikh> MDmalLION: yes! william gibson novels.
<MDmalLION> and should i get a mavbook air
<banisterfiend> rolfb: all that optimism will rot your teeth
<erikh> they will teach you to be leet.
<rolfb> MDmalLION: tutorials for what exactly?
<MDmalLION> anything
<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.
<MDmalLION> my goal is to make an interactive website
<erikh> look at that book. seriously.
<rolfb> MDmalLION: have a look at http://tutorials.jumpstartlab.com
<erikh> corundum: pickaxe?
<corundum> pickaxe is Programming Ruby, 3rd ed. by Dave Thomas, et al. Available for purchase (tree and pdf) at http://www.pragprog.com/ or at http://www.rubycentral.com/book/ (in first edition form) if you are a cheap bastard and hate kittens. or http://ruby-doc.org/docs/ProgrammingRuby/
<erikh> that too.
<MDmalLION> hhave it
<erikh> ok, well, have you read it?
<MDmalLION> yeah
<erikh> ok well you're 95% of the way there
<erikh> good jorb
<MDmalLION> should i make my own example
<MDmalLION> each
<banisterfiend> erikh: do you have much cocoa dev experience?
<MDmalLION> time
<erikh> banisterfiend: not really
<erikh> I tinkered with it once or twice, nothing of note
<rolfb> banisterfiend: i've already been to the far left deep end of the optimism spectrum
samd_ has joined #ruby-lang
kitallis has joined #ruby-lang
<erikh> speaking of brains turning off
<erikh> night fellas.
<banisterfiend> erikh: cya erik
<MDmalLION> pine fming
kiddorails has joined #ruby-lang
Hakon|mbp has joined #ruby-lang
spasbot has joined #ruby-lang
imajes has joined #ruby-lang
MDmalLION has joined #ruby-lang
pygmael has joined #ruby-lang
* manveru wonders if there are still people using kirbybase
<apeiros_> is kirbybase anything but a toy? o0
tekin has joined #ruby-lang
<manveru> seems like
<manveru> well, if you don't know a thing about dbs, that is
<manveru> anw, it's basically csv with type annotations, so it must be useful to someone
io_syl has joined #ruby-lang
francisfish has joined #ruby-lang
tjadc has joined #ruby-lang
publicvoid_ has joined #ruby-lang
DMKE has joined #ruby-lang
workmad3_ has joined #ruby-lang
lianj has joined #ruby-lang
mihar has joined #ruby-lang
sandbags has joined #ruby-lang
bougyman has joined #ruby-lang
bougyman has joined #ruby-lang
gouthamvel has joined #ruby-lang
gouthamvel has quit [#ruby-lang]
chendo_ has joined #ruby-lang
robotmay has joined #ruby-lang
benanne has joined #ruby-lang
Mon_Ouie has joined #ruby-lang
srbartlett has joined #ruby-lang
lianj has joined #ruby-lang
tbuehlmann has joined #ruby-lang
elalande has joined #ruby-lang
kyrylo has joined #ruby-lang
sandbags has joined #ruby-lang
esad has joined #ruby-lang
kyrylo has joined #ruby-lang
sandbags has joined #ruby-lang
esad has joined #ruby-lang
kiddorails has joined #ruby-lang
KINGSABRI has joined #ruby-lang
<KINGSABRI> hello All
<KINGSABRI> how to open a "channel" in telnet in order to keep telnet session opened
<KINGSABRI> for example need to create directory then cd in it
<KINGSABRI> my case is telnet not ssh
benanne has joined #ruby-lang
rushed has joined #ruby-lang
gray has joined #ruby-lang
<gray> hi, could someone explain how it works: http://pastie.org/3786167
bjensen has joined #ruby-lang
<gray> occurs call create table and pass :users as argument
<gray> but what is |t|?
<Mon_Ouie> There's just a create_table method that expects the name of the table as an argument and a block to, I assume, add fields to it
<Mon_Ouie> That's just the syntax for block arguments
<gray> Mon_Ouie: create method GET block and execute it inside? or push data to |t| object?
<gray> if i get more simple example: (1..5).each { |i| puts 2 * i }
<gray> each time from 1 to 5 each method pass current value to |i| and execute block?
<gray> any help?
DMKE has joined #ruby-lang
<apeiros_> gray: the block (`{ |i| puts 2 * i }`) is an argument passed to the method `each`
<apeiros_> a block is similar to a method, it can be called, and it accepts arguments
<apeiros_> the arguments are listed between the |'s, so |i| means it takes a single argument named i
<apeiros_> the method each now calls that block 5 times, the first time passing 1 as argument, then 2, etc.
<gray> apeiros_: thanks you! in this case how each method use block inside?
<gray> apeiros_: if block == argument, then method there was passed block should use block
<apeiros_> gray: Range#each is already relatively complex. I'll show you how you could implement 5.times { |i| puts i }
<apeiros_> gray: http://pastie.org/3786217
kyrylo has joined #ruby-lang
<apeiros_> this is how you could implement Integer#times in pure ruby
<gray> apeiros_: nice, understnad. But interation just example to understand how blocks works.Excuse me for many question, but i am new in ruby. So if block is a method argument. Ans we pass block in to a method.
<apeiros_> gray: sure, you can use it in any other way. create_table for example only yields once, it doesn't iterate.
<gray> each - default method, but if i use my own (defined by me) method and pass block as argument to this method. How can i run this block inside method?
<gray> apeiros_: i apologize for my english, do you understand my question?
<apeiros_> gray: did you read the pastie? I highlighted the part that runs the block
<apeiros_> line 5, the keyword `yield` runs the block
morozovm has joined #ruby-lang
<gray> apeiros_: http://pastie.org/3786243
workmad3_ has joined #ruby-lang
esad has joined #ruby-lang
<apeiros_> gray: yes, 5.times { |i| puts i }, for example
<KINGSABRI> guys ,, any help please ?
<KINGSABRI> how to open a "channel" in telnet in order to keep telnet session opened
<KINGSABRI> for example need to create directory then cd in it
<apeiros_> KINGSABRI: use net/telnet
<apeiros_> btw., shouted (all capitals) nicknames--
<gray> apeiros_: but why Ruby developers use blocks? if they can write something like this: http://pastie.org/3786251
<apeiros_> gray: not the same
<apeiros_> with the block, the caller decides what is done with the number
<shevy> gray blocks are flexible
<apeiros_> gray: consider .each, do you want to write a separate method for every possible thing you'd want to do with every value?
<shevy> call_my_method("bla")
<shevy> call_my_method("bla") { 'also with a block!' }
<apeiros_> easier to explain with .sort
<shevy> I think I remember apeiros_ once wanted to have multiple blocks :D
<apeiros_> .sort { |a,b| a.first_name <=> b.last_name } # <-- easy
<apeiros_> do you want to write instead a .sort_by_first_name, .sort_by_whatever
<shevy> in PHP you would!
<apeiros_> remember, you'd have to implement the complete sorting algorithm
fattastic has joined #ruby-lang
<gray> okay, thank you very much, seems i understand :)
<apeiros_> with blocks, the part that performs the sorting is implemented for you already, all you have to do is provide how the values should be compared
MDmalLION has joined #ruby-lang
DMKE|Router has joined #ruby-lang
DMKE|Router has joined #ruby-lang
<KINGSABRI> apeiros_, yes but my issue is how to keep my session opened ?
<apeiros_> um, don't close it? don't wait until it times out?
<KINGSABRI> I can connect and exceute but I can't keep my session opened to to excute command which related to the prv command
DMKE has joined #ruby-lang
MDmalLION has joined #ruby-lang
kvirani has joined #ruby-lang
tla has joined #ruby-lang
francisfish has joined #ruby-lang
hagabaka has joined #ruby-lang
francisfish has joined #ruby-lang
codewrangler has joined #ruby-lang
mssola has joined #ruby-lang
Jake232 has joined #ruby-lang
BryanWB_ has joined #ruby-lang
shajinx has joined #ruby-lang
<shajinx> hi everyone
<KINGSABRI> still net/telnet can't keep the session opened until I finish from sending all commands :(
<KINGSABRI> shajinx, hi
<shajinx> can any one tell me the code for ruby discount coupen system for e-commerce site
Swimming_Bird has joined #ruby-lang
<shajinx> like 10% discount for sing up and 5% dicount on friend referal
jacktrick has joined #ruby-lang
dejongge has joined #ruby-lang
burgestrand has joined #ruby-lang
felipe has joined #ruby-lang
<shajinx> any one??
KINGSABRI has joined #ruby-lang
<countskm> KINGSABRI: how long is ur session staying open? seconds or are you running a long running command and it event times out?
<countskm> if its a timeout w/ nat u could add "ssh -o ServerAliveInterval=60" or something like that
<KINGSABRI> countskm, the issue is not time out ,, the issue is to keep session opened on the same last status
<KINGSABRI> assume I need to create a directory then excute pwd
<KINGSABRI> mkdir dire_name
<KINGSABRI> cd dire_name
<KINGSABRI> pwd
<countskm> ssh host 'mkdir foo && cd foo && pwd'
<KINGSABRI> if I did pwd ,, I'll be in the same prev path ,, because each time I send a command it creates a new session
<countskm> u have to keep the same shell cd is an internal shell command
<countskm> anyways a bit off topic but lemme did somethin up for ya
<KINGSABRI> yes I know this way ,, but this is now interactive session and this work in one case (windows,linux)
<countskm> k
<KINGSABRI> acutally I'll connect to switch which I've to ecute command to enter to interface config level , then excute another command regarding this interface
<KINGSABRI> what I mean is ,,
<KINGSABRI> level01> config interface
<KINGSABRI> level02/interface> enable interface
<erikh> ios ?
<erikh> there's probably an internal timeout you're hitting
<erikh> (to IOS)
<KINGSABRI> no ,, it's huawei switch :(
<erikh> meh, same deal :)
<KINGSABRI> erikh, so advise please
<countskm> use cisco ;-)
<erikh> well, you need to read the docs for your switch and see what the timeout is set to, and how you can increase that
<erikh> usually you can do it just for the session on most switches/routers
<erikh> e.g., set timeout 120
<erikh> but not wr mem
<erikh> or something.
<KINGSABRI> ok is there any good lib for cisco ?
<erikh> probably not, but you can try
<erikh> net/telnet should be fine here.
<KINGSABRI> ok ,, I'll increase my timeout then I'll feed you back ,, thanks erikh
thone has joined #ruby-lang
<erikh> enjoy
rolfb has joined #ruby-lang
mamat has joined #ruby-lang
gouthamvel has joined #ruby-lang
mamat has quit [#ruby-lang]
gouthamvel has quit [#ruby-lang]
jtoy has joined #ruby-lang
esad has joined #ruby-lang
vesan_ has joined #ruby-lang
dr0id has quit [#ruby-lang]
tomb has joined #ruby-lang
rippa has joined #ruby-lang
tobiaseigen has joined #ruby-lang
<tobiaseigen> hello everyone
<tobiaseigen> I am moving my redmine site from one server to another and am running into difficulties with ruby version - 1.8.5 is installed, I need 1.8.7. Can anyone direct me to a howto for upgrading ruby?
seanstickle has joined #ruby-lang
workmad3_ has joined #ruby-lang
<yxhuvud> 1.8.5? what OS is that? centos5 oslt?
<tobiaseigen> centos5
<tobiaseigen> it's a plesk 10 hosted at mediatemple
<yxhuvud> as far as I can see, basically you have 3 options. 1: find suitable rpms containing the correct verion. 2: build ruby yourself. 3: install rvm and run what you need through that.
<yxhuvud> 1 is probably simplest if you manage to find the packages
<tobiaseigen> hmm.. ok thanks yxhuvud
datanoise has joined #ruby-lang
<KINGSABRI> erikh, I go the issue
<KINGSABRI> I solve it
<KINGSABRI> I did block command(Level2) inside block of command(Level1)
<KINGSABRI> s.cmd(hcmd[0]) do |l0|# Priv escalation
<KINGSABRI> print l0
<KINGSABRI> s.cmd(hcmd[1]) do |l1|# Interface config level
<KINGSABRI> print l1
<KINGSABRI> s.cmd(hcmd[2]) do |l2| # ifup/ifdown
<KINGSABRI> print l2
<KINGSABRI> s.cmd(hcmd[3]) do |l3|# ifstatus
<KINGSABRI> print l3
<rue> Use GIST
<KINGSABRI> end# l3
<KINGSABRI> end#l2
<KINGSABRI> end# l1
<KINGSABRI> end# l0
<rue> You should know this, dood
<KINGSABRI> sorry , just I was rush + happy :)
<MDmalLION> puts "Enter the number of years you want to convert into hours."
<MDmalLION> years = gets.chomp
<MDmalLION> hours = 24*365*#{years}
<MDmalLION> puts "There are #{hours} in a year.
jacktrick has joined #ruby-lang
<MDmalLION> im using hospital internet which has code related stuff blocked
<manveru> wtf is going on today?
<Mon_Ouie> Happened twice yesterday as well
arooni-mobile has joined #ruby-lang
<shevy> the world as we know it is comcing to an end
<shevy> PERL 6!!!!!!!!!!!
<MDmalLION> how many hours are in a year?
<rolfb> 8760 for a regular year, 8784 for leap years?
<rue> Hm, wonder how you could solve that
<shevy> MDmalLION 365 * 24
<shevy> now you only have to replace 365 with what ruby tells you for any given year the amount of days that year has!
<shevy> or perhaps there is a .hour method already
gsav has joined #ruby-lang
<MDmalLION> i'm lost
<manveru> >> require 'date'; d = Date.new(2012); ((((d >> 12) - 1) - d) * 24).to_i
<manveru> => 8760
slimfit has joined #ruby-lang
ezkl has joined #ruby-lang
<rolfb> manveru: isn't that wrong?
fgomez has joined #ruby-lang
<canton7> d = Date.new(2012); (d.next_year - d).to_i * 24
<rolfb> it's a leap year?
* canton7 suspects an off-by-one error with that "- 1"
<manveru> hm
<manveru> next_year goes until next 1st
<manveru> which is one day too much, no?
<canton7> it gives 365 for a non-leap year and 366 for a leap year
<rolfb> manveru: 2012
<rolfb> durr
<rolfb> nvm
<manveru> d = Date.new(2013); (d..d.next_year).count
<manveru> => 366
<rolfb> (Date.new(2013)-Date.new(2012)).to_i*24
<manveru> for 2013 that is
<rolfb> i don't have next_year
<manveru> you required date?
<rolfb> i did
<Mon_Ouie> (d..(d+1)).count is 2, yet (d + 1) - d is 1
<canton7> d = Date.new(2013); (d.next_year - d).to_i # => 365
<manveru> 1.9.3?
<rolfb> manveru: gawd, dkubb is making me use 1.8.7
<rolfb> :P
<manveru> lol
<rolfb> didn't notice
kiddorails has joined #ruby-lang
<rolfb> manveru: good catch ;)
olesu has joined #ruby-lang
rdavila has joined #ruby-lang
gouthamvel has joined #ruby-lang
gouthamvel has quit [#ruby-lang]
A124 has joined #ruby-lang
publicvoid_ has joined #ruby-lang
ericmuyser has joined #ruby-lang
jxie has joined #ruby-lang
gouthamvel has joined #ruby-lang
nofxx has joined #ruby-lang
gouthamvel has quit [#ruby-lang]
gray has joined #ruby-lang
Defusal has joined #ruby-lang
FiXato has joined #ruby-lang
esad has joined #ruby-lang
io_syl has joined #ruby-lang
kensei_ has joined #ruby-lang
kensei has joined #ruby-lang
kensei has quit [#ruby-lang]
fattastic has joined #ruby-lang
savage- has joined #ruby-lang
lsegal has joined #ruby-lang
flak has joined #ruby-lang
kensei has joined #ruby-lang
kensei has quit [#ruby-lang]
gray has joined #ruby-lang
DMKE has joined #ruby-lang
nahhh has joined #ruby-lang
fgomez has joined #ruby-lang
io_syl has joined #ruby-lang
<andrewvos> someone give me something to code
<andrewvos> need a break from skyrim
S1kx has joined #ruby-lang
S1kx has joined #ruby-lang
postmodern has joined #ruby-lang
<any-key> andrewvos: you should write this haskell assignment for me that modifies java class files
<andrewvos> any-key: I said I need a break from SkyRim, not that I'm a masochist.
<any-key> :P
rippa has joined #ruby-lang
nahhh has joined #ruby-lang
<shevy> andrewvos let's work on RubyOS
kiddorails has joined #ruby-lang
<seanstickle> Just bring back Symbolics LISP OS
_dabradley has joined #ruby-lang
<shevy> dont know that
<shevy> it probably was crap
<shevy> :>
gsav has joined #ruby-lang
kensei_ has joined #ruby-lang
slimfit has joined #ruby-lang
pygmael has joined #ruby-lang
brianpWins has joined #ruby-lang
dabradley has joined #ruby-lang
chimkan has joined #ruby-lang
chimkan__ has joined #ruby-lang
chimkan__ has joined #ruby-lang
Defusal has joined #ruby-lang
Defusal has joined #ruby-lang
heppy has joined #ruby-lang
gsav has joined #ruby-lang
FiXato has joined #ruby-lang
kings has joined #ruby-lang
_dabradley has joined #ruby-lang
Sailias has joined #ruby-lang
dabradley has joined #ruby-lang
rdavila has joined #ruby-lang
mistym has joined #ruby-lang
esad has joined #ruby-lang
dabradley has joined #ruby-lang
Zolrath has joined #ruby-lang
dfr|mac has joined #ruby-lang
jacktrick has joined #ruby-lang
rorymckinley has joined #ruby-lang
gnufied has joined #ruby-lang
rockstar1144 has joined #ruby-lang
rockstar1144 has quit [#ruby-lang]
Defusal_ has joined #ruby-lang
Defusal_ has joined #ruby-lang
toretore has joined #ruby-lang
tbuehlmann has joined #ruby-lang
nofxxx has joined #ruby-lang
kiddorails has quit [#ruby-lang]
pygmael has joined #ruby-lang
gouthamvel has joined #ruby-lang
savage- has joined #ruby-lang
macmartine has joined #ruby-lang
tevren has joined #ruby-lang
petercooper has joined #ruby-lang
io_syl has joined #ruby-lang
BryanWB__ has joined #ruby-lang
fayimora has joined #ruby-lang
Luxx_ has joined #ruby-lang
kitallis has joined #ruby-lang
kitallis has joined #ruby-lang
nofxxx has joined #ruby-lang
nofxx has joined #ruby-lang
deobald has joined #ruby-lang
esad has joined #ruby-lang
Asher has joined #ruby-lang
francisfish has joined #ruby-lang
nofxx has joined #ruby-lang
mistym has joined #ruby-lang
Axsuul has joined #ruby-lang
Axsuul has joined #ruby-lang
Axsuul has joined #ruby-lang
Axsuul has joined #ruby-lang
olesu has joined #ruby-lang
codewrangler has joined #ruby-lang
slimfit has joined #ruby-lang
fayimora has joined #ruby-lang
Jay_Levitt has joined #ruby-lang
jfelchner has joined #ruby-lang
workmad3_ has joined #ruby-lang
m3nd3s has joined #ruby-lang
rorymckinley has joined #ruby-lang
fgomez has joined #ruby-lang
Swimming_Bird has joined #ruby-lang
srbaker has joined #ruby-lang
hagabaka has joined #ruby-lang
MDmalLION has joined #ruby-lang
chimkan has joined #ruby-lang
rdavila has joined #ruby-lang
burgestrand has joined #ruby-lang
jstr has joined #ruby-lang
tevren has joined #ruby-lang
Asher has joined #ruby-lang
ezkl has joined #ruby-lang
<bougyman> 29
<andrewvos> 30
heppy has joined #ruby-lang
fgomez has joined #ruby-lang
<shevy> 28
<canton7> ooh, breaking the mould!
kurko_ has joined #ruby-lang
Joeysomo has joined #ruby-lang
kurko__ has joined #ruby-lang
silvia has joined #ruby-lang
srbartlett has joined #ruby-lang
aran418 has joined #ruby-lang
ryanf has joined #ruby-lang
kurko__ has joined #ruby-lang
tevren has joined #ruby-lang
savage- has joined #ruby-lang
t has joined #ruby-lang
<drbrain> also, bougyman will have a much harder time winning Price is Right
<bougyman> why is that?
<bougyman> oh.
<bougyman> heh
* bougyman Doh
igotnolegs has joined #ruby-lang
kyrylo has joined #ruby-lang
niklasb has joined #ruby-lang
<niklasb> join ##c
<niklasb> nvm :)
Pip has joined #ruby-lang
heppy has joined #ruby-lang
kurko__ has joined #ruby-lang
heppy has joined #ruby-lang
heppy has quit [#ruby-lang]
heppy has joined #ruby-lang
peppyheppy has joined #ruby-lang
zenspider has joined #ruby-lang
<zenspider> what'd I miss?
<zenspider> I just got ruby_parser "finished" for 1.9. Fixed ruby2ruby, ruby2c, flog, and flay to work with it
kurko__ has joined #ruby-lang
brushbox has joined #ruby-lang
qpingu has joined #ruby-lang
seoaqua has joined #ruby-lang
<seoaqua> why is this uri invalid? http://mp3.sogou.com/tag.so?query=%u65C5%u884C
esad has quit ["["Textual IRC Client: www.textualapp.com"]"]
guns has joined #ruby-lang