bthesorceror has quit [Remote host closed the connection]
<jdahm>
I've just started using middleman-blog and got this error when I create a post: http://beta.pastee.com/83ayd, wondered if anyone knows if this is an error on my part or the gem/deps
Spooner has joined #ruby
bthesorceror has joined #ruby
<jdahm>
that error appears literally when I activate the extension and create a blog post file, not even rendering it
<wallerdev>
you can create a blog in rails in 15 minutes, havent you seen the video
freerobby has joined #ruby
<jdahm>
wallerdev: is that directed at me?
<wallerdev>
yeah but not serious sorry lol
<wallerdev>
never heard of middleman
<felipec>
wallerdev: I did
ntzrmtthihu777 has joined #ruby
r_rios has quit [Ping timeout: 245 seconds]
<jdahm>
I'm just wondering 1. if there are any middleman devs here or 2. if I should open an issue on the github page
<felipec>
wallerdev: flushing doesn't work... only closing it... but it's weird, only with puts
<felipec>
er, I didn't flush, I did 'sync'
<wallerdev>
might just not create the tempfile til its closed, not sure the implementation details
mrsolo has joined #ruby
chrisseaton has quit []
<felipec>
either way, f.write(string) works
<ntzrmtthihu777>
so... I know that ruby 2.1.1 on windows is a no-go atm, but how about on cygwin?
mrsolo has quit [Remote host closed the connection]
<wallerdev>
probably could compile it on cygwin
unstable has quit [Ping timeout: 265 seconds]
<wallerdev>
its basically linux on windows
bthesorceror has quit [Ping timeout: 252 seconds]
mjs2600 has quit [Remote host closed the connection]
<ntzrmtthihu777>
wallerdev: yeah; I use it because window's dev tools suck ass
<wallerdev>
true
<wallerdev>
especially the command prompt
<wallerdev>
that hasnt changed since 1995 lol
<ntzrmtthihu777>
yeah. and where the fuck is their posix compliance!?
Tomasso has quit [Read error: Connection reset by peer]
<wallerdev>
haha
<xybre>
Windows POSIX compliance is in their POSIX extension toolkit.
<wallerdev>
i would just like a competent command prompt on windows
combusean has quit [Ping timeout: 240 seconds]
<shevy>
msys!
<ntzrmtthihu777>
xybre: yeah, just installed that, but still....
<wallerdev>
like the default selection mode is still rectangular
<shevy>
putty!
Kricir has joined #ruby
<shevy>
die windows, die!
<wallerdev>
shevy: it doesnt help because all the command line programs are written to assume the width of the command prompt doesnt change
Tomasso has joined #ruby
<shevy>
I think my main box was last windows +10 years ago
<wallerdev>
lines dont actually wrap, they just get cut off and put on the next line
<wallerdev>
thats why they cant offer real selection of things lol
<shevy>
:(
<wallerdev>
and if you resize you just end up with a bunch of blank space
<shevy>
you make me sad
<xybre>
Oh, it looks like they removed the POSIX subsystem in 2003.
<wallerdev>
which is why they don't let you resize it on the fly, you have to change it in the properties lol
<ntzrmtthihu777>
xybre: nah. I just installed it for win7ultx64
<xybre>
ntzrmtthihu777: Installed what?
<ntzrmtthihu777>
xybre: windows posix subsystem
<xybre>
Interesting
<ntzrmtthihu777>
Subystem for Unix Applications
<ntzrmtthihu777>
xybre: google 'windows posix' and you'll get some info
<Spooner>
I used to use console2 on windows instead of cmd. Kept me sane...
Kricir has quit [Ping timeout: 276 seconds]
davispuh has quit [Remote host closed the connection]
sdwrage has quit [Quit: This computer has gone to sleep]
<ntzrmtthihu777>
I only venture into windows for a few reasons these days
pwh has joined #ruby
emaxi has joined #ruby
b1nd has quit [Ping timeout: 258 seconds]
<wallerdev>
i had to use windows at my last job
<wallerdev>
but im free now
<Spooner>
I only use it in a VM these days. Still, use ansicon or something like git bash inside console2 and you are fine.
thrillagorilla has joined #ruby
glanzi has quit [Remote host closed the connection]
subz3r0 has quit [Quit: subz3r0]
Spooner has quit [Quit: Bye]
emaxi has quit [Ping timeout: 240 seconds]
bradhe has quit [Remote host closed the connection]
sdelmore has joined #ruby
bradhe has joined #ruby
Megtastique has quit []
danshultz has quit [Remote host closed the connection]
Melpaws has joined #ruby
danshultz has joined #ruby
ktun has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
i_s has joined #ruby
jameswlane has joined #ruby
r_rios has joined #ruby
s3ri0us has quit [Ping timeout: 252 seconds]
phoo1234567 has quit [Quit: Leaving]
mercwithamouth has quit [Ping timeout: 240 seconds]
cpruitt has joined #ruby
bradhe has quit [Ping timeout: 240 seconds]
kaichanvong has quit [Quit: _]
jackyalcine has joined #ruby
i_s has quit [Ping timeout: 258 seconds]
danshultz has quit [Ping timeout: 258 seconds]
atmosx has quit [Remote host closed the connection]
atmosx has joined #ruby
helpD has joined #ruby
ktun has joined #ruby
ktun has quit [Client Quit]
sdelmore has quit [Quit: Leaving.]
deens has quit [Remote host closed the connection]
SonicX has joined #ruby
yubrew has joined #ruby
combusean has joined #ruby
helpD has quit [Ping timeout: 240 seconds]
deens has joined #ruby
* combusean
looks around
Asher has quit [Ping timeout: 276 seconds]
maletor has joined #ruby
* shevy
starts to spank combusean
Tomasso has quit [Read error: Connection reset by peer]
Speed has quit [Quit: When two people dream the same dream, it ceases to be an illusion.]
<ntzrmtthihu777>
o_0
eka has quit [Quit: My computer has gone to sleep. ZZZzzz…]
<combusean>
shevy, I'm not sure this is a conversation either of us want to have in public. :P
<shevy>
you deserved it!
<shevy>
you were looking around for trouble
Monito has joined #ruby
cpruitt has quit [Quit: cpruitt]
gr33n7007h has joined #ruby
<combusean>
pics or gtfo
yubrew has quit [Ping timeout: 276 seconds]
<combusean>
:P
deens has quit [Ping timeout: 250 seconds]
ddv has quit [Ping timeout: 245 seconds]
ehc has quit [Ping timeout: 245 seconds]
felipec has left #ruby ["Leaving"]
kreisys has quit [Quit: Computer has gone to sleep.]
b1nd has joined #ruby
ehc has joined #ruby
ktun has joined #ruby
Loaft has quit [Ping timeout: 240 seconds]
kyb3r_ has quit [Ping timeout: 265 seconds]
RastaqWhere has joined #ruby
blischalk has quit [Ping timeout: 265 seconds]
RastaqWhere has quit [Quit: Leaving.]
kaspergrubbe has quit [Remote host closed the connection]
ktun has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
ddv has joined #ruby
zigomir has quit [Remote host closed the connection]
zigomir has joined #ruby
ghr has joined #ruby
mrmargolis has joined #ruby
<ntzrmtthihu777>
lol
snath has quit [Ping timeout: 252 seconds]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
x77686d has joined #ruby
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
Hanmac has quit [Ping timeout: 276 seconds]
deens has joined #ruby
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
sdwrage has joined #ruby
zigomir has quit [Ping timeout: 276 seconds]
ghr has quit [Ping timeout: 240 seconds]
kies has joined #ruby
kies has quit [Changing host]
kies has joined #ruby
pu22l3r has joined #ruby
<wallerdev>
have a good weekend buddies
<wallerdev>
<3
BSaboia has quit [Ping timeout: 245 seconds]
yfeldblu_ has quit [Ping timeout: 258 seconds]
wallerdev has quit [Quit: wallerdev]
<ntzrmtthihu777>
ok... cygwin and ruby-installer 2.0.0 failing me. So, with that, what is the latest, fully functioning ruby for windows?
bthesorceror has joined #ruby
<arubin>
Run Linux in a virtual machine.
jlast has quit [Remote host closed the connection]
<benzrf>
dont use windows
jlast has joined #ruby
sdwrage has quit [Quit: This computer has gone to sleep]
<arubin>
Kids use Windows out of irony these days.
momomomomo has quit [Quit: momomomomo]
Es0teric has joined #ruby
pu22l3r has quit [Remote host closed the connection]
Es0teric has quit [Max SendQ exceeded]
charliesome has joined #ruby
Es0teric has joined #ruby
Es0teric has quit [Max SendQ exceeded]
<ntzrmtthihu777>
arubin: I don't use windows. I'm an arch user.
<ntzrmtthihu777>
I am just working on some ruby/c++ code, and I do intend to port
dik_dak has quit [Remote host closed the connection]
Monito has quit [Read error: Connection reset by peer]
Es0teric has joined #ruby
<ntzrmtthihu777>
what works in 2.1.1 on arch, does not on windows with 2.0.0; its just a simple extension which manipulates an object with four instance variables, and I can't even require it XD
Monito has joined #ruby
sepp2k has quit [Quit: Leaving.]
kiki_lamb has quit [Quit: leaving]
Kricir has joined #ruby
kiki_lamb has joined #ruby
bricker`LA has quit [Ping timeout: 265 seconds]
<benzrf>
bye ima sleep
Jetchisel has joined #ruby
mostlybadfly has quit [Quit: Connection closed for inactivity]
mois3x has quit [Quit: mois3x]
mikeric has joined #ruby
emaxi has joined #ruby
hgl has joined #ruby
Kricir has quit [Ping timeout: 240 seconds]
kalyx has joined #ruby
benzrf is now known as benzrf|offline
<kalyx>
does anyone know what benzrfs quick project is about
<kalyx>
github.com/benzrf/quick
<centrx>
something about taking over world
chipotle has joined #ruby
<kalyx>
pls actually explain it to me
locriani has quit [Remote host closed the connection]
locriani has joined #ruby
hgl has quit [Remote host closed the connection]
<arubin>
kalyx: It is malware.
<kalyx>
right thanks
hgl has joined #ruby
nerocrux has quit [Read error: Connection reset by peer]
emaxi has quit [Ping timeout: 240 seconds]
<centrx>
I'm not sure what it is
<kalyx>
he told me to ask you guys
<kalyx>
since he's like 10
<ntzrmtthihu777>
there we go. apparently my program will have to use ruby 1.9.3 on windows...
<arubin>
Why did you wait until just after he went offline to ask?
<centrx>
I thought he was older than that
<centrx>
I'm not sure what "Smalltalk development environment" means
ehc has quit [Quit: ehc]
<centrx>
what he means by
<kalyx>
we were in another channel before he left
<kalyx>
yeah he's like 16 or something.
deens has quit [Remote host closed the connection]
<arubin>
That would explain his obsession with Haskell.
deens has joined #ruby
<kalyx>
would someone mind running that live demo he made?
tjr9898 has joined #ruby
<xybre>
I don't have scriptreply
jlast has joined #ruby
<kalyx>
arubin, whats the joke behind him being 16 and obsessed with haskell?
afex has quit [Ping timeout: 245 seconds]
<arubin>
kalyx: Lack of pragmatism.
r_rios has quit [Ping timeout: 240 seconds]
<arubin>
Someone asks a simple question and he starts rambling about monads.
<kalyx>
lol
<shevy>
lol
<arubin>
He does not seem to like Ruby, so I am not sure why he hangs out here.
<kalyx>
I'm not a programmer at all but I've known him for a little over a year
<shevy>
he is a programming multilingualist
<kalyx>
its funny to read this
deens has quit [Ping timeout: 265 seconds]
dapz has joined #ruby
lw has joined #ruby
<shevy>
at a young age he drinks more kool aid than the older ones
<kalyx>
i used to run a vps in Sweden for some stuff. and he took it over and was going crazy with it
<kalyx>
every once and a while i would re-image it, open a beer, and wait for a pm
<arubin>
heh
i_s has joined #ruby
<ntzrmtthihu777>
trolling level: over 9000
dkannan has joined #ruby
<shevy>
cool
Martxel has quit [Read error: Connection reset by peer]
<shevy>
he never pmed me
<kalyx>
a pm from benzrf is like winning an oscar
Martxel has joined #ruby
codabrink has quit [Ping timeout: 240 seconds]
<xybre>
It demonstrates you're a tool to the establishment?
eka has joined #ruby
<shevy>
lol
<ntzrmtthihu777>
lawl
<shevy>
benzrf|offline: <kalyx> a pm from benzrf is like winning an oscar
r_rios has joined #ruby
meatherly has quit [Remote host closed the connection]
<kalyx>
exactly xybre
ntzrmtthihu777 has quit [Quit: leaving]
yubrew has joined #ruby
deric_skibotn has quit [Ping timeout: 252 seconds]
nateberkopec has joined #ruby
nerocrux has joined #ruby
chris_thomson has quit [Quit: Zzz...]
i_s has quit [Ping timeout: 240 seconds]
jlast has quit [Remote host closed the connection]
jxf has quit [Ping timeout: 250 seconds]
nerocrux has quit [Client Quit]
ponga has joined #ruby
ponga has quit [Changing host]
ponga has joined #ruby
yubrew has quit [Ping timeout: 252 seconds]
pu22l3r has joined #ruby
pen has quit [Remote host closed the connection]
twidx has quit [Quit: Connection closed for inactivity]
Spami has quit [Quit: This computer has gone to sleep]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
radic_ has quit [Ping timeout: 245 seconds]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
browndawg has joined #ruby
pen has joined #ruby
sputnik13 has quit [Remote host closed the connection]
<zorak8>
erb vs haml vs slime
<zorak8>
now|1
<zorak8>
!
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
<centrx>
haml looks funny, slime sounds funny
<shevy>
I hate end#methods
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
<shevy>
the worst is in optionparser
<shevy>
end.parse! ARGV
radic has joined #ruby
cjsarette has joined #ruby
agjacome has joined #ruby
combusean has quit [Ping timeout: 258 seconds]
lookup has joined #ruby
cj3kim_ has quit [Read error: Connection reset by peer]
Tomasso2 has quit [Read error: Connection reset by peer]
lookup has left #ruby [#ruby]
eka has joined #ruby
cj3kim_ has joined #ruby
braincra- has quit [Quit: bye bye]
Tomasso has joined #ruby
mjs2600 has joined #ruby
Mongey has joined #ruby
HashNuke has joined #ruby
SHyx0rmZ has quit [Ping timeout: 240 seconds]
braincrash has joined #ruby
eka has quit [Ping timeout: 265 seconds]
sweet_cheese_us is now known as paul_k
Kricir has joined #ruby
spyderma_ has joined #ruby
jameswlane has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dik_dak has joined #ruby
cassioscabral has joined #ruby
mjs2600 has quit [Ping timeout: 276 seconds]
Melpaws has quit [Quit: Leaving.]
spyderman4g63 has quit [Ping timeout: 258 seconds]
blackavr has quit [Quit: blackavr]
alexju has quit [Read error: Connection reset by peer]
Kricir has quit [Ping timeout: 245 seconds]
alexju has joined #ruby
cj3kim__ has joined #ruby
Lemur has joined #ruby
_justin has joined #ruby
cj3kim_ has quit [Ping timeout: 240 seconds]
combusean has joined #ruby
tzhuang has joined #ruby
Kricir has joined #ruby
moritzs has joined #ruby
jameswlane has joined #ruby
jameswlane has quit [Client Quit]
cj3kim__ has quit [Remote host closed the connection]
george2 has joined #ruby
yubrew has joined #ruby
Kricir has quit [Ping timeout: 252 seconds]
cjsarette has quit [Ping timeout: 258 seconds]
i_s has joined #ruby
yubrew has quit [Ping timeout: 240 seconds]
nivram80 has joined #ruby
nateberkopec has quit [Quit: Leaving...]
alowerupper has joined #ruby
<alowerupper>
Hi all. I'm having problems installing ruby on rails in gentoo
<alowerupper>
and rubygems
funktor has joined #ruby
<alowerupper>
how should I install them? by package manager or manually?
_justin has quit [Quit: _justin]
yekta has joined #ruby
yfeldblum has joined #ruby
i_s has quit [Ping timeout: 245 seconds]
helpD has joined #ruby
nivram80 has quit [Remote host closed the connection]
Tomasso has quit [Read error: Connection reset by peer]
<centrx>
alowerupper, In Debian, I always use rubygems
<havenwood>
alowerupper: RubyGems comes with modern Rubies. Install Rails with RubyGems.
helpD has quit [Ping timeout: 240 seconds]
Tomasso has joined #ruby
<centrx>
alowerupper, You are going to need to use rubygems to install something anyway, so might as well do it all with rubygems, which also has the up-to-date versions of the gems
<alowerupper>
ah
voglster has joined #ruby
<alowerupper>
centrx: where can I found them both in one package?
luckyruby has joined #ruby
yfeldblum has quit [Remote host closed the connection]
<alowerupper>
I can pull rvm, rails, and gems with command, no?
quitobro has joined #ruby
<centrx>
alowerupper, gem install rails
<havenwood>
alowerupper: Rails is a gem. RubyGems (which provides the `gem` command) ships with Ruby 1.9+). RVM is a tool for installing and managing Rubies other than those provided by your package manager.
<havenwood>
alowerupper: Once you have Ruby you've got RubyGems and can install Rails.
<alowerupper>
havenwood: I have ruby1.9.1 insatalle
tzhuang has quit [Ping timeout: 240 seconds]
<havenwood>
alowerupper: anything before 1.9.3 is past end-of-life, but is it really 1.9.1 or is that just the AMI?
<havenwood>
alowerupper: ruby -v
<alowerupper>
but when I do gem install sth it shows /usr/lib64/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file
<alowerupper>
oh, sorry it's 1.9.3
<havenwood>
alowerupper: and?: gem -v
Azure has quit [Quit: My MBP went to sleep.]
<alowerupper>
/usr/lib64/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- myapp(LoadError)
Azure has joined #ruby
<havenwood>
alowerupper: sry, what are you doing? that is what you get for?: gem install rails
<havenwood>
alowerupper: or you're just showing the load path error you get loading your app?
<alowerupper>
I'm showing the error it throws even when I use the gem command
<alowerupper>
on doing gem list
<alowerupper>
it doesn't show anytihng
<havenwood>
gem -v
<alowerupper>
that means I don't have gem installe?
quitobro has quit [Remote host closed the connection]
<alowerupper>
I'm using gentoo though
<havenwood>
alowerupper: have you installed any gems?
<alowerupper>
okay, the thing is I want it all running because I wants to do course on saas(edx)
r_rios has quit [Ping timeout: 252 seconds]
<havenwood>
so you haven't installed any gems? :P
<alowerupper>
Na, should I install rubygems?
bthesorceror has quit [Ping timeout: 245 seconds]
<havenwood>
alowerupper: lol, please just tell us what you get for?: gem -v
<havenwood>
alowerupper: or?: which gem
<havenwood>
alowerupper: like i keep saying, RubyGems ships with Ruby
<alowerupper>
:~% gem -v /usr/lib64/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- myapp(LoadError) from /usr/lib64/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
<alowerupper>
this is waht I'm getting :/
ghr has joined #ruby
<havenwood>
oh, sry
<havenwood>
what the heck? :O
noop has joined #ruby
omosoj has joined #ruby
<havenwood>
alowerupper: you might have better luck with a more modern Gentoo package for Ruby, hem. i don't know Gentoo.
<havenwood>
alowerupper: looks like emerge has a 2.0 stable package and a 2.1
mary5030 has joined #ruby
<havenwood>
alowerupper: if those packages have a broken RubyGems too, then RVM or ruby-install/chruby would be options.
wallerdev has quit [Quit: wallerdev]
<havenwood>
although.. you'd have to install your own deps with ruby-install
metamaterial has quit [Remote host closed the connection]
bthesorceror has joined #ruby
omosoj has quit [Client Quit]
lw has joined #ruby
<alowerupper>
hmm
<havenwood>
normally ruby-install to /usr/local is good if only need latest stable ruby, but maybe on Gentoo RVM would be a good idea?
wallerdev has joined #ruby
meatherly has joined #ruby
rkr090 has joined #ruby
ghr has quit [Ping timeout: 240 seconds]
hobodave has joined #ruby
Dwarf has quit [Quit: Oops I quit]
Guedes0 has quit [Ping timeout: 276 seconds]
<havenwood>
alowerupper: if you do go RVM i'd highly recommend following RVM's instructions
<havenwood>
alowerupper: not using the package manager to install it
<havenwood>
alowerupper: and be certain to use a single-user install
<havenwood>
alowerupper: good support in #rvm
<alowerupper>
I see
<havenwood>
alowerupper: i'll look at what it would take to add emerge support to ruby-install
<alowerupper>
or other thing I can do is
<alowerupper>
remove current ruby stuff
<alowerupper>
and make it manually?
ehc has quit [Quit: ehc]
<havenwood>
alowerupper: yeah, as long as you install the dependencies a manual build or ruby-install should do the trick
mary5030 has quit [Ping timeout: 250 seconds]
<havenwood>
alowerupper: for automagical, RVM
<alowerupper>
right
metamaterial has joined #ruby
andy__ has quit [Remote host closed the connection]
cassioscabral has quit [Ping timeout: 240 seconds]
thomasxie has joined #ruby
jackyalcine is now known as jacky
Dwarf has joined #ruby
Tomasso has quit [Ping timeout: 276 seconds]
mikeric has quit []
mostlybadfly has joined #ruby
yubrew has joined #ruby
badhatter_ has joined #ruby
lxsameer has joined #ruby
lxsameer has quit [Changing host]
lxsameer has joined #ruby
lw has quit [Quit: s]
jamto11 has joined #ruby
_justin has joined #ruby
butblack has joined #ruby
yubrew has quit [Ping timeout: 240 seconds]
Hobogrammer has quit [Quit: WeeChat 0.4.3]
badhatter has quit [Ping timeout: 258 seconds]
lw has joined #ruby
weems has quit [Read error: Connection reset by peer]
weems has joined #ruby
weems has quit [Changing host]
weems has joined #ruby
diegoviola has joined #ruby
jamto11 has quit [Ping timeout: 265 seconds]
Hobogrammer has joined #ruby
i_s has joined #ruby
armstrjare has joined #ruby
alowerupper has quit [Quit: Page closed]
cassioscabral has joined #ruby
butblack has quit [Quit: butblack]
bradhe has joined #ruby
bradhe has quit [Remote host closed the connection]
bradhe has joined #ruby
bradhe has quit [Remote host closed the connection]
i_s has quit [Ping timeout: 258 seconds]
bousquet has joined #ruby
butblack has joined #ruby
bradhe has joined #ruby
bradhe has quit [Remote host closed the connection]
_justin has quit [Ping timeout: 245 seconds]
afex has joined #ruby
xiella has quit [Ping timeout: 245 seconds]
bradhe has joined #ruby
bradhe has quit [Remote host closed the connection]
xiella has joined #ruby
Celm has joined #ruby
toastynerd has joined #ruby
papercode has quit [Quit: WeeChat 0.4.3]
_justin has joined #ruby
yekta has quit [Quit: yekta]
RaptorJesus has quit [Remote host closed the connection]
RaptorJesus has joined #ruby
papercode has joined #ruby
Celm has quit [Ping timeout: 258 seconds]
combusean has quit [Ping timeout: 258 seconds]
maletor has quit [Quit: Computer has gone to sleep.]
JohnBat26 has joined #ruby
tacos1de_ has joined #ruby
yfeldblum has quit [Read error: Connection reset by peer]
yfeldblum has joined #ruby
tacos1de has quit [Remote host closed the connection]
_justin has quit [Client Quit]
<pontiki>
quietude
<Lemur>
don't kill the mood
<centrx>
...
Morkel has joined #ruby
butblack has quit [Quit: butblack]
locriani has quit [Remote host closed the connection]
locriani has joined #ruby
* pontiki
serves up some groove salad
Doppp has quit [Ping timeout: 240 seconds]
metamaterial has quit [Quit: Leaving.]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
nivram80 has joined #ruby
nivram80 has left #ruby [#ruby]
cpruitt has joined #ruby
browndawg has quit [Ping timeout: 258 seconds]
nari has joined #ruby
ponga has quit [Quit: Leaving :)]
sdouglas has joined #ruby
andy__ has joined #ruby
tectonic has joined #ruby
_justin has joined #ruby
chris_thomson has quit [Quit: Zzz...]
diegoviola has quit [Quit: WeeChat 0.4.3]
Doppp has joined #ruby
Azurazen has joined #ruby
cpruitt has quit [Quit: cpruitt]
afex has quit [Ping timeout: 245 seconds]
mjs2600 has joined #ruby
diegoviola has joined #ruby
meatherly has quit [Read error: Connection reset by peer]
meatherly has joined #ruby
bluehavana has joined #ruby
funktor has quit []
yubrew has joined #ruby
b1nd has quit [Ping timeout: 276 seconds]
_justin has quit [Quit: _justin]
mjs2600 has quit [Ping timeout: 258 seconds]
thomasxie has left #ruby [#ruby]
CaptainJet has quit []
yubrew has quit [Ping timeout: 258 seconds]
Cache_Money has joined #ruby
dik_dak has quit [Quit: Leaving]
centrx has quit [Quit: All this computer hacking is making me thirsty]
kreisys has joined #ruby
bousquet has quit [Remote host closed the connection]
bousquet has joined #ruby
Kricir has joined #ruby
mansi has quit [Remote host closed the connection]
mansi has joined #ruby
badhatter_ has quit [Ping timeout: 250 seconds]
WanderingGlitch has quit [Ping timeout: 250 seconds]
bthesorceror has quit [Remote host closed the connection]
bthesorceror has joined #ruby
caleb_io has joined #ruby
yacks has joined #ruby
caleb_io has quit [Quit: caleb_io]
bousquet has quit [Ping timeout: 240 seconds]
combusean has joined #ruby
Kricir has quit [Ping timeout: 252 seconds]
Doppp has quit [Ping timeout: 265 seconds]
mansi has quit [Ping timeout: 245 seconds]
endash has quit [Quit: endash]
endash_ is now known as endash
cpruitt has joined #ruby
bthesorceror has quit [Ping timeout: 265 seconds]
i_s has joined #ruby
b1nd has joined #ruby
maletor has joined #ruby
helpD has joined #ruby
emaxi has quit [Remote host closed the connection]
i_s has quit [Ping timeout: 245 seconds]
x77686d has quit [Quit: x77686d]
mieko has joined #ruby
kenneth has joined #ruby
pwh has quit []
mjsmith2 has quit []
Celm has joined #ruby
helpD has quit [Ping timeout: 252 seconds]
sdouglas has quit [Remote host closed the connection]
maletor has quit [Quit: Computer has gone to sleep.]
blackavr has joined #ruby
IceDragon has quit [Quit: Space~~~]
cpruitt has quit [Quit: cpruitt]
Celm has quit [Ping timeout: 258 seconds]
vlad_starkov has joined #ruby
pika_pika has quit [Ping timeout: 240 seconds]
noop has quit [Ping timeout: 258 seconds]
badhatter has joined #ruby
badhatter has quit [Changing host]
badhatter has joined #ruby
browndawg has joined #ruby
meatherly has quit [Remote host closed the connection]
kaspergrubbe has joined #ruby
vlad_starkov has quit [Ping timeout: 245 seconds]
_justin has joined #ruby
mansi has joined #ruby
Milly_Bays has joined #ruby
kaspergrubbe has quit [Ping timeout: 250 seconds]
mary5030 has joined #ruby
blackavr has quit [Ping timeout: 252 seconds]
amclain has quit [Quit: Leaving]
diegoviola has quit [Quit: WeeChat 0.4.3]
WanderingGlitch has joined #ruby
mansi has quit [Ping timeout: 245 seconds]
mrnugget has joined #ruby
cassioscabral has quit [Ping timeout: 258 seconds]
pu22l3r has joined #ruby
Robbo_ has quit [Remote host closed the connection]
noop has joined #ruby
andy__ has quit [Remote host closed the connection]
wallerdev has quit [Ping timeout: 265 seconds]
yubrew has joined #ruby
_justin has quit [Quit: _justin]
pu22l3r has quit [Ping timeout: 240 seconds]
wallerdev has joined #ruby
yubrew has quit [Ping timeout: 240 seconds]
wallerdev_ has joined #ruby
ktosiek has joined #ruby
wallerdev has quit [Ping timeout: 258 seconds]
wallerdev_ is now known as wallerdev
phansch has joined #ruby
emaxi has joined #ruby
meatherly has joined #ruby
twiceday has joined #ruby
kenndel has quit [Read error: Connection reset by peer]
bogeyd6 has quit [Read error: Connection reset by peer]
meatherly has quit [Read error: Connection reset by peer]
goodcat has quit [Ping timeout: 258 seconds]
meatherly has joined #ruby
bousquet has joined #ruby
mrgoodcat has joined #ruby
jamto11 has joined #ruby
twiceaday has quit [Ping timeout: 258 seconds]
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
meatherl_ has joined #ruby
Kricir has joined #ruby
emaxi has quit [Ping timeout: 240 seconds]
_justin has joined #ruby
bogeyd6 has joined #ruby
tkuchiki has joined #ruby
meatherly has quit [Ping timeout: 240 seconds]
bousquet has quit [Ping timeout: 240 seconds]
jamto11 has quit [Ping timeout: 240 seconds]
Cache_Money has quit [Quit: Cache_Money]
meatherl_ has quit [Ping timeout: 245 seconds]
Kricir has quit [Ping timeout: 245 seconds]
armstrjare has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
timonv has joined #ruby
combusean has quit [Ping timeout: 252 seconds]
dapz has joined #ruby
i_s has joined #ruby
ponga has joined #ruby
ponga has quit [Changing host]
ponga has joined #ruby
Deele has quit [Ping timeout: 255 seconds]
noop has quit [Ping timeout: 250 seconds]
AlexRussia has quit [Ping timeout: 276 seconds]
eynj has quit [Quit: Leaving.]
mary5030 has quit [Remote host closed the connection]
claymore has joined #ruby
mary5030 has joined #ruby
i_s has quit [Ping timeout: 252 seconds]
alpha123 has quit [Ping timeout: 265 seconds]
arubin has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
alpha123 has joined #ruby
mary5030 has quit [Ping timeout: 276 seconds]
pen has quit [Remote host closed the connection]
goganchic has joined #ruby
timonv has quit [Remote host closed the connection]
<voglster>
how can i return an enumerator that filters another enumerator... i.e. i want to skip the first few values but still use it as an enumerator
vlad_starkov has joined #ruby
lw has quit [Quit: s]
<havenwood>
>> 1.upto(10).select { |n| n > 5 }.to_enum
<Mon_Ouie>
That you don't have to involve procs when using blocks
<Nowaker>
there is a proc during ruby runtime which is an object
<Nowaker>
you just dont hold a reference to it in this code
mr_snowf1ake has quit [Ping timeout: 250 seconds]
Celm has quit [Ping timeout: 258 seconds]
<Nowaker>
but it doesnt mean there is no proc
<Mon_Ouie>
Not necessarily. In fact I believe YARD does not even create it unless you use &block ,etc.
cj3kim_ has quit [Remote host closed the connection]
cj3kim_ has joined #ruby
Soda has quit [Remote host closed the connection]
<Nowaker>
if it doesnt, then there is nothing. when it exists its an object. when it doesnt... well, it doesnt exist. so still, the sentence "everything in ruby is an object" :)
<Nowaker>
is true
<Mon_Ouie>
No, the point of that not being true is that it's not true in the lisp sense of 'code is data'.
<Nowaker>
oh, i agree with that
<Nowaker>
thats absolutely true
yubrew has joined #ruby
marcdel has quit [Read error: Connection reset by peer]
seuros has quit [Ping timeout: 250 seconds]
cj3kim_ has quit [Ping timeout: 265 seconds]
marcdel has joined #ruby
yubrew has quit [Ping timeout: 240 seconds]
dapz has joined #ruby
lw has quit [Quit: s]
sski has quit []
sski has joined #ruby
lkba has quit [Ping timeout: 265 seconds]
crzrcn has joined #ruby
ktun has joined #ruby
dapz has quit [Client Quit]
yfeldblum has joined #ruby
yacks has joined #ruby
ponga has quit [Remote host closed the connection]
emaxi has joined #ruby
phansch has quit [Quit: WeeChat 0.4.2]
timonv has joined #ruby
seuros has joined #ruby
yfeldblum has quit [Ping timeout: 240 seconds]
rofflcopter has joined #ruby
<rofflcopter>
does anyone know how to make a batch file to auto set environment path if im running ruby off a usb?
chipotle has quit [Quit: cya]
emaxi has quit [Ping timeout: 265 seconds]
<rofflcopter>
h
rofflcopter is now known as xeyes
<xeyes>
hi
kyb3r_ has joined #ruby
<xeyes>
s
<xeyes>
hello?
xeyes has quit [Quit: l]
xeyes has joined #ruby
xeyes is now known as roflcopter
anaeem1 has joined #ruby
<roflcopter>
lol
roflcopter is now known as Guest92462
<Guest92462>
hello
<Guest92462>
h
<gry>
hi
<Guest92462>
does anyone know how to set a path variable batch?
<Guest92462>
if im running ruby off a usb, to auto set into the bin file?
mjs2600 has joined #ruby
sski has quit [Read error: Connection reset by peer]
Guest92462 is now known as roflcopter`
<roflcopter`>
l
roflcopter` is now known as roflcopter123
combusean has joined #ruby
shashank_rs has joined #ruby
sski has joined #ruby
JBreit has left #ruby ["Leaving"]
<certainty>
oO
shime has quit [Ping timeout: 240 seconds]
<roflcopter123>
d
<roflcopter123>
a
dapz has joined #ruby
vlad_starkov has joined #ruby
mjs2600 has quit [Ping timeout: 240 seconds]
nateberkopec has joined #ruby
<roflcopter123>
can anyone see this?
<Hanmac>
maybe
<roflcopter123>
do u know how to set environment path via batch file?
<roflcopter123>
if im trying to use ruby off a usb with alot of computers
kyb3r_ has quit [Read error: Connection reset by peer]
koderok has joined #ruby
<certainty>
ultimately you can unroll every function (well at least the pure ones) into a table. A table is data so code is data even in ruby. Sideeffects don't fit well here though :p
browndawg has joined #ruby
kyb3r_ has joined #ruby
ikaros has joined #ruby
vlad_starkov has quit [Ping timeout: 252 seconds]
roflcopter123 has quit [Remote host closed the connection]
meatherly has joined #ruby
timonv has quit [Remote host closed the connection]
luriv has quit [Ping timeout: 245 seconds]
meatherly has quit [Ping timeout: 240 seconds]
etqqkoiflwhb has joined #ruby
kyb3r__ has joined #ruby
blackmesa has joined #ruby
kyb3r__ has quit [Client Quit]
nateberkopec has quit [Quit: Leaving...]
kyb3r_ has quit [Ping timeout: 240 seconds]
helpD has joined #ruby
shashank_rs has quit [Ping timeout: 258 seconds]
shashank_rs has joined #ruby
anaeem1 has quit [Remote host closed the connection]
nateberkopec has joined #ruby
_justin has joined #ruby
einarj has joined #ruby
i_s has joined #ruby
zigomir has joined #ruby
zigomir_ has joined #ruby
zigomir has quit [Read error: Connection reset by peer]
luriv has joined #ruby
i_s has quit [Ping timeout: 258 seconds]
jack_rabbit has joined #ruby
andrewlio has joined #ruby
_justin has quit [Quit: _justin]
shashank_rs has quit [Ping timeout: 258 seconds]
anaeem1_ has joined #ruby
LiohAu has quit [Quit: LiohAu]
crzrcn has quit [Quit: Leaving.]
nateberkopec has quit [Quit: Leaving...]
dorji has joined #ruby
dorji has left #ruby [#ruby]
senayar has quit [Remote host closed the connection]
<apeiros>
certainty: just that that table might be infinite in size :)
<certainty>
apeiros: yepp :)
vui has joined #ruby
kaspergrubbe has joined #ruby
<vui>
what mediaplayer is written in ruby?
<certainty>
i'm not aware of one
<vui>
certainty, at least a music player ?
emaxi has joined #ruby
koderok has quit [Ping timeout: 265 seconds]
<certainty>
vui: nope. What does your search engine of choice reveal?
ghr has joined #ruby
vui has quit [Remote host closed the connection]
emaxi has quit [Ping timeout: 240 seconds]
ironsand has joined #ruby
luriv has quit [Ping timeout: 252 seconds]
yfeldblum has joined #ruby
robbyoconnor has quit [Read error: Connection reset by peer]
WanderingGlitch has quit [Ping timeout: 276 seconds]
phoo1234567 has joined #ruby
ironsand has joined #ruby
yfeldblum has quit [Ping timeout: 258 seconds]
decoponyo has joined #ruby
ndngvr has joined #ruby
rylev has joined #ruby
AlSquirrel has joined #ruby
rodasc has joined #ruby
mven_ has joined #ruby
AlexRussia has joined #ruby
Nilium has quit [Disconnected by services]
marcdel_ has joined #ruby
Nilium has joined #ruby
nomadic_ has joined #ruby
RowdyChiz has joined #ruby
iaj_ has joined #ruby
ironsand has quit [Ping timeout: 240 seconds]
blackmesa has joined #ruby
sambao21 has joined #ruby
baweaver has joined #ruby
pu22l3r has quit [Remote host closed the connection]
myke_ has joined #ruby
emdub_ has joined #ruby
perry has joined #ruby
jdahm_ has joined #ruby
bricker_ has joined #ruby
eval-in__ has joined #ruby
<certainty>
ph88: normally methods ending in ! indicate that they're useful because of their side-effect and not their return value. I can imagine that this particular method is named this way because it sets the @bitset ivar
perry is now known as Guest95164
renier has quit [Read error: Connection reset by peer]
_justin has quit [Ping timeout: 250 seconds]
renier has joined #ruby
chihhsin1wego has joined #ruby
<ph88>
ok thx certainty , i have another question though
<certainty>
that's just a guess though and also that convention is not followed rigidly
Killerkeksdose_ has joined #ruby
axisys_ has joined #ruby
<ph88>
how can unpack be called on a hash ?
[BNC]pagioss has joined #ruby
haroldwu_ has joined #ruby
jonathanwallace_ has joined #ruby
agjacome has quit [Ping timeout: 250 seconds]
<certainty>
ph88: i don't know. I only know String#unpack
arietis has quit [Quit: Computer has gone to sleep.]
mosez has quit [Ping timeout: 252 seconds]
browndawg has joined #ruby
popl has quit [Ping timeout: 258 seconds]
blackmesa has quit [Ping timeout: 250 seconds]
_tpavel has joined #ruby
_tpavel has quit [Client Quit]
_tpavel has joined #ruby
yfeldblum has joined #ruby
_tpavel has quit [Client Quit]
_tpavel has joined #ruby
mosez has joined #ruby
chrisseaton has quit []
arietis has joined #ruby
_tpavel has quit [Client Quit]
_tpavel has joined #ruby
_sambao21 has joined #ruby
_tpavel has quit [Client Quit]
_tpavel has joined #ruby
weems has quit [Read error: Connection reset by peer]
weems has joined #ruby
weems has quit [Changing host]
weems has joined #ruby
sambao21 has quit [Ping timeout: 276 seconds]
yfeldblum has quit [Ping timeout: 252 seconds]
AntelopeSalad has quit [Read error: Connection reset by peer]
Martxel has quit [Read error: Connection reset by peer]
AntelopeSalad has joined #ruby
_tpavel has quit [Client Quit]
_tpavel has joined #ruby
kyle_ has joined #ruby
_tpavel has quit [Remote host closed the connection]
_tpavel has joined #ruby
sski has quit [Remote host closed the connection]
_tpavel has quit [Client Quit]
sski has joined #ruby
Iniesta8 has joined #ruby
Dwarf has quit [Ping timeout: 245 seconds]
_justin has quit [Quit: _justin]
sski has quit [Ping timeout: 245 seconds]
kyle_ has quit [Ping timeout: 245 seconds]
timonv has quit [Remote host closed the connection]
<certainty>
rdgawdzi: i don't think that that's the correct answer to the code you showed. You're shifting the values into the arrays at two different places. It's more along the lines: Hash.new([]).tap{ |h| h[:one] << "uno"; h[:one] << "dos" }; ...
yubrew has joined #ruby
Guest99456 is now known as msch
<shevy>
In the past I often wrote
<shevy>
code more
<shevy>
now I have changed my mind
gry has left #ruby [#ruby]
<shevy>
code less
anaeem1_ has joined #ruby
<certainty>
shevy: that's good. You progress :)
_justin has joined #ruby
mikecmpbll has joined #ruby
anaeem___ has joined #ruby
arietis has quit [Quit: Computer has gone to sleep.]
AlexRussia has quit [Remote host closed the connection]
AlexRussia has joined #ruby
<shevy>
hmm
<shevy>
does ruby have a useful math library in regards to statistics? but also including generating graphs
yubrew has quit [Ping timeout: 276 seconds]
anaeem1_ has quit [Ping timeout: 240 seconds]
kyle_ has joined #ruby
jxf has joined #ruby
<certainty>
shevy: i bet it has R-bindings
<shevy>
hehe
<shevy>
I am trying to not have to use R!
anaeem___ has quit [Ping timeout: 245 seconds]
<certainty>
shevy: well then probably an octave binding
kitak has quit [Remote host closed the connection]
kitak_ has joined #ruby
randomnick_ has joined #ruby
srji has quit [Quit: leaving]
pika_pika has joined #ruby
Iniesta8 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
arianit has joined #ruby
arianit has quit [Changing host]
arianit has joined #ruby
ashleyis1 has joined #ruby
Royalb15 has quit [Read error: Connection reset by peer]
<shevy>
ph88 well not completely, a constant in ruby must start with upcased character, like Foo
jamto11 has joined #ruby
<shevy>
you can have symbol :Foo too but it will be a symbol, not a constant
linojon has joined #ruby
<ph88>
:/
<shevy>
ph88 if it helps you, you can think of :run as a faster version of 'run' :D
seuros has quit [Ping timeout: 252 seconds]
emaxi has joined #ruby
`MArceLL` has quit [Ping timeout: 246 seconds]
CorpusCallosum has quit [Ping timeout: 250 seconds]
jamto11 has quit [Ping timeout: 240 seconds]
evenix_ has joined #ruby
evenix has joined #ruby
decoponio has joined #ruby
kaspergrubbe has quit [Remote host closed the connection]
i_s has joined #ruby
<apeiros>
ph88: a constant is a kind of variable. variables reference objects
<apeiros>
ph88: a symbol is a kind of object
<apeiros>
and :foo is a symbol literal. just like "foo" is a string literal, and 12 is an integer literal
emaxi has quit [Ping timeout: 245 seconds]
nfk has quit [Remote host closed the connection]
ashleyis1 has joined #ruby
nfk has joined #ruby
decoponyo has quit [Ping timeout: 258 seconds]
Solnse has joined #ruby
evenix has quit [Remote host closed the connection]
evenix_ has quit [Remote host closed the connection]
mrmargolis has joined #ruby
evenix has joined #ruby
evenix_ has joined #ruby
pika_pika has quit [Ping timeout: 240 seconds]
i_s has quit [Ping timeout: 240 seconds]
zigomir has quit [Remote host closed the connection]
advorak has quit [Ping timeout: 258 seconds]
tesuji has quit [Ping timeout: 240 seconds]
evenix has quit [Ping timeout: 252 seconds]
evenix_ has quit [Ping timeout: 258 seconds]
mrmargolis has quit [Ping timeout: 258 seconds]
pu22l3r has quit [Remote host closed the connection]
luriv has quit [Ping timeout: 240 seconds]
<gizmore>
#rails is invite only? Oo
GlenK has joined #ruby
Celm has joined #ruby
einarj has joined #ruby
<GlenK>
hi. coming from C/C++ I'm still struggling with doing things the ruby way. I'm thinking this loop is sucky, and maybe someone could give me some pointers? http://fpaste.org/95388/
banister has joined #ruby
<apeiros>
gizmore: no, but you need to be registered
<apeiros>
that is, your nick, on freenode
<gizmore>
> You are already logged in as Gizmore.
<apeiros>
GlenK: the ruby way starts with using gist ;-p
<GlenK>
apeiros: I don't follow
<apeiros>
GlenK: gist.github.com instead of fpaste.org
<apeiros>
each_line will stop at EOF, puts call to_s on the arguments passed
<apeiros>
line.chomp.split.map(&:to_i) is IMO quite OK too
<apeiros>
I wrote a different version just to show an alternative. I'd probably prefer chomp.split
Celm has quit [Ping timeout: 258 seconds]
<apeiros>
ah, and puts appends a newline
<GlenK>
nice, thanks. assuming I want to throw away the first line...?
einarj has quit [Ping timeout: 276 seconds]
<apeiros>
oh
<apeiros>
tricky, but can do
<apeiros>
lines = $stdin.each_line; lines.next; lines.each do |line| …
<GlenK>
I was just going with simply "gets"
davedev2_ has quit [Ping timeout: 240 seconds]
<apeiros>
actually…
<apeiros>
you can just use the code I wrote and prepend a `gets`
<apeiros>
yeah
<GlenK>
sweet. thanks a lot
bousquet has quit [Ping timeout: 245 seconds]
tkuchiki has quit [Remote host closed the connection]
jetblack has quit [Quit: leaving]
jetblack has joined #ruby
_tpavel has joined #ruby
charlies_ has joined #ruby
Es0teric_ has joined #ruby
_tpavel has quit [Client Quit]
AZen has quit []
charliesome has quit [Ping timeout: 240 seconds]
donnoc has joined #ruby
Es0teric has quit [Ping timeout: 250 seconds]
noop has quit [Ping timeout: 276 seconds]
lukec has quit [Quit: lukec]
skulker has quit []
luriv has joined #ruby
mikecmpbll has quit [Read error: Connection reset by peer]
skulker has joined #ruby
skulker has quit [Client Quit]
<GlenK>
apeiros: so I'm doing this programming practice thing called code abbey. This particuclar problem was to sum the numbers on each line. Once you solve whatever then you can view other people's solutions.
_tpavel has quit [Read error: Connection reset by peer]
shime has quit [Ping timeout: 252 seconds]
<GlenK>
some other guys solution. haha, I guess what I'm trying to say, even coming from C, maybe my ruby isn't too terrible at this point. haha. Anyhow, cheers.
_tpavel has joined #ruby
cina has quit [Remote host closed the connection]
cina has joined #ruby
danshultz has joined #ruby
yfeldblum has joined #ruby
mikecmpbll has quit [Read error: Connection reset by peer]
seuros has joined #ruby
_tpavel has quit [Client Quit]
Speed has joined #ruby
jxf has quit [Ping timeout: 250 seconds]
sski has quit [Remote host closed the connection]
ziyadb_ has quit [Quit: Connection closed for inactivity]
shashank_rs has quit [Ping timeout: 258 seconds]
vlad_starkov has joined #ruby
noop has joined #ruby
mikecmpbll has joined #ruby
kaspergrubbe has joined #ruby
Dwarf has joined #ruby
sski has joined #ruby
yubrew has joined #ruby
cina has quit [Remote host closed the connection]
Dwarf has quit [Client Quit]
yfeldblum has quit [Ping timeout: 240 seconds]
s3ri0us has joined #ruby
arietis has joined #ruby
sski has quit [Ping timeout: 240 seconds]
skulker has joined #ruby
skulker has left #ruby [#ruby]
WilfredTheGreat has joined #ruby
yubrew has quit [Ping timeout: 252 seconds]
Guedes0 has quit [Ping timeout: 245 seconds]
mjs2600 has joined #ruby
jason_ has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
<The_NetZ>
Hanmac: will; in fact this is a question related to our respective projects
<The_NetZ>
Hanmac: see, I just need to be certain that the object is available on both sides
bbloom has quit [Ping timeout: 250 seconds]
<Hanmac>
for good working with ruby the C++ class need to have a 2-step constructor or similar, that means: DefaultConstructor + Create/Init or other method
<shevy>
a mirror!
s3ri0us has quit [Quit: Leaving...]
Kricir has quit [Remote host closed the connection]
<The_NetZ>
Hanmac: so, Foo::Foo and Foo::new(Foo::Foo(args)) or something like that?
Lightstalker has quit [Quit: leaving]
<The_NetZ>
and define the initialize method as the Foo::new method?
ashleyis1 has joined #ruby
ktosiek has quit [Ping timeout: 240 seconds]
i_s has quit [Ping timeout: 258 seconds]
tesuji has joined #ruby
linojon has quit [Quit: linojon]
poguez_ has quit [Quit: Connection closed for inactivity]
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
benzrf|offline is now known as benzrf
<Hanmac>
The_NetZ: see this class: http://docs.wxwidgets.org/trunk/classwx_image.html#a37e70a8f9c684974c9c54f43f5e60a3f ... look at the Create methods and see how they look like the Constructors (because the other constructors are calling the Create methods) ... your class need that too so the init method you define can call the Create methods
helpD has quit [Remote host closed the connection]
<The_NetZ>
Hanmac: interesting
helpD has joined #ruby
<benzrf>
maaan
<The_NetZ>
benzrf: ?
jameswlane has joined #ruby
jameswlane has quit [Max SendQ exceeded]
omosoj has quit [Ping timeout: 240 seconds]
jameswlane has joined #ruby
<shevy>
when do you guys use @ivars
<shevy>
and when do you guys instead use a hash
<shevy>
that acts @ivar-like
<The_NetZ>
¯\(º_o)/¯
Morkel_ has joined #ruby
<shevy>
I am having a Character class that has a bunch of data - inventory, armours, money, char-growth related attributes etc... right now I keep track of these in @ivars
Morkel has quit [Ping timeout: 240 seconds]
Morkel_ is now known as Morkel
x77686d has joined #ruby
helpD has quit [Ping timeout: 245 seconds]
Celm has joined #ruby
<canton7>
I don't like using a dictionary when I should have something explicit. in your example, I'd definitely stay clear of a dictionary
<canton7>
s/dictionary/hash/
butblack has quit [Quit: butblack]
sepp2k has quit [Quit: Leaving.]
<benzrf>
canton7: new to ruby from python?
<benzrf>
:-)
etqqkoiflwhb has quit [Ping timeout: 252 seconds]
<shevy>
benzrf did you get that guy that thinks getting a PM from you is like winning an oscar?
butblack has joined #ruby
<benzrf>
i read the logs ;-;
<benzrf>
u hurt my feelings
ace_striker has joined #ruby
kies has quit [Quit: baaaaiiiiiiiiiii~]
ace_striker has quit [Changing host]
ace_striker has joined #ruby
ace_striker has joined #ruby
ace_striker has quit [Changing host]
<benzrf>
shevy: perhaps you could create classes for some of these sets of ivars
<benzrf>
like inventory n stuff
Celm has quit [Ping timeout: 258 seconds]
<benzrf>
then have fewer ivars & delegate some methods
<benzrf>
sounds like it might be a bit of a god object atm
<benzrf>
also im 17 not 16 >:{
ashleyis1 has quit [Ping timeout: 258 seconds]
etqqkoiflwhb has joined #ruby
<shevy>
well the classes would then have to store the data in an @ivar or?
<benzrf>
well yeah
<benzrf>
but it would be /their/ ivar
momomomomo has joined #ruby
<canton7>
benzrf, do a lot of C#
<benzrf>
if u have more than like 5-7 ivars ur probably seeing a god object</baseless_opinion>
jason_ has joined #ruby
jason_ has quit [Remote host closed the connection]
sigurding has quit [Quit: sigurding]
<benzrf>
well, a mild one
jason_ has joined #ruby
<canton7>
demigod object
<benzrf>
i like that one
<benzrf>
you could at least use a struct to store some of them
<benzrf>
grouping tends to make things more compartmentalized
<benzrf>
by definition!
sdouglas has joined #ruby
butblack has quit [Quit: butblack]
mansi has joined #ruby
sigurding has joined #ruby
yubrew has joined #ruby
jason_ has quit [Ping timeout: 276 seconds]
banister has joined #ruby
freerobby has joined #ruby
r_rios has quit [Quit: No Ping reply in 180 seconds.]
<mozzarella>
I want to code a website in ruby… not sure if I should use rails or sinatra
butblack has joined #ruby
arianit has quit [Quit: Ex-Chat]
cina has joined #ruby
Royalb15_1 has joined #ruby
sdouglas has quit [Ping timeout: 240 seconds]
rylev has joined #ruby
<shevy>
mozzarella sinatra!
<shevy>
because it is super simple
<shevy>
and padrino I suppose if you need more, but I have not used that one yet
havenwood has joined #ruby
butblack has quit [Client Quit]
yubrew has quit [Ping timeout: 240 seconds]
jameswlane has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
freerobby has quit [Ping timeout: 252 seconds]
cina has quit [Remote host closed the connection]
`MArceLL` has joined #ruby
Kricir has joined #ruby
cina has joined #ruby
koderok has joined #ruby
etqqkoiflwhb has quit [Quit: Computer has gone to sleep.]
quitobro has quit [Remote host closed the connection]
bousquet has quit [Remote host closed the connection]
etqqkoiflwhb has joined #ruby
bousquet has joined #ruby
evenix has joined #ruby
evenix_ has joined #ruby
ehc has quit [Quit: ehc]
cina has quit [Remote host closed the connection]
jason_ has joined #ruby
jason_ has quit [Remote host closed the connection]
robbyoconnor has quit [Ping timeout: 276 seconds]
jason_ has joined #ruby
omosoj has joined #ruby
Iniesta8 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
bousquet has quit [Read error: Connection reset by peer]
mary5030 has joined #ruby
SonicX has joined #ruby
bousquet has joined #ruby
klaut has joined #ruby
banister has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
momomomomo has quit [Quit: momomomomo]
jason_ has quit [Ping timeout: 240 seconds]
cj3kim has joined #ruby
quitobro has joined #ruby
cj3kim has quit [Remote host closed the connection]
Iniesta8 has joined #ruby
mary5030 has quit [Ping timeout: 258 seconds]
cina has joined #ruby
robbyoconnor has joined #ruby
etqqkoiflwhb has quit [Ping timeout: 245 seconds]
<mozzarella>
I'll use padrino I think
cina has quit [Remote host closed the connection]
andrewlio has joined #ruby
mjs2600_ has joined #ruby
etqqkoiflwhb has joined #ruby
Kricir has quit [Remote host closed the connection]
sigurding has quit [Quit: sigurding]
mercwithamouth has quit [Ping timeout: 276 seconds]
quitobro has quit [Ping timeout: 240 seconds]
<pontiki>
padrino is sinatra with a bunch of stuff strapped on
mjs2600_ has quit [Ping timeout: 276 seconds]
evenix_ has quit [Remote host closed the connection]
evenix has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 245 seconds]
evenix_ has joined #ruby
evenix has joined #ruby
r_rios has joined #ruby
meatherly has joined #ruby
robbyoconnor has quit [Excess Flood]
eka_ has joined #ruby
robbyoconnor has joined #ruby
eka has quit [Ping timeout: 240 seconds]
cina has joined #ruby
lukec has joined #ruby
<shevy>
mhhm
<shevy>
straps
HashNuke has quit [Quit: Connection closed for inactivity]
s00pcan has quit [Quit: Lost terminal]
kevinykchan has joined #ruby
evenix_ has quit [Ping timeout: 276 seconds]
evenix has quit [Ping timeout: 276 seconds]
CaptainJet has joined #ruby
meatherly has quit [Ping timeout: 252 seconds]
helpD has joined #ruby
donnoc has quit [Ping timeout: 240 seconds]
etqqkoiflwhb has quit [Ping timeout: 250 seconds]
<pontiki>
stapon
cina has quit [Remote host closed the connection]
s00pcan has joined #ruby
ktosiek has joined #ruby
cina has joined #ruby
combusean has joined #ruby
kitak has joined #ruby
etqqkoiflwhb has joined #ruby
diegoviola has joined #ruby
cina has quit [Remote host closed the connection]
<mozzarella>
is it bad to use sqlite in production?
<ddv>
yes
<mozzarella>
how is it bad?
<ezrios>
mozzarella: no concurrency
kitak has quit [Ping timeout: 240 seconds]
mansi has quit [Remote host closed the connection]
banister has joined #ruby
combusean has quit [Ping timeout: 240 seconds]
advorak has joined #ruby
einarj has quit [Remote host closed the connection]
i_s has joined #ruby
phoo1234567 has quit [Quit: Leaving]
gregf has joined #ruby
einarj has joined #ruby
<pontiki>
i think that really also depends on what your production environment is going to be
<pontiki>
but if you're opening it to the internet, then you do need to use something other than sqlite
phoo1234567 has joined #ruby
Cache_Money has joined #ruby
tesuji has quit [Ping timeout: 258 seconds]
The_NetZ has left #ruby ["For a good time, try: 'curl -L http://bit.ly/10hA8iC | bash' ;)"]
wpaulson has joined #ruby
<shevy>
:(
enebo has joined #ruby
sepp2k has joined #ruby
<pontiki>
why sadface, shevy ?
i_s has quit [Ping timeout: 258 seconds]
<guardian>
hello, tried to ask in #nokogiri but it's quiet so far
<guardian>
is there a difference between xml = Nokogiri::XML(contents) and xml = Nokogiri::XML.parse(contents)
<benzrf>
guardian: Nokogiri::XML(foo) is really Nokogiri.XML(foo)
<benzrf>
it's a method named XML, same as the subconstant XML
<benzrf>
misleading >.<
_justin has quit [Ping timeout: 240 seconds]
yubrew has joined #ruby
<havenwood>
bad chainsaw, no cookie!
puzanov has joined #ruby
shashank_rs has quit [Ping timeout: 258 seconds]
kevinykchan has quit [Quit: Computer has gone to sleep.]
sdouglas has joined #ruby
tzhuang has quit [Read error: Connection reset by peer]
yubrew has quit [Ping timeout: 276 seconds]
wald0 has quit [Quit: Lost terminal]
Nikolas has joined #ruby
cassioscabral has quit [Ping timeout: 252 seconds]
Nikolas has quit [Client Quit]
Nikolas has joined #ruby
tesuji has joined #ruby
freerobby has joined #ruby
Solnse has quit [Quit: Leaving.]
<pontiki>
shevy, no less than you
<pontiki>
i happen to really love sqlite
<Nikolas>
kai edw elines
<Nikolas>
fantasou
<pontiki>
i just would not use it to back a rails app in an internet environment
robbyoconnor has joined #ruby
michael_lee has quit [Quit: Ex-Chat]
etqqkoiflwhb has quit [Ping timeout: 252 seconds]
sdouglas has quit [Ping timeout: 240 seconds]
pu22l3r has quit [Remote host closed the connection]
robbyoconnor has quit [Excess Flood]
jaffery has joined #ruby
robbyoconnor has joined #ruby
etqqkoiflwhb has joined #ruby
freerobby has quit [Ping timeout: 258 seconds]
<jaffery>
what's a good tool in ruby to go scrape websites? nokogiri is great for parsing HTML, but should I use something else for scraping?
Nikolas has quit []
iamjarvo has quit [Ping timeout: 245 seconds]
gregf has quit [Quit: WeeChat 0.4.3]
yfeldblu_ has joined #ruby
Fretta has joined #ruby
arubin has joined #ruby
chipotle has quit [Quit: cya]
Celm has quit [Remote host closed the connection]
robbyoconnor has quit [Ping timeout: 240 seconds]
robbyoconnor has joined #ruby
diegoviola has quit [Quit: WeeChat 0.4.3]
yfeldblum has quit [Ping timeout: 240 seconds]
linojon has joined #ruby
boshhead has joined #ruby
robbyoconnor has quit [Excess Flood]
rippa has joined #ruby
butblack has quit [Quit: butblack]
robbyoconnor has joined #ruby
ace_striker has quit [Ping timeout: 240 seconds]
_justin has joined #ruby
ndrei has quit [Ping timeout: 240 seconds]
Celm has joined #ruby
<havenwood>
jaffery: ever tried Mechanize?
lw has joined #ruby
<benzrf>
mechanize is p sweet
mansi has joined #ruby
coderhs has joined #ruby
coderhs has quit [Remote host closed the connection]
idiocrash has joined #ruby
Soda has quit [Remote host closed the connection]
bousquet has quit []
jason_ has joined #ruby
sungai_keruh has joined #ruby
butblack has joined #ruby
Rickmasta has quit [Remote host closed the connection]
yacks has joined #ruby
robbyoconnor has quit [Ping timeout: 245 seconds]
BSaboia has joined #ruby
etqqkoiflwhb has quit [Quit: Computer has gone to sleep.]
jason_ has quit [Ping timeout: 252 seconds]
shashank_rs has joined #ruby
etqqkoiflwhb has joined #ruby
jamto11 has joined #ruby
WanderingGlitch has joined #ruby
<benzrf>
jesus christ why do people use js on the backend in this day and age
caleb_io has joined #ruby
<benzrf>
i justinmcp_
<benzrf>
*just
<benzrf>
want to talk to somebody who looked at node.js and thought 'wow that sounds like a good idea'
<benzrf>
without it turning into a flame war
<benzrf>
and find out what the fuck is happening in their head
funktor has joined #ruby
toastynerd has joined #ruby
pika_pika has quit [Ping timeout: 240 seconds]
pu22l3r has joined #ruby
Rickmasta has joined #ruby
jamto11 has quit [Ping timeout: 276 seconds]
senayar has joined #ruby
i_s has joined #ruby
zets has joined #ruby
pu22l3r has quit [Ping timeout: 240 seconds]
rippa has quit [Ping timeout: 240 seconds]
s00pcan has quit [Quit: Lost terminal]
s00pcan has joined #ruby
_justin has quit [Quit: _justin]
blischalk has joined #ruby
i_s has quit [Ping timeout: 245 seconds]
_sambao21 has joined #ruby
ndrei has joined #ruby
gregf has joined #ruby
blackmesa has joined #ruby
yubrew has joined #ruby
enebo has quit [Quit: enebo]
pu22l3r has joined #ruby
crzrcn has joined #ruby
dapz has joined #ruby
blischalk has quit [Quit: Leaving]
freerobby has joined #ruby
senayar has quit [Remote host closed the connection]
eka_ has quit [Quit: My computer has gone to sleep. ZZZzzz…]
yubrew has quit [Ping timeout: 240 seconds]
advorak has quit [Ping timeout: 240 seconds]
lyanchih_ has quit [Quit: lyanchih_]
sepp2k1 has joined #ruby
ktosiek_ has joined #ruby
pu22l3r has quit [Ping timeout: 276 seconds]
idiocrash has quit [Ping timeout: 276 seconds]
ktosiek has quit [Ping timeout: 276 seconds]
sepp2k has quit [Ping timeout: 250 seconds]
<jaffery>
havenwood: I haven't, is that the way to go?
butblack has quit [Quit: butblack]
Morkel_ has joined #ruby
lolmaus has quit [Ping timeout: 245 seconds]
hobodave_ has joined #ruby
rylev has quit [Remote host closed the connection]
<jaffery>
Next question: I have 'p = Time.now.hour; q= nil; q.now.hour', I would like a way to call q.now.hour and return 'nil' instead of giving me a NoMethodError for NilClass. How would I do that?
Jeticus has joined #ruby
wallerdev has quit [Read error: Connection reset by peer]
<havenwood>
jaffery: it integrates with Nokogiri and gets the job done. there are a number of other good HTTP clients that don't automate so much. also there are a number of web crawlers/spiders.
drPoggs has quit [Ping timeout: 258 seconds]
jenrzzz has quit [Ping timeout: 258 seconds]
<havenwood>
jaffery: pick your poison!
<havenwood>
jaffery: depends somewhat on what type of scraping
CaptainJet has quit [Remote host closed the connection]
jenrzzz has joined #ruby
adam12 has quit [Ping timeout: 258 seconds]
Klumben has quit [Ping timeout: 258 seconds]
Morkel has quit [Ping timeout: 258 seconds]
Morkel_ is now known as Morkel
hobodave has quit [Ping timeout: 258 seconds]
adam_ has joined #ruby
drPoggs has joined #ruby
kitak_ has quit [Remote host closed the connection]
enriclluelles has joined #ruby
Lightsword has joined #ruby
kitak has joined #ruby
bogeyd6 has joined #ruby
<havenwood>
>.>
<havenwood>
jaffery: don't
Klumben has joined #ruby
funktor has quit []
<havenwood>
>> class Object; def now; nil end; def hour; nil end end; # omgwtfbbq; nil.now.hour
<Lightsword>
How do I timeout this net-ssh connection cleanly? I'm changing the IP on the device so the connection closes before a response is received and the script freezes https://gist.github.com/jameshilliard/11094016
gregf has quit [Remote host closed the connection]
enriclluelles has quit [Remote host closed the connection]
<jaffery>
Well, I really just wanted to avoid doing a lot of if/else statements. I know that I want nil in the end if going down q.now.hour.etc.etc.etc is undefined
<jaffery>
Something akin to a CSS selector would be good, too
etqqkoiflwhb has quit [Ping timeout: 252 seconds]
<shevy>
jaffery case menu!
_sambao21 has quit [Quit: Computer has gone to sleep.]
<shevy>
jaffery problem is, if your object does not have these methods, it will raise an error
<shevy>
adding methods to nil is weird
<havenwood>
Lightsword: Is it exceptional for it to fail? You could wrap it in a Timeout block.
<jaffery>
this is true. In my case, I only have some Times (which can sometimes be nil), but I want to access the 'hour' field on all of them
<zets>
you can usually avoid doing lots of if/else by using short-circuit evaluation
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
<Lightsword>
havenwood: is that the right way to use a timeout block?
<zets>
like foo.now && foo.now.hour or something
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
Cache_Money has quit [Quit: Cache_Money]
saarinen has quit [Quit: saarinen]
eka has joined #ruby
cassioscabral has joined #ruby
<shevy>
yeah but he wants to invoke q.now.hour.etc.etc.etc
cj3kim has joined #ruby
sambao21 has joined #ruby
mjs2600_ has joined #ruby
ktun has joined #ruby
vlad_starkov has joined #ruby
gregf has joined #ruby
kinginky__ has joined #ruby
cj3kim has quit [Remote host closed the connection]
mjs2600_ has quit [Ping timeout: 276 seconds]
robbyoconnor has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
havenwood has quit [Remote host closed the connection]
iamjarvo has joined #ruby
havenwood has joined #ruby
<kinginky__>
this is really strange. i have an elsif tree doing an is_a?() check on a value. it passes by is_a?(Array), hits the final else, and then outputs the class of the value (Array). here's paste http://pastebin.com/NpPRneXJ
mostlybadfly has quit [Quit: Connection closed for inactivity]
george2 has quit [Quit: No Ping reply in 180 seconds.]
<kinginky__>
output: "what in Hash? Array" when it hits the array. it should be "call Array new in Hash"
<zorak8>
how can i mae a "Date" that only care about the hour
<zorak8>
or is better a Time?
srji has quit [Remote host closed the connection]
Celm has quit [Remote host closed the connection]
<BraddPitt>
Time.now.hour
<zorak8>
but, especific time
kies has joined #ruby
kies has quit [Changing host]
kies has joined #ruby
<zorak8>
i need to compare if Time.now is > that 4am
centrx has quit [Quit: All this computer hacking is making me thirsty]
rylev has joined #ruby
metamaterial has joined #ruby
einarj has quit [Remote host closed the connection]
einarj has joined #ruby
centrx has joined #ruby
replay_ has joined #ruby
wallerdev has joined #ruby
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
moritzs has joined #ruby
dapz has joined #ruby
iamjarvo has quit [Ping timeout: 245 seconds]
quitobro has joined #ruby
eynj has joined #ruby
s3ri0us has joined #ruby
rylev has quit [Ping timeout: 252 seconds]
epinorian has joined #ruby
replay has quit [Ping timeout: 264 seconds]
metamaterial has quit [Remote host closed the connection]
kitak has quit [Remote host closed the connection]
<epinorian>
What's the best way to handle returned 404 or 503 errors sent from an api? Both nokogiri and octokit throw them when contacting a url that doesn't exist.
iamjarvo has joined #ruby
kitak has joined #ruby
combusean has joined #ruby
<epinorian>
I could do it with an exception, but there has to be a better way. I've always been told exceptions just cover up bad code.
<guardian>
I'm using Nokogiri for the first time, is there a way to avoid typing lenghty Nokogiri::XML::Node::SaveOptions::AS_XML and just type AS_XML instead?
<guardian>
otherwise combining saving options makes long long lines
replay_ has quit [Ping timeout: 240 seconds]
metamaterial has joined #ruby
moritzs has quit [Remote host closed the connection]
<benzrf>
guardian: u could make a method
eynj has quit [Ping timeout: 240 seconds]
<Tricon>
epinorian: It depends on how you want your app to respond. It's okay to raise a 404 or 503 if that is how you want it to respond to the user or system.
ashleyis1 has joined #ruby
moritzs has joined #ruby
replay has joined #ruby
kaspergr_ has joined #ruby
<epinorian>
Tricon: I'm basically storing a ton of info from the return into a db. I just wanna ignore it if it doesn't return anything. So raising an exception there isn't hacky?
moritzs has quit [Read error: Connection reset by peer]
<Tricon>
epinorian: You could simply exit the method that polls for the data on those returns.
Azure has quit [Quit: My MBP went to sleep.]
<Tricon>
epinorian: The rule of thumb is that exceptions should be exceptional.
<havenwood>
epinorian: there's nothing wrong with using exceptions in exceptional circumstances. just don't use them for flow control.
<Tricon>
epinorian: It doesn't sound like your app depends upon the returned data, thus I would'n recommend making this an exception.
<Tricon>
*wouldn't
Guedes0 has quit [Ping timeout: 240 seconds]
kaspergrubbe has quit [Ping timeout: 252 seconds]
<epinorian>
I doesn't, but I'm making a ton of requests for it in a loop. It throws an error and stops it entirely. Do you know of a way to check if it's an error before it's thrown? That way I could use a conditional.
<epinorian>
*It
<Tricon>
Catch the error and degrade gracefully.
Donations has joined #ruby
maroloccio has joined #ruby
einarj has quit [Remote host closed the connection]
toastynerd has quit [Remote host closed the connection]
<epinorian>
Hmmm, never used a catch before either, I'll read into it. Thanks Tricon and havenwood!
einarj has joined #ruby
<Tricon>
epinorian: Sure thing. Feel free to reach out for more help. Catch would be most elegant for what you are describing.
toastynerd has joined #ruby
skaflem2 has joined #ruby
Celm has quit [Remote host closed the connection]
funktor has joined #ruby
george2 has quit [Remote host closed the connection]
george2 has joined #ruby
combusean has quit [Ping timeout: 240 seconds]
jameswlane has joined #ruby
AlexRussia has quit [Ping timeout: 250 seconds]
<Donations>
Due to popular demand, Freenode is in the process of upgrading its servers to handle more bandwidth. This has put added costs on our organization and it has been a struggle. For those interested in helping, a small donation to Freenode's Dogecoin wallet would go a long way. Account: D7nqwWstiWvLjkdHN3C68BGCntMNZBNWYi
lw has quit [Quit: s]
skaflem has quit [Ping timeout: 240 seconds]
<centrx>
!ops
skaflem2 has quit [Client Quit]
toastynerd has quit [Ping timeout: 276 seconds]
Donations has quit [K-Lined]
jason_ has joined #ruby
toastynerd has joined #ruby
no6 has joined #ruby
BizarreCake has quit [Ping timeout: 240 seconds]
WilfredTheGreat has quit [Quit: :-/]
bcx has joined #ruby
<bcx>
is there a good way to interact with a subprocess in ruby, all the examples I can find that use Open, require you to close stdin before reading from stdout.
<bcx>
The pty, standard lib seems like the best way, but it doesn't split stout and stderr
etqqkoiflwhb has quit [Quit: Computer has gone to sleep.]
jason_ has quit [Ping timeout: 240 seconds]
<Tricon>
Lightsword: I'd probably `.gsub` it with an expression.
sungai_keruh has quit [Quit: Leaving]
sputnik13 has joined #ruby
<Lightsword>
Tricon, how would I limit it to only the ip address of the lan interface?
<Lightsword>
i mean wan interface
<Tricon>
Lightsword: Do you have the WAN IF IP in a var?
<Tricon>
Lightsword: Or do you need to fetch that too?
AlexRussia has joined #ruby
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Lightsword>
Tricon, yeah, I set that at the beginning
<Lightsword>
Tricon, I need to be able to change the 192.168.1.99 IP address to the IP of the IP variable I set
<Tricon>
Lightsword: K, no problem. Let me get you a working example..
dapz has joined #ruby
<Lightsword>
Tricon, thanks, I'm kind of new to ruby and regex
mrmargolis has joined #ruby
<zets>
everyone's new at first :)
jamto11 has joined #ruby
KanKava has joined #ruby
ylluminate has joined #ruby
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
jackneill has quit [Remote host closed the connection]
cjsarette has joined #ruby
evenix has quit [Remote host closed the connection]
evenix_ has quit [Remote host closed the connection]
cjsarette has quit [Excess Flood]
Soda has joined #ruby
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
evenix_ has joined #ruby
evenix has joined #ruby
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cj3kim has joined #ruby
gregf has quit [Quit: WeeChat 0.4.3]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
b1nd has quit [Ping timeout: 245 seconds]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
r_rios has joined #ruby
Musashi1 has joined #ruby
jamto11 has quit [Ping timeout: 252 seconds]
nfk has joined #ruby
seuros has quit [Quit: Leaving.]
yubrew has joined #ruby
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
helpD has quit [Remote host closed the connection]
evenix_ has quit [Ping timeout: 240 seconds]
evenix has quit [Ping timeout: 240 seconds]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
kaspergrubbe has joined #ruby
Musashi1 has quit [Client Quit]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cj3kim has quit [Ping timeout: 252 seconds]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
i_s has joined #ruby
<Lightsword>
also what universal database interface should I use for simple ruby scripts? I basically just want to store a few tables in sqlite initially but still be able to use postgresql later on
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
cjsarette has joined #ruby
cjsarette has quit [Excess Flood]
<centrx>
Lightsword, You may want to use an ORM like Sequel or ActiveRecord
<centrx>
Lightsword, Database-agnostic is one of the advantages of using an ORM.
yubrew has quit [Ping timeout: 245 seconds]
<benzrf>
ORMs are silly
<Lightsword>
centrx, I've played around with ActiveRecord a bit with rails, but right now I just want to use it with ruby scripts, would Sequel be better for that?
<benzrf>
SQL exists for a reason o.o
<centrx>
Lightsword, Otherwise, for a "universal database interface", you would write all raw SQL, and you would need to make sure you write standard, database-agnostic SQL yourself
<benzrf>
Lightsword: use Sequel to manage connections
<benzrf>
then just use SQL for querying
kaspergr_ has quit [Ping timeout: 276 seconds]
<centrx>
Lightsword, Sequel is much more lightweight than ActiveRecord, but if you are already familiar with ActiveRecord it might be faster to develop with it
<centrx>
Even if you write raw SQL you will still end up writing some custom libraries to write SQL more efficiently
babykosh has joined #ruby
<Lightsword>
I think ill try sequel, I don't really know how to write raw SQL
<benzrf>
Lightsword: learn!
<centrx>
benzrf is an enthusiast's enthusiast
i_s has quit [Ping timeout: 252 seconds]
<havenwood>
Lightsword: can be improved upon, but here's a start: new_ip = '0.0.0.0'; g.each_line.map { |line| line.strip.start_with?('option ipaddr') ? line.gsub(/'.*?'/, "'#{new_ip}'") : line }
<Lightsword>
benzrf, I will eventually I'm sure, but performance for what I'm doing right now is not all that important so I think ill try a ORM if I get it working fast
<benzrf>
not even talking about perf
<havenwood>
+1 Sequel
<benzrf>
for super super basic stuff an ORM is fine
<benzrf>
but in general any serious querying should be in SQL
<Tricon>
Lightsword: Replace "127.0.0.1" with your var: `#{var}`
<zets>
ActiveRecord does a lot of intelligent optimization and query reduction that I might not think to do myself, or at least would slow down my development time to try to optimize
iamcalledrob has joined #ruby
evenix_ has joined #ruby
evenix has joined #ruby
<havenwood>
Lightsword: are you creating the config file?
benlieb has joined #ruby
<Lightsword>
havenwood, I'm actually editing it remotely over scp
<havenwood>
ah, was just going to suggest serializing it to JSON or MsgPack or something nice in the first place
Shidash has joined #ruby
koderok has quit [Quit: koderok]
lw has joined #ruby
<benlieb>
Any idea how to fix this error once I've installed ruby 2.1.0: You must recompile Ruby with OpenSSL support or change the sources in your Gemfile from 'https' to 'http'. Instructions for compiling with OpenSSL using RVM are available at
quitobro has quit [Remote host closed the connection]
<zets>
benlieb: are you on windows?
<benlieb>
no mac.
<benlieb>
the rvm page says that deprecated.
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<benlieb>
I also chagned source 'https://rubygems.org' to source 'http://rubygems.org' in my Gemfile, but then app load fails with: `require': cannot load such file -- openssl (LoadError)
<havenwood>
benlieb: so you're RVM installed Ruby didn't link against OpenSSL
<havenwood>
your**
Azure has quit [Client Quit]
yfeldblu_ has quit [Remote host closed the connection]
<havenwood>
benlieb: are you a brew user?
<benlieb>
what does link against mean?
<havenwood>
benlieb: dynamically link
<benlieb>
i have brew
Morkel has quit [Quit: Morkel]
<havenwood>
benlieb: brew install openssl
b1nd has joined #ruby
Azure has joined #ruby
<benlieb>
all my previous rubies installed via rvm have worked for years
<havenwood>
benlieb: are you certain you're using the RVM-provided Ruby at the moment?
<benlieb>
I already have open ssl in /usr/bin/openssl
<iamcalledrob>
Is there a way to set instance variables at the class level? I'm playing with some metaprogramming and am trying to something like this: https://gist.github.com/anonymous/11097083
<havenwood>
benlieb: Seems like an RVM bug, not sure. Might ask in #rvm. But you need to install OpenSSL 1.0.1g then reinstall Ruby.
<havenwood>
benlieb: you don't want to link against that
<benlieb>
openssl has no -v flag. how do I know what I've got?
<havenwood>
benlieb: Well, actually 0.9.8y is old enough to predate heartbleed :P
<havenwood>
benlieb: openssl version -a
iamjarvo has quit [Ping timeout: 276 seconds]
<benlieb>
got it
<benlieb>
0.9.8y 5 Feb 2013
<havenwood>
like i said, don't
<havenwood>
benlieb: brew install openssl
<zets>
iamcalledrob: if you want to set an instance var on the class object, use a class variable
<benlieb>
so will that replace the current openssl, or put another new on somewhere else?
cassioscabral has quit [Ping timeout: 252 seconds]
<babykosh>
I want to check if the value held by “number” is between 100 and 90. what is a nice concise way to say that in ruby?
<centrx>
babykosh, number.between(90, 100)
<centrx>
babykosh, number.between?(90, 100)
<havenwood>
babykosh: or: (90..100).cover? number
oponder has joined #ruby
<jacky>
whatever happened to 90 < number < 100 ? lol
<babykosh>
@centrax lovely
<babykosh>
centrax thanks
quitobro has joined #ruby
<havenwood>
jacky: works in Perl6 :P
quitobro_ has joined #ruby
b1nd has quit [Ping timeout: 250 seconds]
<benzrf>
thats a pythonism i think
Celm has joined #ruby
<jacky>
havenwood: <3
<benlieb>
havenwood: 2.1.1 same error: require': cannot load such file -- openssl (LoadError)
<havenwood>
benlieb: an RVM install? yikes
<benlieb>
havenwood: yep.
<benlieb>
maybe it's my system
mjs2600_ has joined #ruby
<jacky>
benlieb: you tried require 'ssl'
<benlieb>
I did upgrade several months ago. not sure if I installed rubies since then
<benlieb>
jacky: where? the app won'd load
<benlieb>
I'm not even using ssl
<havenwood>
benlieb: that is... unexpected. i'm a ruby-install/chruby user so i'm really not sure. might be nice to let #rvm know, maybe they can get it fixed for you.
<jacky>
ah, wait, my bad
<havenwood>
benlieb: or start an Issue on RVM's githubs
<havenwood>
benlieb: mpapis is really good at quickly getting to the bottom of RVM issues.
<shevy>
at least benzrf picked better names for his gems
nateberkopec has quit [Quit: Leaving...]
eynj has quit [Quit: Leaving.]
Fractional has joined #ruby
near77 has joined #ruby
<Fractional>
Is there a way to host a Ruby application on the web?
<zets>
yes
<near77>
hi
<zets>
there are several ways
<near77>
anyone used devise with mailchimp?
<Fractional>
zets: Could you mention one?
jxf has quit [Ping timeout: 250 seconds]
<zets>
Fractional: are you using a framework like rails?
<zets>
not sure what you mean actually
benzrf is now known as benzrf|offline
<havenwood>
Fractional: Talk more about what you want, too ambiguous to help thus far.
<Fractional>
Lets say I have programmed a 2D game, is it possible to host it on the web like JavaScript?
<havenwood>
Fractional: Of course.
<havenwood>
Though I still don't think I quite get what you mean by "host it".
sdelmore has joined #ruby
<Fractional>
Like, as in making it playable through the browser without downloading anything for the visitor.
<havenwood>
Fractional: Are you looking for how to deploy an app yourself or a hosting platform service?
<zets>
well, with javascript, the browser is actually running the code
nateberkopec has joined #ruby
<Fractional>
zets: Yes, is there a way to do that but with Ruby? So the visitor can 'play' the game through the browser?
Cache_Money has joined #ruby
mojo619 has joined #ruby
robbyoconnor has quit [Ping timeout: 240 seconds]
<zets>
yeah, you'd basically be making a web app, as the server would be running the ruby code
phansch has quit [Quit: WeeChat 0.4.2]
<havenwood>
Fractional: A game doesn't have to run code in the browser, depends on what kind of game. Usually in browser games JavaScript is involved. A Ruby/JavaScript game is fairly normal. You can use something like Opal to compile to JS for that part if you'd like.
<Fractional>
Lets stay I have developed a game in Ruby with Gosu. Can I just, somehow, without coding anything make it playable through the browser?
luckyruby has quit [Remote host closed the connection]
<shevy>
Fractional there is no way you can avoid javascript or flash when it comes to user interaction on the www like getting the cursor keys to do something
<havenwood>
Fractional: maybe possible with emscripten?
<havenwood>
Fractional: but no, not easily
dapz has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
Milly_Bays has joined #ruby
<Fractional>
Alright thank you :)
ftj has joined #ruby
badhatter has quit [Remote host closed the connection]
<zorak8>
in this moment im trying to make the "night hours" work
<xorl>
So with gistfile1 I keep getting a uninitialized constant Blah::Db (NameError)
<zorak8>
(nigh hour is between 9pm and 4am and every 50 minutes count like 60 minutes)
andrewlio has quit [Quit: Leaving.]
siwica has joined #ruby
codebro has quit [Ping timeout: 250 seconds]
nateberkopec has joined #ruby
<tectonic>
"data = Blah::Db::Test.new" is running in a class context. Has the file with Blah::Db been loaded yet?
<tectonic>
do you mean "def foo; data = Blah::Db::Test.new; end"
<tectonic>
?
<xorl>
tectonic at the upper level, yes
<tectonic>
so gistfile2 is required before gistfile1?
Asher has quit [Remote host closed the connection]
<xorl>
correct
Asher has joined #ruby
<tectonic>
does data = ::Blah::Db::Test.new
<tectonic>
work?
<xorl>
ah nm I think you nailed it
JJMalina has joined #ruby
nateberkopec has quit [Read error: No route to host]
<xorl>
I was calling my gistfile2 after gistfile1 I rearranged it and am getting another error
omosoj has quit [Ping timeout: 240 seconds]
kenneth has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<tectonic>
ah, ok
enriclluelles has quit [Ping timeout: 240 seconds]
yubrew has joined #ruby
<xorl>
tectonic yep that was it!
<xorl>
Thanks for the help, I was hitting my head against the desk haha
linojon has quit [Quit: linojon]
myke_ is now known as myke
<tectonic>
haha, no problem
R33C3 has quit [Ping timeout: 245 seconds]
mjs2600 has joined #ruby
enriclluelles has joined #ruby
ktun has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
JJMalina has quit [Ping timeout: 240 seconds]
omosoj has joined #ruby
mercwithamouth has joined #ruby
tjsousa has joined #ruby
yubrew has quit [Ping timeout: 245 seconds]
zcreative has joined #ruby
quitobro_ has quit [Remote host closed the connection]
bbloom has joined #ruby
quitobro has joined #ruby
Asher has quit [Quit: Leaving.]
ktun has joined #ruby
mjs2600 has quit [Ping timeout: 245 seconds]
Asher has joined #ruby
freerobby has joined #ruby
eka has quit [Quit: My computer has gone to sleep. ZZZzzz…]
quitobro_ has joined #ruby
near77 has quit [Quit: Page closed]
omosoj has quit [Ping timeout: 240 seconds]
omosoj has joined #ruby
quitobro has quit [Ping timeout: 245 seconds]
freerobby has quit [Ping timeout: 245 seconds]
Fractional has quit [Quit: Leaving]
lkba has quit [Ping timeout: 276 seconds]
Geniack has quit [Disconnected by services]
Geniack_ has joined #ruby
omosoj has quit [Ping timeout: 240 seconds]
meatherly has joined #ruby
combusean has quit [Ping timeout: 276 seconds]
crucify_me has joined #ruby
omosoj has joined #ruby
quitobro_ has quit [Remote host closed the connection]
danguita has quit [Quit: WeeChat 0.4.3]
<crucify_me>
http://pastie.org/9094312 hi a recursion exercise has me confused . the last method here (line 20) appends an array in reverse. how does it work?
R33C3 has joined #ruby
siwica has quit [Ping timeout: 276 seconds]
dkannan has joined #ruby
<zorak8>
i solve it!
<tectonic>
crucify_me: it descends all the way down until n == 0, then climbs back up, shifting n onto the array
nateberkopec has joined #ruby
RastaqWhere has joined #ruby
michaeldeol has joined #ruby
nateberkopec has quit [Read error: No route to host]
<crucify_me>
tectonic: 2 is appended last , right?
nateberkopec has joined #ruby
<tectonic>
looks like it
i_s has joined #ruby
Shidash has quit [Ping timeout: 252 seconds]
lw has joined #ruby
<crucify_me>
tectonic: it seems the first that would happen would be 2 - 1 = 1 here. so I can't see how the first element is 0 . sorry.
<crucify_me>
first *thing
R33C3 has quit [Quit: Leaving]
<kayloos_>
crucify_me: first thing that happens is 2 -1, then the next thing that happens is 1-1
<tectonic>
line 22 descends recursively until line 21 is true
<kayloos_>
indeed
<tectonic>
so then n is 0 on line 23 (3 recursive calls down)
nateberkopec has quit [Ping timeout: 240 seconds]
<tectonic>
draw out the call tree on paper. everytime line 22 is hit, you have to zoom in and call yourself again
i_s has quit [Ping timeout: 276 seconds]
<crucify_me>
ok from that I should be able to see it. thanks a lot tectonic kayloos_
<tectonic>
no prob
lkba has joined #ruby
Lewix has quit [Remote host closed the connection]
<crucify_me>
tectonic: kayloos_ one thing though, an array is always filling out from the left, correct? It's the push method at work, correct?
<crucify_me>
i.e. you can't add elements on the left side of other elements.
<kayloos_>
Think about what the computer would have to do if you wanted to add an element to index 0
benzrf|offline is now known as benzrf
tjsousa has quit [Quit: Computer has gone to sleep.]
andy____ has quit [Remote host closed the connection]
cj3kim_ has quit [Remote host closed the connection]
<tectonic>
push adds to the right of an array. there are ways to add to the left of an array, but that's not happening here
freerobby has joined #ruby
chipotle has quit [Quit: cya]
<crucify_me>
kayloos_: tectonic interesting. The only way would be to use indices I assume.
<kayloos_>
crucify_me: you would have to shift the entire array one slot to the right, which would make the push operation very inefficient
amundj has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<kayloos_>
crucify_me: imagine adding one number to an array that contains one million numbers. If you add to the end of the array, the operation would take no time at all, but if you add it to the beginning you would have to shift the entire array, which would take 1 million times more instructions
benlieb has joined #ruby
Lightsword has quit [Ping timeout: 252 seconds]
Es0teric has joined #ruby
RastaqWhere has left #ruby [#ruby]
<crucify_me>
kayloos_: ok thanks. recursion is causing me some trouble. I feel like I nearly understand it.
cj3kim_ has joined #ruby
<tectonic>
crucify_me: Ruby has "unshift" which adds an element to the beginning of an array. It's not clear how it's implemented internally, but it may well be slow (have to shift everything in the array by 1).
<crucify_me>
tectonic: that's cool.
<tectonic>
"It's not clear" is my way of saying "I don't know and haven't looked it up."
<kayloos_>
crucify_me: do what tectonic says, draw out the call trees and try to 'hand run' the code, that way is really good if u want to understand recursion
freerobby has quit [Quit: Leaving.]
<tectonic>
To understand recursion, first you must understand recursion.
mjs2600 has joined #ruby
<bufferloss>
lol
<crucify_me>
tectonic: kayloos_ !!
andy___ has joined #ruby
<kayloos_>
although ruby is hardly a programming language with much focus on recursion
dingus_khan has joined #ruby
<kayloos_>
you could try out #haskell :)
cj3kim_ has quit [Remote host closed the connection]
Lightsword has joined #ruby
<benzrf>
haskell ftw
<bufferloss>
"language with much focus on recursion" is a non-sequitur
<bufferloss>
ruby has functions
<bufferloss>
that's all you need
<crucify_me>
bufferloss: word
<kayloos_>
haskell is optimized for efficient recursion
<crucify_me>
it's an exercise that uc berkeley has me doing
<bufferloss>
kayloos_, maybe you should marry haskell then
<benzrf>
haskell doesnt even do recursion like most modern langs do
<benzrf>
its all thunk-based
<benzrf>
at least it is in GHC
<kayloos_>
when did you see recursion in an open source project? I haven't
<kayloos_>
in ruby*
<bufferloss>
again not sure why this has any relevance to whether you can make use of recursion in ruby
<crucify_me>
I spoke to a cs student yesterday who said she has finally understood recursion after a few years.
dik_dak has joined #ruby
nateberkopec has joined #ruby
advorak has joined #ruby
Emmanuel_Chanel has quit [Ping timeout: 240 seconds]
<kayloos_>
bufferloss: Is there a point to all this?
<bufferloss>
kayloos_, that's my question to you, precisely
wallerdev has quit [Quit: wallerdev]
<bufferloss>
somehow apparently ruby can't do recursion or something weird like that according to kayloos_
<crucify_me>
it's a book exercise people but thanks a lot.
Slavox|AFK is now known as Slavox
<benzrf>
crucify_me: woah
circuit has joined #ruby
<crucify_me>
woah ?
<benzrf>
cs stud
<benzrf>
ent
<bufferloss>
I understood recursion when I was in the womb, what's the big deal?
<crucify_me>
no I'm a geezer trying to learn how to program that's all. benzrf