apeiros changed the topic of #ruby to: Ruby 2.0.0-p353: http://ruby-lang.org (Ruby 1.9.3-p484) || Paste >3 lines of text on http://gist.github.com || this channel is logged at http://irclog.whitequark.org, other public logging is prohibited
mmitchell has joined #ruby
bklane has joined #ruby
joaoh82 has quit [Ping timeout: 246 seconds]
drumusician has quit [Ping timeout: 272 seconds]
cespare has joined #ruby
cespare has left #ruby ["WeeChat 0.4.1"]
flubba has quit [Remote host closed the connection]
joaoh82 has joined #ruby
mmitchell has quit [Ping timeout: 272 seconds]
Yarou has joined #ruby
LexicalScope has quit [Quit: Leaving]
Yarou has quit [Client Quit]
joaoh82 has quit [Ping timeout: 246 seconds]
robbyoconnor has quit [Excess Flood]
robbyoconnor has joined #ruby
skulker has joined #ruby
bklane has quit [Ping timeout: 240 seconds]
spider-mario has quit [Read error: Connection reset by peer]
Barrin6 has joined #ruby
Kricir has joined #ruby
grep_away is now known as grep_awesome
nari has joined #ruby
bklane has joined #ruby
smathieu has joined #ruby
s2013 has quit [Quit: Leaving]
Hanmac1 has joined #ruby
ambushsabre has quit [Quit: rip]
mercwithamouth has quit [Ping timeout: 246 seconds]
ambushsabre has joined #ruby
specious has joined #ruby
petey has quit [Remote host closed the connection]
guest456 has joined #ruby
Hanmac has quit [Ping timeout: 252 seconds]
smathieu has quit [Ping timeout: 272 seconds]
petey has joined #ruby
aspires has joined #ruby
klaut has quit [Remote host closed the connection]
pinage404 has quit [Quit: Screw you guys i'm going home ! KMP !]
axl_ has quit [Quit: axl_]
petey has quit [Ping timeout: 272 seconds]
aspiers has joined #ruby
lewix has joined #ruby
phipes has quit [Remote host closed the connection]
coffeina has quit [Remote host closed the connection]
grep_awesome is now known as grep_away
lnormous has quit [Quit: Leaving]
shedd has joined #ruby
Yarou has joined #ruby
Yarou has joined #ruby
Yarou has quit [Changing host]
bklane has quit [Ping timeout: 240 seconds]
bklane has joined #ruby
nomenkun has quit [Remote host closed the connection]
specious has quit [Ping timeout: 260 seconds]
chrisramon has joined #ruby
shedd has quit [Ping timeout: 246 seconds]
<pontiki> hi all
jkhwan has joined #ruby
Virtualize has joined #ruby
geggam has quit [Quit: Leaving]
banghouse has joined #ruby
banghouse is now known as Guest63675
_honning_ has quit [Ping timeout: 272 seconds]
Virtualize has quit [Ping timeout: 246 seconds]
jkhwan has quit [Ping timeout: 272 seconds]
shime has quit [Ping timeout: 245 seconds]
petey has joined #ruby
marr has quit [Ping timeout: 252 seconds]
nisstyre has quit [Quit: Leaving]
Wolland has joined #ruby
nisstyre has joined #ruby
mengu has quit []
Hanmac has joined #ruby
Hanmac1 has quit [Ping timeout: 245 seconds]
rjhunter has joined #ruby
eka has joined #ruby
samsonasu has joined #ruby
Wolland has quit [Ping timeout: 260 seconds]
dawe has quit [Ping timeout: 260 seconds]
rjhunter has quit [Ping timeout: 245 seconds]
nari has quit [Ping timeout: 252 seconds]
chrisgw has joined #ruby
guest456 has left #ruby [#ruby]
chrisgw has left #ruby [#ruby]
rjhunter has joined #ruby
havenwood has quit [Remote host closed the connection]
havenwood has joined #ruby
aspiers has quit [Ping timeout: 252 seconds]
predator217 has joined #ruby
Wolland has joined #ruby
robustus has quit [Ping timeout: 245 seconds]
klaut has joined #ruby
guest456 has joined #ruby
reach has joined #ruby
havenwood has quit [Ping timeout: 245 seconds]
predator117 has quit [Ping timeout: 260 seconds]
robustus has joined #ruby
klaut has quit [Remote host closed the connection]
clamstar has joined #ruby
joaoh82 has joined #ruby
flame_ has quit [Quit: Computer has gone to sleep.]
joaoh82 has quit [Read error: Connection reset by peer]
joaoh82 has joined #ruby
rjhunter has quit [Remote host closed the connection]
frx has joined #ruby
ambushsabre has quit [Quit: rip]
sassamo_ has joined #ruby
wallerdev has joined #ruby
timonv has joined #ruby
phipes has joined #ruby
aspires has quit []
joaoh82 has quit [Ping timeout: 246 seconds]
rjhunter has joined #ruby
Sawbones has joined #ruby
flubba has joined #ruby
sassamo has quit [Ping timeout: 260 seconds]
timonv has quit [Ping timeout: 272 seconds]
phipes has quit [Ping timeout: 252 seconds]
nisstyre has quit [Quit: Leaving]
smathieu has joined #ruby
aharris6 has joined #ruby
aharris6 has quit [Client Quit]
chrisramon has quit [Quit: chrisramon]
threesome has quit [Ping timeout: 260 seconds]
zxq9 has joined #ruby
havenwood has joined #ruby
Wolland has quit [Ping timeout: 252 seconds]
rootshift has joined #ruby
smathieu has quit [Ping timeout: 252 seconds]
flame_ has joined #ruby
ScottNYC has joined #ruby
clamstar has quit [Quit: Computer has gone to sleep.]
rjhunter has quit [Remote host closed the connection]
peregrine81 has joined #ruby
bklane has quit [Read error: Connection reset by peer]
rjhunter has joined #ruby
rhunter has joined #ruby
rjhunter has quit [Read error: Connection reset by peer]
dscrd has quit [Remote host closed the connection]
Xeago has joined #ruby
ehaliewicz has joined #ruby
crazymykl has quit [Quit: Konversation terminated!]
crazymykl has joined #ruby
ericmathison has joined #ruby
shedd has joined #ruby
<Rennex> any ideas on compiling ruby on a VM with 512MB of ram and no swap and no way to add a swapfile?
fschuindt has joined #ruby
<Rennex> i have a gut feeling that that's enough ram if the compilation process just doesn't try to do too much at the same time...
tappi has left #ruby [#ruby]
<Rennex> oh and someone should maybe update ruby 2.1.0 to the topic :)
greven_ has joined #ruby
olivier_bK has quit [Ping timeout: 246 seconds]
<pontiki> might be tight
<pontiki> idk
Speed has quit [Quit: When two people dream the same dream, it ceases to be an illusion.]
<havenwood> Rennex: checking what it seems to take on my machine
<havenwood> Rennex: so far: 287MB
<Rennex> well, last time i tried it, the OOM killer killed a bunch of stuff. But 512MB is a huge amount of ram compared to any single source file or object file in ruby...
<Rennex> or the final exectuable
shedd has quit [Ping timeout: 260 seconds]
<Rennex> so what's hogging all the ram :/
<havenwood> Rennex: i think you'll make it, try?
Hanmac1 has joined #ruby
rhunter has quit [Remote host closed the connection]
<Rennex> havenwood: did yours finish yet? because the ram usage shot up pretty late last time...
<Xeago> why can't you make a swap?
<pontiki> turn off other services not needed during the compile?
<Rennex> Xeago: it's a shitty OpenVZ VM
<havenwood> Rennex: Aborted the build to try 8 core parallel build
<Xeago> so?
<Rennex> pontiki: there aren't almost any, currently 79MB used
maletor has joined #ruby
<Xeago> don't you ahve root on the vm and disk space?
Sawbones has quit [Remote host closed the connection]
<Xeago> and if you don\'t have root but do have disk space and do have enough time
<Xeago> vm in a vm :3
<Xeago> and give that one a lot of disk-memor
<Xeago> u
<Xeago> slow as hell
kirun has quit [Quit: Client exiting]
<Xeago> but I've done it before for similar reasons
fschuindt has quit [Client Quit]
<havenwood> Rennex: looks to me to be same amount of gross memory with parallel build, just spread out
jkhwan has joined #ruby
<Rennex> Xeago: yeah i have root, but the kernel doesn't let me swapon
Virtualize has joined #ruby
dscrd has joined #ruby
Hanmac has quit [Ping timeout: 252 seconds]
petey has quit [Remote host closed the connection]
<havenwood> Rennex: i dunno, eyeballing it seems it 512 is more than enough
petey has joined #ruby
<Rennex> Xeago: vm in a vm isn't needed, i also have a better VM on my home pc... i'd just like to avoid faffing with libc version differences or whatnot :)
Astralum has quit [Ping timeout: 272 seconds]
<Rennex> havenwood: hmm, well the last i tried was 2.0 i think, maybe 2.1 takes a bit less ram... it's just risky because last time it also killed my ssh process, and i hope i don't have to go digging at the web-based control panel to be able to reboot it :D
Virtualize has quit [Ping timeout: 272 seconds]
jkhwan has quit [Ping timeout: 272 seconds]
<havenwood> Rennex: you're right on topic bump, our regular op's laptop is being repaired so topic freeze for the moment :P
guardianx has joined #ruby
petey_ has joined #ruby
<havenwood> Rennex: 2.1.0 ftw \o/
phipes has joined #ruby
petey has quit [Read error: Connection reset by peer]
ewnd9 has joined #ruby
Wolland has joined #ruby
Kricir has quit [Remote host closed the connection]
speakingcode has quit [Ping timeout: 272 seconds]
asteve has joined #ruby
cbetta is now known as cbetta_afk
Wolland has quit [Ping timeout: 252 seconds]
speakingcode has joined #ruby
asteve has quit [Client Quit]
<Rennex> laptop schmaptop, don't they have anything else to irc off? :D
<havenwood> Rennex: private key
RoryHughes has quit []
<Rennex> tsk
skulker_ has joined #ruby
<havenwood> Rennex: building from source?
<Rennex> what if the laptop is returned with a wiped disk :)
aryaching has joined #ruby
<havenwood> Rennex: i can't recall details, i just recall something re laptop :P
<Rennex> i'm about to try the build... there are a few small services i can also kill
rootshift has quit [Quit: rootshift]
skulker has quit [Ping timeout: 245 seconds]
AlSquire has quit [Ping timeout: 245 seconds]
AlSquire has joined #ruby
mzdravkov has left #ruby [#ruby]
Sawbones has joined #ruby
crazymykl has quit [Quit: Konversation terminated!]
crazymykl has joined #ruby
deol has joined #ruby
AlSquire has quit [Client Quit]
ScottNYC has quit [Quit: Linkinus - http://linkinus.com]
<Rennex> nope
<Rennex> gcc: Internal error: Killed (program cc1)
flubba has quit [Read error: Connection reset by peer]
flubba has joined #ruby
grep_away is now known as grep_awesome
coinsen has quit [Ping timeout: 245 seconds]
deol has quit [Client Quit]
estebistec has joined #ruby
bklane has joined #ruby
RoryHughes has joined #ruby
<Rennex> hmm, i went into the dir in /tmp to resume "make", now it seems to be going well
ss has joined #ruby
Hanmac has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
ss is now known as Guest32280
Notte_ has quit []
heidi has quit [Quit: Leaving.]
joaoh82 has joined #ruby
havenwood has quit [Remote host closed the connection]
Hanmac1 has quit [Ping timeout: 252 seconds]
crazymykl has quit [Remote host closed the connection]
mikemac has joined #ruby
flubba has quit [Remote host closed the connection]
specious has joined #ruby
petey_ has quit [Remote host closed the connection]
petey has joined #ruby
joaoh82 has quit [Ping timeout: 272 seconds]
psyl0n has quit []
skulker_ has quit [Remote host closed the connection]
danshultz has quit [Remote host closed the connection]
grep_awesome is now known as grep_away
Seich has quit [Quit: Computer has gone to sleep.]
<Rennex> wahey, it's installed
danshultz has joined #ruby
petey has quit [Ping timeout: 252 seconds]
aryaching has quit [Ping timeout: 272 seconds]
smathieu has joined #ruby
<Rennex> hmm... looking at ruby-build, it seems that it looks at the number of cpu cores (24 on that server) and uses that many concurrent threads :D
danshult_ has joined #ruby
danshultz has quit [Read error: Connection reset by peer]
peregrine81 has quit []
rickruby has joined #ruby
bklane has quit [Remote host closed the connection]
smathieu has quit [Ping timeout: 272 seconds]
dscrd has quit [Quit: .]
lyanchih_ has quit [Quit: lyanchih_]
guardianx has quit [Remote host closed the connection]
Hien has quit [Remote host closed the connection]
HashNuke_ has joined #ruby
platzhirsch has left #ruby [#ruby]
freebs has joined #ruby
mercwithamouth has joined #ruby
aryaching has joined #ruby
noob101 has joined #ruby
<noob101> Hello, I am a 16 year old male from NY and I want to be a programmer. please check out my code. I developed this game by myself took me maybe 1 month.
<noob101> Any suggestions please. link---> https://eval.in/83881
<noob101> Personal message me I have to go afk thanks.
Hien has joined #ruby
fenicks has joined #ruby
sepp2k1 has quit [Read error: Connection reset by peer]
<WJW> noob101, you write "to often" when you mean "too often".
<pontiki> lol
<WJW> Is there really a way to personal message someone?
emocakes has joined #ruby
<noob101> WJW, what you mean? I practice my programming on a daily basis.
<pontiki> WJW: use /msg <nick> <msg> or /query <nick> <msg>
<pontiki> noob101: WJW is tweaking you on your English grammar, not your coding
<WJW> Thanks, pontiki.
<WJW> noob101, Where you write "This selection is cannot be undo so think before making this decision.", you should say "undone" instead of "undo", and should put a comma after it.
<WJW> noob101, also, omit "is".
shedd has joined #ruby
okinomo has joined #ruby
nisstyre has joined #ruby
zxq9 has quit [Quit: Konversation terminated!]
<WJW> noob101, the test on line 232 will always fail.
shedd has quit [Ping timeout: 245 seconds]
lowski has joined #ruby
<noob101> how come'
mercwithamouth has quit [Ping timeout: 245 seconds]
Seich has joined #ruby
<pontiki> Rennex: i just source-compiled ruby2.1.0 in 384MB RAM, no swap
<WJW> noob101, because on line 229, you have already established that the variable 'user_input' contains exactly "h".
Virtualize has joined #ruby
<WJW> noob101, and when we get to line 232, we are still in the scope of the 'if' on line 229.
<Rennex> pontiki: yeah, i'll be making some suggestions to the ruby-build guy ;)
sassamo_ has quit [Remote host closed the connection]
sassamo has joined #ruby
<pontiki> Rennex: *nod*
BradPitt_ has quit [Ping timeout: 272 seconds]
<WJW> noob101, some (or all) of your begin-end blocks are unnecessary. But maybe you are choosing to use them as a matter of style?
BraddPitt has joined #ruby
byprdct has joined #ruby
mikepack has quit []
flubba has joined #ruby
okinomo has quit [Ping timeout: 245 seconds]
zxq9 has joined #ruby
Virtualize has quit [Ping timeout: 252 seconds]
mikepack has joined #ruby
<Rennex> noob101: some basic suggestions: first of all, just "puts" will print an empty line, you don't need to give it a string with one space in it :) And second, see how many times you've written a few lines that say "What was your answer, I didn't catch that" and handle the input - those would be a perfect thing to move to a method that you call instead of copypasting that snippet (DRY - don't repeat yourself)
sassamo has quit [Ping timeout: 246 seconds]
nisstyre has quit [Quit: Leaving]
jamesaxl_ has quit [Ping timeout: 252 seconds]
mikepack has quit [Remote host closed the connection]
descala has quit [Ping timeout: 272 seconds]
larissa has quit [Quit: Leaving]
<WJW> noob101, Line 269 again tests user_input in a context where it is known.
descala has joined #ruby
mgberlin has quit [Quit: mgberlin]
ewnd9 has quit [Ping timeout: 240 seconds]
<WJW> noob101, line 282, "chose" should be "chosen".
lowski is now known as lowski_away
Bumptious has quit [Remote host closed the connection]
rjhunter has joined #ruby
Seich has quit [Quit: Computer has gone to sleep.]
<WJW> noob101, line 300 is probably not what you mean.
<Rennex> true
<noob101> Sorry I was busy I am back.
<noob101> I will read from the top, thanks for the advice.
<WJW> noob101, in line 300, cpu_cards will always appear to be truthy.
michael_lee has joined #ruby
<Rennex> you'd want if cpu_cards > 21 && user_cards > 21
<WJW> noob101, you probably mean something like what Rennex said.
Seich_ has joined #ruby
<WJW> Interesting that what he tried resembles expressions that work in natural language.
<IceDragon> hey folks, FileUtils#touch is bugged
<IceDragon> it doesn't create the when it doesn't exist
<noob101> WJW, about line 229 and 232 in my code, it's a loop so wouldn't the variable user_input receive a different string each time it's iterated? Isn't that what I did correctly.
<Rennex> noob101: and all those sleeps would make for a slow game... 43.5 seconds just to print that help on lines 118..176 :)
<noob101> WJW I am choosing my begin and end blocks cause that is how a loop is right? I was taught that.
<IceDragon> nvm, for some odd reason, my paths went haywire
<noob101> Rennex, thanks for the suggestion. That is an excellent idea to make a method to print that.
<WJW> noob101, I was wrong about the tests, you are doing a loop and there is an input at the bottom.
michael_lee has quit [Max SendQ exceeded]
<Rennex> noob101: and not just print, also get the input and check for valid commands :)
<WJW> noob101, does the program do what you want it to do?
nanoyak has joined #ruby
okinomo has joined #ruby
flubba has quit [Remote host closed the connection]
lowski_away is now known as lowski
michael_lee has joined #ruby
lowski has quit [Quit: Textual IRC Client: www.textualapp.com]
gordon__ has left #ruby ["WeeChat 0.4.1"]
<noob101> WJW I suppose so, this is my first program kind of.
<Rennex> noob101: those begin...end while (..) loops work, but they're rare to see in ruby, mostly because it looks so awkward. Usually you'd have the condition at the top: while (stuff) ... end
<noob101> I am just trying to practice. my programming skills.
<noob101> Oh the condition is in the beginning of a loop?? I had no idea.
<noob101> I have to go in 3 minutes sadly.
<Rennex> usually you're also repeating the same condition at the bottom as in your "if" clause at the top - a single "while" clause would handle both and again reduce repetition
timonv has joined #ruby
<noob101> Rennex for my help method should I just print it straight with no sleep?
<noob101> Rennex, so I should have a while and an end?
<noob101> Something like this.
<Rennex> yeah
<Rennex> noob101: i would print without sleeps, yeah.. or if you want an effect of text appearing slowly, at least make it faster. like a sleep 0.1 between lines :)
<WJW> noob101, whether to use sleep is a decision about user interface. If it's your judgment that that gives a better user experience, I will not oppose that.
<noob101> while (user_input != "h") && (user_input != "s)
<noob101> puts " I am sorry, repeat that"
<noob101> end
<noob101> Like that?
<WJW> yes.
<noob101> Oh thanks.
<Rennex> yeah, but also user_input = gets.chomp inside the loop
<Rennex> :)
MrJoshua has quit [Quit: MrJoshua]
<noob101> Have to go, it's 10 o'clock I would stay up longer but it's the rules.
<WJW> noob101, test it until you know for sure whether it does what you throught it would do.
<noob101> Thanks a lot please keep in touch, add me.
<noob101> I do WJW, thanks.
heidi has joined #ruby
<noob101> Have a good time..
<noob101> Thanks again.
freezey has joined #ruby
<WJW> You can add someone in IRC?
danshult_ has quit [Remote host closed the connection]
<noob101> IDK I heard.
<noob101> One more question before I go.
<pontiki> "add me" ?? to what?
<noob101> Can you make the text appearing on screen slower?
<WJW> I doubt it.
<pontiki> noob101: do you mean when it's typing across?
<noob101> forget it I have to go see you guys next time.
<noob101> Thanks for help everyone
<pontiki> cheers
noob101 has quit [Quit: Page closed]
timonv has quit [Ping timeout: 260 seconds]
okinomo has quit [Ping timeout: 240 seconds]
chrisan has quit [Ping timeout: 260 seconds]
hl has quit [Ping timeout: 246 seconds]
flubba has joined #ruby
juarlex has quit [Remote host closed the connection]
fenicks has quit [Read error: Connection reset by peer]
ewnd9 has joined #ruby
RoryHughes has quit []
joaoh82 has joined #ruby
crapple has quit [Ping timeout: 252 seconds]
bogeyd6 has joined #ruby
heidi has quit [Quit: Leaving.]
joaoh82 has quit [Ping timeout: 260 seconds]
burlyscudd has quit [Quit: Leaving.]
crapple has joined #ruby
michael_lee has quit [Quit: Ex-Chat]
mojjojo has joined #ruby
skulker has joined #ruby
mikepack has joined #ruby
smathieu has joined #ruby
petey has joined #ruby
bogeyd6 has quit [Ping timeout: 272 seconds]
mojjojo has quit [Client Quit]
iliketurtles has joined #ruby
tkuchiki has joined #ruby
mojjojo has joined #ruby
rickruby has quit [Remote host closed the connection]
mikepack has quit [Ping timeout: 260 seconds]
crapple has quit [Ping timeout: 252 seconds]
smathieu has quit [Ping timeout: 246 seconds]
eka has quit [Quit: Computer has gone to sleep.]
shadoi has quit [Ping timeout: 245 seconds]
aryaching_ has joined #ruby
mikepack has joined #ruby
blarghmatey_ has joined #ruby
stetho has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
aryaching has quit [Ping timeout: 252 seconds]
crapple has joined #ruby
asteve has joined #ruby
ambushsabre has joined #ruby
<WJW> I'm looking for a fairly elegant way to express a certain kind of graph.
ambushsabre has quit [Client Quit]
<WJW> Nodes in it will belong to types that mean something, and I also want an elegant way to define the types.
<WJW> I want the graph notation to apply to several programming languages.
skulker has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
<WJW> I mean, I intend to define several languages in which the graphs are the programs.
shedd has joined #ruby
asteve has quit [Client Quit]
blarghmatey_ has quit [Ping timeout: 246 seconds]
<WJW> One question is whether to use a class for each node type or something that is not a class to represent that.
smathieu has joined #ruby
crapple has quit [Ping timeout: 246 seconds]
<WJW> https://gist.github.com/waugh/8167130 is an example of using something that is not a class, to represent a node type.
mojjojo has quit [Quit: mojjojo]
shedd has quit [Ping timeout: 246 seconds]
blarghmatey has joined #ruby
<WJW> What this example doesn't extend to is where a node needs a variable number of edges coming in to it, e. g. to represent an array constructor or a record constructor.
jkhwan has joined #ruby
Virtualize has joined #ruby
smathieu has quit [Ping timeout: 245 seconds]
sassamo has joined #ruby
petey has quit [Remote host closed the connection]
petey has joined #ruby
crapple has joined #ruby
Virtualize has quit [Ping timeout: 240 seconds]
jkhwan has quit [Ping timeout: 272 seconds]
flubba has quit [Remote host closed the connection]
dima has joined #ruby
Neomex has quit [Quit: Neomex]
jego has joined #ruby
okinomo has joined #ruby
maycon has quit [Quit: Saindo]
<pcfreak30> What is "endclass" for? My IDE apparently auto-added it? Thought the end statement handled everything
sassamo has quit [Ping timeout: 260 seconds]
<WJW> New one on me.
crapple has quit [Ping timeout: 246 seconds]
<pcfreak30> "endclass MulticraftApi"
reach has quit [Read error: Connection reset by peer]
blandflakes_ has joined #ruby
habanany has joined #ruby
blandflakes has quit [Disconnected by services]
blandflakes_ is now known as blandflakes
<WJW> Does your IDE think you are using another langauge, pcfreak30?
<pcfreak30> no
<pcfreak30> its rubymine
<pcfreak30> and a .rb file..
<WJW> http://mismatched-end.rubyforge.org/ I don't know whether this is a good idea or not.
<WJW> pcfreak30, sounds like a broken IDE.
ambushsabre has joined #ruby
cosmicpanda is now known as JackStoner
JackStoner is now known as cosmicpanda
nisstyre has joined #ruby
randomnick_ has quit [Quit: Leaving]
<WJW> I saw a language definition that allows embedded HTML; the language treats HTML as a data type and provides a constructor for it. In that constructor syntax, you could write something like <div>foo</> and it would mean <div>foo</div>.
peregrine81 has joined #ruby
<WJW> So we see some people providing a way to say what you are ending when the original language doesn't, and other people providing a way to not say what you are ending when the original language required you to say it.
vinian has joined #ruby
crapple has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
nanoyak has quit [Quit: Computer has gone to sleep.]
grep_away is now known as grep_awesome
Gestahlt has quit [Read error: Connection reset by peer]
habanany has quit [Ping timeout: 245 seconds]
Gestahlt has joined #ruby
ericmathison has quit [Quit: leaving]
emocakes has quit [Quit: Leaving...]
<Rennex> well i for one hate that idea of endclass etc :)
crapple has quit [Ping timeout: 246 seconds]
juarlex has joined #ruby
radic has quit [Ping timeout: 245 seconds]
<WJW> It could break existing code.
crapple has joined #ruby
<WJW> Algol 68 used backward-spelled keywords, e. g. case...esac, if...fi.
sassamo has joined #ruby
<WJW> comment ... tnemmoc
radic has joined #ruby
rjhunter has quit [Remote host closed the connection]
petey has quit [Remote host closed the connection]
gquental has quit [Ping timeout: 245 seconds]
petey has joined #ruby
braincrash has quit [Quit: bye bye]
juarlex has quit [Ping timeout: 252 seconds]
phipes has quit [Remote host closed the connection]
phipes has joined #ruby
phansch has joined #ruby
braincrash has joined #ruby
joaoh82 has joined #ruby
petey has quit [Ping timeout: 252 seconds]
hl has joined #ruby
freerobby has quit [Quit: Leaving.]
<WJW> I didn't want to write an interpreter in Ruby for any of these languages, but there might not be any other sane way to test that my notation supports being crawled by a module that would understand the meaning enough to do a translation to another language, say.
<pontiki> pcfreak30: are you sure that isn't a comment?
freezey has quit [Remote host closed the connection]
estebistec has quit [Remote host closed the connection]
habanany has joined #ruby
<pontiki> WJW: you could make it a grammar, and parse it the lexx/yacc
braincra- has joined #ruby
<pontiki> s/it the/it with/
<WJW> pontiki, I think yacc wants a linear concrete syntax.
ner0x has joined #ruby
danshultz has joined #ruby
<pontiki> it's been so long
LexicalScope has joined #ruby
ItSANgo has quit [Ping timeout: 246 seconds]
<WJW> Maybe I'll define abstract Javascript and write a translator from that to concrete Javascript.
joaoh82 has quit [Ping timeout: 272 seconds]
heidi has joined #ruby
<WJW> I have to do that eventually for my purposes anyway.
braincrash has quit [Ping timeout: 246 seconds]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
smathieu has joined #ruby
danshultz has quit [Ping timeout: 252 seconds]
gja has joined #ruby
gquental has joined #ruby
shedd has joined #ruby
gja has quit [Client Quit]
ItSANgo has joined #ruby
smathieu has quit [Ping timeout: 240 seconds]
SHyx0rmZ has quit [Quit: ネウロイを負かさなきゃならないね]
eriquez has joined #ruby
shedd has quit [Ping timeout: 252 seconds]
<WJW> I guess there isn't a comprehensive, intimate bridge between Ruby and node.js
guest456 has quit [Quit: Page closed]
<WJW> I was Googling for something like that just now.
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<WJW> Of course, they could send characters to each other over a socket or something like that.
heidi has quit [Quit: Leaving.]
<WJW> And I could use JSON to encode values in those characters.
smathieu has joined #ruby
Sawbones has quit [Remote host closed the connection]
Sawbones has joined #ruby
LadyRainicorn has joined #ruby
heidi has joined #ruby
falood has joined #ruby
juarlex has joined #ruby
CaptainJet has quit []
smathieu has quit [Ping timeout: 246 seconds]
dkamioka has joined #ruby
mechanicles has joined #ruby
B064F377 has joined #ruby
charliesome has joined #ruby
Bumptiou_ has joined #ruby
Sawbones has quit [Ping timeout: 252 seconds]
<pcfreak30> line 19, multicraft_api.rb why isnt it catching it
cescalante is now known as ce_afk
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
dkamioka has quit [Read error: Connection reset by peer]
dkamioka has joined #ruby
nomenkun has joined #ruby
<WJW> pcfreak30, how do you know it isn't?
<pcfreak30> woops put in wrong test case, ugg
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
heidi has quit [Quit: Leaving.]
blarghmatey has quit [Ping timeout: 246 seconds]
nomenkun has quit [Read error: Connection reset by peer]
<WJW> I didn't know you could post multi-file gists; that's cool.
nomenkun has joined #ruby
Vivekananda has quit [Remote host closed the connection]
Monie has quit [Read error: Connection reset by peer]
<LadyRainicorn> You can do *anything* with GitHub!
dima has quit [Remote host closed the connection]
nomenkun has quit [Read error: Connection reset by peer]
nomenkun has joined #ruby
rickruby has joined #ruby
heidi has joined #ruby
cflat has joined #ruby
flame_ has quit [Quit: Computer has gone to sleep.]
kenrick has quit [Read error: Connection reset by peer]
Monie has joined #ruby
Monie has quit [Max SendQ exceeded]
crapple has quit [Ping timeout: 294 seconds]
Virtualize has joined #ruby
peregrine81 has quit []
<WJW> The people I work with like Bitbucket better.
Monie has joined #ruby
Monie has quit [Max SendQ exceeded]
cflat has quit [Remote host closed the connection]
crapple has joined #ruby
Monie has joined #ruby
dima has joined #ruby
nomenkun has quit [Ping timeout: 272 seconds]
<pcfreak30> WJW: as otherwise it would return a hash and not throw an error
lewix has quit [Remote host closed the connection]
lewix has joined #ruby
heidi has quit [Client Quit]
echevemaster has joined #ruby
<WJW> pcfreak30, I guess when you post your example, I'll run it.
Virtualize has quit [Ping timeout: 246 seconds]
<LadyRainicorn> I was never a fan of hg. It made me crazy.
crapple has quit [Excess Flood]
* LadyRainicorn twirls her hat.
crapple has joined #ruby
ewnd9 has quit [Read error: Connection reset by peer]
lewix has quit [Ping timeout: 252 seconds]
<pcfreak30> WJW, i use bitbucket for all private stuff. github to show off :P
ewnd9 has joined #ruby
w4y has joined #ruby
crapple has quit [Ping timeout: 272 seconds]
<WJW> LadyRainicorn, what is hg?
Wolland has joined #ruby
petey has joined #ruby
skulker has joined #ruby
<pcfreak30> WJW, jg last I checked is a VCS
<pcfreak30> hg*
Roa has quit [Changing host]
Roa has joined #ruby
<LadyRainicorn> Bitbucket uses Mercurial, whose command line tool is called hg.
<WJW> LadyRainicorn, Oh. Bitbucket also supports 'git'.
<WJW> They should have used Hg.
<WJW> 'git' drives my colleague crazy.
mr_red has quit [Quit: Bye :)]
<LadyRainicorn> (Also, the symbol for mercury, to which exposure may induce insanity.)
<LadyRainicorn> Ah, that must be recent.
<LadyRainicorn> It used to be only Mercurial.
ner0x has quit [Quit: Leaving]
<WJW> Hg is the symbol for mercury.
<WJW> Case matters.
crapple has joined #ruby
pskosinski has quit [Quit: Til rivido Idisti!]
sorbo_ has joined #ruby
<WJW> pcfreak30, @@methods doesn't have key :testa.
<LadyRainicorn> case iS IRrelEVaNt, biTcH.
<sorbo_> I'm having difficulty matching wildcards with Sinatra::AssetPack (the JS and CSS files just aren't pulled in). anyone else had this problem?
browndawg has joined #ruby
mr_red has joined #ruby
vinian has joined #ruby
coca_rails has joined #ruby
vinian has quit [Max SendQ exceeded]
<WJW> sorbo_, did you by any chance ask on #sinatra?
Synthead has quit [Remote host closed the connection]
<pcfreak30> WJW, that was the test
<sorbo_> WJW: not yet! good call. will do
<phipes> oooh. i could have named parameters in ruby like objc/smalltalk
<pcfreak30> if (!@@methods.has_key? method) is supported to catch it
<WJW> pcfreak30, your code works as designed; it rejected :testa.
<phipes> do rubyists like named parameters?
<WJW> phipes, you mean using a Hash to pass them in?
<phipes> yes
<WJW> phipes, Yes, in partcular, Rails does that a lot.
<WJW> In Smalltalk, the names are part of the selector; in Ruby, they are not.
coca_rails has quit [Remote host closed the connection]
<pcfreak30> how do you excape a "
<WJW> pcfreak30, put a backslash in front of it.
<pcfreak30> hmm
<pcfreak30> it seemed to print the \
<WJW> pcfreak30, you already do that.
joaoh82 has joined #ruby
<pcfreak30> ["Unknown API method \"#{method.to_s}\""]
<pcfreak30> {:success=>false, :errors=>["Unknown API method \"listUser\""], :data=>{}}
juarlex has quit [Remote host closed the connection]
<RubyPanther> rubyists don't care about named parameters, they just care about having something with those semantics, even if it is just the convention of passing an options hash
<WJW> pcfreak30, it's because the interpreter is printing the object like source code for creating it.
sheap has joined #ruby
juarlex has joined #ruby
sheap has left #ruby [#ruby]
<WJW> pcfreak30, if you "puts" the string, you will not see the backslashes.
Mars` has joined #ruby
Sawbones has joined #ruby
<WJW> pcfreak30, puts api.testa.errors.first
joaoh82 has quit [Ping timeout: 252 seconds]
rjhunter has joined #ruby
juarlex has quit [Ping timeout: 245 seconds]
<sorbo_> hm. #sinatra is pretty empty
vinian has joined #ruby
elux has quit [Quit: Leaving...]
vinian has quit [Max SendQ exceeded]
LadyRainicorn has quit [Read error: Connection reset by peer]
<pontiki> the google group has a bit more action
ebobby has joined #ruby
<pontiki> but not much
LadyRainicorn has joined #ruby
rjhunter has quit [Ping timeout: 272 seconds]
IceDragon has quit [Quit: Space~~~]
petey has quit [Remote host closed the connection]
dseitz has joined #ruby
<WJW> sorbo_, is the tool you are calling supposed to take filename globbing?
<sorbo_> I'll keep hacking around on it, but it's weird that filenames work and globs don't
smathieu has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
lewix has joined #ruby
<WJW> sorbo_, not that wierd -- the globbing feature could be broken.
<sorbo_> WJW: yeah, that did cross my mind
petey has joined #ruby
<WJW> In the old, old days, the Unix shell would call a tool called 'glob'.
<pontiki> oh, it still does :)
<WJW> But it was glob(1), not glob(3).
smathieu has quit [Ping timeout: 245 seconds]
sayan has joined #ruby
kate_r has joined #ruby
LadyRainicorn has quit [Read error: Connection reset by peer]
phansch has quit [Remote host closed the connection]
sayan has quit [Client Quit]
petey has quit [Ping timeout: 252 seconds]
nari has joined #ruby
<WJW> All of old Unix for a PDP11 now fits in a browser; there is an emulator for it in JS.
dima has quit [Remote host closed the connection]
<WJW> including the whole contents of the RK11 pizza-oven disk.
mechanicles has quit [Quit: Computer has gone to sleep.]
axl_ has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
joaoh82 has joined #ruby
<WJW> I'd like to see a plot of how much memory you could get for a dollar, year by year. It would probably have to be logarithmic to be readable.
nowthatsamatt has quit [Quit: nowthatsamatt]
juarlex has joined #ruby
<pcfreak30> WJW, ive gotten that (gist). Whats the issue
<WJW> pcfreak30, I guess that's the next test of your code. It is trying to compare nil for <.
nomenkun has joined #ruby
<pcfreak30> i really have no idea what "<" is
<pcfreak30> or where that came from
<WJW> pcfreak30, < is less than.
<pcfreak30> i know that
<pcfreak30> but in this context
crapple has quit [Ping timeout: 260 seconds]
<WJW> pcfreak30, the previous test case, the one you sent, seemed to work OK; the code correctly rejected "testa" as a method selector.
<pcfreak30> WJW, but listConnections seems to throw it for a loop
<pcfreak30> i mean findConnections
<WJW> Line 30, if index < arguments.count
jkhwan has joined #ruby
ner0x has joined #ruby
Virtualize has joined #ruby
<WJW> pcfreak30, you forgot to change each_index to what our other friend here told you to change it to.
bklane has joined #ruby
bklane has quit [Client Quit]
juarlex has quit [Ping timeout: 272 seconds]
figgleberry has joined #ruby
nomenkun has quit [Ping timeout: 272 seconds]
crapple has joined #ruby
<pcfreak30> thanks
<pcfreak30> ive figured that :)
Xiti has quit [Ping timeout: 260 seconds]
Virtualize has quit [Ping timeout: 260 seconds]
jkhwan has quit [Ping timeout: 272 seconds]
Xiti has joined #ruby
figgleberry has quit [Ping timeout: 240 seconds]
phipes has quit [Remote host closed the connection]
Xiti has quit [Client Quit]
Xiti has joined #ruby
axl_ has quit [Quit: axl_]
sorbo_ has quit [Quit: sorbo_]
<pcfreak30> how do you dump a hash
ner0x has quit [Quit: Leaving]
<WJW> pcfreak30, a_hash.inspect
flubba has joined #ruby
crapple has quit [Ping timeout: 272 seconds]
emocakes has joined #ruby
blandflakes has quit [Ping timeout: 272 seconds]
<pcfreak30> if i use net::http post_form, does it not follow 302's?
<pcfreak30> #<Net::HTTPFound 302 Moved Temporarily readbody=true>
cbetta_afk is now known as cbetta
dima has joined #ruby
nari has quit [Ping timeout: 272 seconds]
dima__ has joined #ruby
dima has quit [Read error: No buffer space available]
speakingcode has quit [Quit: leaving]
reach has joined #ruby
speakingcode has joined #ruby
BrixSat has quit [Remote host closed the connection]
BrixSat has joined #ruby
aagdbl has joined #ruby
subbyyy has joined #ruby
subbyyy has quit [Client Quit]
crapple has joined #ruby
speakingcode has quit [Client Quit]
speakingcode has joined #ruby
aryaching_ has quit []
aspires has joined #ruby
cbetta is now known as cbetta_afk
<pcfreak30> Anyone have input?
Seich_ has quit [Quit: Computer has gone to sleep.]
crapple has quit [Ping timeout: 246 seconds]
WickedAtMelb has joined #ruby
ambushsabre has quit [Quit: rip]
Kricir has joined #ruby
crapple has joined #ruby
WickedAtMelb has quit [Client Quit]
Kneecaps has joined #ruby
crapple has quit [Excess Flood]
crapple has joined #ruby
freebs has quit [Quit: Leaving.]
grep_awesome is now known as grep_away
subbyyy has joined #ruby
anshin has quit [Ping timeout: 272 seconds]
subbyyy has quit [Client Quit]
crapple has quit [Ping timeout: 272 seconds]
subbyyy has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
Mars` has quit [Remote host closed the connection]
smathieu has joined #ruby
Jetchisel has joined #ruby
flubba has quit [Read error: Connection reset by peer]
flubba has joined #ruby
sayan has joined #ruby
smathieu has quit [Ping timeout: 246 seconds]
crapple has joined #ruby
crapple has quit [Excess Flood]
crapple has joined #ruby
croaky has joined #ruby
ceej has joined #ruby
dkamioka has quit [Remote host closed the connection]
crapple has quit [Excess Flood]
crapple has joined #ruby
timonv has joined #ruby
byprdct has quit [Quit: Textual IRC Client: www.textualapp.com]
nomenkun has joined #ruby
mmitchell has joined #ruby
<pcfreak30> i realize i was passing a bad url
<pcfreak30> realized
stetho has joined #ruby
crapple has quit [Excess Flood]
timonv has quit [Ping timeout: 246 seconds]
nomenkun has quit [Ping timeout: 245 seconds]
tropicalmug has joined #ruby
Tearan has quit []
Virtualize has joined #ruby
LexicalScope has quit [Ping timeout: 252 seconds]
Tearan has joined #ruby
crapple has joined #ruby
ningu has joined #ruby
<ningu> I am trying to install the ruby-augeas gem on OS X and getting the following error:
<ningu> extconf.rb:27:in `<main>': augeas-devel not installed (RuntimeError)
<ningu> but it is installed.
<emocakes> merry xmas everyone
<ningu> what exactly is unless pkg_config("augeas") checking?
<ningu> from the command line, I get the correct response for pkg-config --libs augeas
Virtualize has quit [Ping timeout: 272 seconds]
<ningu> it's installed in /usr/local and ruby is in /usr, but ...
Tearan has quit [Ping timeout: 245 seconds]
gja has joined #ruby
<pontiki> ningu: augeas may be installed, but it looks like augeas-devel is not. probably needs header files
<ningu> header files are in /usr/local/include
<pcfreak30> what method does a md5 hash
<ningu> pkg-config files are in /usr/local/lib
<pcfreak30> as Digest::MD5.digest is returning non ascii chars
<ningu> pontiki: any way I can check what mkmf is actually doing for pkg_config()?
Guest32280 has quit []
<pcfreak30> nvm
heidi has joined #ruby
heidi has quit [Client Quit]
cbetta_afk is now known as cbetta
OdNairy has joined #ruby
<WJW> >>
zoned has joined #ruby
flubba has quit [Remote host closed the connection]
zoned has left #ruby [#ruby]
nisstyre has quit [Quit: Leaving]
<pontiki> ningu: read the code?
<ningu> I am :)
<pontiki> cool :)
<ningu> looks like something is wrong with my pkg-config. weird.
<ningu> I uninstalled and reinstalled it and now it works fine.
cbetta is now known as cbetta_afk
Kricir has quit [Remote host closed the connection]
sayan has quit [Ping timeout: 246 seconds]
guest456 has joined #ruby
araujo has quit [Quit: Leaving]
stkowski has quit [Quit: stkowski]
Kneecaps has quit []
Tearan has joined #ruby
decoponio has joined #ruby
<guest456> is anybody here
<guest456> i have a quick question
<WJW> The way to find out is to pose the question.
ningu has left #ruby [#ruby]
<guest456> im using the .sample method and i want to know is this really random
<guest456> is .sample really the same as rand or is it semi random
kitak has joined #ruby
agjacome_ has joined #ruby
<WJW> guest456, the doc says there is an optional parameter that you can fill with any random number generator you want.
<WJW> guest456, I didn't check for older versions of Ruby, but http://www.ruby-doc.org/core-2.1.0/Array.html#method-i-sample
<guest456> i dont want to replace it i want to know is .sample simular to picking a random
<pontiki> for practical purposes, yes
<WJW> guest456, well, if you replace it, you will know for sure.
agjacome has quit [Ping timeout: 272 seconds]
<pontiki> it's equivalent to using rand
<guest456> ahh ok thanks
<pontiki> as that's what is implemented
<pontiki> read the code
<WJW> The code is in C.
<pontiki> still quite readable
croaky has quit [Read error: Connection reset by peer]
<WJW> randgen = rb_cRandom
<guest456> im finally making headway on implementing this ultimate game that every told me to give up on yesterday lol
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
LexicalScope has joined #ruby
skulker has quit [Remote host closed the connection]
Mars` has joined #ruby
skulker has joined #ruby
guest456 has quit [Quit: Page closed]
petey has joined #ruby
weeems is now known as weems
weems has quit [Changing host]
weems has joined #ruby
croaky has joined #ruby
mmitchell has quit [Remote host closed the connection]
skulker has quit [Ping timeout: 246 seconds]
Mars` has quit [Ping timeout: 246 seconds]
ripnix has quit [Remote host closed the connection]
petey has quit [Ping timeout: 240 seconds]
ripnix has joined #ruby
flubba has joined #ruby
nomenkun has joined #ruby
juarlex has joined #ruby
nomenkun_ has joined #ruby
nomenkun has quit [Read error: No buffer space available]
ripnix has quit [Ping timeout: 240 seconds]
lewix has quit [Remote host closed the connection]
mikepack has quit [Remote host closed the connection]
snath has quit [Ping timeout: 272 seconds]
charliesome has joined #ruby
jkhwan has joined #ruby
gja has quit [Ping timeout: 240 seconds]
lewix has joined #ruby
Virtualize has joined #ruby
nomenkun_ has quit [Ping timeout: 272 seconds]
juarlex has quit [Ping timeout: 272 seconds]
lewix has quit [Remote host closed the connection]
lewix has joined #ruby
vlad_starkov has joined #ruby
lewix has quit [Remote host closed the connection]
Virtualize has quit [Ping timeout: 246 seconds]
jkhwan has quit [Ping timeout: 272 seconds]
<bnagy> sample is as pseudorandom as anything else in ruby
<bnagy> oh, guess they buggered off
aspires has quit []
maoko has joined #ruby
mary5030 has joined #ruby
Yarou has quit [Quit: This computer has gone to sleep]
rippa has joined #ruby
cbetta_afk is now known as cbetta
vlad_starkov has quit [Remote host closed the connection]
Yarou has joined #ruby
Yarou has quit [Client Quit]
maoko has quit [Remote host closed the connection]
maoko has joined #ruby
maoko has quit [Remote host closed the connection]
Yarou has joined #ruby
Yarou has quit [Client Quit]
Yarou has joined #ruby
snath has joined #ruby
cbetta is now known as cbetta_afk
iliketurtles has joined #ruby
mikepack has joined #ruby
dseitz has quit [Quit: Textual IRC Client: www.textualapp.com]
rippa has quit [Ping timeout: 248 seconds]
mikepack has quit [Ping timeout: 272 seconds]
Tearan has quit []
Synthead has joined #ruby
alvinsj has joined #ruby
Synthead has quit [Remote host closed the connection]
jamesaxl has joined #ruby
timonv has joined #ruby
Synthead has joined #ruby
phipes has joined #ruby
alvinsj has quit [Client Quit]
aagdbl has quit [Quit: Leaving.]
Mars` has joined #ruby
flubba_ has joined #ruby
timonv has quit [Ping timeout: 252 seconds]
smathieu has joined #ruby
nomenkun has joined #ruby
flubba has quit [Ping timeout: 245 seconds]
Mars` has quit [Ping timeout: 252 seconds]
smathieu has quit [Ping timeout: 246 seconds]
nomenkun has quit [Ping timeout: 245 seconds]
nomenkun has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
nomenkun has quit [Ping timeout: 245 seconds]
shogo2040 has joined #ruby
dapz has joined #ruby
Virtualize has joined #ruby
Hobogrammer_ has joined #ruby
<shogo2040> I used JSON.parse on a variable, and when i puts a variable to log, I see the following: {"length"=>1625146, "media_type"=>"application/pdf", "uri"=>"http://feedproxy.google.com/~r/OmMalik/~5/eNCrFMSjN6k/Wang11IJSI.pdf"} The question is, how do I access it? I tried the dot operator, variable.media_type and I get NoMethodError.
Hobogrammer has quit [Ping timeout: 252 seconds]
<pontiki> shogo2040: it's a Hash
mechanicles has joined #ruby
phipes has quit [Remote host closed the connection]
RoryHughes has joined #ruby
<shogo2040> ok, how would I access the hash map properties?
<shogo2040> foo.media_type ?
LexicalScope has quit [Ping timeout: 246 seconds]
<pontiki> hash["length"]
Virtualize has quit [Ping timeout: 246 seconds]
Mon_Ouie has joined #ruby
dima__ has quit [Remote host closed the connection]
subbyyy has quit [Ping timeout: 245 seconds]
zz_N00D is now known as CripperZ
<shogo2040> ohhh.. i was using single quotes.. maybe thats my problem
<pontiki> no, hash['length'] would work just as well
<shogo2040> strange, I get TypeError - can't convert String into Integer
speakingcode has quit [Ping timeout: 272 seconds]
kitak has quit [Remote host closed the connection]
kitak has joined #ruby
<Hanmac> shogo2040: make a gist/pastie of your code
<pontiki> >> foo={"length"=>12345,"media_type"=>"application/pdf","url"=>"http://blahblah/junk.pdf"}; puts foo["length"]
<pontiki> hmm
<pontiki> >> puts "hello?"
<Hanmac> evalin is dead :'(
<pontiki> :'(
codenapper has joined #ruby
<Hanmac> charliesome: did you see this? :'(
<charliesome> aw
kitak has quit [Ping timeout: 245 seconds]
cbetta_afk is now known as cbetta
eval-in has quit [Remote host closed the connection]
eval-in has joined #ruby
<shogo2040> hanmac, pontiki... i ripped it out and dumped into irb.. and it works fine in irb... thanks for the info.. I'll keep at it before I give in to pastebin..
RoryHughes has quit []
Sawbones has quit [Remote host closed the connection]
<emocakes> evalin?
<emocakes> who is evalin
<emocakes> or what is evalin
<pontiki> she's your date
Sawbones has joined #ruby
<emocakes> i wont say no
<emocakes> nsfw
rubyracer has joined #ruby
samsonasu has quit [Quit: samsonasu]
<charliesome> >> "eval.in is cool"
<emocakes> anyway
<eval-in> charliesome => "eval.in is cool" (https://eval.in/83908)
<emocakes> dinner time
<emocakes> time to cook
<pontiki> >> puts "hello?"
<eval-in> pontiki => hello? ... (https://eval.in/83909)
<pontiki> yay!! \o/
* pontiki hugs charliesome
<Hanmac> >> RUBY_VERSION
<eval-in> Hanmac => "2.0.0" (https://eval.in/83910)
<WJW> >> self.class.name
<eval-in> WJW => "Object" (https://eval.in/83911)
<pontiki> omg that is cool :)))
<Hanmac> charliesome: the version is a bit outdated ...
<pontiki> i know it's not doing what it says
* Hanmac opens the can of evil » 2.1 was released «
<pontiki> i just source compiled 2.1.0 on a vm
<pontiki> works great afaict
Guest28016 has joined #ruby
* Hanmac already installed 2.2trunk
soobus has joined #ruby
<charliesome> i use 2.2.0dev as my main day to day ruby
<charliesome> i've dropped the ball a bit in lagging behind getting 2.1 on eval.in
Sawbones has quit [Ping timeout: 272 seconds]
<charliesome> i promise i'll get it done soon ;)
wallerdev has quit [Quit: wallerdev]
<pontiki> living dangerously!
<WJW> >> methods - Object.new.methods
<eval-in> WJW => [] (https://eval.in/83912)
frx has quit [Ping timeout: 260 seconds]
<WJW> >> `hostname`
<pontiki> you broke it :(((
<charliesome> hmmm i wonder why it's breaking
<charliesome> >> 1+2
<charliesome> god fuck
<WJW> [hides under a chair]
cbetta is now known as cbetta_afk
Synthead has quit [Remote host closed the connection]
kate_r has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
<shogo2040> i fixed it! I had to shove it in a loop before i can access it.. hmm.. wish i understood why.. it was a lucky guess.. I better read up on that hash documentation.
<pontiki> i'm guessing some scoping issue or other
<WJW> shogo2040, no idea why a loop would be necessary.
<charliesome> looks like the bot can't connect to the db or something
Sawbones has joined #ruby
RoryHughes has joined #ruby
<charliesome> >> 1+2
<shogo2040> 12
<charliesome> looks like it's a cinch problem ugh
<shogo2040> jk
<dominikh> considering Cinch doesn't care about your db, I don't think so ;)
codezomb has joined #ruby
<charliesome> nah a cinch/activerecord thing
<charliesome> my naive code is breaking
<dominikh> I'm impressed every time someone uses AR instead of something that's not going bonkers when facing threads ;)
<charliesome> heh
<dominikh> (yeah, I've never heard of a happy Cinch+AR user…)
CripperZ is now known as zz_CripperZ
iliketurtles has joined #ruby
<charliesome> i'll try that pool hack
iliketurtles has quit [Excess Flood]
<charliesome> then maybe spend some time digging into what's causing this
eval-in has quit [Remote host closed the connection]
eval-in has joined #ruby
iliketurtles has joined #ruby
mary5030 has quit [Remote host closed the connection]
klaut has joined #ruby
mary5030 has joined #ruby
shogo2040 has left #ruby [#ruby]
diegoviola has joined #ruby
mary5030 has quit [Ping timeout: 246 seconds]
BraddPitt has quit [Ping timeout: 260 seconds]
Mars` has joined #ruby
BraddPitt has joined #ruby
RoryHughes has quit []
Guest63675 has quit [Remote host closed the connection]
smathieu has joined #ruby
petey has joined #ruby
rjhunter has joined #ruby
mmitchell has joined #ruby
Mars` has quit [Ping timeout: 272 seconds]
mechanicles has quit [Quit: Computer has gone to sleep.]
soobus has quit [Ping timeout: 246 seconds]
workmad3 has joined #ruby
croaky has quit [Ping timeout: 246 seconds]
mechanicles has joined #ruby
Sawbones has quit [Remote host closed the connection]
smathieu has quit [Ping timeout: 246 seconds]
autumn has joined #ruby
Sawbones has joined #ruby
petey has quit [Ping timeout: 245 seconds]
kate_r has joined #ruby
sivoais has quit [Ping timeout: 264 seconds]
sivoais has joined #ruby
nomenkun has joined #ruby
mmitchell has quit [Ping timeout: 245 seconds]
mmitchell has joined #ruby
RoryHughes has joined #ruby
mechanicles has quit [Ping timeout: 246 seconds]
juarlex has joined #ruby
Sawbones has quit [Ping timeout: 272 seconds]
nomenkun has quit [Ping timeout: 245 seconds]
mmitchell has quit [Ping timeout: 252 seconds]
jkhwan has joined #ruby
zipper has joined #ruby
juarlex has quit [Ping timeout: 272 seconds]
Virtualize has joined #ruby
frx has joined #ruby
Sawbones has joined #ruby
lurch_ has joined #ruby
<lurch_> is there a way to write: s = *(1..11); stars = s.sample(2) as a single statement?
Seich has joined #ruby
<lurch_> basically pick 2 random numbers from a list from 1 to 11
jkhwan has quit [Ping timeout: 272 seconds]
Virtualize has quit [Ping timeout: 272 seconds]
<WJW> Lurch_, do you require the assignment to s?
<lurch_> WJW: no, i'm trying to loose it
<lurch_> but *(1..11).sample(2) doesn't seem to work
<WJW> (1..11).to_a.sample 2
<lurch_> ah, great. thanks
Seich has quit [Client Quit]
Tool_Fan has joined #ruby
rootshift has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
popl has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
subbyyy has joined #ruby
cbetta_afk is now known as cbetta
Tool_Fan has quit [Quit: Leaving]
croaky has joined #ruby
zipper has quit [Ping timeout: 245 seconds]
pyrac has joined #ruby
charliesome has joined #ruby
timonv has joined #ruby
dawe has joined #ruby
dawe is now known as Guest15104
kate_r has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
Blaze_Boy has joined #ruby
cbetta is now known as cbetta_afk
S0da has quit [Read error: Connection reset by peer]
ephemerian has joined #ruby
croaky has quit [Ping timeout: 252 seconds]
araujo has joined #ruby
pyrac has quit [Quit: pyrac]
falood has quit [Remote host closed the connection]
emocakes has quit [Quit: Linkinus - http://linkinus.com]
zipper has joined #ruby
Mars` has joined #ruby
Barrin6 has quit [Quit: Leaving]
rickruby has quit [Remote host closed the connection]
Yarou has quit [Quit: This computer has gone to sleep]
rickruby has joined #ruby
rickruby has quit [Remote host closed the connection]
pierre1 has quit [Ping timeout: 272 seconds]
rickruby has joined #ruby
Mars` has quit [Ping timeout: 272 seconds]
B064F377 has quit [Ping timeout: 252 seconds]
Mars` has joined #ruby
workmad3 has quit [Ping timeout: 245 seconds]
olivier_bK has joined #ruby
rickruby has quit [Ping timeout: 272 seconds]
B064F377 has joined #ruby
rickruby has joined #ruby
smathieu has joined #ruby
Mars` has quit [Ping timeout: 240 seconds]
subbyyy has quit [Quit: none 0.4.2]
smathieu has quit [Ping timeout: 272 seconds]
nomenkun has joined #ruby
nomenkun has quit [Ping timeout: 246 seconds]
croaky has joined #ruby
LadyRainicorn has joined #ruby
rootshift has quit [Quit: rootshift]
Sawbones has quit [Remote host closed the connection]
jkhwan has joined #ruby
Virtualize has joined #ruby
BraddPitt has quit [Ping timeout: 240 seconds]
BraddPitt has joined #ruby
LadyRainicorn has quit [Ping timeout: 245 seconds]
marr has joined #ruby
jkhwan has quit [Ping timeout: 272 seconds]
xiphias has quit [Ping timeout: 240 seconds]
Virtualize has quit [Ping timeout: 245 seconds]
Sawbones has joined #ruby
xiphias has joined #ruby
LadyRainicorn has joined #ruby
croaky has quit [Ping timeout: 245 seconds]
Emmanuel_Chanel has quit [Ping timeout: 272 seconds]
dogweather has joined #ruby
timonv has quit [Remote host closed the connection]
jamesaxl has quit [Ping timeout: 246 seconds]
LadyRainicorn has quit [Ping timeout: 245 seconds]
cbetta_afk is now known as cbetta
drumusician has joined #ruby
_honning_ has joined #ruby
LadyRainicorn has joined #ruby
ripnix has joined #ruby
Seich has joined #ruby
Astralum has joined #ruby
Astralum has quit [Read error: Connection reset by peer]
LadyRainicorn has quit [Ping timeout: 246 seconds]
Astralum has joined #ruby
rubyracer has quit [Read error: Connection reset by peer]
zipper has quit [Ping timeout: 272 seconds]
Seich has quit [Ping timeout: 246 seconds]
rubyracer has joined #ruby
maroloccio has quit [Quit: WeeChat 0.4.2]
zipper has joined #ruby
cbetta is now known as cbetta_afk
Jetchisel has quit [Remote host closed the connection]
Kneferilis has quit [Killed (herbert.freenode.net (Nickname regained by services))]
m8 has joined #ruby
hashbangchris has joined #ruby
hashbangchris has quit [Client Quit]
hashbangchris has joined #ruby
timonv has joined #ruby
klaut has quit [Remote host closed the connection]
RoryHughes has quit []
marr has quit [Ping timeout: 252 seconds]
hashbangchris has quit [Client Quit]
TomRone has quit [Ping timeout: 240 seconds]
klaut_ has joined #ruby
psyprus has quit [Ping timeout: 240 seconds]
lyanchih has joined #ruby
psyprus has joined #ruby
cow_ has joined #ruby
croaky has joined #ruby
maroloccio has joined #ruby
Jetchisel has joined #ruby
TomRone has joined #ruby
carraroj has joined #ruby
eka has joined #ruby
maroloccio2 has joined #ruby
assurbanipal has joined #ruby
Hanmac1 has joined #ruby
specious has quit [Ping timeout: 245 seconds]
maroloccio has quit [Ping timeout: 240 seconds]
kirun has joined #ruby
Hanmac has quit [Ping timeout: 272 seconds]
kurotor has joined #ruby
Guest15104 has quit [Quit: leaving]
kurotor has quit [Remote host closed the connection]
iliketurtles has quit [Quit: zzzzz…..]
RoryHughes has joined #ruby
amundj has quit [Read error: Connection reset by peer]
falood has joined #ruby
m__s has quit [Ping timeout: 260 seconds]
mzdravkov has joined #ruby
Czupa has joined #ruby
banghouse has joined #ruby
habanany has quit [Ping timeout: 272 seconds]
mercwithamouth has joined #ruby
banghouse is now known as Guest16742
habanany has joined #ruby
petey has joined #ruby
smathieu has joined #ruby
croaky has quit [Ping timeout: 240 seconds]
mmitchell has joined #ruby
gasbakid has joined #ruby
claymore has joined #ruby
yshh has joined #ruby
Guest16742 has quit [Ping timeout: 245 seconds]
smathieu has quit [Ping timeout: 246 seconds]
petey has quit [Ping timeout: 252 seconds]
nomenkun has joined #ruby
mmitchell has quit [Ping timeout: 245 seconds]
RoryHughes has quit [Read error: Connection reset by peer]
RoryHughes has joined #ruby
atzorvas has joined #ruby
reach has quit [Remote host closed the connection]
maroloccio2 has quit [Quit: WeeChat 0.4.2]
_honning_ has quit [Ping timeout: 272 seconds]
juarlex has joined #ruby
skaflem has joined #ruby
nomenkun has quit [Ping timeout: 260 seconds]
freerobby has joined #ruby
Hanmac has joined #ruby
Sawbones has quit [Remote host closed the connection]
ephemerian has quit [Ping timeout: 272 seconds]
Hanmac1 has quit [Ping timeout: 260 seconds]
dogweather has quit [Remote host closed the connection]
atzorvas has quit [Quit: leaving]
juarlex has quit [Ping timeout: 240 seconds]
lkba has quit [Ping timeout: 252 seconds]
Sawbones has joined #ruby
jkhwan has joined #ruby
Virtualize has joined #ruby
Wolland has quit [Remote host closed the connection]
zipper has quit [Ping timeout: 240 seconds]
zipper has joined #ruby
Hanmac1 has joined #ruby
RoryHughes has quit []
tropicalmug has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Virtualize has quit [Ping timeout: 252 seconds]
jkhwan has quit [Ping timeout: 272 seconds]
Hanmac has quit [Ping timeout: 246 seconds]
mojjojo has joined #ruby
psyl0n has joined #ruby
zipper_ has joined #ruby
zipper has quit [Ping timeout: 246 seconds]
ehaliewicz has quit [Ping timeout: 246 seconds]
lurch_ has quit [Quit: lurch_]
cow_ has quit [Remote host closed the connection]
croaky has joined #ruby
cow_ has joined #ruby
zipper_ has quit [Ping timeout: 252 seconds]
OdNairy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
aagdbl has joined #ruby
RoryHughes has joined #ruby
cbetta_afk is now known as cbetta
aagdbl has quit [Client Quit]
codezomb has quit [Ping timeout: 240 seconds]
aagdbl has joined #ruby
ItSANgo has quit [Ping timeout: 240 seconds]
cow_ has quit [Ping timeout: 246 seconds]
aagdbl has quit [Client Quit]
threesome has joined #ruby
popl has quit [Ping timeout: 252 seconds]
ItSANgo has joined #ruby
Sawbones has quit []
zipper has joined #ruby
nari has joined #ruby
Hanmac1 has quit [Ping timeout: 272 seconds]
timonv has quit [Remote host closed the connection]
Hanmac has joined #ruby
cbetta is now known as cbetta_afk
rootshift has joined #ruby
noop has joined #ruby
Astralum has quit [Read error: Connection reset by peer]
Astralum has joined #ruby
OdNairy has joined #ruby
timonv_ has joined #ruby
cow_ has joined #ruby
apeiros_ has quit [Ping timeout: 246 seconds]
croaky has quit [Ping timeout: 272 seconds]
robertjpayne has joined #ruby
Emmanuel_Chanel has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
spider-mario has joined #ruby
spider-mario has quit [Remote host closed the connection]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
cow_ has quit []
habanany has quit [Ping timeout: 245 seconds]
apeiros has joined #ruby
danshultz has joined #ruby
vinian has joined #ruby
spider-mario has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
mojjojo has quit [Quit: mojjojo]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
falood has quit [Remote host closed the connection]
vinian has joined #ruby
sepp2k has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
freggles has quit [Remote host closed the connection]
RoryHughes has quit []
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
RoryHughes has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
allsystemsarego has joined #ruby
vinian has joined #ruby
smathieu has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
ewnd9 has quit [Ping timeout: 260 seconds]
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
dapz has quit [Ping timeout: 252 seconds]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
sepp2k1 has joined #ruby
Steven_ has joined #ruby
sepp2k has quit [Ping timeout: 245 seconds]
mechanicles has joined #ruby
smathieu has quit [Ping timeout: 240 seconds]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
Jetchisel has quit [Quit: "Unfortunately time is always against us" -- *Morpheus*]
croaky has joined #ruby
klaut_ has quit [Remote host closed the connection]
danshultz has quit [Remote host closed the connection]
lyanchih has quit [Ping timeout: 240 seconds]
gasbakid has quit [Read error: Connection reset by peer]
zxd has joined #ruby
danshultz has joined #ruby
<zxd> what does %w mean in default['apache']['listen_ports'] = %w[80]
jkhwan has joined #ruby
Virtualize has joined #ruby
lyanchih has joined #ruby
<WJW> Seems to be a syntax for literals.
mPresent has quit [Remote host closed the connection]
<apeiros> zxd: array of strings
<WJW> >> "running?"
<eval-in> WJW => "running?" (https://eval.in/83951)
<apeiros> >> %w[a b c]
<eval-in> apeiros => ["a", "b", "c"] (https://eval.in/83952)
<WJW> >> $w{this is crap}
<eval-in> WJW => /tmp/execpad-2d1f12e63495/source-2d1f12e63495:2: syntax error, unexpected '{', expecting keyword_end ... (https://eval.in/83953)
soobus has joined #ruby
<WJW> Seems to be a literal syntax, flexible in grouping symbols ( () [] {} ), with elements separated with spaces (words).
nari has quit [Quit: Ex-Chat]
dr_bob has joined #ruby
dima has joined #ruby
<WJW> >> %w(these are words)
<eval-in> WJW => ["these", "are", "words"] (https://eval.in/83954)
danshultz has quit [Ping timeout: 252 seconds]
<WJW> >> %w[so are these]
<eval-in> WJW => ["so", "are", "these"] (https://eval.in/83955)
rickruby has quit [Remote host closed the connection]
<WJW> >> %w(and these here, too)
<eval-in> WJW => ["and", "these", "here,", "too"] (https://eval.in/83956)
jkhwan has quit [Ping timeout: 272 seconds]
rickruby has joined #ruby
Virtualize has quit [Ping timeout: 252 seconds]
<apeiros> >> %w|a b c d|
<eval-in> apeiros => ["a", "b", "c", "d"] (https://eval.in/83957)
<apeiros> with string literals, spaces as delimiters are funny too
<apeiros> >> %q foobar .upcase
<eval-in> apeiros => "FOOBAR" (https://eval.in/83958)
<WJW> %w<how about these?>
<zxd> howdo I access the elements in the array
<WJW> >> %w<how about these?>
<eval-in> WJW => ["how", "about", "these?"] (https://eval.in/83959)
<apeiros> zxd: like any other array
<WJW> >> ["foo", "bar"][0]
<eval-in> WJW => "foo" (https://eval.in/83960)
<apeiros> by index/position
<WJW> >> ["foo", "bar"][1]
<eval-in> WJW => "bar" (https://eval.in/83961)
<apeiros> an array is an array is an array. doesn't matter how it is created.
<WJW> >> ["foo", "bar"].last
<eval-in> WJW => "bar" (https://eval.in/83962)
<WJW> >> ["foo", "bar"].first
<eval-in> WJW => "foo" (https://eval.in/83963)
rickruby has quit [Remote host closed the connection]
vinian has joined #ruby
dima has quit [Ping timeout: 245 seconds]
vinian has quit [Max SendQ exceeded]
rickruby has joined #ruby
<WJW> >> ["foo", "bar"].map{|e| "I said #{e} and I meant #{e}, dammit!"}
<eval-in> WJW => ["I said foo and I meant foo, dammit!", "I said bar and I meant bar, dammit!"] (https://eval.in/83964)
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<WJW> %w|hee haw|.reverse
<WJW> >> %w|hee haw|.reverse
<eval-in> WJW => ["haw", "hee"] (https://eval.in/83965)
croaky has quit [Ping timeout: 245 seconds]
<apeiros> should rename eval-in to funbot
kate_r has joined #ruby
<zxd> eval-in: array of strings? how do I call the name of the array ["a", "b", "c"][0] ?
chrisan has joined #ruby
<zxd> apeiros
<WJW> That would be "a".
vinian has joined #ruby
<apeiros> zxd: objects don't have names, variables have
vinian has quit [Max SendQ exceeded]
<apeiros> zxd: you assign the array to a variable
<apeiros> again, just like any other array. there's no special magic here.
vinian has joined #ruby
<apeiros> >> myvariable = %w[some array does not matter how it is created]; myvariable[3]
<eval-in> apeiros => "not" (https://eval.in/83966)
<WJW> >> crap = %w<This is crap.>; crap[1]
<eval-in> WJW => "is" (https://eval.in/83967)
vinian has quit [Max SendQ exceeded]
<zxd> arrayname = %w[foo bar] , arrayname[0] should print foo ?
samsonasu has joined #ruby
<zxd> ok
<WJW> zxd Yes.
<apeiros> zxd: return, but otherwise yes
<apeiros> print != return
skulker has joined #ruby
<apeiros> (eval-in prints the return value - as does irb)
vinian has joined #ruby
matchaw_ has joined #ruby
vinian has quit [Max SendQ exceeded]
<WJW> >> puts true.inspect
<eval-in> WJW => true ... (https://eval.in/83969)
rickruby has quit [Ping timeout: 245 seconds]
larissa has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
matchaw has quit [Ping timeout: 245 seconds]
kate_r has quit [Quit: My MacBook Air has gone to sleep. ZZZzzz…]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
skulker has quit [Remote host closed the connection]
<apeiros> >> p true
<eval-in> apeiros => true ... (https://eval.in/83970)
anshin has joined #ruby
shime has joined #ruby
avalarion has quit [Ping timeout: 264 seconds]
OdNairy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mojjojo has joined #ruby
ewnd9 has joined #ruby
eriquez has quit [Remote host closed the connection]
avalarion has joined #ruby
<zxd> ruby-lang.org has basic ruby syntax info?
beaudette has joined #ruby
<zxd> coming from perl, I think this iterates through 'log_config' and 'logio' and assigns them to the variable 'log_mod' , then I am lost what does '.include?' mean ?
<zxd> %w[log_config logio].each do |log_mod| default['apache']['default_modules'] << log_mod if %w[rhel fedora suse arch freebsd].include?(node['platform_family']) end
noop has quit [Ping timeout: 260 seconds]
dunc has joined #ruby
pushpak has joined #ruby
greven_ has quit [Quit: Lost terminal]
emocakes has joined #ruby
postmodern has quit [Quit: Leaving]
<WJW> zxd, .include? means 'does it include?'
Hanmac has quit [Ping timeout: 240 seconds]
<WJW> >> [1, 2, 3].include? 3
Hanmac has joined #ruby
<WJW> I guess the interpreter died again.
zipper has quit [Quit: leaving]
<zxd> so it assigns default['apache']['default_modules']=log_config and then to logio ?
Guest28016 has quit [Remote host closed the connection]
<zxd> what does log_mod need | | after do
<WJW> conditionally.
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<WJW> The bars delimit a list of parameters.
cbetta_afk is now known as cbetta
vinian has joined #ruby
<canton7> so that stuff between the do ... end is a "block" - an anonymous function. the stuff between the pipes are the args for that block
vinian has quit [Max SendQ exceeded]
<WJW> The parameters, not the arguments.
rootshift has quit [Quit: rootshift]
<WJW> << means shifted into by.
<canton7> if you're being pedantic, yup
<WJW> or rather with.
<canton7> and #<< is a method. it normally means 'append to'
flubba_ has quit [Remote host closed the connection]
<zxd> # means a variable ?
<zxd> not $ ?
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<WJW> In jargon about Ruby, they write #something to mean something as a selector.
<canton7> # just convention when naming methods. so String#to_a means "the instance method called to_a on String"
stetho has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<WJW> It's not part of Ruby.
<canton7> (whereas String.to_a is a class method on String)
vinian has joined #ruby
<WJW> In Ruby, "#" marks comments.
vinian has quit [Max SendQ exceeded]
Guest49727 has joined #ruby
croaky has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<WJW> I don't know why the snippet of code puts the test inside the loop.
tkuchiki has quit [Remote host closed the connection]
yshh has quit [Remote host closed the connection]
tkuchiki has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
rootshift has joined #ruby
shime has quit [Ping timeout: 246 seconds]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
hakunin has quit [Remote host closed the connection]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
croaky has quit [Ping timeout: 245 seconds]
tkuchiki has quit [Ping timeout: 272 seconds]
psyl0n has quit [Remote host closed the connection]
Hanmac has quit [Ping timeout: 245 seconds]
falood has joined #ruby
croaky has joined #ruby
banghouse has joined #ruby
Hanmac has joined #ruby
olivier_bK has quit [Ping timeout: 246 seconds]
banghouse is now known as Guest98369
Mon_Ouie has quit [Ping timeout: 245 seconds]
smathieu has joined #ruby
vlad_starkov has joined #ruby
filo3sofie has joined #ruby
croaky has quit [Ping timeout: 240 seconds]
* filo3sofie buona sera
Guest98369 has quit [Ping timeout: 260 seconds]
coinsen has joined #ruby
Speed has joined #ruby
cosmicpanda has quit [Ping timeout: 246 seconds]
smathieu has quit [Ping timeout: 246 seconds]
Czupa has quit [Remote host closed the connection]
<WJW> Only know a few words of your language.
abra has joined #ruby
lurch_ has joined #ruby
juarlex has joined #ruby
rootshift has quit [Quit: rootshift]
t_p has quit [Ping timeout: 272 seconds]
<zxd> maybe you can help me out with this, I am learning chef http://docs.opscode.com/essentials_cookbook_templates.html and I don't understand the difference between <%= user %> and <% end -%> they have examples of both
emocakes has quit [Quit: Linkinus - http://linkinus.com]
<WJW> I don't know what chef is, but those expressions look like ERB, embedded Ruby.
<apeiros> zxd: <%= expr %> inserts the results of expr in that place
<apeiros> <% code %> just executes the code
<apeiros> it's presumably an ERB template. check ERBs docs.
juarlex has quit [Ping timeout: 260 seconds]
vlad_starkov has quit [Remote host closed the connection]
jonathanwallace has quit [Quit: WeeChat 0.4.1]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<AntelopeSalad> zxd: the -% part ignores whitespace in the output
<zxd> cool, thanks
<AntelopeSalad> if you removed the -% and just used % then it would print a new line in replace of both the .each loop and the end tag
jonathanwallace has joined #ruby
<AntelopeSalad> (in the compiled template)
<WJW> The minus sign before ">" just suppresses some whitespace from the result.
jkhwan has joined #ruby
Virtualize has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
vlad_starkov has joined #ruby
Hanmac1 has joined #ruby
heftig has quit [Quit: Quitting]
vlad_starkov has quit [Remote host closed the connection]
Hanmac has quit [Ping timeout: 246 seconds]
coffeina has joined #ruby
charliesome has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jkhwan has quit [Ping timeout: 272 seconds]
larissa has quit [Quit: Leaving]
Virtualize has quit [Ping timeout: 245 seconds]
heftig has joined #ruby
m8 has quit [Quit: Sto andando via]
rickruby has joined #ruby
LadyRainicorn has joined #ruby
danshultz has joined #ruby
OdNairy has joined #ruby
AHAHA-HA has joined #ruby
<AHAHA-HA> ruby is crap
<LadyRainicorn> Totes.
<LadyRainicorn> I really hate it.
<AHAHA-HA> its shite
<LadyRainicorn> It's like Brainfuck but with worse design choices.
blarghmatey has joined #ruby
maroloccio has joined #ruby
<AHAHA-HA> fuckers
<LadyRainicorn> We are.
<LadyRainicorn> We fuck all day and night.
<LadyRainicorn> Dirty whores the lot of us.
AHAHA-HA has quit [Quit: Page closed]
atno has joined #ruby
danshultz has quit [Ping timeout: 240 seconds]
rubyracer has quit [Quit: Konversation terminated!]
<mzdravkov> I think that someone had too much of Java and freaked out...
<LadyRainicorn> haha
vlad_starkov has joined #ruby
alexherbo2 has quit [Quit: WeeChat 0.4.2]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
Guest34757 has joined #ruby
diegoviola has quit [Ping timeout: 272 seconds]
drumusician has quit [Ping timeout: 245 seconds]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
tkuchiki has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
mojjojo has quit [Quit: mojjojo]
xiphias has quit [Ping timeout: 240 seconds]
<chrisan> Could someone point me in the right direction with ruby + C library? Is this a problem with how the C library was built or how ruby is loading it? https://gist.github.com/chrisan/39d5d0f4f80e99f172e6
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
xiphias has joined #ruby
nism has joined #ruby
sayan has joined #ruby
arietis has joined #ruby
Guest34757 has quit [Ping timeout: 240 seconds]
robertjpayne has quit [Remote host closed the connection]
diego1 has joined #ruby
diego1 has quit [Changing host]
diego1 has joined #ruby
diego1 is now known as diegoviola
nism has quit [Quit: Leaving]
ephemerian has joined #ruby
mojjojo has joined #ruby
dr_bob has left #ruby [#ruby]
drumusician has joined #ruby
nm_ has joined #ruby
nm_ is now known as nism
timonv_ has quit [Remote host closed the connection]
carraroj has quit [Ping timeout: 260 seconds]
robertjpayne has joined #ruby
rjhunter has quit [Remote host closed the connection]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
AlSquire has joined #ruby
freerobby has quit [Quit: Leaving.]
smathieu has joined #ruby
SHyx0rmZ has joined #ruby
<apeiros> chrisan: as far as I understand it - problem with the C library
olivier_bK has joined #ruby
<chrisan> cool that was my thinking as well, wanted to confirm being first time using it, ty!
SHyx0rmZ has quit [Client Quit]
Steven_ has quit [Remote host closed the connection]
smathieu has quit [Ping timeout: 272 seconds]
SHyx0rmZ has joined #ruby
<shevy> lol LadyRainicorn totally defeated AHAHA-HA
larssmit has joined #ruby
larssmit has quit [Client Quit]
DrShoggoth has quit [Ping timeout: 260 seconds]
larssmit has joined #ruby
carameldeath has joined #ruby
mechanicles has quit [Quit: Computer has gone to sleep.]
mojjojo has quit [Quit: mojjojo]
browndawg1 has joined #ruby
maroloccio has quit [Ping timeout: 252 seconds]
kep has joined #ruby
browndawg has quit [Ping timeout: 245 seconds]
okinomo has quit [Ping timeout: 252 seconds]
<Crazydoode> why is this erroring at the reassignment on line 16? https://gist.github.com/crazydoode/c13196a175829b4348c2
burlyscudd has joined #ruby
freerobby has joined #ruby
DrShoggoth has joined #ruby
<LadyRainicorn> Crazydoode: You can't access instance variables outside a class (like that).
Virtualize has joined #ruby
<LadyRainicorn> Use attr_accessor
<Hanmac1> Crazydoode: where do you think does a "name=" method should came from?
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
DrShoggoth has quit [Max SendQ exceeded]
<Hanmac1> chrisan: 1) i would recomend to use newer ruby
DrShoggoth has joined #ruby
lurch_ has quit [Quit: lurch_]
vinian has joined #ruby
maroloccio has joined #ruby
vinian has quit [Max SendQ exceeded]
drumusician has quit [Ping timeout: 252 seconds]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<Crazydoode> LadyRainicorn: right, thankyou, I see where i was reading the example wrong.
lurch_ has joined #ruby
Virtualize has quit [Ping timeout: 245 seconds]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
okinomo has joined #ruby
banghouse has joined #ruby
johnmilton has joined #ruby
vlad_sta_ has joined #ruby
banghouse is now known as Guest31959
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
vlad_starkov has quit [Ping timeout: 240 seconds]
olivier_bK has quit [Ping timeout: 246 seconds]
Naoe-Kanno has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
dicanio_v has joined #ruby
SHyx0rmZ has quit [Ping timeout: 252 seconds]
vinian has joined #ruby
dicanio_v has left #ruby [#ruby]
TomRone has quit [Ping timeout: 240 seconds]
vinian has quit [Max SendQ exceeded]
ambushsabre has joined #ruby
flame_ has joined #ruby
mojjojo has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
TomRone has joined #ruby
vinian has joined #ruby
carraroj has joined #ruby
vinian has quit [Max SendQ exceeded]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
Wolland has joined #ruby
<zxd> can you cascade multiplie, if statements?
<bnagy> nest? yes.
zz_CripperZ has quit [Quit: ZNC - http://znc.sourceforge.net]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
rickruby has quit [Remote host closed the connection]
<apeiros> zxd: you can also combine expressions with && (and) and || (or)
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
zz_CripperZ has joined #ruby
diegoviola has quit [Quit: WeeChat 0.4.2]
<shevy> zxd you can even do this:
<LadyRainicorn> You mean elsif?
<shevy> if @game_over
<shevy> exit
<shevy> end unless ponicorns.exist?
vinian has joined #ruby
Naoe-Kanno has quit [Ping timeout: 260 seconds]
vinian has quit [Max SendQ exceeded]
<ddd> s/pon/porn/
<LadyRainicorn> I think that would be a nonop.
<shevy> or instead of the unless, and "if ! "
<shevy> *an
<shevy> damn it, my brain does not work with multiple ifs and unless ifs :(
<shevy> ddd now now there, ponicorns don't know about that word you just used
mikemac has quit [Remote host closed the connection]
<shevy> hmm or do they...
<shevy> <LadyRainicorn> Dirty whores the lot of us.
<shevy> !!!
mikemac has joined #ruby
shime has joined #ruby
<LadyRainicorn> It's valid, haha.
<LadyRainicorn> Just saying it's unless true
<LadyRainicorn> ;P
<LadyRainicorn> so a nonop
<WJW> AHAHA-HA, what programming language do you like best?
<LadyRainicorn> We mature quite quickly.
<apeiros> WJW: he left long ago
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<ddd> hehe
noop has joined #ruby
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<shevy> wait
<shevy> unless true
casheew has quit [Read error: Connection reset by peer]
<shevy> my brain needs more time to understand that :(
casheew has joined #ruby
<shevy> if true
<shevy> now that is easier!
<shevy> it's like positive, forward thinking
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<bnagy> you need to cut down or change supplier, shevy
casheew has quit [Read error: Connection reset by peer]
vinian has joined #ruby
vinian has quit [Max SendQ exceeded]
<ddd> shevy: if false ; true ; else ; true ; end
<ddd> just for you
byprdct has joined #ruby
frxx has joined #ruby
frx has quit [Read error: Connection reset by peer]
<shevy> no
<shevy> when I see code like that
<shevy> I remove it
assurbanipal has quit [Quit: Leaving]
<ddd> heh. denying truth?
vlad_sta_ has quit [Remote host closed the connection]
<shevy> life is too short to waste on anything but simplicity
`MArceLL` has joined #ruby
vinian has joined #ruby
<shevy> ddd I went through two years of hell already!!!
<ddd> but but but..
<shevy> I was using PHP :(
vinian has quit [Max SendQ exceeded]
freerobby has quit [Quit: Leaving.]
<ddd> oh you poor poor sod
<ddd> well, you're a sod no longer! you've joined the land of angels! Ruby-land!
pixelgremlins has quit [Read error: Connection reset by peer]
<shevy> yeah
<shevy> now I am looking for a better language
pixelgremlins has joined #ruby
dgfdgf has quit [Ping timeout: 246 seconds]
<bnagy> go
<ddd> Silence! I kill you! There is no better language!
casheew has joined #ruby
<ddd> </ahkmed_the_dead_terrorist>
SHyx0rmZ has joined #ruby
<bnagy> but I still come crawling back any time there's dynamic typing or unserialisation to be done :<
<ddd> someone was mentioning Io as well
<shevy> hmm
<ddd> forget the nick
matled- has joined #ruby
<shevy> what would be cool would be a dual language, with both dynamic typing and optional typing
hakunin has joined #ruby
carameldeath has quit [Quit: Page closed]
<shevy> I am too superficial ddd, I hate the := assignment in Io
<bnagy> and if farts smelled like honey nectar
* LadyRainicorn likes dc.
<LadyRainicorn> Rust
<ddd> damn who was it? mjc?
<shevy> bnagy you would like farts if they would smell like honey nectar? :)
eregon_ has joined #ruby
coffeina has quit [Quit: Wychodzi]
Tranquility_ has quit [Ping timeout: 246 seconds]
dreamchaser has quit [Ping timeout: 246 seconds]
notbrent__ has quit [Ping timeout: 246 seconds]
frode15243 has quit [Ping timeout: 246 seconds]
vinian has joined #ruby
crus` has quit [Remote host closed the connection]
jaybe has quit [Ping timeout: 246 seconds]
ripnix has quit [Read error: Connection reset by peer]
tr4656 has quit [Ping timeout: 246 seconds]
ryotarai has quit [Ping timeout: 246 seconds]
eregon has quit [Read error: Connection reset by peer]
ripnix has joined #ruby
JoeTheGuest has quit [Ping timeout: 246 seconds]
paul_k has quit [Ping timeout: 246 seconds]
zleslie has quit [Ping timeout: 246 seconds]
crus has joined #ruby
<bnagy> even more than I do now
nism has quit [Read error: No route to host]
<ddd> shevy: hehe of all the reasons not not use a language yep := would be it!
<LadyRainicorn> Mine do!
<shevy> ddd I really hate it
matled has quit [Read error: Connection reset by peer]
matled- is now known as matled
patteh has quit [Ping timeout: 246 seconds]
pragmatism has quit [Ping timeout: 246 seconds]
<LadyRainicorn> I like :=
frode15243 has joined #ruby
notbrent__ has joined #ruby
<shevy> does Rust use := for assignment as well?
patteh has joined #ruby
allsystemsarego has quit [Ping timeout: 246 seconds]
B064F377 has quit [Ping timeout: 246 seconds]
<LadyRainicorn> shevy: I think rust has partially static typing
<bnagy> I am still traumatised by Ada, but I can live with :=
Tranquility_ has joined #ruby
<LadyRainicorn> I've never used it
JoeTheGuest has joined #ruby
B064F377 has joined #ruby
allsystemsarego has joined #ruby
allsystemsarego has joined #ruby
<shevy> hmm
sharms has quit [Ping timeout: 240 seconds]
<bnagy> you can completely write around it in Go, if you're pathological
hakunin_ has joined #ruby
ryotarai has joined #ruby
jaybe has joined #ruby
<LadyRainicorn> Oh no I am thinking of Dart
tr4656 has joined #ruby
<ddd> shevy.. not patholigical? say it aint so!
Guest74989 has joined #ruby
<LadyRainicorn> What is wrong with :=?
paul_k has joined #ruby
<LadyRainicorn> You can do it in ruby!
zleslie has joined #ruby
<bnagy> it looks like genitals?
<zxd> is this valid syntax: if %w[ubuntu].include?(node['platform']) && (node['platform_version']) >= '13.10'
pragmatism has joined #ruby
<shevy> yeah but I don't have to use it often in ruby
<ddd> it reminds me of that charactor from Futurama. the pink guy with the dangly stuff for a mouth
<LadyRainicorn> >> genital=:=
zz_CripperZ has quit [Quit: ZNC - http://znc.sourceforge.net]
<shevy> In Io = means update slot
TomRone has quit [Ping timeout: 240 seconds]
zz_CripperZ has joined #ruby
<LadyRainicorn> zxd: Assuming there is an end somewhere
<bnagy> zxd: without testing, yes?
hakunin has quit [Ping timeout: 245 seconds]
<LadyRainicorn> Also you may like symbols
sharms has joined #ruby
<shevy> zxd should be, you just test two conditions here
ripnix_ has joined #ruby
casheew_ has joined #ruby
<shevy> zxd but it depends what note[] returns in both cases
Guest31959 is now known as banghouse
<shevy> node['platform_version'] could perhaps return an integer hmm
casheew has quit [Read error: No buffer space available]
klaas_ has joined #ruby
<shevy> 5 > '5' ArgumentError: comparison of Fixnum with String failed
<bnagy> none of which is relevant to the syntax question
LarsSmit1 has joined #ruby
<bnagy> that's all runtime
<shevy> he'll rewrite it to become better eventually
<shevy> it's like bringing him to a whole different level!
sassamo_ has joined #ruby
BraddBitt has joined #ruby
<shevy> ENLIGHTENMENT, bnagy, that's what #ruby is all about
Zap-W_ has joined #ruby
leandroico_ has joined #ruby
<shevy> or beer
zer0px has joined #ruby
mojjojo_ has joined #ruby
LarsSmit1 has quit [Client Quit]
<bnagy> why not both?
thumpba has joined #ruby
vongrippen_ has joined #ruby
nm_ has joined #ruby
<bnagy> \(o;;;o)/
<Zap-W_> got disco
BrixSat_ has joined #ruby
<shevy> wat
<shevy> \(o;;;o)/
_zxq9_ has joined #ruby
<shevy> hmm
<shevy> what is that
ereslibre has joined #ruby
ereslibre has joined #ruby
sassamo_ has quit [Remote host closed the connection]
<bnagy> ghetto attempt at zoidberg
<shevy> hehehe
dbjeepn- has joined #ruby
sassamo_ has joined #ruby
TomRone has joined #ruby
michael_imac has joined #ruby
okinomo_ has joined #ruby
phreax_ has joined #ruby
<Zap-W_> can you use decimals in >= test conditions?
nuclearblast has joined #ruby
wmoxam_ has joined #ruby
Taranis_ has joined #ruby
nuba has joined #ruby
Garo__ has joined #ruby
kwertie_ has joined #ruby
<bnagy> no, ruby doesn't support numbers
hoelzro_ has joined #ruby
<shevy> Zap-W_ if it is comparable, yeah
<Zap-W_> heh
<bnagy> it's only v 2.1, we're thinking of bringing that in in 2.8
klaas has quit [Disconnected by services]
<shevy> >> 5.5 >= 5.4
klaas_ is now known as klaas
<shevy> where is the stupid bot!
randomnick_ has joined #ruby
kep has quit [Quit: WeeChat 0.4.2]
<bnagy> charliesome broke it
<shevy> :(
<bnagy> he changed like 5 things at once trying to u/g
<shevy> I never liked the bot... but now that it is no longer working, I start to miss it
ripnix_ has quit []
ripnix_ has joined #ruby
byprdct has quit [Ping timeout: 240 seconds]
drago777 has quit [Ping timeout: 240 seconds]
timonv has joined #ruby
mercwithamouth has quit [Ping timeout: 272 seconds]
<bnagy> right, bed
<bnagy> o/
ripnix_ has quit [Client Quit]
waxjar_ has joined #ruby
anicet has joined #ruby
epochwolf|2 has joined #ruby
epochwolf|2 has quit [Excess Flood]
_bart has joined #ruby
TomRone has quit [Ping timeout: 240 seconds]
epochwolf|2 has joined #ruby
epochwolf|2 has quit [Excess Flood]
rubyracer has joined #ruby
mercwithamouth has joined #ruby
Davedo1 has joined #ruby
drago777 has joined #ruby
ivanoats_ has joined #ruby
epochwolf|2 has joined #ruby
mary5030 has joined #ruby
ripnix has quit [*.net *.split]
Tranquility_ has quit [*.net *.split]
Wolland has quit [*.net *.split]
mojjojo has quit [*.net *.split]
vinian has quit [*.net *.split]
okinomo has quit [*.net *.split]
larssmit has quit [*.net *.split]
browndawg1 has quit [*.net *.split]
falood has quit [*.net *.split]
sayan has quit [*.net *.split]
BraddPitt has quit [*.net *.split]
zxd has quit [*.net *.split]
BrixSat has quit [*.net *.split]
snath has quit [*.net *.split]
sassamo has quit [*.net *.split]
zxq9 has quit [*.net *.split]
anderson has quit [*.net *.split]
vongrippen has quit [*.net *.split]
Tarential has quit [*.net *.split]
Liothen has quit [*.net *.split]
thumpba_ has quit [*.net *.split]
zeropx has quit [*.net *.split]
Davedo has quit [*.net *.split]
hoelzro has quit [*.net *.split]
wildharvest_ has quit [*.net *.split]
leandroico has quit [*.net *.split]
lupine has quit [*.net *.split]
wmoxam has quit [*.net *.split]
waxjar has quit [*.net *.split]
Akuma has quit [*.net *.split]
dbjeepn has quit [*.net *.split]
yxhuvud has quit [*.net *.split]
UForgotten has quit [*.net *.split]
phreax has quit [*.net *.split]
kwertie has quit [*.net *.split]
nuba_ has quit [*.net *.split]
newton has quit [*.net *.split]
sebastianb has quit [*.net *.split]
Garo_ has quit [*.net *.split]
Jamo has quit [*.net *.split]
Taranis has quit [*.net *.split]
juni0r has quit [*.net *.split]
ereslibre_laptop has quit [*.net *.split]
ivanoats has quit [*.net *.split]
garndt has quit [*.net *.split]
epochwolf has quit [*.net *.split]
zeusmns has quit [*.net *.split]
michael_mbp has quit [*.net *.split]
mojjojo_ is now known as mojjojo
zer0px is now known as zeropx
ivanoats_ is now known as ivanoats
epochwolf|2 is now known as epochwolf
UForgotten_ has joined #ruby
_honning_ has joined #ruby
petey has joined #ruby
Davedo1 is now known as Davedo
michael_imac is now known as michael_mbp
TomRone has joined #ruby
anicet is now known as juni0r
<LadyRainicorn> ♥ bot
peneconleche has joined #ruby
leandroico_ is now known as leandroico
<LadyRainicorn> luvbot
UForgotten_ is now known as UForgotten
Jamo has joined #ruby
mmitchell has joined #ruby
Xiti` has joined #ruby
Niamkik has quit [Quit: Disconnecting from stoned server.]
Niamkik has joined #ruby
zz_CripperZ has quit [Quit: ZNC - http://znc.sourceforge.net]
Xiti` has quit [Read error: Connection reset by peer]
elux has joined #ruby
zz_CripperZ has joined #ruby
Xiti has quit [Ping timeout: 272 seconds]
sharms has quit [Ping timeout: 240 seconds]
ambushsabre has quit [Ping timeout: 240 seconds]
petey has quit [Ping timeout: 272 seconds]
ambushsabre has joined #ruby
rjhunter has joined #ruby
Wolland has joined #ruby
aryaching has joined #ruby
nouitfvf has joined #ruby
sharms has joined #ruby
yxhuvud has joined #ruby
flame_ has quit [Quit: Computer has gone to sleep.]
mercwithamouth has quit [Ping timeout: 246 seconds]
Tarential has joined #ruby
anderson has joined #ruby
Akuma has joined #ruby
olivier_bK has joined #ruby
mmitchell has quit [Remote host closed the connection]
newton has joined #ruby
Tranquility_ has joined #ruby
peneconleche has quit [Quit: Leaving...]
zeusmns has joined #ruby
vinian has joined #ruby
browndawg has joined #ruby
vinian has quit [Max SendQ exceeded]
pskosinski has joined #ruby
wildharvest__ has joined #ruby
juarlex has joined #ruby
r0bby_ has joined #ruby
garndt has joined #ruby
rjhunter has quit [Ping timeout: 245 seconds]
Zap-W_ has left #ruby [#ruby]
nfk has joined #ruby
kyle__ has joined #ruby
alvinsj has joined #ruby
zxd has joined #ruby
lupine has joined #ruby
robertjpayne has quit [Remote host closed the connection]
lupine has quit [Changing host]
lupine has joined #ruby
lyanchih has quit [Ping timeout: 252 seconds]
<zxd> define :apache_conf do template "#{node['apache']['dir']}/mods-available/#{params[:name]}.conf" do , what does ':' before apache_conf and in params mean? also what does the # in #{node['apache] mean ?
<zxd> what happens if i ommit the :
<kyle__> I'm trying to find the rubygem that tells you the filetype by magic number, but all my google searches are showing me stuff on the imagemagic/grapicsmagic and fileutils libraries.
nm_ has quit [Quit: leaving]
nfk has quit [Client Quit]
Neomex has joined #ruby
Speed has quit [Quit: When two people dream the same dream, it ceases to be an illusion.]
zz_CripperZ has quit [Quit: ZNC - http://znc.sourceforge.net]
lewix has joined #ruby
juarlex has quit [Ping timeout: 272 seconds]
robbyoconnor has quit [Max SendQ exceeded]
TomRone has quit [Ping timeout: 240 seconds]
xiphias has quit [Ping timeout: 240 seconds]
sakshi has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
xiphias has joined #ruby
drago777 has joined #ruby
TomRone has joined #ruby
xiphias has quit [Changing host]
xiphias has joined #ruby
mercwith1mouth has joined #ruby
zz_CripperZ has joined #ruby
Neomex has quit [Client Quit]
<apeiros> zxd: :foo is a symbol literal, just like "foo" is a string literal or 12 is an integer literal
jkhwan has joined #ruby
sakshi has left #ruby [#ruby]
alexherbo2 has joined #ruby
<apeiros> plain `foo` is either a local variable or a method (i.e., not an object, not a literal - but it will evaluate to an object)
Virtualize has joined #ruby
lxsameer has joined #ruby
TomRone has quit [Ping timeout: 240 seconds]
drago777 has quit [Ping timeout: 240 seconds]
<lxsameer> i try to push a gem, but i get this http://dpaste.com/1528484/ , what can i do ?
axl_ has joined #ruby
<Jamo> gem -v
<lxsameer> Jamo: 2.0.3
mercwith1mouth has quit [Ping timeout: 240 seconds]
klaut has joined #ruby
ambushsabre has quit [Quit: rip]
jkhwan has quit [Ping timeout: 272 seconds]
Virtualize has quit [Ping timeout: 246 seconds]
mercwithamouth has joined #ruby
noop has quit [Ping timeout: 252 seconds]
Mon_Ouie has joined #ruby
<zxd> apeiros: so :foo dosen't expand?
ambushsabre has joined #ruby
<shevy> what do you want to expand it into?
drago777 has joined #ruby
<shevy> zxd params is a hash. [] is a way to query the value of a key here, in your example the value that the key at :name has
wallerdev has joined #ruby
TomRone has joined #ruby
petey has joined #ruby
<DouweM> zxd: :foo is syntax for a Symbol object with value foo, like "bar" is syntax for a String object with value bar.
eka has quit [Quit: Computer has gone to sleep.]
hakunin_ has quit [Read error: Connection reset by peer]
hakunin has joined #ruby
<apeiros> zxd: no. it's a literal. no expansion.
<apeiros> zxd: as said, just like a string literal
havenwood has joined #ruby
<apeiros> zxd: with `x = "foo"`, what happens if I remove the " marks? <-- same question as yours, just for strings
estebistec has joined #ruby
kyle__ has left #ruby [#ruby]
jego has quit [Ping timeout: 252 seconds]
Hanmac has joined #ruby
lewix has quit [Remote host closed the connection]
Hanmac1 has quit [Ping timeout: 272 seconds]
relix has joined #ruby
relix has quit [Max SendQ exceeded]
relix has joined #ruby
freerobby has joined #ruby
juarlex has joined #ruby
hakunin_ has joined #ruby
_bart has quit []
hakunin has quit [Ping timeout: 272 seconds]
mjburgess has joined #ruby
TomRone has quit [Ping timeout: 240 seconds]
juarlex has quit [Ping timeout: 272 seconds]
mercwithamouth has quit [Ping timeout: 260 seconds]
TomRone has joined #ruby
rickruby has joined #ruby
lewix has joined #ruby
carraroj has quit [Ping timeout: 245 seconds]
mgberlin has joined #ruby
tkuchiki has quit [Remote host closed the connection]
tkuchiki has joined #ruby
sharms has quit [Ping timeout: 240 seconds]
sharms has joined #ruby
freebs has joined #ruby
okinomo_ has quit [Ping timeout: 245 seconds]
axl_ has quit [Quit: axl_]
tkuchiki has quit [Ping timeout: 272 seconds]
dkamioka has joined #ruby
Wolland has quit [Remote host closed the connection]
browndawg has quit [Read error: Connection timed out]
klaut has quit [Remote host closed the connection]
lewix has quit [Remote host closed the connection]
browndawg has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
<shevy> test
bogeyd6 has joined #ruby
RoryHughes has quit []
vongrippen_ is now known as vongrippen
Czupa has joined #ruby
freezey has joined #ruby
freezey has quit [Remote host closed the connection]
freezey has joined #ruby
drago777 has joined #ruby
yshh has joined #ruby
MindfulMonk has joined #ruby
timonv has quit [Remote host closed the connection]
estebistec has quit [Remote host closed the connection]
estebistec has joined #ruby
crazysim_ has quit [Excess Flood]
crazysim has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
Jake232 has joined #ruby
mary5030 has quit [Read error: Connection reset by peer]
mary5030 has joined #ruby
pskosinski has quit [Remote host closed the connection]
pskosinski has joined #ruby
maroloccio has quit [Quit: WeeChat 0.4.2]
drago777 has joined #ruby
Virtualize has joined #ruby
pskosinski has quit [Remote host closed the connection]
Megtastique has joined #ruby
phansch has joined #ruby
pskosinski has joined #ruby
pskosinski has quit [Remote host closed the connection]
pskosinski has joined #ruby
Virtualize has quit [Ping timeout: 240 seconds]
Astralum has quit [Ping timeout: 272 seconds]
mgberlin has quit [Quit: mgberlin]
IceDragon has joined #ruby
freezey has quit [Remote host closed the connection]
casheew_ has quit [Ping timeout: 272 seconds]
vlad_starkov has joined #ruby
wallerdev has quit [Quit: wallerdev]
klaut has joined #ruby
ambushsabre has quit [Quit: rip]
griffitb has joined #ruby
mgberlin has joined #ruby
blackmesa has joined #ruby
freezey has joined #ruby
hakunin_ has quit [Read error: Connection reset by peer]
drago777 has quit [Ping timeout: 240 seconds]
hakunin has joined #ruby
drago777 has joined #ruby
ae-r has joined #ruby
griffitb has quit [Remote host closed the connection]
mgberlin has quit [Client Quit]
ambushsabre has joined #ruby
cosmicpanda has joined #ruby
crazysim is now known as crazysim_
lkba has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
Astralum has joined #ruby
<shevy> hmmm
<shevy> (10 ** -3) - (10 **3)
<shevy> this should give 0 in math right?
<shevy> irb gives me -9999991000. is there a way to force math-like output?
ewnd9 has quit [Ping timeout: 245 seconds]
mgberlin has joined #ruby
<DouweM> why would it give 0?
drago777 has joined #ruby
<shevy> isn't 10 ** -3 0,001 ?
<shevy> oops
yacks has quit [Read error: Connection reset by peer]
CaptainJet has joined #ruby
<shevy> (10 ** 3) * (10 ** -3)
shtirlic_ has joined #ruby
bgy_ has joined #ruby
petey is now known as PeterP
rubyracer has quit [Read error: Connection reset by peer]
bgy has quit [*.net *.split]
monomyth has quit [*.net *.split]
Scient has quit [*.net *.split]
iaj_ has quit [*.net *.split]
maddog__ has quit [*.net *.split]
bbloom has quit [*.net *.split]
haken29a has quit [*.net *.split]
jibi has quit [*.net *.split]
amedeiros has quit [*.net *.split]
krainboltgreene has quit [*.net *.split]
pipecloud has quit [*.net *.split]
nemesit|- has quit [*.net *.split]
qpls has quit [*.net *.split]
eliasp has quit [*.net *.split]
DrForr has quit [*.net *.split]
xsdg has quit [*.net *.split]
ptierno has quit [*.net *.split]
shtirlic has quit [*.net *.split]
spacemud has quit [*.net *.split]
kaichanvong has quit [*.net *.split]
Raboo has quit [*.net *.split]
PeterP is now known as totalmajor
<shevy> 1000 * 0.001 # => 1.0
rubyracer has joined #ruby
<DouweM> >> (10 ** 3) * (10 ** -3)
<DouweM> Oh right, I broke eval-in
<shevy> (10 ** 3) * (10 ** -3) # => 11
<shevy> (10 ** 3) * 0.001 # => 1.0
maddog_ has joined #ruby
<shevy> ok ... so (10 ** -3) is not 0.001 I guess
qpls has joined #ruby
Scient has joined #ruby
iaj has joined #ruby
spacemud has joined #ruby
<shevy> but (10 ** 3) == 1000 # => true
xsdg has joined #ruby
nemesit|znc has joined #ruby
Raboo has joined #ruby
amedeiros has joined #ruby
ptierno has joined #ruby
pipecloud has joined #ruby
haken29a has joined #ruby
jellow has quit [Ping timeout: 260 seconds]
DrForr has joined #ruby
krainboltgreene has joined #ruby
habanany has joined #ruby
eliasp has joined #ruby
monomyth has joined #ruby
<DouweM> ** for a negative rhs gives a Rational
<shevy> hmm
kaichanvong has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
<shevy> you are right
vlad_starkov has quit [Remote host closed the connection]
TomRone has quit [Ping timeout: 240 seconds]
vlad_starkov has joined #ruby
<shevy> (10 ** -3).to_f # => 0.001
gja has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
<DouweM> You can also just .to_i the end result of (10**3)*(10 ** -3)
<shevy> yeah just tested
<shevy> with float tho
<shevy> (10 ** 3) * (10 ** -3).to_f # => 1.0
<shevy> thanks DouweM
<DouweM> that just #to_fs the rhs of the multiplication, not the entire thing
<DouweM> don't round intermediate values
<shevy> it gives the correct result now
jibi has joined #ruby
drago777 has joined #ruby
<DouweM> for this case, sure, but it's arguably better to call #to_f/#to_i on the end result, not the intermediate values
Azure has quit [Ping timeout: 252 seconds]
<shevy> well 10 ** -3 is 0.001 so it would always be a float
hakunin has quit [Ping timeout: 246 seconds]
jellow_ has joined #ruby
<shevy> now I need to find out why it returns a Rational
<DouweM> Because (3 ** -1) can't be accurately expressed as a float
Azure has joined #ruby
psyl0n has joined #ruby
Azure has quit [Read error: Connection reset by peer]
mjburgess has quit [Ping timeout: 245 seconds]
<shevy> you mean for a computer?
TomRone has joined #ruby
gja has quit [Quit: This computer has gone to sleep]
Astralum has quit [Ping timeout: 240 seconds]
<DouweM> for anyone. (3 ** -1) is (1/3), which isn't the same thing as 0.33333333333... Which is where the Rational class comes in
Astralum has joined #ruby
<shevy> well that is 3 ** -1
<DouweM> Or rather, it is the same thing as 0.33..., but not w/o the dots, which the computer obviously can't represent
ambushsabre has quit [Quit: rip]
<shevy> but 10 ** -3 should be 0,001 which is accurate
Wolland has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
mercwithamouth has joined #ruby
<DouweM> Meh, it's much easier to just have ** return a Rational for any negative rhs
noop has joined #ruby
ae-r has quit [Remote host closed the connection]
<ceej> I'm trying to learn/improve the way I write ruby, would anyone have any suggestions to making this method look better https://gist.github.com/5468851c5d7f1e61c2c8
hakunin has joined #ruby
Megtastique has quit []
zxd has quit [Ping timeout: 252 seconds]
drago777 has joined #ruby
hakunin_ has joined #ruby
brennanMKE has joined #ruby
hakunin__ has joined #ruby
hakunin has quit [Read error: Connection reset by peer]
elux has quit [Quit: Leaving...]
gja has joined #ruby
DrShoggoth has quit [Ping timeout: 252 seconds]
hakunin has joined #ruby
St_Marx has quit [Quit: Ex-Chat]
hakunin_ has quit [Read error: Connection reset by peer]
<DouweM> ceej: I'll fork the gist, gimme a sec :)
havenwood has quit [Remote host closed the connection]
klaut has quit [Remote host closed the connection]
rickruby has quit [Remote host closed the connection]
casheew has joined #ruby
ForceMultiplier has quit [Ping timeout: 252 seconds]
havenwood has joined #ruby
kep has joined #ruby
ForceMultiplier has joined #ruby
hakunin_ has joined #ruby
DrShoggoth has joined #ruby
simplyaubs has joined #ruby
snath has joined #ruby
gja has quit [Client Quit]
hakunin has quit [Read error: Connection reset by peer]
hakunin__ has quit [Ping timeout: 252 seconds]
hakunin has joined #ruby
<ceej> DouweM: thank you :)
Astralum has quit [Ping timeout: 246 seconds]
havenwood has quit [Ping timeout: 245 seconds]
ForceMultiplier has quit [Ping timeout: 252 seconds]
Hanmac1 has joined #ruby
<LadyRainicorn> ceej: Parentheses help readability a lot.
hakunin__ has joined #ruby
<DouweM> Untested, and I've made some assumptions like model.persisted?
ForceMultiplier has joined #ruby
hakunin_ has quit [Ping timeout: 252 seconds]
<LadyRainicorn> Do you really eant to use an environment variable for that?
<DouweM> ceej: Why the `associated_model.respond_to?(:id)`?
Hanmac has quit [Ping timeout: 252 seconds]
<LadyRainicorn> Use \z instead of $
<DouweM> ah, good call
DrShoggoth has quit [Ping timeout: 240 seconds]
<ceej> DouweM: that does look more readable.... it's just checking to see if it's a model object, I guess I could use is_a? Object there too
<DouweM> you can also use name[0..-4] instead of the gsub and regex
<ceej> LadyRainicorn: what's the reason for using \z instead of $?
hakunin has quit [Ping timeout: 240 seconds]
<Mon_Ouie> >> "foo_id\nbar" =~ /_id$/
zumba_addict has quit [Quit: zumba_addict]
hakunin__ has quit [Read error: Connection reset by peer]
<ceej> DouweM: [0..-4] didn't think of that either, ye that would be cleaner
hakunin has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
wallerdev has joined #ruby
<DouweM> ceej: is_a? is bad practice usually, but I think it's fine here. Better than the confusing respond_to?(:id)
<Mon_Ouie> The bot is down, but this would be truthy
shime has quit [Ping timeout: 245 seconds]
<DouweM> Mon_Ouie: I think I killed it yesterday :/
<Mon_Ouie> (i.e. $ is end of line, not end of string)
<ceej> Mon_Ouie: ah, that's good to know!
<ceej> DouweM: why is 'is_a?' bad practice?
p8952 has quit [Ping timeout: 260 seconds]
<DouweM> because duck typing
hakunin__ has joined #ruby
<LadyRainicorn> You can optimize out checking new_current_params for nil
LexicalScope has joined #ruby
<LadyRainicorn> nil.is_a?(Hash) is false anyway
hakunin__ has quit [Remote host closed the connection]
atno_ has joined #ruby
<LadyRainicorn> Also id will be defined on all objects in older Rubies.
<LadyRainicorn> pre-2.0 I think?
totalmajor has quit [Remote host closed the connection]
<Mon_Ouie> 1.8 and less
<LadyRainicorn> Maybe 1.9.3
<Mon_Ouie> 1.8 being dead it doesn't matter anymore
<DouweM> good point on#id
totalmajor has joined #ruby
<LadyRainicorn> ah ok
S0da has joined #ruby
Speed has joined #ruby
sassamo_ has quit []
atno has quit [Ping timeout: 245 seconds]
<LadyRainicorn> rstrip can replace gsub btw
atno__ has joined #ruby
<DouweM> But yeah, ask for what you actually want to know. In this case it isn't whether the obj responds to :id, because you're not even using :id. It's whether we're dealing with a model.
<DouweM> LadyRainicorn: or just name[0..-4]
drago777 has joined #ruby
yshh has quit [Remote host closed the connection]
rm_ has joined #ruby
Yarou has joined #ruby
hakunin has quit [Ping timeout: 272 seconds]
<LadyRainicorn> associated_model also doesn't need to be checked for truthiness
<LadyRainicorn> yeah
mrfoto has joined #ruby
atno_ has quit [Ping timeout: 260 seconds]
mrfoto has quit [Client Quit]
mrfoto has joined #ruby
totalmajor has quit [Ping timeout: 245 seconds]
Azure has joined #ruby
mrfoto has quit [Client Quit]
<LadyRainicorn> Wait, is name a user supplied parameter?
<DouweM> its a parameter to the #each block
jkhwan has joined #ruby
<LadyRainicorn> You want to use [] and not try
<LadyRainicorn> oh nvm
<ceej> thanks guys :)
Virtualize has joined #ruby
bbloom has joined #ruby
noop has quit [Ping timeout: 252 seconds]
heidi has joined #ruby
geggam has joined #ruby
aagdbl has joined #ruby
jkhwan has quit [Ping timeout: 272 seconds]
flubba has joined #ruby
Virtualize has quit [Ping timeout: 252 seconds]
ae-r has joined #ruby
theoretick has joined #ruby
DrShoggoth has joined #ruby
p8952 has joined #ruby
<ceej> so I cleaned it up more after all you suggestions https://gist.github.com/cj/5468851c5d7f1e61c2c8
ambushsabre has joined #ruby
Hobogrammer has joined #ruby
ae-r has quit [Remote host closed the connection]
arietis has quit [Quit: Computer has gone to sleep.]
Hobogrammer_ has quit [Ping timeout: 252 seconds]
havenwood has joined #ruby
Astralum has joined #ruby
joelio has quit [Ping timeout: 252 seconds]
DrShoggoth has quit [Ping timeout: 245 seconds]
joelio has joined #ruby
lurch_ has quit [Quit: lurch_]
TomRone has quit [Ping timeout: 240 seconds]
cosmicpanda has quit [Ping timeout: 240 seconds]
bashdy has joined #ruby
cosmicpanda has joined #ruby
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Hanmac has joined #ruby
bashdy has quit [Client Quit]
maletor has joined #ruby
TomRone has joined #ruby
ambushsabre has quit [Quit: rip]
freezey has quit [Remote host closed the connection]
DrShoggoth has joined #ruby
Hanmac1 has quit [Ping timeout: 246 seconds]
Astralum has quit [Ping timeout: 245 seconds]
freezey has joined #ruby
deever has quit [Ping timeout: 252 seconds]
Seich has joined #ruby
x0nic has quit [Ping timeout: 248 seconds]
Hanmac has quit [Ping timeout: 245 seconds]
Seich has quit [Client Quit]
fenicks has joined #ruby
juarlex has joined #ruby
juarlex has quit [Remote host closed the connection]
juarlex has joined #ruby
x0nic has joined #ruby
Hanmac has joined #ruby
frx has joined #ruby
stryek has joined #ruby
frxx has quit [Remote host closed the connection]
wereHams1er has joined #ruby
DrShoggoth has quit [Ping timeout: 260 seconds]
wereHamster has quit [Ping timeout: 245 seconds]
cosmicpanda has quit [Ping timeout: 252 seconds]
arietis has joined #ruby
yano has quit [Read error: Connection reset by peer]
deever has joined #ruby
Blaze_Boy has quit [Quit: Leaving]
browndawg has quit [Quit: Leaving.]
udon has joined #ruby
mengu has joined #ruby
tsupertramp has joined #ruby
zipper has joined #ruby
<LadyRainicorn> You can use elsif instead of next/end if you like. It may be clearer
peregrine81 has joined #ruby
rippa has joined #ruby
lewix has joined #ruby
deever has quit [Ping timeout: 240 seconds]
deever has joined #ruby
alexherbo2 has quit [Quit: WeeChat 0.4.2]
habanany has quit [Ping timeout: 245 seconds]
Seich has joined #ruby
matchaw has joined #ruby
<ceej> Is it possible to get the argument count for a new instance of something? So to avoid ArgumentError: wrong number of arguments (0 for 1) doing if SomeClass.new.args_count == 1
atno_ has joined #ruby
matchaw_ has quit [Ping timeout: 263 seconds]
<tsupertramp> Nice evening everyone. Trying to write a Vagrantfile: http://pastebin.com/hHqrtECy - No Ruby Skills :( - Maybe you could help me to print out a multidimensional Array Value with a help of a Variable (incremented by a foor-Loop). Thanks in Advance.
drago777 has quit [Ping timeout: 240 seconds]
heidi has quit [Quit: Leaving.]
<ceej> tsupertramp: have you tried something like https://github.com/michaeldv/awesome_print
freezey has quit [Remote host closed the connection]
Seich has quit [Client Quit]
Hanmac1 has joined #ruby
Hanmac has quit [Ping timeout: 272 seconds]
atno__ has quit [Ping timeout: 246 seconds]
pen has joined #ruby
<tsupertramp> Thanks ceej. It would be great, if we could achieve the Task without the help of a module. Otherwise it will be difficult to use this File in my company.
drago777 has joined #ruby
threesome has quit [Ping timeout: 260 seconds]
<LadyRainicorn> ceej: SomeClass.method(:new).arity
<LadyRainicorn> I am not 100% sure how that respons to * and **
Guest74989 is now known as dreamchaser
dreamchaser has quit [Changing host]
dreamchaser has joined #ruby
<ceej> LadyRainicorn: I just found that out, I tried YardCompanyForm.new.method(:initialize).arity but still throws the ArgumentError: wrong number of arguments (0 for 1) error
dkamioka has quit [Remote host closed the connection]
dkamioka has joined #ruby
<LadyRainicorn> No, you check new.
<LadyRainicorn> Use YardCompanyForm.method(:new).arity
kostine has joined #ruby
pushpak has quit [Ping timeout: 260 seconds]
timonv has joined #ruby
<ceej> hmmm always comes back as -1
brunops has joined #ruby
Rainicorn has joined #ruby
mityaz has joined #ruby
kostine has quit [Client Quit]
atmosx has joined #ruby
dkamioka has quit [Read error: No route to host]
<Hanmac1> ceej & LadyRainicorn: YardCompanyForm.instance_method(:initialize).arity
dkamioka has joined #ruby
<Hanmac1> but more interesting would be YardCompanyForm.instance_method(:initialize).parameters
chrisan has quit [Ping timeout: 252 seconds]
pen has quit []
coinsen has quit [Quit: Lost terminal]
LadyRainicorn has quit [Ping timeout: 245 seconds]
matchaw_ has joined #ruby
freezey has joined #ruby
<ceej> Hanmac1: ah, that last one is a lot more usable. thank you
LadyRainicorn has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
habanany has joined #ruby
timonv has quit [Ping timeout: 265 seconds]
<Hanmac1> ceej PS: beware! #parameters does not work on native methods (C-implemented)
matchaw has quit [Ping timeout: 272 seconds]
blarghmatey has quit [Remote host closed the connection]
maletor has quit [Quit: Computer has gone to sleep.]
Rainicorn has quit [Ping timeout: 272 seconds]
<ceej> Hanmac1: I'll make a note of that, it will work perfectly for what I need right now. thank you again
senayar has joined #ruby
timonv has joined #ruby
szerated_ has joined #ruby
Seich has joined #ruby
elux has joined #ruby
blarghmatey_ has joined #ruby
heidi has joined #ruby
LexicalScope has quit [Ping timeout: 252 seconds]
abramovic has joined #ruby
havenwood has quit [Remote host closed the connection]
abramovic has quit [Quit: Leaving.]
rippa has quit [Ping timeout: 248 seconds]
Baluse has quit []
nisstyre has joined #ruby
reach has joined #ruby
maletor has joined #ruby
ahawkins has joined #ruby
maletor has quit [Client Quit]
Hanmac has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
Mapley has quit [Read error: Connection reset by peer]
shevy has left #ruby ["I'll be back ... maybe"]
shevy has joined #ruby
<shevy> Hanmac soon year 2013 is over and no rwx gem :(
pushpak has joined #ruby
<Hanmac> yeah ... and i didnt worked on rwx the recent days (i am currently reading fanfiction)
Hanmac1 has quit [Ping timeout: 245 seconds]
drago777 has joined #ruby
samsonasu has quit [Quit: samsonasu]
drago777 has quit [Excess Flood]
drago777 has joined #ruby
g3orge has joined #ruby
Virtualize has joined #ruby
decoponio has quit [Quit: Leaving...]
aryaching has quit [Ping timeout: 260 seconds]
Kricir has joined #ruby
<shevy> hmm
heidi has quit [Quit: Leaving.]
<shevy> we must destroy fanfiction
elux has quit [Quit: Bye!]
TomRone has quit [Ping timeout: 240 seconds]
Virtualize has quit [Ping timeout: 245 seconds]
Hanmac1 has joined #ruby
senayar has quit [Remote host closed the connection]
senayar has joined #ruby
Hanmac has quit [Ping timeout: 252 seconds]
TomRone has joined #ruby
tylersmith has joined #ruby
lxsameer has quit [Ping timeout: 245 seconds]
virtual|a has joined #ruby
brunops has quit [Ping timeout: 240 seconds]
brunops has joined #ruby
Seich has quit [Quit: Computer has gone to sleep.]
drago777 has quit [Ping timeout: 240 seconds]
lxsameer has joined #ruby
freebs has quit [Quit: Leaving.]
senayar has quit [Remote host closed the connection]
asteve has joined #ruby
byprdct has joined #ruby
virt|away has quit [Ping timeout: 260 seconds]
umurgdk has joined #ruby
LadyRainicorn has quit [Ping timeout: 246 seconds]
drago777 has joined #ruby
LadyRainicorn has joined #ruby
maletor has joined #ruby
byprdct has quit [Client Quit]
<umurgdk> hey guys my gf trying to learn ruby, and her book says "you can get documentation for a method with ri String.to_i on irb", but when she tries irb Says String class has no method to_i. btw she uses OS X
soobus has quit [Ping timeout: 246 seconds]
Sourceless_ is now known as Sourceless
Hanmac has joined #ruby
<shevy> no
<shevy> well
<shevy> I think you can enable that in irb
<shevy> but by default, ri works only on the commandline
<shevy> String class definitely has #to_i
brunops has quit [Changing host]
brunops has joined #ruby
<shevy> perhaps the documentation on OS X is not complete
nanoyak has joined #ruby
<apeiros> umurgdk: might well be that the docs are not built on stock OS X
carif has joined #ruby
<shevy> cool, there is even a gem for ri
<shevy> String.ri
<shevy> hehe
IceDragon has quit [Ping timeout: 246 seconds]
Hanmac1 has quit [Ping timeout: 240 seconds]
<apeiros> umurgdk: I'd install rvm, and then install the newest ruby. using rvm, you can generate the core/stdlib docs using `rvm docs generate`
Asher has quit [Quit: Leaving.]
<shevy> wow
<apeiros> umurgdk: btw., your gf is welcome on irc/in this channel too
<shevy> I just tried: "--help" in irb and it worked
nanoyak has quit [Client Quit]
<umurgdk> shevy: ah ok haha :D no no she must run the command on terminal not irb
carif has quit [Remote host closed the connection]
<LadyRainicorn> haha
<shevy> yeah, or `ri` from inside irb too, you can run system commands from irb when you use backticks, or system() method call
<apeiros> umurgdk: also while not strictly following the book - I suggest installing pry (`gem install pry pry-doc`) and use pry instead of irb. within pry, you can do `? String#to_i` to get the docs
<umurgdk> apeiros: ahaha let's see, i don't know i can see her on freenode haha
stetho has joined #ruby
<LadyRainicorn> I'd recommend pry.
Hanmac1 has joined #ruby
rm_ has quit [Remote host closed the connection]
<umurgdk> apeiros: thanks for suggesting the book also suggest pry. but for a now i don't want to manipulate her too much let she find something :)
rm_ has joined #ruby
stetho has quit [Read error: Connection reset by peer]
JustinAiken has joined #ruby
Hanmac has quit [Ping timeout: 240 seconds]
heidi has joined #ruby
heidi has quit [Client Quit]
croaky has joined #ruby
freezey has quit [Remote host closed the connection]
flubba has quit [Quit: Leaving...]
Seich has joined #ruby
relix has joined #ruby
colonolGron has joined #ruby
flubba has joined #ruby
intuxicated has joined #ruby
drago777 has quit [Ping timeout: 240 seconds]
Hanmac1 has quit [Ping timeout: 265 seconds]
Hanmac has joined #ruby
drago777 has joined #ruby
ahawkins has quit [Ping timeout: 252 seconds]
cbetta is now known as cbetta_afk
atno has joined #ruby
ahawkins has joined #ruby
atno_ has quit [Ping timeout: 272 seconds]
dunc has quit []
atno_ has joined #ruby
MindfulMonk has quit [Remote host closed the connection]
Seich has quit [Quit: Computer has gone to sleep.]
Guest49727 has quit [Remote host closed the connection]
lewix has quit [Remote host closed the connection]
atno has quit [Ping timeout: 245 seconds]
danshultz has joined #ruby
udon has quit [Quit: Leaving]
szerated_ has quit [Ping timeout: 240 seconds]
mvangala_ has joined #ruby
JustinAiken is now known as JustinAiken_afk
senayar has joined #ruby
freebs has joined #ruby
cj3kim has joined #ruby
<shevy> until she outsmarts you
<shevy> then she makes you learn php
<shevy> then she wins
Tearan has joined #ruby
mvangala has quit [Ping timeout: 245 seconds]
simplyaubs has quit [Quit: simplyaubs]
RubyRonin has joined #ruby
markfletcher has joined #ruby
senayar has quit [Ping timeout: 246 seconds]
freebs has quit [Ping timeout: 252 seconds]
ozkan has joined #ruby
pen has joined #ruby
ambushsabre has joined #ruby
Tearan has quit [Ping timeout: 272 seconds]
jimmy__ has joined #ruby
Kricir has quit [Remote host closed the connection]
jimmy__ has quit [Client Quit]
drago777 has quit [Ping timeout: 240 seconds]
Kricir has joined #ruby
jwp121 has joined #ruby
freezey has joined #ruby
<jwp121> hi
<waxjar_> hi
<jwp121> Any tips for learning ruby for someone with a python and C backgorund?
Asher has joined #ruby
mercwithamouth has quit [Ping timeout: 245 seconds]
drago777 has joined #ruby
<RubyRonin> what does the -d to detach mean in the rails server command?
wallerdev has quit [Quit: wallerdev]
Kricir has quit [Ping timeout: 265 seconds]
maletor has quit [Quit: Computer has gone to sleep.]
carraroj has joined #ruby
jwp121 has left #ruby [#ruby]
olivier_bK has quit [Ping timeout: 246 seconds]
LadyRainicorn has quit [Ping timeout: 272 seconds]
<shevy> jwp121 did not stay for long now did he :P
freerobby has quit [Quit: Leaving.]
<shevy> RubyRonin the railsers are on #RubyOnRails, many people here don't know rails
<RubyRonin> thanks
<RubyRonin> @shevy my apologies, wrong window
jkhwan has joined #ruby
Asher has quit [Quit: Leaving.]
<shevy> no worries
Mapley has joined #ruby
mgberlin has quit [Quit: mgberlin]
olivier_bK has joined #ruby
Azure has quit [Ping timeout: 246 seconds]
markfletcher has quit [Ping timeout: 252 seconds]
<atmosx> shevy: how are you?
alvinsj has quit [Remote host closed the connection]
alvinsj has joined #ruby
lxsameer has quit [Quit: Leaving]
lewix has joined #ruby
jkhwan has quit [Ping timeout: 272 seconds]
<shevy> hmm quite ok, bit too much todo, trying to hurry up with everything
bricker`LA has quit [Quit: leaving]
flubba has quit [Read error: Connection reset by peer]
gregoriokusowski has joined #ruby
Azure has joined #ruby
carraroj has quit [Quit: Konversation terminated!]
maletor has joined #ruby
diegoviola has joined #ruby
alvinsj has quit [Ping timeout: 260 seconds]
mvangala_ has quit []
jego has joined #ruby
<shevy> 2013 is soon over
reach has quit [Remote host closed the connection]
freerobby has joined #ruby
<shevy> then I have one week in the lab in january, 2 exams at the end, and full time work for february 2014
<shevy> atmosx but I had a really cool idea
kraljev0 has joined #ruby
<atmosx> shevy: what kind of idea?
<kraljev0> Hey, is "in" a reserved word?
<shevy> atmosx what if you could use spaced nanocarbontubes to (repeatedly) run certain enzymatic processes
<shevy> kraljev0 dont think so, lemme check
<kraljev0> >> in = 10
Hanmac1 has joined #ruby
flubba has joined #ruby
<shevy> oh
aagdbl has quit [Quit: Leaving.]
<shevy> kraljev0 yeah seems it is
<kraljev0> any idea where it is used?
<shevy> I guess with for loops?
<shevy> for x in y
<atmosx> kraljev0: it's an awful name for a variable anyway
<kraljev0> func
<atmosx> evenr worst
tylersmith has quit [Remote host closed the connection]
nisstyre has quit [Quit: Leaving]
<kraljev0> #in and #out :)
olivier_bK has quit [Ping timeout: 246 seconds]
<shevy> hehe
<shevy> well out = 5 works
<kraljev0> :)
<shevy> I once tried this:
Hanmac has quit [Ping timeout: 272 seconds]
<shevy> def foo(i = '', class = 'marr5')
<shevy> and it did not work!
<kraljev0> klass
threesome has joined #ruby
aspires has joined #ruby
<waxjar_> qlaz
<shevy> isn't there a way to find out all reserved keywords in ruby at runtime?
zombiebit has joined #ruby
<shevy> ah ... kraljev0 someone made an extra page http://ruby-doc.org/docs/keywords/1.9/
klaut has joined #ruby
ForceMultiplier has quit [Ping timeout: 240 seconds]
ForceMultiplier has joined #ruby
matchaw_ has quit [Ping timeout: 272 seconds]
<kraljev0> for a in [1,2,3]
<kraljev0> [1,2,3].each do |a|
<kraljev0> I guess you spare a char or two
arietis has quit [Quit: Computer has gone to sleep.]
<canton7> for..in has scoping issues, and mutates 'a' each time
<canton7> (which has issues if you capture 'a' in a block, etc)
mary5030 has quit [Remote host closed the connection]
mary5030 has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
<kraljev0> and that is also true
<kraljev0> similar thing as with
<kraljev0> while true
<kraljev0> and loop {}
mikepack has joined #ruby
freezey has quit [Remote host closed the connection]
wildroman2 has joined #ruby
theoretick has quit [Quit: Textual IRC Client: www.textualapp.com]
JustinAiken_afk is now known as JustinAiken
<shevy> kraljev0 you can use { instead of do
<shevy> and if you align it right next to the { you don't need the ' ' space
<shevy> hmm let me compare
<shevy> for a in [1,2,3]
<shevy> [1,2,3].each{|a|
<shevy> [1,2,3].each {|a|
peregrine81 has quit [Ping timeout: 246 seconds]
<shevy> oh well
<kraljev0> actually I prefer { in my code
<shevy> the for loop is still shorter there
<shevy> I hate "each{"
mary5030 has quit [Ping timeout: 252 seconds]
<shevy> loop {} is beautiful
<kraljev0> yep
<kraljev0> it bothers me that
<kraljev0> func param { |x|
<kraljev0> doesn't work
<kraljev0> but
<kraljev0> func param do |x|
<kraljev0> does
<kraljev0> stupid precedence rules
<waxjar_> that always annoys me
<waxjar_> mostly because i have never looked it up and dont know the exact semantics :p
drago777 has quit [Ping timeout: 240 seconds]
Beoran_ has joined #ruby
<kraljev0> I'm coming from C++ background
<kraljev0> and PHP which I'm ashamed of :)
<kraljev0> very much
noob101 has joined #ruby
<waxjar_> their Name\Spaces are hideous :p
peregrine81 has joined #ruby
<kraljev0> not just that
<kraljev0> they are at least considering for all standard functions to be mapped using:
<noob101> Good evening fellow programmers. I am a 16 year old from NYC. I want to be a programmer, major in CS and go to either Manhattan College or CSI for my major.
<kraljev0> good evening.
<noob101> This is a program I have been working on for approximately a month, can you tell me if I did a good job. https://eval.in/83881
drago777 has joined #ruby
<canton7> ooh it's you again
<kraljev0> at the first impression
<kraljev0> it's not good
<shevy> php is such inconsistent in design
<kraljev0> too much repetition
<kraljev0> ruby is about DRY a lot
<shevy> from $this->type() to $this->getDataType()
Beoran__ has quit [Ping timeout: 245 seconds]
<noob101> I am sorry, I am new to programming. Please enlightened me, I want to be a rubyist,
<canton7> lines 51-56 can be refactored to remove that duplicate test
Mars` has joined #ruby
<kraljev0> php guy are thinking of preprocessing all function using 1. remove underscore, 2. downcase
<JustinAiken> noob101, afraid it's not very good,
<JustinAiken> but on the brightside,
<shevy> noob101 in ruby it is best to become as terse as possible
arietis has joined #ruby
<JustinAiken> you know more ruby than I did when I got my first real programming job :)
<kraljev0> so Html_Strip_Tags or htmlstriptags or HtmlStriptags calls the same function.
<shevy> noob101 in your code you use things which are not really necessary, like def help(), the () is not needed
<canton7> noob101, and your intentation's way off :P
tharkun512_ has joined #ruby
<shevy> kraljev0 see I don't understand it
freezey has joined #ruby
<canton7> shevy, that's minor, in the grand scheme of things here
dkamioka has quit [Remote host closed the connection]
<shevy> it's like cargo cult designing
<waxjar_> noob101: where are your classes? :O
<kraljev0> noob101, indentation is fine. tabs are fine
<shevy> like perfection on areas where it does not matter
<waxjar_> kraljev0: that's just awful
<shevy> though in all fairness
<kraljev0> Well, it is. However, it is the only way to repair their mess
<shevy> I think #nimrod does something similar
<noob101> I don't know how to use classes OMG I did my code so bad ;_;
<shevy> noob101 look, try to be terse. whether you use classes or not is secondary
<kraljev0> noob101 if it works, then it's just ok
<canton7> noob101, if you're just starting, do lots of simple things
<kraljev0> i wasn't just born a good programer either
<shevy> if (user_input != "Yes") && (user_input != "No") <-- the intent is not clear here
<noob101> What are classes, can someone enlighten me please.
<shevy> :\
<JustinAiken> perhaps before getting into classes and object oritentinedness, at least break some stuff into methods
<shevy> noob101 think of a class as specialized code that tries to solve a program in an easily re-usable manner
<kraljev0> ["Yes", "No"].none? user_input
<noob101> shevy, I am saying that if the user_input isn't equal to a string of Yes or No .
<JustinAiken> ooh, nm, you do have methods
<shevy> noob101 in ruby: class Foo;end; foo = Foo.new is a class
<JustinAiken> make more things mehtods
<shevy> noob101 I still did not understand it
arietis has quit [Client Quit]
<shevy> ah I think I know what you mean
<shevy> noob101, use case menu
<shevy> case x
<shevy> when 'Yes','No'
<shevy> else
<shevy> end
<noob101> shevy can you show me a class using eval or pastebin please.
<kraljev0> noob101, your code is ok, if it works. If you want to go into inproving it, do it one step at the time
<shevy> noob101, http://pastie.org/8585917
<kraljev0> ruby takes time
<noob101> Shevy, can you just redirect me to some good ruby tutorials so I can program better.
<waxjar_> noob101: any ruby guide aimed at beginners will explain classes :)
<shevy> you will not learn ruby from tutorials
<shevy> you must write scripts
<shevy> that's the only way
<noob101> I am seeking for better videos so I can learn new functions to add to my program.
<kraljev0> ruby is unique
<noob101> Ok.
<canton7> shevy, no! decent tutorials help you a lot
<canton7> they show you the unknown unknowns :P
<shevy> he has so many questions
<kraljev0> Neither am I fond of tutorial
<shevy> so many wants and needs
<kraljev0> take a book rather
<canton7> s/book/tutorial
<canton7> tutorial -> book rather
<noob101> I am inquisitive sorry, I love knowledge.
<kraljev0> that is great
<kraljev0> in fact it is the greatest thing
<shevy> there is theoretical knowledge and there is practical knowledge
<kraljev0> the strive for knowledge
<noob101> For my birthday, I told my grandma to get me a ruby book.
<shevy> you can master all knowledge there is but when you do not apply it, you don't really know the impact it has
<noob101> I want practical knowledge, I am a realist.
<kraljev0> :) Cool. But just code.
mary5030 has joined #ruby
<shevy> I have seen game designers ruin their games after years when they no longer understood their own games :(
<noob101> Thanks kraljev0
<shevy> because they stopped playing them on their own
<shevy> kraljev0 why did you use C++?
<shevy> and php :P
<noob101> shevy please explain this. As simple as it is, I just don't comprehend this. --> http://pastie.org/8585917
MindfulMonk has joined #ruby
<kraljev0> c++ I still use. It's just fast, where I need performance
<kraljev0> php - because I didn't know better
<kraljev0> I regret having lost 3 years of my life to php
<kraljev0> srsly
<shevy> noob101 you wrap things inside a class here. initialize() is a method on your class. it gets invoked when you do Foo.new, do you see that?
<noob101> Can someone please personal message me, I need one on one tutorial/tutoring.
<kraljev0> in that time noob101 is going to become professional rubyist
<shevy> lol
flubba has quit [Ping timeout: 240 seconds]
<shevy> I don't think he will
<kraljev0> just ask
<noob101> :(
<shevy> he won't really write code
<noob101> shevy initialize means what exactly?
marr has joined #ruby
<kraljev0> initialize is the method called when you instantiate the class
blackmesa has joined #ruby
flubba has joined #ruby
<shevy> noob101 every object that wants to exist will have to be initialized. the class is like the blueprint, you instantiate it into an object. you can have a million objects from the given class, it is like a factor
<shevy> *factory
<JustinAiken> noob101 - Here's part of your app refactored: https://gist.github.com/35ce2aca0aa41df7dad8
<shevy> kraljev0 well I used php as well
codezomb has joined #ruby
mary5030 has quit [Remote host closed the connection]
<shevy> it was not so bad in the sense that I could do things that seemed "useful" for the web
<shevy> but trying to use php for anything else just was plain horrid and awful
<kraljev0> well, when I have used it I have though I have a real powerful language
<shevy> I once wanted to write a MUD in php
<kraljev0> in which I could do everything
<shevy> yeah
<noob101> Thank you Mr.Justin Aiken..
<kraljev0> but then I have met ruby
<shevy> I thought that as well
rm__ has joined #ruby
<kraljev0> I have programmed a lot in ruby
<kraljev0> *php
<shevy> apparently noob101 has not
<kraljev0> but since then, I have rewritten everything to ruby & rack
<shevy> noob101, php has classes too. learn php first :D
<JustinAiken> noob101, take what I just gave you, and put the rest of your game inside the game class; come back after that, and we'll help you improve it from there
<noob101> shevy what does instantiate mean?
<JustinAiken> and for the love of God or the FSM, don't learn PHP first
senayar has joined #ruby
<shevy> noob101 to create an instance (something like a copy) of something
<kraljev0> go with C or Pascal
<noob101> Wow, thanks Mr.Justin.
<kraljev0> Mine first was BASIC on Spectrum ZX computer
<shevy> noob101, do you know tom and jerry? class Cat; end; tom = Cat.new
IceDragon has joined #ruby
skaflem has quit [Quit: Leaving]
<kraljev0> shevy, nice play! :)
<shevy> I loved tom and jerry
<waxjar_> noob101: you have a technical drawing of a house. this is your class. you hand the drawing to the builders and they build the actual house. this is your instance. then you give the drawing to some other builders who also build a house. this is another instance.
<shevy> it was melodic
<kraljev0> me too!
<shevy> today's cartoons are so awful, I don't hear good sounds. I don't understand how one can watch cartoons just for the visuals/drawings :(
<kraljev0> I prefer old ones very much
<kraljev0> though my younger brothers watch the newer ones
<kraljev0> like yu-gi-oh, which is not that bad I guess
rm_ has quit [Ping timeout: 252 seconds]
iamjarvo_ has joined #ruby
<noob101> I watch adventure time, is that good? It's on cartoon network.
<noob101> JustinAiken, I put the code from github to my original code. Thank you for the help.
<shevy> dunno
gigetoo has quit [Remote host closed the connection]
<shevy> Hanmac knows adventure time, I just can't watch all these new things, I am like being stuck in the past here
saarinen has joined #ruby
gigetoo has joined #ruby
<shevy> noob101 remember the most important rule of ruby - if you can be terse, try to be terse, as long as the code intent is clear
<noob101> My code was too much right?
<shevy> noob101 yeah
<shevy> noob101 you could even alias puts
<shevy> alias e puts
<shevy> then you can use e rather than puts
<CaptainJet> i thought the most important rule of ruby was 'be cool'
<shevy> nah
<shevy> terse code is already cool
<JustinAiken> unless you're just code golfing :p
cbetta_afk is now known as cbetta
timonv has quit [Remote host closed the connection]
habanany has quit [Ping timeout: 272 seconds]
<noob101> What does alias mean?
LexicalScope has joined #ruby
phansch has quit [Quit: Leaving]
Mars` has quit [Remote host closed the connection]
<kraljev0> your code could be written in 70% lines less
<kraljev0> alias means you give a function another name
Seich has joined #ruby
<kraljev0> how old are you?
<noob101> 16
<kraljev0> then we're too harsh on you. :)
<noob101> It's alright, I am learning a little bit.
<noob101> kraljevo, give me an example on how you would use alias.
<CaptainJet> 16? I started Ruby coding when i was 16
<CaptainJet> that was 4 years ago
mgorbach has quit [Read error: Connection reset by peer]
<kraljev0> alias yell scream
<kraljev0> this means you can call wife.scream and wife.yell with the same effect
Seich has quit [Ping timeout: 265 seconds]
Hanmac has joined #ruby
hakunin has joined #ruby
<JustinAiken> self.hide
<waxjar_> noob101: if you see things that are very similar, try to do something smart so that you don't repeat yourself but you still get the same results. example: https://gist.github.com/britishtea/89e542f57afffb4fdbf1
<shevy> noob101 alais is like a pointer
<shevy> *alias
Hanmac1 has quit [Ping timeout: 260 seconds]
<shevy> noob101 if you write a method, like: def foo; end; you can alias to it f, like: alias f foo, then you can call f or f() to call method foo() ok?
<JustinAiken> noob101, waxjar_'s post there will also work inside the Game class I showed, please take his advice and put that in your refactor too
mgorbach has joined #ruby
iliketurtles has joined #ruby
iliketurtles has quit [Max SendQ exceeded]
saarinen has quit [Quit: saarinen]
iliketurtles has joined #ruby
<shevy> noob101 I think the next thing you should do is add methods to your code
<shevy> noob101 when you use lots of methods, it becomes clear and structured what you wanna do. and then using a class is the next evolutionary step
<noob101> So much advice, hard to comprehend. Must not give up.
saarinen has joined #ruby
<shevy> no, just write code on your own, it will become more clear when you do
<noob101> Right.
<shevy> and once you did that, also start early publishing gems of your own on rubygems.org
<shevy> but make sure they have no bugs :D
brunops has quit [Ping timeout: 252 seconds]
<noob101> Can I make money from my code?
drago777 has quit [Ping timeout: 240 seconds]
<shevy> indirectly
<shevy> as you gain experience
<waxjar_> not yet noob101 :p
jkhwan has joined #ruby
<noob101> >:( Ok.
<shevy> there are people who are paid to write perl code
<shevy> that depresses me the most :(
<kraljev0> maybe take up php or C
mgorbach has quit [Read error: Connection reset by peer]
<kraljev0> and then return to ruby
<kraljev0> or java, for that matter
<kraljev0> I want you to suffer and then see ruby as your saviour :)
<shevy> ack
<shevy> java
<shevy> why don't you just send him to hell already man
<shevy> but it's true
<noob101> Not C, No.
<shevy> noob101, if you wanna become rich, go use java then work at banks
<noob101> I am about to jump out the window.
<kraljev0> C++, ok. But C is not bad.
<kraljev0> If you want to get rich, then COBOL
<noob101> COBOL, LOL. WHO USES COBOL???
<shevy> banks
kep has quit [Ping timeout: 246 seconds]
drago777 has joined #ruby
<atmosx> Russians to sent missiles to the moon iirc
<atmosx> military in general I think uses cobol
<noob101> I know this man who went to college and he was learning COBOL, he switched his major to become a social worker. He didn't like it.
mechanicles has joined #ruby
mgberlin has joined #ruby
<JustinAiken> you can make money in any language; but C programmers tend to not get paid that much more than Ruby developers,
TomRone has quit [Ping timeout: 240 seconds]
<JustinAiken> so why not work in something pleasant? :)
kraljev0 has quit [Read error: Operation timed out]
kraljev0 has joined #ruby
<noob101> waxjar_ should I put this in the very beginning of my program or at the very bottom? https://gist.github.com/britishtea/89e542f57afffb4fdbf1
<waxjar_> the beginning
<noob101> The very very very beginning?
<noob101> Line 1?
TomRone has joined #ruby
<waxjar_> well, as long as you put it before you start using it you're fine :)
jkhwan has quit [Ping timeout: 272 seconds]
<noob101> thanks
kedibasi has joined #ruby
<JustinAiken> puts the delayed_puts definition anywhere inside your Game class
mgorbach has joined #ruby
g3orge has quit [Quit: WeeChat 0.4.2]
<noob101> Oh I was going to ask that lol
<noob101> It goes in the class. Got it.
<JustinAiken> and since it's in your class, order won't even matter :)
<noob101> Oh cool.
<noob101> Ok, I have some questions about having a job as a programmer.
<noob101> I want to major in CS. Does the school matter first of all?
<noob101> I want to go to either Manhattan College or College of Staten Island.
workmad3 has joined #ruby
matchaw has joined #ruby
shime has joined #ruby
<kraljev0> Your question is too location specific
Hanmac1 has joined #ruby
<kraljev0> I guess nobody here knows
<kraljev0> but manhattan college sounds nicer, so...
<JustinAiken> I went to school at ARetardedUniversity for Sound Engineering, so I have no idea :p
<kraljev0> :)
Hanmac has quit [Ping timeout: 252 seconds]
aspires has quit []
<noob101> Ok, this is what I have so far. However, I am getting this error. https://eval.in/84012
<JustinAiken> you need one more end to close the first line
<JustinAiken> line 42 should be end
mengu has quit [Quit: This computer has gone to sleep]
<JustinAiken> and everything between class Game and that end should be indented two spaces
<JustinAiken> and only use the delayed_puts from within other methods within Game, not bareback
<kraljev0> you have to end the class too
<kraljev0> so put one more end
<kraljev0> on line 32
<kraljev0> *42
alexherbo2 has joined #ruby
<kraljev0> not necesarily two spaces
<kraljev0> but a tab suffices, too
dapz has joined #ruby
<JustinAiken> NO! use two spaces, not tab characters
<JustinAiken> grumble grumble :p
senayar has quit [Remote host closed the connection]
timonv has joined #ruby
alexherbo2 has quit [Client Quit]
shime has quit [Ping timeout: 252 seconds]
iliketurtles has quit [Quit: zzzzz…..]
brunops has joined #ruby
timonv has quit [Client Quit]
tylersmith has joined #ruby
iliketurtles has joined #ruby
iliketurtles has quit [Excess Flood]
LexicalScope has quit [Ping timeout: 272 seconds]
iliketurtles has joined #ruby
timonv has joined #ruby
saarinen has quit [Quit: saarinen]
brunops has quit [Ping timeout: 240 seconds]
tylersmith has quit [Ping timeout: 245 seconds]
brunops has joined #ruby
matchaw has quit [Ping timeout: 260 seconds]
Faris has quit [Ping timeout: 252 seconds]
<shevy> it's time to slay the tab users!
<shevy> noob101, do you use tabs?
brunops has quit [Changing host]
brunops has joined #ruby
<shevy> noob101 btw in the code you showed there, you are not indenting consistently
VTLob has joined #ruby
<shevy> noob101, look at line 16
<shevy> why has it one indent level
<IceDragon> o: Tabs are silly
<IceDragon> just use spaces
<IceDragon> much better
<IceDragon> also hi shevy, can I has cookies?
Hanmac has joined #ruby
<shevy> ohhh noob101 now I see, you use a class, remember, you should indent one full level to the right when you use a class
<shevy> IceDragon now you are too fat
<shevy> fat dragons can no longer fly
mechanicles has quit [Quit: Lingo - http://www.lingoirc.com]
<shevy> so you get no cookie
<shevy> noob101 at any rate, all methods in your class should have the same level of indent
<IceDragon> But I'm not fat ;-; (is actually under weight)
Hanmac1 has quit [Ping timeout: 240 seconds]
Faris has joined #ruby
alexherbo2 has joined #ruby
<RubyPanther> One of the great things about Ruby, what whitespace to use is not a matter of opinion, there is a recognized correct answer. It isn't the setting I would of chosen, but it works great and isn't surprising.
Mars` has joined #ruby
Baluse has joined #ruby
<Baluse> hello
<Baluse> what does this line of code mean
<Baluse> @order = (parent? && parent.active_order) || collection.build
<Baluse> where is parent?
allsystemsarego has quit [Quit: Leaving]
<RubyPanther> Baluse: parent is an object attribute on whatever class you found that code
jego has quit [Remote host closed the connection]
<Baluse> searching the code dont find any reference to if
<Baluse> it
<RubyPanther> Baluse: I'm more worried about, why do you want to know what it means? What are you doing?
<Baluse> nothing looking some code
ozkan has quit [Quit: Leaving...]
timonv has quit [Remote host closed the connection]
<RubyPanther> Right but if you're doing "nothing" then there is no need for questions about it. It is just code in that case. http://programming-motherfucker.com/become.html
<JustinAiken> Baluse, the code is shorthand for this overly-verobse example: https://gist.github.com/fdbb2322aafaf83b6627
<Baluse> ok then
dkamioka has joined #ruby
<Baluse> JustinAiken thanks . parent where is refers ? not sure ( i have no experience with ruby yet)
Mars` has quit [Remote host closed the connection]
levity_island has joined #ruby
<JustinAiken> somewhere, in whatever class the code you're looking at inherited from, there's a line that starts with def parent?; …; end
<JustinAiken> (unless it's added with crazy :define_method or method_missing's, but let's not get in to that yet ;) )
noob101 has quit [Ping timeout: 272 seconds]
<JustinAiken> Ruby let's you end any method you like with a ?
<Baluse> parent class doesnt have active_order things
<JustinAiken> although convention is any method_ending_with_a? returns true or false
jacderida has joined #ruby
<JustinAiken> Baluse, is this a Rails app?
<Baluse> yes
<Baluse> there is so much "magic" in rails/ruby
<shevy> yea
<JustinAiken> so I'm not sure what the parent class is, but in it's model, there's probably a line like "has_many :orders"
joaoh82 has quit [Remote host closed the connection]
lkba has quit [Ping timeout: 245 seconds]
<JustinAiken> and also a method to describe the active order
<Baluse> its a controller class
Jake232 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<JustinAiken> what controller?
danshultz has quit [Remote host closed the connection]
<Baluse> maybe i should do a grep to find it
dkamioka has quit [Ping timeout: 265 seconds]
butblack has joined #ruby
yano has joined #ruby
<Baluse> it seems that it has a belongs_to
shime has joined #ruby
LexicalScope has joined #ruby
dapz has quit [Ping timeout: 260 seconds]
coca_rails has joined #ruby
Mars` has joined #ruby
kedibasi has left #ruby ["WeeChat 0.3.7"]
umurgdk has quit [Remote host closed the connection]
coca_rails has quit [Remote host closed the connection]
peregrine81 has quit []
shime has quit [Ping timeout: 240 seconds]
mmitchell has joined #ruby
coca_rails has joined #ruby
jrobeson has joined #ruby
shime has joined #ruby
lewix has quit [Remote host closed the connection]
ambushsabre has quit [Quit: rip]
tsupertramp has quit [Remote host closed the connection]
lewix has joined #ruby
lewix has quit [Read error: Connection reset by peer]
Mars`_ has joined #ruby
peregrine81 has joined #ruby
lewix has joined #ruby
<JustinAiken> does anyone know how to get lots of Ruby code into a nice PDF?
atmosx has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
Mars`_ has quit [Remote host closed the connection]
gregoriokusowski has quit [Read error: Connection reset by peer]
Mars` has quit [Ping timeout: 240 seconds]
Hanmac1 has joined #ruby
coca_rails has quit [Remote host closed the connection]
Hanmac has quit [Ping timeout: 272 seconds]
gregoriokusowski has joined #ruby
freezey has quit [Remote host closed the connection]
klaut has quit [Remote host closed the connection]
drumusician has joined #ruby
benzrf has joined #ruby
phipes has joined #ruby
<benzrf> hi, is anybody willing to look over 330 LOC and tell me if anything in it is particularly stupid?
johnmilton has quit [Remote host closed the connection]
mikepack has quit [Remote host closed the connection]
mikepack has joined #ruby
wildroman2 has quit [Remote host closed the connection]
<Jamo> just share it. probably some one idling here will help
<benzrf> hmm, actually maybe i shouldnt
wildroman2 has joined #ruby
<benzrf> im being paid to make this and even if it's not much and no contracts were signed, i feel like i probably shouldnt be tossing the source around
heidi has joined #ruby
<Jamo> oh :)
<Jamo> I can check it
subbyyy has joined #ruby
subbyyy has quit [Client Quit]
mikepack has quit [Ping timeout: 265 seconds]
subbyyy has joined #ruby
<mojjojo> where can i get help regarding google analytics api?
agjacome_ has quit [Quit: leaving]
wildroman2 has quit [Ping timeout: 245 seconds]
ozkan has joined #ruby
freezey has joined #ruby
Hanmac has joined #ruby
drumusician has quit [Read error: Connection reset by peer]
iamjarvo_ has quit [Remote host closed the connection]
drumusician has joined #ruby
iamjarvo_ has joined #ruby
Hanmac1 has quit [Ping timeout: 245 seconds]
klaut has joined #ruby
iamjarvo has joined #ruby
<DouweM> benzrf: I'd be happy to check it as well.
<benzrf> its klaut
<benzrf> *k
kraljev0 has quit [Quit: kraljev0]
agjacome has joined #ruby
iamjarvo_ has quit [Ping timeout: 245 seconds]
ozkan has quit [Quit: Linkinus - http://linkinus.com]
RoryHughes has joined #ruby
heidi has quit [Quit: Leaving.]
senayar has joined #ruby
elux has joined #ruby
pskosinski_ has joined #ruby
Barrin6 has joined #ruby
pskosinski has quit [Disconnected by services]
pskosinski_ is now known as pskosinski
popl has joined #ruby
popl has joined #ruby
popl has quit [Changing host]
OdNairy has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
senayar has quit [Ping timeout: 246 seconds]
<shevy> benzrf the code sucks
<mojjojo> can anyone manage to create service account at google api https://developers.google.com/analytics/devguides/reporting/core/v3/gdataAuthorization?hl=fr ?
pen has quit [Read error: Connection reset by peer]
ambushsabre has joined #ruby
danshultz has joined #ruby
<benzrf> har
lewix has quit [Remote host closed the connection]
bluOxigen has quit [Ping timeout: 252 seconds]
lewix has joined #ruby
lewix has quit [Read error: Connection reset by peer]
Jake232 has joined #ruby
lewix has joined #ruby
Speed has quit [Quit: When two people dream the same dream, it ceases to be an illusion.]
Speed has joined #ruby
pen has joined #ruby
freezey has quit [Remote host closed the connection]
sts has joined #ruby
<sts> hello folks! When creating methods with (*args, &block), how would I best avoid writing the implementation for block and args?
chrisan has joined #ruby
<benzrf> hmm?
<benzrf> sts: what do you mean exactly?
croaky has quit [Ping timeout: 265 seconds]
<benzrf> this doesnt explain anything
<benzrf> also, why are you using 'if block_given?' instead of 'if block'
matti has quit [Quit: Oh dear...]
<benzrf> [it will be nil if no block was given]
dr_bob has joined #ruby
Wolland has quit [Read error: Connection reset by peer]
freezey has joined #ruby
Wolland has joined #ruby
<sts> benzrf: slowly. I'm just starting to play with this whole block stuff. :) I saw several implementations using block_given?
<benzrf> you only need that if you don't specify an arg to get the block in
<benzrf> you can always receive blocks regardless of whether you have a &param
<benzrf> if you dont set one, you can still use block_given? and yield
<sts> benzrf: but if I could pass a hash to the function as well, which will end up in args.
<benzrf> ok... so?
<DouweM> also, use Duty.create(&block)
<sts> DouweM: thats the same as yield?
Czupa has quit [Remote host closed the connection]
<benzrf> sts: you can pass blocks with & as well as receive them
<benzrf> so that will pass block as the block arg to create
<DouweM> Duty.create takes a block, so instead of building one in which you call the one your were passed, just pass the one you were passed
RubyRonin has quit [Quit: ChatZilla 0.9.90.1 [Firefox 25.0.1/20131112160018]]
<benzrf> ^
dr_bob has quit [Client Quit]
<sts> so I could actually just pass both of them along ... Duty.create(*args, &block)
<benzrf> right
<benzrf> but then there's no point in having your current code
<benzrf> it does exactly the same thing as create
<sts> well, the schedule function should do more, once its finished.
<benzrf> ahuman:
<benzrf> *ah
<sts> if Duty.overlaps? ...
<sts> and so on, and in the end it will create it.
<benzrf> ok, cool
<benzrf> why create instead of new?
fuhgeddaboudit has joined #ruby
B064F377 has quit [Ping timeout: 246 seconds]
iamjarvo has quit [Remote host closed the connection]
<apeiros> sts: a passed block never end up in *args, and no other arg end up in &block
<apeiros> those two are separate things
B064F377 has joined #ruby
fenicks has quit [Read error: Connection reset by peer]
agent_white has joined #ruby
iamjarvo has joined #ruby
ahawkins has quit [Ping timeout: 252 seconds]
matchaw has joined #ruby
Guedes0 has joined #ruby
gregoriokusowski has quit [Quit: gregoriokusowski]
<sts> apeiros: what else would &block be good for?
diegoviola has quit [Quit: WeeChat 0.4.2]
kirun has quit [Quit: Client exiting]
shime has quit [Ping timeout: 245 seconds]
alexherbo2 has quit [Quit: WeeChat 0.4.2]
mgberlin has quit [Quit: mgberlin]
mercwithamouth has joined #ruby
dayepa has quit [Quit: dayepa]
Hanmac1 has joined #ruby
dayepa has joined #ruby
Hanmac has quit [Ping timeout: 264 seconds]
cj3kim has quit [Read error: Connection reset by peer]
cj3kim has joined #ruby
jkhwan has joined #ruby
matti has joined #ruby
benzrf is now known as benzrf|afk
mgberlin has joined #ruby
Neomex has joined #ruby
benzrf|afk has left #ruby [#ruby]
rubyracer has quit [Quit: Konversation terminated!]
momomomomo has joined #ruby
Mars` has joined #ruby
jkhwan has quit [Ping timeout: 272 seconds]
jalcine has left #ruby ["WeeChat 0.4.3-dev"]
flame_ has joined #ruby
ephemerian has quit [Quit: Leaving.]
mklappstuhl has joined #ruby
popl has quit [Ping timeout: 272 seconds]
subbyyy has quit [Ping timeout: 252 seconds]
Mars` has quit [Ping timeout: 240 seconds]
samsonasu has joined #ruby
joaoh82 has joined #ruby
mois3x has joined #ruby
Nilium has quit [Ping timeout: 265 seconds]
Nilium has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
joaoh82 has quit [Ping timeout: 240 seconds]
blackmesa has joined #ruby
joshu_ has joined #ruby
rien has quit [Read error: Connection reset by peer]
rien has joined #ruby
jnoob22_ has joined #ruby
Jetchisel has joined #ruby
peregrine81 has quit []
joshu has quit [Ping timeout: 248 seconds]
jnoob22 has quit [Ping timeout: 248 seconds]
kaldrenon has joined #ruby
Neomex has quit [Quit: Neomex]
fuhgeddaboudit has quit [Ping timeout: 272 seconds]
butblack has quit [Quit: butblack]
Nilium has quit [Ping timeout: 245 seconds]
croaky has joined #ruby
freezey has quit [Ping timeout: 246 seconds]
LexicalScope has quit [Ping timeout: 264 seconds]
timonv has joined #ruby
dscrd has joined #ruby
eka has joined #ruby
Nilium has joined #ruby
claymore has quit [Quit: Leaving]
freerobby has quit [Quit: Leaving.]
freerobby has joined #ruby
lkba has joined #ruby
joaoh82 has joined #ruby
drumusician has quit [Ping timeout: 246 seconds]
timonv has quit [Ping timeout: 240 seconds]
banghouse has quit [Remote host closed the connection]
phipes has quit [Remote host closed the connection]
iamjarvo has quit [Remote host closed the connection]
iamjarvo has joined #ruby
zxd has joined #ruby
kaldrenon has quit [Remote host closed the connection]
Bumptiou_ has quit [Remote host closed the connection]
_br_ has quit [Ping timeout: 272 seconds]
jlast has joined #ruby
senayar has joined #ruby
_br_ has joined #ruby
senayar has quit [Remote host closed the connection]
iamjarvo has quit [Ping timeout: 240 seconds]
zxd has quit [Ping timeout: 272 seconds]
asteve has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rickruby has joined #ruby
mois3x has quit [Quit: mois3x]
nuclearblast is now known as sebastianb
JustinAiken has quit [Quit: Leaving.]
jellow_ is now known as jellow
jellow has quit [Changing host]
jellow has joined #ruby
peneconleche has joined #ruby
<mgberlin> hey, if I found a typo in the ruby documentation, should I report it somewhere?
devdvd has joined #ruby
havenwood has joined #ruby
aspires has joined #ruby
eka has quit [Quit: Computer has gone to sleep.]
tharkun512_ has quit [Quit: leaving]
wowowewa has quit [Ping timeout: 246 seconds]
dscrd has quit [Quit: .]
kewubenduben has quit [Ping timeout: 252 seconds]
flubba has quit [Remote host closed the connection]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<apeiros> sts: to store the passed block
<apeiros> sts: with block_given? and yield, you can only use the block directly, you can't store it or pass it on
<apeiros> def foo(&block); @block = block; end; def bar; @block.call; end # <-- foo stores the block, bar calls it
mklappstuhl has quit [Remote host closed the connection]
MindfulMonk has quit [Ping timeout: 246 seconds]
iliketurtles has quit [Ping timeout: 245 seconds]
spider-mario has quit [Read error: Connection reset by peer]
cosmicpanda has joined #ruby
JustinAiken has joined #ruby
Faris has quit [Ping timeout: 245 seconds]
colonolGron has quit [Quit: leaving]
phipes has joined #ruby
afhammad has joined #ruby
iliketurtles has joined #ruby
iliketurtles has quit [Excess Flood]
iliketurtles has joined #ruby
_honning_ has quit [Ping timeout: 272 seconds]
postmodern has joined #ruby
mojjojo has quit [Quit: mojjojo]