fflush changed the topic of #ruby to: Ruby 1.9.3-p194: http://ruby-lang.org || Paste > 3 lines of text on pastebin.com
tiripamwe has joined #ruby
replore_ has joined #ruby
Takehiro has quit [Ping timeout: 252 seconds]
jorge_ has quit [Remote host closed the connection]
perun_ has joined #ruby
just4dos has left #ruby ["Leaving"]
Agis__ has joined #ruby
Speed has quit [Remote host closed the connection]
schaerli has joined #ruby
ph^ has quit [Remote host closed the connection]
gloomer has quit [Ping timeout: 244 seconds]
gloomer has joined #ruby
fantazo has quit [Quit: Verlassend]
gloomer has quit [Client Quit]
havenn has joined #ruby
enroxorz has joined #ruby
devnull_ has joined #ruby
enroxorz is now known as Guest87369
samflores has joined #ruby
samflores has left #ruby [#ruby]
<devnull_> hello can someone tell me how from this id variable I can get only the number inside the brakets ? : http://pastebin.com/jKjeiMfd thanks
CarlB_the_great has joined #ruby
pingfloyd has joined #ruby
<canton7> puts id["uuids"][0]
dmiller has joined #ruby
freeayu has joined #ruby
enroxorz_ has joined #ruby
Guest87369 has quit [Ping timeout: 246 seconds]
winstons101 has joined #ruby
<devnull_> canton7: thanks a lot !!
<devnull_> canton7: umh nope that didn't work
havenn has quit [Remote host closed the connection]
Russell^^ has quit [Quit: Russell^^]
sailias has joined #ruby
ryanf has quit [Ping timeout: 276 seconds]
havenn has joined #ruby
<canton7> oh, id is a string?
<devnull_> canton7: I think so it returns u
enroxorz__ has joined #ruby
<canton7> something like puts id[/\["(.*)"\]/, 1] in that case, although it'd be much better to turn id into an object
freeayu has quit [Read error: Connection reset by peer]
enroxorz_ has quit [Ping timeout: 246 seconds]
enroxorz__ has quit [Read error: Connection reset by peer]
<devnull_> canton7: yes that worked :) how would you turn it into an object o_O
<canton7> what's the data type? JSON?
<canton7> if so, require 'json'; id = JSON.parse('{"uuids":["86ad9c28e89f9653592ca76c4a001cc3"]}'); puts id["uuids"][0]
skipper has joined #ruby
<devnull_> canton7: yes from couchdb
replore_ has quit [Remote host closed the connection]
<devnull_> canton7: thanks a lot !
havenn has quit [Ping timeout: 264 seconds]
freeayu has joined #ruby
dev_ryan70 has joined #ruby
kirun has quit [Quit: Client exiting]
CarlB_the_great has quit [Remote host closed the connection]
dmiller has quit [Remote host closed the connection]
jorge has joined #ruby
winstons101 has left #ruby ["Leaving"]
t29232 has quit [Remote host closed the connection]
t47425 has joined #ruby
skipper has quit [Remote host closed the connection]
k_89 has quit [Ping timeout: 244 seconds]
jasonkuhrt has joined #ruby
johnjohnson has quit []
Vert has quit [Read error: Connection reset by peer]
havenn has joined #ruby
dmiller has joined #ruby
havenn has quit [Remote host closed the connection]
ryanf has joined #ruby
schaerli has quit [Remote host closed the connection]
CarlB_the_great has joined #ruby
rails has quit [Read error: Connection reset by peer]
Eplemosen has quit [Quit: NOPE]
mroth has joined #ruby
mroth has quit [Changing host]
mroth has joined #ruby
mroth has joined #ruby
gfontenot has quit []
ken_barber1 has quit [Remote host closed the connection]
mucker has quit [Remote host closed the connection]
<Cache_Money> are there any gems that provide a list of all the words in the English language?
Takehiro has joined #ruby
<seanstickle> Cache_Money: /usr/share/dict/words
whowantstolivefo has quit [Read error: Connection reset by peer]
Spaceghostc2c has quit [Disconnected by services]
Foxandxss has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
Takehiro has quit [Ping timeout: 252 seconds]
ken_barber has joined #ruby
ken_barber has quit [Remote host closed the connection]
FifthWall has quit [Quit: Zzzzzzzzzzzzz]
<Cache_Money> seanstickle: thanks
dmiller has quit [Remote host closed the connection]
bbloom has joined #ruby
bbloom has left #ruby [#ruby]
emmanuelux has joined #ruby
Spaceghost|cloud has joined #ruby
qos has quit [Ping timeout: 255 seconds]
replore has joined #ruby
replore has quit [Read error: Connection reset by peer]
sailias has quit []
<Cache_Money> seanstickle: I have a 4x4 grid of letters and I'm trying to wrtie a script that looks at all of the possible combinations (a tile can only be used once) that create a legitimate word (ie in the /usr/share/dict/words file)
<Cache_Money> any advice or things I should consider?
n_blownapart has joined #ruby
CarlB_the_great has quit [Remote host closed the connection]
n_blownapart has quit [Remote host closed the connection]
jearvondharrie1 has joined #ruby
specialGuest has quit [Ping timeout: 244 seconds]
jearvondharrie has quit [Ping timeout: 244 seconds]
seanyo has joined #ruby
<David_Miller> why is it fact that its a grid important?
ph^ has joined #ruby
Monie has quit [Read error: Connection reset by peer]
jenrzzz has quit [Ping timeout: 245 seconds]
ph^ has quit [Ping timeout: 246 seconds]
<matti> ITS A GRID!!!
<matti> :)
Agis__ has quit [Quit: Agis__]
<Cache_Money> David_Miller: that's the setup of the game
Hanmac1 has joined #ruby
jarred has quit [Quit: jarred]
Hanmac has quit [Ping timeout: 260 seconds]
heftig has quit [Remote host closed the connection]
heftig has joined #ruby
banisterfiend` has quit [Remote host closed the connection]
<David_Miller> so they could be in row of 12 and it would still be the same
<David_Miller> 16
niklasb has quit [Ping timeout: 276 seconds]
yasushi has joined #ruby
dakine has quit [Read error: Connection reset by peer]
Banistergalaxy has joined #ruby
yasushi has quit [Ping timeout: 246 seconds]
yasushi has joined #ruby
aristidesfl has quit [Ping timeout: 248 seconds]
<Cache_Money> David_Miller: You can only spell words using letters from adjacent tiles
ZachBeta has joined #ruby
lusory has quit [Ping timeout: 240 seconds]
jz has joined #ruby
sailias has joined #ruby
jz is now known as Guest66077
hipertracker has quit [Ping timeout: 265 seconds]
aristidesfl has joined #ruby
replore has joined #ruby
aknagi has quit [Quit: Leaving]
<elico> If anyone want to help me think loud i will be more then happy.
tk___ has joined #ruby
nw has quit [Ping timeout: 246 seconds]
nw has joined #ruby
dju has quit [Ping timeout: 246 seconds]
<elico> i'm trying to build efficient domain names on Tokyo Cabinet BTree DB
<elico> domain names DB..
replore has quit [Ping timeout: 276 seconds]
BrokenCog has quit [Ping timeout: 252 seconds]
<billyoc> elico: I'd *love* to help you think out loud. Let's begin: I installed execjs and 'rails server' is still complaining about execjs unavailable. This is a brand new maching I just installed rails on. So, what do we think about that? :)
<elico> hmm what Distro?
<elico> how did you installed execjs?
<billyoc> gem install execjs
<billyoc> parabola GNU/Linux
Takehiro has joined #ruby
t47425 has quit [Remote host closed the connection]
<elico> i must say this is the first time i'm hearing about parabola linu
<elico> linux
<seanstickle> It's not quite as nice as Elliptical Linux
t24102 has joined #ruby
<billyoc> but it's better than rhomboid linux
<seanstickle> Ah, see, you flunked conic sections right there
BrokenCog has joined #ruby
BrokenCog has quit [Changing host]
BrokenCog has joined #ruby
dju has joined #ruby
<elico> i like Square Linux
<elico> "sudo ..."
yubiwasabi2 has joined #ruby
Progster has joined #ruby
<elico> So my problem is that i want to somehow implement the BDB in a way i can benefit from the BTREE and the domain name structure
Takehiro has quit [Ping timeout: 252 seconds]
psyl0n has joined #ruby
<elico> and what about the execjs? rails dont like it or just ruby?
DefV has quit [Ping timeout: 272 seconds]
pipopopo has quit [Ping timeout: 244 seconds]
DefV has joined #ruby
<billyoc> oh, hell, it's *execjs* that's complaining about no js runtime!
<billyoc> Like I said, this is a brand new box, I haven't started from scratch like this in a while.
sailias has joined #ruby
<elico> well it's arch linux based so... dont be supprised
dpk has quit [Quit: Asleep at the keyboard.]
<elico> it uses js runtime to run the js.. it make the same for me
pipopopo has joined #ruby
<elico> what js runtime do you have?
rudyl313 has joined #ruby
<elico> since it's based on arch you can compile\install nodejs
<elico> or install therubyracer gem
ttilley has quit [Quit: ttilley]
cj3kim has joined #ruby
cj3kim has quit [Changing host]
cj3kim has joined #ruby
<billyoc> elico: gotcha
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
jearvondharrie2 has joined #ruby
<elico> billyoc: so about my "problem"
<elico> do you have some background with db?bdb?
replore has joined #ruby
jearvondharrie1 has quit [Ping timeout: 244 seconds]
ZachBeta has quit [Quit: Computer has gone to sleep.]
dmiller has joined #ruby
replore has quit [Ping timeout: 276 seconds]
Markvilla has quit [Quit: Computer has gone to sleep.]
<elico> billyoc: ?
jasonkuhrt has quit [Quit: Leaving...]
Monie has joined #ruby
Monie has quit [Changing host]
Monie has joined #ruby
<billyoc> elico: Thanks, I just needed nodejs. I'm more of a TokyoCabinet man, but I've used bdb.
justsee has quit [Quit: Leaving...]
<billyoc> Well, I used Berkeley DB for years, but with C.
dmiller has quit [Ping timeout: 255 seconds]
<billyoc> It makes me sick to see that Oracle logo all over it now. :-|
<seanstickle> Like a sickness
<seanstickle> That spreads across so many database products
<billyoc> Right? You can't even use mysql anymore, because they're starting to hide code now. I'm working with PostgreSQL now.
<billyoc> The Diaspora project.
<billyoc> elico: what's going wrong with your bdb?
tiripamwe has quit [Ping timeout: 272 seconds]
dpk has joined #ruby
<seanstickle> I am using Percona instead.
<seanstickle> But looking towards Postgres
jgrevich_ has joined #ruby
<elico> actually i am not using bdb but tokyo cabind bdb stands for Btree db
<elico> it's nothing wrong... but i want to implement something and my mind is blocked
jgrevich has quit [Ping timeout: 245 seconds]
jgrevich_ is now known as jgrevich
<billyoc> elico: wow, you let me go off like that and didn't stop me? lol
<elico> Ha HA
<elico> i dont like oracle like you
<elico> i dont like their way of taking code out of anyone hands...
Banistergalaxy has quit [Ping timeout: 248 seconds]
<elico> any way my scenario is: i have a domain names list .. a black list.
<elico> it's a black list and the rules are;
nari_ has joined #ruby
Banistergalaxy has joined #ruby
<elico> one domain name in the db will block all subdomains and if there is a domain name and domain + subdomains it's an exact match wins only
banisterfiend` has joined #ruby
<elico> for now i store it in the db in a reverse order to maintain the btree
<elico> so a google.com becomes:
<elico> >> ["google.com".reverse, "google.com".to_a.reverse]
<al2o3cr> -e:1:in `eval': undefined method `to_a' for "google.com":String (NoMethodError), from -e:1:in `eval', from -e:1:in `<main>'
replore has joined #ruby
becom33 has quit [Ping timeout: 248 seconds]
<elico> >> ["google.com".reverse, ("google.com".split('.')).reverse]
<al2o3cr> (Array) ["moc.elgoog", ["com", "google"]]
becom33 has joined #ruby
<elico> one of the two that i will choose..
<elico> so tokyo cabiet has the option to search for a range but i have no idea on how to do a lookup for "com.google%"
Banistergalaxy has quit [Ping timeout: 268 seconds]
uris has joined #ruby
dimday has joined #ruby
<elico> maybe they have prefix thing
replore has quit [Ping timeout: 255 seconds]
dimday has quit [Client Quit]
dimday has joined #ruby
dimday has quit [Client Quit]
dimday has joined #ruby
dimday has quit [Client Quit]
<atno> morning
<elico> atno: morning
<elico> >>require "tokyocabinet"
<al2o3cr> -e:1:in `eval': cannot load such file -- tokyocabinet (LoadError), from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require', from (eval):1:in `<main>', from -e:1:in `eval', from -e:1:in `<main>'
<elico> no tokyo cabinet for the bot...
<elico> but it seem that Tokyo cabinet has a nice function for that
<elico> fwmkeys
banisterfiend` has quit [Remote host closed the connection]
Banistergalaxy has joined #ruby
ryanf has quit [Ping timeout: 264 seconds]
<elico> billyoc: PING
<Cache_Money> How would I go about removing words from an array that contained non-ASCII characters (ie the spanish tilde, etc)? Here's the error message: http://imagebin.org/226817
replore_ has joined #ruby
nwest has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<heftig> Cache_Money: add a comment "# encoding: utf-8" add the start of the file, and it will accept the characters
<Cache_Money> heftig: thanks!
<Cache_Money> much easier
<elico> to the start of the ruby file?
<koshii> Why is unless false the same as !false ?
<seanstickle> koshii: you mean why is "unless false" the same as "if !false" ?
<koshii> Yeah
<koshii> I guess I see what it means, but that's pretty awkward.
Takehiro has joined #ruby
<heftig> well, consider "unless foo.zero?" and "if !foo.zero?"
<heftig> I think the former parses better
davidcelis has quit [Quit: K-Lined.]
Takehiro has quit [Ping timeout: 252 seconds]
williamherry has joined #ruby
<seanstickle> And ultimately the same reason we have foo.any? and not just !foo.empty?
<seanstickle> Sometimes it's cleaner
Spooner has quit [Ping timeout: 246 seconds]
elico has quit [Quit: Leaving.]
jorge has quit [Remote host closed the connection]
jorge has joined #ruby
seanstickle_ has joined #ruby
seanstickle has quit [Ping timeout: 276 seconds]
seanstickle_ is now known as seanstickle
hernerdies has joined #ruby
replore_ has quit [Remote host closed the connection]
davidcelis has joined #ruby
chrisjuric has joined #ruby
davidcelis is now known as Guest73400
chrisjuric has quit [Client Quit]
yubiwasabi2 has quit [Quit: Computer has gone to sleep.]
elico has joined #ruby
<elico> >> "test"
<al2o3cr> (String) "test"
replore_ has joined #ruby
Guest73400 has quit [Remote host closed the connection]
williamherry has quit [Quit: Leaving]
williamherry has joined #ruby
<elico> >>!reset
<al2o3cr> -e:1:in `eval': undefined local variable or method `reset' for main:Object (NameError), from -e:1:in `eval', from -e:1:in `<main>'
<elico> !reset
<al2o3cr> AAAAAAAH
<al2o3cr> Still alive~
mr-rich has quit [Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/]
<elico> al2o3cr: !reset
<elico> >> "haha NOT WORKING"
<al2o3cr> (String) "haha NOT WORKING"
seanyo has quit [Ping timeout: 255 seconds]
<seanstickle> >> "test"
<al2o3cr> (String) "test"
<seanstickle> Oooh
<seanstickle> >> while true; 1; end
davidcelis_ has joined #ruby
<seanstickle> >> "test again"
<al2o3cr> (String) "test again"
<seanstickle> Dang
<seanstickle> >> 1.class
<al2o3cr> (Class) Fixnum
t24102 has quit [Remote host closed the connection]
<seanstickle> >> system 'ls'
<al2o3cr> (NilClass) nil
davidcelis_ is now known as davidcelis
davidcelis has quit [Changing host]
ryanf has joined #ruby
davidcelis has joined #ruby
t15270 has joined #ruby
<seanstickle> >> `ls`
<al2o3cr> -e:1:in `eval': No such file or directory - ls (Errno::ENOENT), from (eval):1:in `<main>', from -e:1:in `eval', from -e:1:in `<main>'
<seanstickle> >> Dir["*"]
<al2o3cr> (Array) ["usr", "bot.err", "log", "bot.rb", "bot.out", "sys", "root", "proc", "node_modules", "bin", "lib", "etc", "lost+found"]
<seanstickle> >> File.readlines("/etc/passwd")
<al2o3cr> (Array) ["root:x:0:0:root:/root:/bin/bash\n", "bin:x:1:1:bin:/bin:/bin/false\n", "daemon:x:2:2:daemon:/sbin:/bin/false\n", "mail:x:8:12:mail:/var/spool/mail:/bin/false\n", "ftp:x:14:11:ftp:/srv/ftp:/bin/false\n", "http:x:33:33:http:/srv/http:/bin/false\n", "nobody:x:99:99:nobody:/:/bin/false\n", "dbus:x:81:81:System message bus:/:/bin/false\n", "jrajav:x:1000:100::/home/jrajav:/bin/bash\n", "al:x:1001:1001::/home/al:/bin/bash\n"]
FifthWall has joined #ruby
<seanstickle> >> File.readlines("/etc/shadow")
<al2o3cr> -e:1:in `eval': No such file or directory - /etc/shadow (Errno::ENOENT), from (eval):1:in `<main>', from -e:1:in `eval', from -e:1:in `<main>'
<seanstickle> >> File.readlines("/etc/master.passwd")
<al2o3cr> -e:1:in `eval': No such file or directory - /etc/master.passwd (Errno::ENOENT), from (eval):1:in `<main>', from -e:1:in `eval', from -e:1:in `<main>'
<seanstickle> >> File.readlines("bot.rb")
<al2o3cr> (Array) ["require 'cinch'\n", "require 'open3'\n", "require 'timeout'\n", "\n", "def smush(text, length)\n", " array_len = (length / 3).ceil\n", " half_len = (length / 2).floor\n", " lines = text.lines.to_a.each { |l| l.chomp! }\n", " last...
<seanstickle> >> __FILE__
<al2o3cr> (String) "(eval)"
<seanstickle> >> Dir["/home/jrajav"]
<al2o3cr> (Array) []
<seanstickle> >> Dir["/home/al"]
<al2o3cr> (Array) []
<seanstickle> Fun!
<seanstickle> >> Dir["/root"]
<al2o3cr> (Array) ["/root"]
<seanstickle> >> Dir["/home/jrajav/**"]
<al2o3cr> (Array) []
<seanstickle> >> Dir["**/"]
<al2o3cr> (Array) ["usr/", "usr/include/", "usr/include/node/", "usr/include/node/uv-private/", "usr/bin/", "usr/lib/", "usr/lib/node/", "usr/lib/ruby/", "usr/lib/ruby/gems/", "usr/lib/ruby/gems/1.9.1/", "usr/lib/ruby/gems/1.9.1/gems/", "usr/lib/ruby/gems/1.9.1...
<seanstickle> >> Dir["home/**/"]
<al2o3cr> (Array) []
davidcelis_ has joined #ruby
<seanstickle> >> Dir["/home/**/"]
<al2o3cr> (Array) []
<seanstickle> >> File.readlines("bot.err")
<al2o3cr> (Array) ["[2012/08/21 13:23:34.716] !! [on handler] Registering handler with pattern `#<Cinch::Pattern:0x00000000c4d128 @prefix=nil, @pattern=/^>>(.+)/, @suffix=nil>`, reacting on `message`\n", "[2012/08/21 13:23:34.718] !! [on handler] Registering ha...
davidcelis_ has quit [Remote host closed the connection]
<dominikh> it surprises me nobody has banned the bot yet.
<dominikh> and its owner, for that matter
<seanstickle> Trying to see if I can have the bot destruct itself
<dominikh> >> 1+1
<al2o3cr> (Fixnum) 2
<dominikh> >> bot.config.sasl
<al2o3cr> -e:1:in `eval': undefined local variable or method `bot' for main:Object (NameError), from -e:1:in `eval', from -e:1:in `<main>'
<dominikh> >> @bot.config.sasl
<al2o3cr> -e:1:in `eval': undefined method `config' for nil:NilClass (NoMethodError), from -e:1:in `eval', from -e:1:in `<main>'
davidcelis_ has joined #ruby
<dominikh> >> self.class
<al2o3cr> (Class) Object
<dominikh> >> self
<al2o3cr> (Object) main
<dominikh> >> ObjectSpace
<al2o3cr> (Module) ObjectSpace
<seanstickle> >> Process.pid
<al2o3cr> (Fixnum) 7202
<dominikh> >> ObjectSpace.each_object(Cinch::Bot)
<al2o3cr> -e:1:in `eval': uninitialized constant Cinch (NameError), from -e:1:in `eval', from -e:1:in `<main>'
<dominikh> bummer
williamherry has quit [Quit: Leaving]
havenn has joined #ruby
<seanstickle> >> Process.kill("TERM", 7202)
<al2o3cr> -e:1:in `eval': No such process (Errno::ESRCH), from (eval):1:in `<main>', from -e:1:in `eval', from -e:1:in `<main>'
<seanstickle> >> Process.kill("TERM", Process.pid)
<seanstickle> >> "test"
<al2o3cr> (String) "test"
<seanstickle> Dang
havenn has quit [Remote host closed the connection]
mengu has quit [Remote host closed the connection]
<seanstickle> >> Process.kill("HUP", Process.pid)
<seanstickle> >> "test"
<al2o3cr> (String) "test"
<FifthWall> >> 10.times { puts "Hello, I am the bot!" }
<al2o3cr> (Fixnum) 10, Console: Hello, I am the bot!, Hello, I am the bot!, Hello, I am the bot!, Hello, I am the bot!, Hello, I am the bot!, Hello, I am the bot!, Hello, I am the bot!, Hello, I am the bot!, Hello, I am the bot!, Hello, I am the bot!
dpk has quit [Quit: Asleep at the keyboard.]
<davidcelis> >> Process.pid
<al2o3cr> (Fixnum) 7258
<davidcelis> >> Process.pid
<al2o3cr> (Fixnum) 7265
<seanstickle> >> def foo; "hello"; end; foo
<al2o3cr> (String) "hello"
<davidcelis> new process each time bro
<seanstickle> True
<dominikh> and don't bother with a fork bomb, he has it limited :(
<seanstickle> >> def bomb; loop { fork { bomb } }; end; bomb
<al2o3cr> [FATAL] Failed to create timer thread (errno: 11), [FATAL] Failed to create timer thread (errno: 11), [FATAL] Failed to create timer thread (errno: 11), [FATAL] Failed to create timer thread (errno: 11), [FATAL] Failed to create timer thread (errno: 1..., [FATAL] Failed to create timer thread (errno: 11)
<seanstickle> Dang
<davidcelis> hahahaha
<seanstickle> >> "test"
<al2o3cr> (String) "test"
<FifthWall> >> 50.times { puts "abcdefghijklmnopqrstuvwxyz" }
<al2o3cr> (Fixnum) 50, Console: abcdefghijklmnopqrstuvwxyz, abcdefghijklmnopqrstuvwxyz, abcdefghijklmnopqrstuvwxyz, abcdefghijklmnopqrstuvwxyz, abcdefghijklmnopqrstuvwxyz, abcdefghijklmnopqrstuvwxyz, abcdefghijklmnopqrstuvwxyz, abcdefghijklmnopqrstuvwxyz, abcdefghijklmnopqrstuvwxyz,...
<FifthWall> boo
<seanstickle> >> File.open("test", "w") {|x| x.print "test" }
<al2o3cr> -e:1:in `eval': Permission denied - test (Errno::EACCES), from (eval):1:in `open', from (eval):1:in `<main>', from -e:1:in `eval', from -e:1:in `<main>'
<seanstickle> >> Dir["/etc/**"]
<al2o3cr> (Array) ["/etc/resolv.conf", "/etc/ld.so.cache", "/etc/pam.d", "/etc/sudoers", "/etc/group", "/etc/passwd", "/etc/nsswitch.conf"]
<dominikh> >> File.readlines("/etc/resolv.conf").join
<al2o3cr> (String) "# Generated by dhcpcd from eth0\n# /etc/resolv.conf.head can replace this line\ndomain int.westgroup.com\nnameserver 163.231.22.17\nnameserver 163.231.22.2\n# /etc/resolv.conf.tail can replace this line\n"
<seanstickle> >> Dir["/etc/password"]
<al2o3cr> (Array) []
<seanstickle> >> Dir["/etc/passwd"]
<al2o3cr> (Array) ["/etc/passwd"]
<dominikh> it's a chroot fyi ;)
<seanstickle> Ah
<dominikh> at least that's what etc being in the cwd tells me
<dominikh> I don't know the bot any more than you do
<seanstickle> Right, right.
<seanstickle> Well, maybe we should just kick it then
<dominikh> hehe
<seanstickle> Bots are sort of non-welcome
<FifthWall> test >> "test"
<elico> seanstickle: it is suppose to run here...
<seanstickle> Supposed to run here?
replore_ has quit [Remote host closed the connection]
<dominikh> this is #ruby, not #ruby-lang, who cares :>
<seanstickle> Tell me more.
<seanstickle> I care. A little bit.
<elico> i dont know who runs it but it helps to check and demonstrate stuff
TheLZA has joined #ruby
TheLZA has quit [Client Quit]
<elico> and here i was thinking ruby and ruby-lang was the same
<seanstickle> Alright, fair enough
mr-rich has joined #ruby
<elico> seanstickle: if you have seen it's code you will die.. it's funny
<seanstickle> Oh?
<elico> try this:
<seanstickle> >> Dir["*"]
<al2o3cr> (Array) ["usr", "bot.err", "log", "bot.rb", "bot.out", "sys", "root", "proc", "node_modules", "bin", "lib", "etc", "lost+found"]
<elico> !reset
<al2o3cr> AAAAUUUUGH
<al2o3cr> Crisis averted
<seanstickle> Wow. That is hilarious.
<seanstickle> >> Dir["bin/**"]
<al2o3cr> (Array) []
<seanstickle> >> Dir["/bin/**"]
<al2o3cr> (Array) []
<seanstickle> >> Dir["/bin/*"]
<elico> i see you like it
<al2o3cr> (Array) []
<seanstickle> >> Dir["/lib/*"]
<al2o3cr> (Array) ["/lib/libresolv.so.2", "/lib/libutil.so.1", "/lib/libdl.so.2", "/lib/libpam_misc.so.0", "/lib/libssl.so.1.0.0", "/lib/libz.so.1", "/lib/libprocps.so.0", "/lib/libcrypt.so.1", "/lib/libnss_dns.so.2", "/lib/libnss_files.so.2", "/lib/libm.so.6",...
<seanstickle> >> Dir["/node_modules/*"]
<al2o3cr> (Array) ["/node_modules/forever"]
<seanstickle> >> Dir["/usr/*"]
<al2o3cr> (Array) ["/usr/include", "/usr/bin", "/usr/lib"]
<seanstickle> >> Dir["/usr/bin/*"]
<al2o3cr> (Array) ["/usr/bin/timeout", "/usr/bin/node", "/usr/bin/ruby", "/usr/bin/gem", "/usr/bin/sudo", "/usr/bin/pkill"]
<seanstickle> >> File.readlines("bot.rb")
<al2o3cr> (Array) ["require 'cinch'\n", "require 'open3'\n", "require 'timeout'\n", "\n", "def smush(text, length)\n", " array_len = (length / 3).ceil\n", " half_len = (length / 2).floor\n", " lines = text.lines.to_a.each { |l| l.chomp! }\n", " last...
<dominikh> oh stop the highlights :P
<seanstickle> It vaguely annoys me.
mercwith1mouth has quit [Ping timeout: 276 seconds]
Bosma has joined #ruby
dmiller has joined #ruby
jorge has quit [Remote host closed the connection]
yubiwasabi2 has joined #ruby
<dominikh> tbh I do like the idea of the bot
<dominikh> and I'm impressed by the implementation
<seanstickle> What impresses you in particular?
<dominikh> the fact it didn't break yet
<seanstickle> :D
dmiller has quit [Ping timeout: 246 seconds]
<dominikh> >> ObjectSpace.each_object(Class)
<al2o3cr> (Enumerator) #<Enumerator: ObjectSpace:each_object(Class)>
becom33 has quit [Remote host closed the connection]
Takehiro has joined #ruby
t15270 has quit [Remote host closed the connection]
t87427 has joined #ruby
<dominikh> >> ObjectSpace.each_object(Class).to_a.select {|c| c.name =~ /bot/}
<al2o3cr> (Array) []
<dominikh> bloody two process infrastructure
<seanstickle> Heh
<dominikh> >> $SAFE
<al2o3cr> (Fixnum) 0
<dominikh> heh
Takehiro has quit [Ping timeout: 246 seconds]
mikepack has quit [Remote host closed the connection]
cj3kim has left #ruby ["Leaving"]
<Cache_Money> I have an array of one letter strings and an array of words (strings). Trying to test whether each word can be spelled using letters in array. Need some advice http://pastebin.com/fnyk740K
gmci has quit [Quit: Computer has gone to sleep.]
davidcelis_ has quit [Quit: ZNC - http://znc.in]
gmci has joined #ruby
Jake232 has joined #ruby
dev_ryan70 has quit [Remote host closed the connection]
<bnagy> what have you tried so far?
davidcelis_ has joined #ruby
davidcelis_ has quit [Client Quit]
davidcelis_ has joined #ruby
mercwith1mouth has joined #ruby
davidcelis_ has quit [Client Quit]
<Cache_Money> bnagy: I know my logic is wrong... and I'm having trouble focusing right now http://pastebin.com/ms2z8QvR
pingfloyd has quit [Ping timeout: 245 seconds]
<GeekOnCoffee> woo I love it when I can solve problems like this after a few drinks
wmoxam has quit [Quit: Lost terminal]
<GeekOnCoffee> although I'm ignoring duplication of letters
<dominikh> if you ignore that, it's a one-liner :P
<GeekOnCoffee> actually, I was trying too hard
<GeekOnCoffee> it's a one-liner even with duplicate levels
<bnagy> Cache_Money: I think you're kind of on the right track
<bnagy> so %w( h e l o ) shouldn't spell "hello"?
<Cache_Money> bnagy: correct
itnomad has joined #ruby
<GeekOnCoffee> well that sucks… it really is an awesome one-liner otherwise… words.select{|w| (w.split(//) - user_arr).empty?}
FifthWall has quit [Quit: Goodbye everyone]
deryl has joined #ruby
verto|off is now known as verto
<bnagy> GeekOnCoffee: don't think that would work anyway, like it should spell hoe and ho I guess
<bnagy> oh sorry wrong way round :)
<bnagy> my bad
catery has joined #ruby
<catery> can anyone compare rails to struts2 for me?
<bnagy> GeekOnCoffee: hm in that case then why does your solution not just work?
<Cache_Money> bnagy: http://pastebin.com/NZF1kEtv I'm close but it's not find "well" Any ideas?
<bnagy> Cache_Money: eh? that looks like a different problem?
<GeekOnCoffee> bnagy: [1,1,1,1,1,1]-[1] => []
emmanuelux has quit [Ping timeout: 246 seconds]
<bnagy> oic you didn't include the inputs
<elico> >> [1,1,1,1,1,1]-[1]
<al2o3cr> (Array) []
<bnagy> ahhh..
<bnagy> stupid set -
catery has left #ruby [#ruby]
<GeekOnCoffee> catery: rails is ruby, which is enjoyable to write, struts2 is java, which is torture
<GeekOnCoffee> and you're gone
<Cache_Money> bnagy: I think it has something to do with the line user_arr = arr
aristidesfl has quit []
<bnagy> Cache_Money: I can't read your code, because you don't have the input listed , and your indenting is horrible
mdelcx has joined #ruby
<bnagy> but you probably want to dup or clone the letter array if you're going to delete from it
seanstickle has quit [Quit: seanstickle]
<Cache_Money> bnagy: http://pastebin.com/radsydhf
pingfloyd has joined #ruby
ronnieBoy has joined #ruby
<bnagy> Cache_Money: yeah you still didn't include the array you're testing with, but like I said, dup the input array
<Cache_Money> bnagy: duplicating the array fixed the problem. Although I'm still worried that iterating over each word in the dictionary will take some time with the code I have now
<Cache_Money> bnagy: oops. I was using arr = %(h e l l o w o r l d)
savage- has quit [Remote host closed the connection]
savage- has joined #ruby
<bnagy> well this is actually a pretty well studied area for algorithms
<bnagy> scrabble and such
<bnagy> so there's plenty of literature if you want to go looking for it
ananthakumaran has joined #ruby
verto is now known as verto|off
mercwith1mouth has quit [Ping timeout: 244 seconds]
dev_ryan70 has joined #ruby
null- has joined #ruby
LBRapid has joined #ruby
dev_ryan70 has quit [Ping timeout: 276 seconds]
chaplain is now known as christmas
christmas is now known as chaplain
hernerdies has quit [Ping timeout: 250 seconds]
chaplain is now known as christmas
christmas is now known as Guest4069
Beoran__ has quit [Ping timeout: 252 seconds]
null- has left #ruby [#ruby]
Takehiro has joined #ruby
Guest4069 is now known as chaplain
billyoc has quit [Quit: unicode me]
LBRapid has quit [Quit: LBRapid]
Takehiro has quit [Ping timeout: 245 seconds]
perry has quit [Ping timeout: 246 seconds]
perryh has joined #ruby
tr4656 has quit [Ping timeout: 246 seconds]
thorncp has quit [Ping timeout: 246 seconds]
thorncp has joined #ruby
tr4656 has joined #ruby
billyoc has joined #ruby
uris has quit [Quit: leaving]
areil has joined #ruby
Beoran__ has joined #ruby
catery has joined #ruby
<catery> So why do i want to setup rails with nginx vs unicorn vs lighthy vs whatever else i don't understand
fearoffish has quit [Ping timeout: 252 seconds]
iToast has joined #ruby
<davidcelis> #rubyonrails
<iToast> davidcelis, How did you know
<iToast> I wanted that chnnel
<iToast> e.e
<davidcelis> i was talking to catery
<davidcelis> but you're welcome too
<catery> #rubyonrails requires giving email addr
<catery> not doing that
fearoffish has joined #ruby
<davidcelis> sux2bu
<iToast> catery, ...?
<davidcelis> that's where rails is
<davidcelis> why even connect to FreeNode if you're not willing to register a nick
<catery> not giving away my email addr so i can get spam in my inbox
<davidcelis> they're a pretty trusted server
<davidcelis> lol yeah bro, freenode's gonna spam the fuck out of you
<davidcelis> glwt
mwilson_ has quit [Excess Flood]
mwilson_ has joined #ruby
noyb has joined #ruby
<TheMoonMaster> Freenode spams me, so hard.
<TheMoonMaster> Not really. But I find it funny that someone would think that.
mercwith1mouth has joined #ruby
Takehiro has joined #ruby
fyolnish has joined #ruby
mwilson_ is now known as shadda_
mohits has quit [Remote host closed the connection]
shadda_ is now known as mwilson`
jorge has joined #ruby
jenrzzz has joined #ruby
billyoc has quit [Read error: Connection reset by peer]
jgrevich has quit [Quit: jgrevich]
Hanmac1 is now known as Hanmac
sambio has quit [Quit: Saliendo]
pingfloyd has quit [Quit: pingfloyd]
Takehiro has quit [Remote host closed the connection]
banisterfiend has joined #ruby
c0rn_ has joined #ruby
Banistergalaxy has quit [Ping timeout: 248 seconds]
Synthead has quit [Quit: p33 ba115]
k_89 has joined #ruby
Takehiro has joined #ruby
NiteRain has quit [Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/]
charliesome has joined #ruby
digitalcakestudi has quit [Ping timeout: 252 seconds]
Takehiro has quit [Remote host closed the connection]
Cache_Money has quit [Ping timeout: 244 seconds]
jearvondharrie2 has quit [Ping timeout: 244 seconds]
dev_ryan70 has joined #ruby
c0rn_ has quit []
Synthead has joined #ruby
Synthead has quit [Remote host closed the connection]
Bosma has quit [Ping timeout: 264 seconds]
dev_ryan70 has quit [Ping timeout: 276 seconds]
phanousit has joined #ruby
banisterfiend has quit [Remote host closed the connection]
ringotwo has joined #ruby
und3f has joined #ruby
xbayrockx has joined #ruby
banisterfiend has joined #ruby
phanousit has quit [Ping timeout: 260 seconds]
Takehiro has joined #ruby
yxhuvud has joined #ruby
t87427 has quit [Remote host closed the connection]
t32738 has joined #ruby
Cache_Money has joined #ruby
LBRapid has joined #ruby
catery has quit [Quit: Page closed]
yubiwasabi2 has quit [Quit: Computer has gone to sleep.]
ringotwo has quit [Remote host closed the connection]
answer_42 has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
mariooo-sleep is now known as mariooo
nricciar has quit [Ping timeout: 252 seconds]
nricciar has joined #ruby
Cache_Money has quit [Ping timeout: 248 seconds]
mercwith1mouth has quit [Ping timeout: 264 seconds]
jorge has quit [Remote host closed the connection]
LBRapid has quit [Quit: LBRapid]
carrythe1ero is now known as carrythezero
diegoviola has quit [Ping timeout: 260 seconds]
justsee has quit [Quit: Leaving...]
<mdelcx> im sending a multipart post with rest-client, and I'm having trouble getting the redirect url that comes back from the inital response
<mdelcx> im sending a multipart post with rest-client, and I'm having trouble getting the redirect url that comes back from the inital response
cdepue has joined #ruby
ringotwo has joined #ruby
ringotwo has quit [Remote host closed the connection]
<notwen> how could I take Dir['plugins/*.rb'].each {|p| puts p.gsub(/(plugins\/|\.rb)/, '').to_s} and make it actually turn the output to a string? to_s isn't doing anything
mohits has joined #ruby
Banistergalaxy has joined #ruby
itnomad has quit [Quit: Leaving]
<Hanmac> notwen the output is allready a string
<notwen> Hanmac, even when it doesn't have "'s around the output?
banisterfiend has quit [Ping timeout: 244 seconds]
<davidcelis> puts doesn't show the outer quotes
deryl has quit [Quit: deryl]
fyolnish has quit [Remote host closed the connection]
fyolnish has joined #ruby
fyolnish has quit [Ping timeout: 252 seconds]
dev_ryan70 has joined #ruby
thaz has joined #ruby
OODavo has joined #ruby
<OODavo> I've written a tool fairly similar to Rake, which registers Procs as "commands" (basically tasks). I'm trying to have each command executed in a unique method scope, so that commands don't encroach on each other (some methods are defined inside the commands' blocks).
<OODavo> To achieve this, I'm trying to evaluate the commands' blocks inside an anonymous module (Module.new do). However, methods defined in one command's block seem still to be accessible from other commands. Do methods just not work that way, or is there another evaluation technique I should be using?
dev_ryan70 has quit [Ping timeout: 246 seconds]
<OODavo> I also tried defining a custom class that runs a block with instance_eval, under the assumption that any methods in that block would be defined on the eigenclass. Doesn't seem to work either, though.
<OODavo> I suspect in the eigenclass case that happened because the methods are just "def method" rather than "def self.method", but I don't understand why that would be an issue when using Module.new instead.
<Banistergalaxy> Noob
<Banistergalaxy> ;)
qwebirc47241 has quit [Quit: Page closed]
Takehiro has quit [Remote host closed the connection]
Guest5516 has joined #ruby
Essobi has quit [Ping timeout: 246 seconds]
Progster has quit [Ping timeout: 260 seconds]
banisterfiend has joined #ruby
Essobi has joined #ruby
<OODavo> As far as I can tell from Metaprogramming Ruby and Stack Overflow, instance_eval sets the current class to the object's eigenclass and therefore a regular def /should/ put a method on that eigenclass. So why doesn't it? :/
<banisterfiend> OODavo: can you show how your'e using it?
<banisterfiend> OODavo: it works here, see:
<banisterfiend> >> o = Object.new; o.instance_eval { def pig; "piggywig"; end }; o.pig
<al2o3cr> (String) "piggywig"
<bnagy> mmmm pork
Banistergalaxy has quit [Ping timeout: 246 seconds]
shadoi has quit [Quit: Leaving.]
Guest66077 has quit [Quit: Guest66077]
Takehiro has joined #ruby
jorum has joined #ruby
<banisterfiend> bnagy: sup nags
t32738 has quit [Remote host closed the connection]
<OODavo> Minimal example of the design I'm trying to use: http://sprunge.us/dAcL?ruby
t8438 has joined #ruby
<OODavo> I'd expect that in the second block, a_method() would be undefined and produce a NoMethodError. It doesn't, though.
<banisterfiend> OODavo: you want: Scope.new(&a)
<banisterfiend> not, Scope.new { a.call }
<banisterfiend> OODavo: this would work too, but isn't very nice: Scope.new { instance_eval(&a) }
<OODavo> Ah. That does produce the right result.
<OODavo> Trouble is, in the real code, it's Scope.new { a.call with_an_argument }
<banisterfiend> OODavo: then use this: Scope.new { instance_exec(with_an_argument, &a) }
devnull_ has quit [Remote host closed the connection]
<banisterfiend> OODavo: or redefine your Scope#intialize method so it takes argumetns as well as a block
<banisterfiend> and change tis implementation to use: instance_exec(*args, &block)
hekin has joined #ruby
<OODavo> Right. Thanks.
khakimov has quit [Quit: Computer has gone to sleep.]
Takehiro has quit [Remote host closed the connection]
replore has joined #ruby
Axsuul has quit [Read error: Connection reset by peer]
matrixise has quit [Ping timeout: 276 seconds]
Axsuul has joined #ruby
timonv has quit [Ping timeout: 245 seconds]
iToast has quit [Quit: Leaving]
Takehiro has joined #ruby
mucker has joined #ruby
timonv has joined #ruby
ph^ has joined #ruby
daniel_hinojosa has quit [Quit: Leaving.]
und3f has quit [Quit: Leaving.]
stuartrexking has joined #ruby
und3f has joined #ruby
pradeepto has quit [Ping timeout: 246 seconds]
jorge has joined #ruby
und3f has quit [Client Quit]
und3f has joined #ruby
pradeepto has joined #ruby
und3f has quit [Client Quit]
tr4656 has quit [Ping timeout: 246 seconds]
und3f has joined #ruby
crankycoder has quit [Ping timeout: 246 seconds]
crankycoder has joined #ruby
und3f has quit [Client Quit]
und3f has joined #ruby
zii has left #ruby ["WeeChat 0.3.7"]
replore has quit [Remote host closed the connection]
tr4656 has joined #ruby
nim_ has quit [Ping timeout: 255 seconds]
jorge has quit [Ping timeout: 252 seconds]
fantazo has joined #ruby
tr4656 has quit [Ping timeout: 246 seconds]
thone_ has joined #ruby
timonv has quit [Ping timeout: 244 seconds]
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
nukenn has joined #ruby
<nukenn> how can I make my script to update with the latest file in github ?
vandemar has quit [Ping timeout: 246 seconds]
thone has quit [Ping timeout: 245 seconds]
vandemar has joined #ruby
tr4656 has joined #ruby
<nukenn> can anyone hear me ? do I have voice permissions in this channel ?
* nukenn hello ?
<banisterfiend> nukenn: no, i cant see anything you're typing. Must be some kind of bug, you should send an email to freenode
<nukenn> banisterfiend: lol
<nukenn> here I wrote a script and Im gonna host it on github . I wanna add a update function to the script so users can update it automatically trough githun . any help ?
<nukenn> github *
stuartrexking has quit [Quit: Leaving...]
yxhuvud has quit [Ping timeout: 252 seconds]
* nukenn ummm anyone
tr4656 has quit [Ping timeout: 246 seconds]
<OODavo> Have your function download the head revision of the script off Github?
<OODavo> Alternatively, have the users clone the actual git repo and then just make your function do a git pull.
Essobi has quit [Ping timeout: 246 seconds]
thaz has quit [Quit: thaz]
mc0e has quit [Ping timeout: 276 seconds]
<nukenn> OODavo: no thats the problem . I dont no how to write that function download the latest version
tr4656 has joined #ruby
dev_ryan70 has joined #ruby
<OODavo> If the script doesn't need to be platform-independent, just shell out to wget for that purpose.
<OODavo> If you /do/ need platform-independence, this SO answer appears to address it: http://stackoverflow.com/questions/2263540/how-do-i-download-a-binary-file-over-http-using-ruby
Takehiro has quit [Remote host closed the connection]
<bnagy> nukenn: if it's a ruby script then you should make it a gem and publish it
<nukenn> OODavo: how to check if the versions are grater or less ?
<bnagy> that's what they're for
nim_ has joined #ruby
<bnagy> nobody is going to want to use your own weird revision control system based on shelling out to git pull
<nukenn> bnagy: what do u mean make a gem and release ?
<bnagy> google tiem!
Takehiro has joined #ruby
<nukenn> bnagy: but normal ruby scripts has --update right ? Im just asking how are they doing it . because u need to check the version of the script that u has then the remote version if its grater or less then update and replace with the files that u has
baphled has quit [Ping timeout: 246 seconds]
justinmcp has joined #ruby
atno has quit [Quit: Leaving...]
dev_ryan70 has quit [Ping timeout: 246 seconds]
<bnagy> the gem infrastructure handles updates for the vast majority of ruby code that people release
<bnagy> and it's independant of where the source is hosted
tr4656 has quit [Ping timeout: 246 seconds]
<bnagy> but you need to package your code as a gem, and there are some steps involved
<nukenn> its a very simple script . Im not sure , isn it too much to make a gem outof it ?
<bnagy> if you expect anyone to use it and you expect to update it, probably not, no
bradhe has quit [Remote host closed the connection]
banisterfiend has quit [Ping timeout: 240 seconds]
tr4656 has joined #ruby
Essobi has joined #ruby
ryanf has quit [Quit: leaving]
mrdodo has joined #ruby
rudyl313 has quit [Quit: Page closed]
atno has joined #ruby
t8438 has quit [Remote host closed the connection]
t19774 has joined #ruby
mwilson` has quit [Excess Flood]
mwilson` has joined #ruby
Banistergalaxy has joined #ruby
s1n4 has joined #ruby
noyb has quit [Ping timeout: 245 seconds]
arturaz has joined #ruby
dangerousdave has joined #ruby
freeayu has quit [Ping timeout: 264 seconds]
cdepue has quit [Remote host closed the connection]
hekin has quit [Quit: hekin]
chimay has joined #ruby
justinmcp has quit [Remote host closed the connection]
s1n4 has quit [Quit: leaving]
brianpWins has quit [Quit: brianpWins]
atno has quit [Read error: Connection reset by peer]
lkba has quit [Quit: Bye]
atno has joined #ruby
brianpWins has joined #ruby
elico has quit [Quit: elico]
graspee has joined #ruby
Xeago__ has quit [Read error: Connection reset by peer]
Xeago has joined #ruby
mohits has quit [Remote host closed the connection]
imami|afk is now known as banseljaj
jamaa has joined #ruby
ly_gs has joined #ruby
<jamaa> hi, is there a way to access last evaluated result in ruby like in irb '_' ? Let's say I want to add some 'puts' at the end of existing methods, and I want to return whatever value it was supposed return before me adding puts. is the a way to do it ?
BrianJ has quit [Quit: Computer has gone to sleep.]
replore_ has joined #ruby
yasushi has quit [Remote host closed the connection]
banisterfiend has joined #ruby
<Hanmac> jamaa nope
<OODavo> jamaa: Well, puts evaluates to a result (nil), so it would replace the previous _ value anyway.
<OODavo> Object#tap might be what you're after.
c0rn_ has joined #ruby
<jamaa> OODavo: my intention is to add some printing for a debugging but without affecting the result value which is nil for puts
ronnieBoy has quit [Quit: Leaving...]
<banisterfiend> jamaa: what u trying to do exactly
<banisterfiend> jamaa: ah, u can do this: meth1.meth2.meth3.tap(&:display).meth4
Banistergalaxy has quit [Ping timeout: 252 seconds]
<jamaa> banisterfiend: lets say I have some method that returns value, but I want to debug it and for debugging I add puts at the end of the method. now instead of whatever result this method was going to return i'm going to get nil cause of puts, so I ask if there is something like _ in irb, so I can add last_val = _, puts xxxxx, return last_val
<OODavo> Definitely use Object#tap for this.
<banisterfiend> jamaa: as OODavo says, use tap
<banisterfiend> OODavo: or use p
<banisterfiend> jamaa: using 'p' will return the object too
<OODavo> some.big.complicated.expression.tap &:display == some.big.complicated.expression, except that it runs the tap code as well.
<banisterfiend> jamaa: p 5 #=> 5
<jamaa> will read about tap, thanks for hint. but would be nice to have something like _ in the lang itself
punkrawkR has joined #ruby
replore_ has quit [Remote host closed the connection]
<banisterfiend> jamaa: also, look into using a better debugger than 'puts' :)
<banisterfiend> jamaa: http://pryrepl.org
bradhe has joined #ruby
chimay has quit [Remote host closed the connection]
<jamaa> banisterfiend: actually I using rubymine which has great debugger, I was just wondering if there is such thing in language so gave puts for debugging as an example
<banisterfiend> ah ok
<OODavo> Object#tap works in pretty much all circumstances where you'd want _, I think.
<banisterfiend> jamaa: you could implement _ pretty easily i think
replore_ has joined #ruby
<jamaa> banisterfiend: maybe after i finish reading eliquent ruby, cause for now I have no idea how to implement _ :)
<banisterfiend> jamaa: lol @ spelling "eloquent" wrong ;)
<jamaa> oops :)
<banisterfiend> jamaa: goodluck
rakl has quit [Quit: sleeping]
<jamaa> thanks a lot guys
mohamad has joined #ruby
jamaa has quit [Quit: Leaving]
mohamad has quit [Remote host closed the connection]
robustus has joined #ruby
dev_ryan70 has joined #ruby
banisterfiend has quit [Remote host closed the connection]
Banistergalaxy has joined #ruby
Russell^^ has joined #ruby
justsee has quit [Quit: Leaving...]
rakl has joined #ruby
dev_ryan70 has quit [Ping timeout: 246 seconds]
uokesita has joined #ruby
suborbital has joined #ruby
hipertracker has joined #ruby
<suborbital> ive ran out of things tooo.
replore_ has quit [Remote host closed the connection]
nukenn has quit [Ping timeout: 245 seconds]
matrixise has joined #ruby
cantonic_ has joined #ruby
cantonic has quit [Ping timeout: 255 seconds]
cantonic_ is now known as cantonic
atno has quit [Quit: Leaving...]
Chryson has quit [Quit: Leaving]
SCommette has joined #ruby
radic has quit [Read error: Operation timed out]
t19774 has quit [Remote host closed the connection]
t45599 has joined #ruby
radic has joined #ruby
SCommette has quit [Client Quit]
ly_gs has quit [Remote host closed the connection]
cdepue has joined #ruby
SCommette has joined #ruby
specialGuest has joined #ruby
specialGuest has quit [Changing host]
specialGuest has joined #ruby
banseljaj is now known as imami|afk
cdepue has quit [Ping timeout: 240 seconds]
k_89 has quit [Ping timeout: 248 seconds]
atmosx has joined #ruby
atmosx has quit [Client Quit]
adambeynon has joined #ruby
atno has joined #ruby
nim__ has joined #ruby
atmosx has joined #ruby
nim_ has quit [Ping timeout: 272 seconds]
specialGuest has quit [Quit: WeeChat 0.3.8]
SCommette has quit [Quit: SCommette]
wallerdev has quit [Quit: wallerdev]
Niamkik has joined #ruby
SCommette has joined #ruby
chimay has joined #ruby
matrixise has quit [Ping timeout: 276 seconds]
wez has joined #ruby
OODavo has left #ruby [#ruby]
banisterfiend` has joined #ruby
Banistergalaxy has quit [Ping timeout: 246 seconds]
phrame_ has joined #ruby
mrdodo has quit [Remote host closed the connection]
phrame has quit [Ping timeout: 256 seconds]
phrame_ is now known as phrame
Oliver` has joined #ruby
wez has quit [Quit: Colloquy for iPhone - http://colloquy.mobi]
Oliver` has quit [Quit: Bye, friends!]
nari_ has quit [Ping timeout: 246 seconds]
dev_ryan70 has joined #ruby
ph^ has quit [Remote host closed the connection]
sepp2k has joined #ruby
Mon_Ouie has quit [Ping timeout: 276 seconds]
nim__ has quit [Ping timeout: 244 seconds]
adambeynon has quit [Quit: Computer has gone to sleep.]
adambeynon has joined #ruby
c0rn_ has quit []
dev_ryan70 has quit [Ping timeout: 272 seconds]
jenrzzz has quit [Ping timeout: 272 seconds]
fearoffish has quit [Quit: Computer has gone to sleep.]
mbk has quit [Ping timeout: 264 seconds]
<mdelcx> working with curl (via curb)... how can I get the "location" header in the response?
x0F has quit [Disconnected by services]
x0F_ has joined #ruby
x0F_ is now known as x0F
nim__ has joined #ruby
Niamkik has quit [Remote host closed the connection]
gmci has quit [Quit: Computer has gone to sleep.]
gmci has joined #ruby
rakl has quit [Quit: sleeping]
ph^ has joined #ruby
Foxandxss has joined #ruby
ph^ has quit [Ping timeout: 264 seconds]
<matti> mdelcx: on_header {} ?
mbk has joined #ruby
edwardj has joined #ruby
pskosinski has quit [Read error: No route to host]
rakl has joined #ruby
pskosinski has joined #ruby
<atmosx> is there any optoin to make ruby's output verbose?>
<atmosx> there's something but I can't recall the flag
<matti> atmosx: -d
<atmosx> -d?
<atmosx> omg
<matti> ;d
<matti> atmosx: And if that is not enough, look at any profiler.
<matti> ;][
LouisGB has joined #ruby
<banisterfiend`> matti: has any man ever misinterpreted your winks and tried to bring u home
rakl has quit [Quit: sleeping]
SCommette has quit [Quit: SCommette]
twinturbo has joined #ruby
<matti> banisterfiend`: No.
jenrzzz has joined #ruby
<matti> banisterfiend`: At least, not the opposite sex.
<matti> ;]
<banisterfiend`> matti: I a misinterpreting your winks right now. *beware!* *beware!*
<matti> Oh.
<matti> Ohh.
<matti> Right.
<matti> Em.
<matti> I mean.
<matti> Look there ->
* matti runs away
<matti> :>
<matti> banisterfiend`: Are you in the US as well? [ Just our of curiosity ]
DarthGandalf has quit [Ping timeout: 260 seconds]
<banisterfiend`> matti: New Zealand
caveat- has quit [Ping timeout: 260 seconds]
<matti> WOT
<matti> Awesome ;]
<mdelcx> figured out my issue
berserkr has joined #ruby
ph^ has joined #ruby
Takehiro has quit [Remote host closed the connection]
<mdelcx> im writing a gem that has a class file and a module with the same name
<matti> Ah.
<mdelcx> the module is in lib/foo.rb and the class is in lib/foo/foo.rb
<mdelcx> when i require 'foo/foo' i get an error
<mdelcx> any ideas?
<mdelcx> any ideas?
ub|k has quit [Quit: leaving]
DarthGandalf has joined #ruby
<mdelcx> sry*
<atmosx> mdelcx: require_relative
caveat- has joined #ruby
dev_ryan70 has joined #ruby
<burgestrand> mdelcx: what error?
<burgestrand> don’t use require_relative in gems, it’s just unnecessary
Progster has joined #ruby
gry has quit [Quit: gone]
<Hanmac> burgestrand if you want to blockout 1.8 it is :P
SegFaultAX|work2 has quit [Ping timeout: 276 seconds]
<burgestrand> in that case just set required ruby version in gemfile and raise in your main file if somebody uses it with 1.8 :p
Vert has joined #ruby
ph^ has quit [Remote host closed the connection]
<Hanmac> most of my gems will not finish before june 2013 so i have no reason why i should support 1.8
dev_ryan70 has quit [Ping timeout: 276 seconds]
specialGuest has joined #ruby
specialGuest has quit [Changing host]
specialGuest has joined #ruby
omry has quit [Ping timeout: 252 seconds]
dejanr has joined #ruby
<Hanmac> with my gems i can do 3D games with ruby
baphled has joined #ruby
dejanr has quit [Quit: leaving]
<shevy> mdelcx you can use setup.rb to install stuff into your ruby SITE DIR
mwilson` has quit [Excess Flood]
xorgnak has joined #ruby
mwilson` has joined #ruby
<mdelcx> figured it out
<mdelcx> thanks
resure has joined #ruby
resure is now known as resure_away
elaptics`away is now known as elaptics
<matti> ;]
psyl0n has quit [Quit: psyl0n]
<Hanmac> matti do you want to see my 3D engine binding for ruby in action? i maked a little video
<banisterfiend`> matti: wtf did the idea for this: ;] come from? why has he got a square mouth and why is he winking? whats the significance of it?
<matti> Hanmac: Yes yes!
<matti> banisterfiend`: Emm. I don't know.
<matti> banisterfiend`: I just wink sometimes.
<matti> banisterfiend`: Is this bad? ;]
<banisterfiend`> matti: Yeah, i feel intruded upon physically and emotionally
<matti> banisterfiend`: But this is only in your head ;]
<matti> p
<matti> Hanmac: Looks awesome :)
<matti> banisterfiend`: You have +o, and if you wish so, you can kick me / ban me if smiles are so much of a bother. Um.
<matti> ;d
<banisterfiend`> matti: hehehe
<Hanmac> and it has still 20FPS ...
<banisterfiend`> matti: im just teasing u :)
<matti> banisterfiend`: I know :)
arist` has joined #ruby
justsee has joined #ruby
<matti> Ahh.
justsee has quit [Client Quit]
<matti> Why it is so hard to get job in Japan ;/
Takehiro has joined #ruby
<matti> LOL
<matti> Takehiro: :)
<matti> I wonder if what just happened was a mere co-incidence ;d
arist` has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
t45599 has quit [Remote host closed the connection]
t37780 has joined #ruby
bluebie has joined #ruby
Takehiro has quit [Ping timeout: 244 seconds]
l has joined #ruby
l is now known as Guest72329
s1n4 has joined #ruby
Guest72329 has left #ruby [#ruby]
elico has joined #ruby
<Hanmac> matti
schaerli has joined #ruby
resure_away is now known as resure
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
resure has quit [Remote host closed the connection]
dekroning has joined #ruby
Virunga has joined #ruby
Takehiro has joined #ruby
<Takehiro> matti: ???
yasushi has joined #ruby
frogprince_mac has joined #ruby
dev_ryan70 has joined #ruby
<matti> Takehiro: Sorry :) I was talking about Japan, and then you joined with *.jp host ;]
<Takehiro> i c :o
<Takehiro> what about japan?
<matti> Takehiro: I am trying to fulfill my life's long dream of moving to Japan.
<Takehiro> really :O
<matti> Takehiro: And recently I am looking for job there.
<Takehiro> where do u live right now
<Takehiro> i c
<matti> And that is what happened:
<matti> [13:28:32] < matti> Why it is so hard to get job in Japan ;/
<matti> [13:30:10] >> Takehiro [~Takehiro@zaq77197637.zaq.ne.jp] has joined #ruby
<matti> ;]
<Takehiro> :d
<matti> Takehiro: I am in London, UK.
<Takehiro> might be cuas most of the people in japan cant speak
<Takehiro> english
<matti> Takehiro: I have heard that Tokyo is better in that regards.
<matti> Takehiro: But indeed, a lot of people told me that I need business level Japanese.
ph^ has joined #ruby
<Takehiro> yea, ull def need that
<matti> Takehiro: I am learning Japanese in London for about a year now.
<matti> Takehiro: Somebody on Twitter send me link to: http://global.rakuten.com/careers/
<Takehiro> will be differenct if ur aiming for like google japan, buya
<Takehiro> but yea*
<matti> There is a recruiter in London who is looking for English speaker to join some company in Tokyo.
<matti> I am full of hope ;]
<matti> Which is funny, because I am not a native English speaker anyway ;d
timonv has joined #ruby
<Hanmac> i want travel to tokyo too ... but my japanese is not so good :(
<banisterfiend`> Hanmac: neither is your english
<matti> banisterfiend`: ... ;p
<banisterfiend`> :D
<matti> banisterfiend`: You big tease you.
dev_ryan70 has quit [Ping timeout: 276 seconds]
<banisterfiend`> just trying to get a reaction :)
<matti> banisterfiend`: You are recently so Passive-Aggressive ;p
<Hanmac> i could travel to UK first, impov my english, and then i travel to japan :P
ph^ has quit [Ping timeout: 246 seconds]
<matti> banisterfiend`: ;] ;] ;] ;] ;] ;] ;] ;] ;] ;]
<banisterfiend`> matti: i would have described it as just aggressive
<banisterfiend`> nothing that passive about it ;)
<matti> banisterfiend`: I was trying to be polite p
Virunga has quit [Remote host closed the connection]
<matti> Takehiro: Anyhow, I am not sure how to do it yet, but I am motivated :)
<matti> Takehiro: Even my Sensei (at the Japanese school) is encouraging me to try :)
<Takehiro> :D
Virunga has joined #ruby
<matti> And I do like sound of cicadas in summer ;p
<matti> ;p
<Hanmac> matti you could try to tavel prefore you learn the language :P it could be a motivation-boost :P
<matti> Hanmac: I never have enough money to buy ticket.
<Hanmac> i dont have too :(
<matti> Hanmac: I bought one a year ago, but then Tsunami stroke.
<matti> Hanmac: And I lost my ticket / chance.
<matti> Hanmac: Only got very little refunded which set back my plans a little :)
omry has joined #ruby
ph^ has joined #ruby
berserkr has quit [Quit: Leaving.]
und3f has quit [Ping timeout: 244 seconds]
und3f has joined #ruby
<albel727> looks like yet another new age kind of sect to me.
<albel727> hmm, no, not really new age. the one of those "corporation of successful people" types. oh well.
<matti> albel727: Rakuten?
<albel727> yeah
ph^ has quit [Ping timeout: 246 seconds]
edwardj has quit [Remote host closed the connection]
<matti> albel727: I am not sure how companies in Japan look like, but from what I was told and what I've seen, most resembles Rakuten.
Virunga has quit [Remote host closed the connection]
mengu has joined #ruby
mengu has quit [Changing host]
mengu has joined #ruby
<matti> albel727: I was not really able to find "startup like" mentality. I might be wrong, though.
<albel727> well, it's not like I can reliably tell what it really is just by looking at its site, either.
<matti> :)
<albel727> what tickles me off most, is its supposed internationality. japanese are bad with that.
t37780 has quit [Remote host closed the connection]
<matti> albel727: s/bad/not used to/ -- is what I've noticed.
t23063 has joined #ruby
<albel727> that's the same thing, for all intents and purposes.
Virunga has joined #ruby
<matti> albel727: Although, every single Japanese person in London I've met so far, was super-open about things like that. Which is what really impresses me.
<matti> Takehiro would have to comment ;d
und3f has quit [Ping timeout: 252 seconds]
<Takehiro> whats the things like that ? :O
<albel727> japanese person in london <- that's the problem. travelling japanese (and I don't really mean plain tourism), are wholly different beasts.
<matti> Ah.
<matti> Takehiro: Being open for other cultures etc etc.
<Takehiro> oh, most of the people arent open minded for those things :P
<matti> ;p
justinmcp has joined #ruby
<Takehiro> been improving these days, but still nah :p
<matti> Darn ;p
<matti> So, my chances are slim.
<matti> ;d
radic has quit [Read error: Connection reset by peer]
<albel727> they are. unless it's some very VERY unusual japanese company, you'll be better off working somewhere else.
<matti> It so funny.
<matti> Getting a job as English teacher seems to be easier.
<albel727> yeah
<matti> Trying to get a job as an Engineer seems to be next-to-impossible.
johnjohnson has joined #ruby
radic has joined #ruby
emmanuelux has joined #ruby
<albel727> it's only logical. japanese goverment is all for keeping workplaces for japanese. so they only open up for those kind of jobs, where a japanese can't reasonably handle.
<matti> albel727: True. And fair.
yasushi has quit [Remote host closed the connection]
<matti> albel727: But I've few people telling me that there is shortage of skills in Engineering as well.
<banisterfiend`> matti: software engineering?
<banisterfiend`> or a real kind?
<matti> banisterfiend`: Systems, Software ...
<matti> banisterfiend`: Haha
<matti> banisterfiend`: I see what you did there.
<matti> d;
<banisterfiend`> hehe
<banisterfiend`> most "software engineers" are woefully underqualified compared to their civil/electrical engineer counterparts
<Hanmac> albel727 so jobs with "R" are the only jobs for outsiders?
<matti> banisterfiend`: http://i.qkme.me/355949.jpg
<matti> banisterfiend`: I am not even a CS person ;] I was studying Physics ;d
* matti is such a nerd ;/
thaz has joined #ruby
<banisterfiend`> matti: cool
<banisterfiend`> matti: how far did u take it?
<matti> banisterfiend`: I decided to stop after getting BSc.
<banisterfiend`> ah ok
<matti> banisterfiend`: Getting a job that pay bills being a Physicist was ...
<banisterfiend`> do you still remember some of the math?
tommyvyo has joined #ruby
<matti> banisterfiend`: When I realised that, I quit and went with something else.
<matti> banisterfiend`: I am studying now CS.
<matti> banisterfiend`: But more for fun.
<banisterfiend`> matti: well, u can do alright as a physicist. My friend who studied physics now works for meteorology department
<Hanmac> matti you know that there are virtual particles that appears and disappears in the void? i read that they manage to turn them into "real" particles ...
<banisterfiend`> and loves it
fixl has quit [Quit: KVIrc 4.1.3 Equilibrium http://www.kvirc.net/]
<matti> Although, not sure how this is going to end. Tuition is so expensive in the UK right now. I may not be able to afford to finish.
<matti> banisterfiend`: :)
<banisterfiend`> matti: you should have studied in amsterdam where education is very cheap
<matti> Hanmac: Quantum Physics (or whichever branch concerns itself with virtual particles and multi-verse theories) is full of things like that.
<banisterfiend`> matti: my brother did a masters in law in amsterdam university for next to nothing
dev_ryan70 has joined #ruby
answer_42 has quit [Remote host closed the connection]
<matti> banisterfiend`: Well, when I was younger it was a little different story / time.
<matti> banisterfiend`: I was born in Poland.
<Hanmac> matti: that makes the startrek replcator "possible" :D ... the only problem is the enery source :(
<matti> banisterfiend`: And back then it was not even close to a "country of wholesale possibilities".
<matti> Hanmac: It is always about engergy ;]
<banisterfiend`> matti: maybe you can transfer to a university and get your current courses cross credited
<matti> Hanmac: FTL speed -- all about energy too ;d
mrck has joined #ruby
<matti> banisterfiend`: Maybe. But I don't know German / Duch.
<banisterfiend`> matti: you dont need to i think, their courses are in english iirc
<banisterfiend`> at least it was at masters level, not sure about undergrad
<matti> banisterfiend`: Plus, I would not move to Netherlands at this point in time.
* Hanmac thinks about a engine that steal enery from the void itself
savage- has quit [Remote host closed the connection]
<matti> Hanmac: There are energy sources apparently successful at doing that.
hagihala has joined #ruby
<matti> Hanmac: Alsmost like the zero-point energy we know form science ficiton series.
<Hanmac> yeah ... now we need to make them "real" :P
<matti> Hanmac: And people even keep inventing coils wired using some pattern common in the Universe claiming that they are more efficient.
<matti> Hanmac: None of which was proven by science yet ;d
<matti> banisterfiend`: I see no reason to get MSc. It seem redundant.
<Hanmac> matti question about turning matter into energy ... exist a way to convert matter into pure energy without using anti-matter?
<matti> banisterfiend`: I was thinkning about getting onto a PhD programme, but when I learned how much of a cut-throat business this is, and that I would have to move out to a shack in under the London Bridge.
<banisterfiend`> matti: well, it can give you an opportunity to specialize
<matti> banisterfiend`: I decided that its not worth the effort / money.
paolooo has joined #ruby
eldariof has joined #ruby
<matti> Hanmac: Define "pure energy" ;d
<matti> banisterfiend`: MSc in the UK now its ~9k.
<matti> banisterfiend`: No way I can afford that.
<banisterfiend`> matti: get the fuck out of the UK
<Hanmac> like heat or radiaton ... or something that can be used for electic energy
<matti> banisterfiend`: I am trying :) UK -> Japan
<banisterfiend`> matti: continental europe is cheap as chips and unless you're at cambridge/oxford, it's likely the continental university will be much higher ranked
hagihala has left #ruby ["Leaving..."]
* Hanmac is trying saxony -> somewhere else
<matti> banisterfiend`: I also cannot do a full time curse.
<matti> banisterfiend`: There is only me. I would have to work.
specialGuest has quit [Ping timeout: 244 seconds]
bapa has quit [Read error: Connection reset by peer]
bapa has joined #ruby
<banisterfiend`> matti: you could do it part time
yshh has joined #ruby
<matti> Not sure.
tommyvyo has quit [Quit: Computer has gone to sleep.]
Virunga is now known as LennyLinux
yshh has quit [Client Quit]
jarek has joined #ruby
yasushi has joined #ruby
fantazo has quit [Remote host closed the connection]
dekroning has quit [Remote host closed the connection]
paolooo has quit [Quit: Page closed]
hoelzro|away is now known as hoelzro
Xeago has quit [Read error: Connection reset by peer]
timonv_ has joined #ruby
jorum has quit [Quit: Leaving...]
yshh has joined #ruby
timonv has quit [Ping timeout: 240 seconds]
s1n4 has quit [Quit: leaving]
RudyValencia has quit [Quit: My IRC client doesn't advertise in /quit messages.]
Xeago has joined #ruby
edwardj has joined #ruby
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
deryl has joined #ruby
lggr has quit [Quit: leaving]
Eldariof-ru has joined #ruby
eldariof has quit [Ping timeout: 245 seconds]
dekroning has joined #ruby
lggr has joined #ruby
Axsuul has quit [Ping timeout: 246 seconds]
Eldariof-ru has quit []
eldariof has joined #ruby
lggr has quit [Client Quit]
ph^ has joined #ruby
lggr has joined #ruby
Spooner has joined #ruby
specialGuest has joined #ruby
ph^ has quit [Ping timeout: 246 seconds]
Agis__ has joined #ruby
<matti> Hanmac: I am trying to find you a link to a nice article about Ambient Energy, but I fail on hard with my bookmarks being a total mess.
jearvondharrie2 has joined #ruby
Progster has quit [Ping timeout: 260 seconds]
krion has left #ruby [#ruby]
<Hanmac> energy cant be destroyed ... but the link to topic about that can :P
aristidesfl has joined #ruby
LennyLinux has quit [Remote host closed the connection]
specialGuest1 has joined #ruby
niklasb has joined #ruby
specialGuest has quit [Ping timeout: 246 seconds]
Foxandxss has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
Agis__ has quit [Quit: Agis__]
dpk has joined #ruby
vlad_starkov has joined #ruby
<matti> Hanmac: And it requires a very little energy to do so ;d
justinmcp has quit [Remote host closed the connection]
dpk has quit [Ping timeout: 244 seconds]
dpk has joined #ruby
dpk has quit [Ping timeout: 260 seconds]
dpk has joined #ruby
dekronin1 has joined #ruby
sailias has quit []
dekroning has quit [Read error: Operation timed out]
LouisGB has quit [Ping timeout: 240 seconds]
dev_ryan70 has quit [Remote host closed the connection]
dpk has quit [Ping timeout: 245 seconds]
dpk has joined #ruby
dekronin1 has quit [Read error: Connection reset by peer]
Marshac has joined #ruby
johnjohnson has quit []
vlad_starkov has quit [Remote host closed the connection]
goodieboy has joined #ruby
binw has joined #ruby
gmci has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
dpk has quit [Ping timeout: 244 seconds]
Takehiro has quit [Remote host closed the connection]
dpk has joined #ruby
mrck has quit [Ping timeout: 255 seconds]
fatgeek has joined #ruby
mercwith1mouth has joined #ruby
brandon has joined #ruby
<fatgeek> Hi, I have a ruby code that pings a server or set of servers, the DNS is unlikely to change even once every few days
<fatgeek> would Resolv.getaddress(hostname) cache the DNS response or is it unto the application to cache the mapping and timeout ?
vitor-br has joined #ruby
Kiall has quit [Ping timeout: 252 seconds]
davidpk has joined #ruby
dpk has quit [Disconnected by services]
davidpk is now known as dpk
<elico> fatgeek: Resolve.getaddress is not suppose to cahche
<elico> >>Resolv.getaddress("www.walla.com")
<al2o3cr> -e:1:in `eval': uninitialized constant Resolv (NameError), from -e:1:in `eval', from -e:1:in `<main>'
<fatgeek> elico: thanks .
Takehiro has joined #ruby
<fatgeek> require 'resolv
<elico> hmm what is this resolve is?
vectorshelve has joined #ruby
<vectorshelve> /msg NickServ identify web2labswebl2abs
LennyLinux has joined #ruby
goodieboy has quit [Remote host closed the connection]
Takehiro has quit [Read error: Connection reset by peer]
Takehiro_ has joined #ruby
<elico> vectorshelve: you should do it on a private chat with the nickserv
<graspee> and change your password now hehe
vectorshelve has quit [Client Quit]
<elico> graspee: i have a question...
<graspee> shoot
jorge has joined #ruby
vectorshelve has joined #ruby
<elico> whoo it was fast
<vectorshelve> hi
<elico> too fast
<vectorshelve> elico: :)
<graspee> what's the question
<elico> so i am working on blacklisting domains...
dpk has quit [Ping timeout: 240 seconds]
<elico> so now i have the db to store the domain ..and the rules are: domain.com in db all domain.com domains and subdomains are blacklisted
gfontenot has joined #ruby
t23063 has quit [Remote host closed the connection]
jasonkuhrt has joined #ruby
<elico> while if i have domain.com and sub.domain.com it will only black list the two
t88562 has joined #ruby
<elico> so i'm thinking loud.... get all the domains prefix from the db and then ...
baphled has quit [Ping timeout: 245 seconds]
<elico> iterate over the array of domain and find if there is more then one of the domains and subdomains..
mohit has joined #ruby
Mon_Ouie has joined #ruby
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby
araujo has quit [Quit: Leaving]
jjbohn has joined #ruby
gmci has joined #ruby
ALFREDO has joined #ruby
ALFREDO has left #ruby [#ruby]
Kiall has joined #ruby
ph^ has joined #ruby
<vectorshelve> how can I impleement this.. http://pastie.org/4651023
<vectorshelve> shevy: hi man
<Mon_Ouie> define_method(string) { puts string }
mohit has quit [Client Quit]
mohit has joined #ruby
<elico> this is fast
<vectorshelve> Mon_Ouie: could you show me the syntax please.. thanks.. in the pastie
<elico> here i leard something...
<vectorshelve> elico: :)
<Mon_Ouie> Just call that method on Object
<Mon_Ouie> Object.send :define_method …
<elico> Mon_Ouie: it will be in your case "define_method(a) { puts a }"
<shevy> vectorshelve heya
Marshac has quit [Ping timeout: 245 seconds]
rakunHo has joined #ruby
<vectorshelve> Mon_Ouie cool thanks
<elico> >> ["hello", "hi", "hai"].each { |a| define_method(a) { puts a } }
<al2o3cr> -e:1:in `eval': undefined method `define_method' for main:Object (NoMethodError), from (eval):1:in `each', from (eval):1:in `<main>', from -e:1:in `eval', from -e:1:in `<main>'
<banisterfiend`> vectorshelve: you could also do: define_method(a) { puts __method__ }
<vectorshelve> banisterfiend`: ok.. Mon_Ouie it seems to give me the above error
ph^ has quit [Ping timeout: 246 seconds]
<banisterfiend`> vectorshelve: define_singleton_method
johnjohnson has joined #ruby
<elico> >>define_method("string") { puts __method__ }
<al2o3cr> -e:1:in `eval': undefined method `define_method' for main:Object (NoMethodError), from -e:1:in `eval', from -e:1:in `<main>'
<vectorshelve> banisterfiend`: singleton methods are methods defined on a single class.. whats that got to do with this ?
<elico> banisterfiend`: >>define_singleton_method("a") { puts __method__ }
<elico> seems to work
<banisterfiend`> >> define_singleton_method("string") { __method__ }; string
<al2o3cr> (Symbol) :string
<banisterfiend`> vectorshelve: trust me, im an expert
<banisterfiend`> :P
<vectorshelve> banisterfiend`: ok.. leme try :)
<elico> banisterfiend`: i will bring something...
<vectorshelve> banisterfiend`: it returns an the same array
<vectorshelve> banisterfiend`: ["hai","hello","hi"].each do |a| 1.9.3p194 :005 > define_singleton_method("a") { __method__ }; a 1.9.3p194 :006?> end => ["hai", "hello", "hi"]
<banisterfiend`> vectorshelve: u're a dement
<vectorshelve> banisterfiend`: :( sorry
specialGuest1 has quit [Ping timeout: 276 seconds]
* Hanmac is only helping people what wants to learn
<banisterfiend`> >> ["hai","hello","hi"].map { |a| define_singleton_method(a) { __method__ }; send(a) }
<al2o3cr> (Array) [:hai, :hello, :hi]
freeayu has joined #ruby
deryl has quit [Quit: deryl]
<vectorshelve> banisterfiend`: thanks
fatgeek has quit [Read error: Connection reset by peer]
fatgeek has joined #ruby
<elico> well i got it on code
dpk has joined #ruby
ph^ has joined #ruby
mercwith1mouth has quit [Ping timeout: 276 seconds]
yasushi has quit [Remote host closed the connection]
freeayu has quit [Quit: 离开]
<Hanmac> elico arr.any?{|s| s.include?(dom)}
schaerli has quit [Remote host closed the connection]
jarek has quit [Quit: jarek]
dpk has quit [Ping timeout: 244 seconds]
wo66le has joined #ruby
ZachBeta has joined #ruby
schaerli has joined #ruby
mohit has quit [Quit: Leaving]
sailias has joined #ruby
mohit has joined #ruby
<elico> Hanmac: not good.. arr2.any?{|s| s.include?(dom1)} should return true
mohit has quit [Client Quit]
<Hanmac> hm ok this is better: arr.any?{|s| dom.include?(s)}
mohits has joined #ruby
mohits has quit [Changing host]
mohits has joined #ruby
<elico> and... it should return for: arr.any?{|s| s.include?(dom)} false but return true
Kiall has quit [Quit: ZNC - http://znc.sourceforge.net]
dpk has joined #ruby
omry has quit [Remote host closed the connection]
<elico> it should first check if there are duplicates of a domain over a subdomain..
<elico> it should be pretty fast since the list should be really filtered on a tld level and country +tld
johnjohnson has quit []
Cache_Money has joined #ruby
ananthakumaran1 has joined #ruby
dpk has quit [Ping timeout: 245 seconds]
wo66le has quit [Quit: Computer has gone to sleep.]
ananthakumaran has quit [Ping timeout: 244 seconds]
atmosx has quit [Quit: Computer has gone to sleep.]
Neil_ has joined #ruby
ph^ has quit [Remote host closed the connection]
Kiall has joined #ruby
hoelzro is now known as hoelzro|away
johnjohnson has joined #ruby
ph^ has joined #ruby
sonkei has joined #ruby
atno has left #ruby ["Leaving..."]
tk___ has quit [Quit: ばいばい]
jearvondharrie2 has quit [Quit: WeeChat 0.3.9-dev]
pettsson has joined #ruby
samflores has joined #ruby
mercwith1mouth has joined #ruby
samflores has quit [Client Quit]
HotJessicaBOOBS has joined #ruby
VictorMartins has joined #ruby
HotJessicaBOOBS has quit [Killed (idoru (Spam is off topic on freenode.))]
<Cache_Money> I need some help conceptualizing an approach to this problem: I have a 4x4 grid of letters and I'm trying to make as many words as possible using adjacent letters (no repeating) http://a5.mzstatic.com/us/r1000/115/Purple/v4/48/06/81/480681cc-fc59-02f8-6089-aa59fd698c1b/mza_2979092071817216396.320x480-75.jpg
vitoravelino is now known as vitoravelino`afk
<Cache_Money> I already have an array of all the words in the English language, loop over those and see if it's possible to spell that world given the 16 input letters. But this approach doesn't take into account where the tile is on the board
emmanuelux has quit [Ping timeout: 246 seconds]
bluebie has quit [Quit: Linkinus - http://linkinus.com]
specialGuest1 has joined #ruby
sonkei has quit [Quit: Computer has gone to sleep.]
savage- has joined #ruby
yasushi has joined #ruby
specialGuest1 has quit [Read error: Connection reset by peer]
gfontenot has quit []
<matti> Cache_Money: Why so complex?
yasushi has quit [Read error: Connection reset by peer]
yasushi_ has joined #ruby
<Cache_Money> matti: which part?
<matti> Cache_Money: Can't you just check the word after somebody finishes sliding?
Xeago has quit [Remote host closed the connection]
<matti> They are cedent data structures designed to stre strings.
<matti> That allow for quick lookup.
dpk has joined #ruby
<Cache_Money> mattI: I want to identify the word so I can use it before my turn is over.
otters has quit [Ping timeout: 240 seconds]
<Cache_Money> matti: Here's how I'm going to use it: Once my turns start I input all the letters in their corresponding location. Hit the pause button, run this script, it spits out the words (with values from highest to lowest), then I resume the game
<Cache_Money> similar to the Words with Friends cheat http://www.omghalp.com/
<matti> Cache_Money: TI'd ask on StackOverflow or something. There is one for alghortms IIRC..
<Cache_Money> matti: Ok. Good call
<matti> :)
baphled has joined #ruby
answer_42 has joined #ruby
<matti> Takehiro_: Would you mind if I ask you about something?
<Takehiro_> yea sure :D
<Takehiro_> matti:
otters has joined #ruby
burgestrand has quit [Quit: Leaving.]
jjbohn has quit [Quit: Leaving...]
burgestrand has joined #ruby
t88562 has quit [Remote host closed the connection]
t52633 has joined #ruby
fatgeek has quit [Quit: fatgeek]
digitalcakestudi has joined #ruby
digitalcakestudi has quit [Read error: Connection reset by peer]
amskah has joined #ruby
digitalcakestudi has joined #ruby
arturaz has quit [Remote host closed the connection]
fkumro has quit [Quit: WeeChat 0.3.8]
savage- has quit [Remote host closed the connection]
johnjohnson has quit []
jasonkuhrt has quit [Quit: Leaving...]
otters has quit [Ping timeout: 252 seconds]
vitoravelino`afk is now known as vitoravelino
sarl has joined #ruby
sarl has quit [Client Quit]
Kiall has quit [Quit: ZNC - http://znc.sourceforge.net]
yshh has quit [Remote host closed the connection]
thaz has quit [Read error: Connection reset by peer]
lusory has joined #ruby
thaz has joined #ruby
thaz has quit [Read error: Connection reset by peer]
thaz has joined #ruby
edwardj has quit [Remote host closed the connection]
LBRapid has joined #ruby
jorge has quit [Remote host closed the connection]
deryl has joined #ruby
Kiall has joined #ruby
ph^ has quit [Remote host closed the connection]
<vectorshelve> can anyone explain to me this http://pastie.org/4651413
ph^ has joined #ruby
ph^ has quit [Remote host closed the connection]
<matti> Takehiro_: Have you seen my /query? ;]
<vectorshelve> shevy: ^^
<matti> >> a = 1 ; c = b = a ; p a, b, c
<al2o3cr> (Array) [1, 1, 1], Console: 1, 1, 1
<matti> Simples.
<matti> ;]
allsystemsarego has joined #ruby
allsystemsarego has quit [Changing host]
allsystemsarego has joined #ruby
qwerxy has joined #ruby
Cork has quit [Quit: .]
ph^ has joined #ruby
Cork has joined #ruby
<shevy> vectorshelve, so you have two variables @value and @new_value
<shevy> whoever wrote that must have thought he needs them both
LBRapid has quit [Quit: LBRapid]
dagnachewa has joined #ruby
heisenmink has joined #ruby
sarl has joined #ruby
gfontenot has joined #ruby
<Cache_Money> matti: I posted my question on Stack Overflow if you were interested in taking a stab at it http://stackoverflow.com/questions/12237422/4x4-grid-of-letters-word-generator-scramble-with-friends
cakehero has joined #ruby
gmci has quit [Quit: Computer has gone to sleep.]
specialGuest has joined #ruby
specialGuest has quit [Changing host]
specialGuest has joined #ruby
<matti> Cache_Money: OK, great :)
<matti> Cache_Money: Well done ;]
<matti> Cache_Money: Some hard-code thinkers tend to look there, so you may have some nice answers.
ixti has joined #ruby
wo66le has joined #ruby
gmci has joined #ruby
goodieboy has joined #ruby
goodieboy has quit [Remote host closed the connection]
otters has joined #ruby
sarl has quit []
pradeepto has quit [Changing host]
pradeepto has joined #ruby
Raduwen_ has joined #ruby
Raduwen has quit [Ping timeout: 255 seconds]
jonathanwallace has quit [Remote host closed the connection]
dagnachewa has quit [Quit: Leaving]
dagnachewa has joined #ruby
t52633 has quit [Remote host closed the connection]
t51319 has joined #ruby
nim__ has quit [Ping timeout: 248 seconds]
<shevy> yeah
<shevy> better post there than ask here
<shevy> :>
<shevy> YOU EVIL EVIL matti YOU
yoklov has joined #ruby
<matti> shevy: He was asking here as well.
<shevy> let's vote for the most evil person on #ruby
<shevy> matti +1
<matti> Phew.
<matti> I actually disagree.
* matti yields his score on behalf of banisterfiend`
<shevy> folks seem to be lazy today, noone else votes
khakimov has joined #ruby
<matti> shevy: No one else cares ;p
<shevy> :(
amskah has quit [Read error: Connection reset by peer]
<matti> Oh dear. Poor thing.
amskah has joined #ruby
yshh has joined #ruby
lusory has quit [Ping timeout: 246 seconds]
eldariof has quit [Ping timeout: 240 seconds]
eldariof has joined #ruby
Whoop has quit [Quit: WeeChat 0.3.8]
Wh00p has joined #ruby
sonkei has joined #ruby
yasushi_ has quit [Remote host closed the connection]
dagnachewa has quit [Remote host closed the connection]
wereHamster has quit [Changing host]
wereHamster has joined #ruby
A124 has joined #ruby
nim__ has joined #ruby
A124 has quit [Client Quit]
Raduwen_ has quit [Quit: Leaving...]
Whoop has joined #ruby
sepp2k1 has joined #ruby
berkes has joined #ruby
Takehiro_ has quit [Remote host closed the connection]
carl_ has joined #ruby
sepp2k has quit [Ping timeout: 276 seconds]
shevy has quit [Ping timeout: 244 seconds]
ixti has quit [Quit: So Long, and Thanks for All the Fish!]
<Hanmac> it seems that death is shevy-picking
fayimora has joined #ruby
Takehiro has joined #ruby
tommyvyo has joined #ruby
Criztian has joined #ruby
Agis__ has joined #ruby
specialGuest has quit [Ping timeout: 246 seconds]
vectorshelve has quit [Ping timeout: 245 seconds]
Whoop has quit [Quit: Gone]
Whoop has joined #ruby
<matti> Hanmac: LOL
jgrevich has joined #ruby
CodeVision has quit [Ping timeout: 240 seconds]
Marshac has joined #ruby
quest88 has joined #ruby
dmiller has joined #ruby
kaushik_ has joined #ruby
shevy has joined #ruby
richwestcoast has joined #ruby
sonkei has quit [Quit: Computer has gone to sleep.]
vectorshelve has joined #ruby
<vectorshelve> hi
ph^ has quit [Remote host closed the connection]
<kaushik_> hi
<shevy> die
<shevy> oops
<shevy> wrong channel
<shevy> I meant
<shevy> hi
<matti> LOL
<matti> shevy: We love you too, shevy
carl_ has quit [Quit: Linkinus - http://linkinus.com]
fayimora has quit [Quit: fayimora]
vectorshelve_ has joined #ruby
vectorshelve_ has quit [Client Quit]
fayimora has joined #ruby
deryldoucette has joined #ruby
vectorshelve has quit [Ping timeout: 245 seconds]
chimkan_ has joined #ruby
specialGuest has joined #ruby
vectorshelve has joined #ruby
karakedi has joined #ruby
deryl has quit [Ping timeout: 244 seconds]
deryldoucette is now known as deryl
Wh00p has quit [Quit: WeeChat 0.3.8]
fayimora has quit [Ping timeout: 245 seconds]
A124 has joined #ruby
<matti> Takehiro: I figured out my question :)
johnjohnson has joined #ruby
qwerxy has quit [Quit: offski]
becom33 has joined #ruby
<becom33> even if I did http.verify_mode = OpenSSL::SSL::VERIFY_NONE it still gives me the error OpenSSL::SSL::SSLError
specialGuest has quit [Ping timeout: 244 seconds]
<becom33> nvm wrong port
<becom33> lol
yshh has quit [Remote host closed the connection]
tommyvyo has quit [Quit: Computer has gone to sleep.]
bradhe has quit [Remote host closed the connection]
bradhe has joined #ruby
fayimora has joined #ruby
khakimov has quit [Quit: Computer has gone to sleep.]
t51319 has quit [Remote host closed the connection]
chimkan_ has quit [Quit: chimkan_]
t88393 has joined #ruby
Cache_Money has quit [Ping timeout: 255 seconds]
johnjohnson has quit []
jasonkuhrt has joined #ruby
chimkan has joined #ruby
Takehiro has quit [Remote host closed the connection]
ph^ has joined #ruby
kirun has joined #ruby
rippa has joined #ruby
savage- has joined #ruby
ZachBeta has quit [Quit: Computer has gone to sleep.]
Poapfel has quit [Quit: WeeChat 0.3.7]
Poapfel has joined #ruby
wvms has left #ruby [#ruby]
Takehiro has joined #ruby
bradhe has quit [Remote host closed the connection]
Takehiro has quit [Remote host closed the connection]
jenrzzz has quit [Ping timeout: 252 seconds]
Paradox has quit [Quit: derpderp]
tvw has joined #ruby
ringotwo has joined #ruby
Takehiro has joined #ruby
<shevy> becom33 you got SSL to work?
mercwith1mouth has quit [Ping timeout: 268 seconds]
jenrzzz has joined #ruby
Morkel has joined #ruby
mohits has quit [Read error: Connection reset by peer]
c0rn_ has joined #ruby
brandon has quit [Remote host closed the connection]
wvms has joined #ruby
tvw has quit [Ping timeout: 246 seconds]
c0rn_ has quit [Client Quit]
s1n4 has joined #ruby
elico has quit [Ping timeout: 260 seconds]
Takehiro has quit [Remote host closed the connection]
Takehiro has joined #ruby
td123 has joined #ruby
Speed has joined #ruby
Speed has quit [Changing host]
Speed has joined #ruby
rakunHo has quit [Remote host closed the connection]
tvw has joined #ruby
yxhuvud has joined #ruby
savage- has quit [Remote host closed the connection]
Takehiro has quit [Remote host closed the connection]
Markvilla has joined #ruby
tvw has quit [Ping timeout: 246 seconds]
Takehiro has joined #ruby
jorge has joined #ruby
brianpWins has quit [Quit: brianpWins]
Takehiro has quit [Remote host closed the connection]
baphled has quit [Ping timeout: 240 seconds]
Takehiro has joined #ruby
Takehiro has quit [Remote host closed the connection]
johnjohnson has joined #ruby
minijupe has joined #ruby
rakl has joined #ruby
Takehiro has joined #ruby
td123 has quit [Ping timeout: 245 seconds]
bradhe has joined #ruby
tvw has joined #ruby
gfkjunior has joined #ruby
Takehiro has quit [Remote host closed the connection]
hoelzro|away is now known as hoelzro
<vectorshelve> shevy: hi
diegoviola has joined #ruby
Takehiro has joined #ruby
<shevy> vectorshelve hi
<shevy> vectorshelve you coding something great today?
<gfkjunior> Hey ya'll quick question I was hopping someone could answer. How can you have 2 .include? methods in one if.
<gfkjunior> here is what I have http://pastebin.com/yissJDFJ
<vectorshelve> shevy: what does this mean ? http://pastie.org/4651942
<shevy> gfkjunior does that work
<gfkjunior> no it does not work, not sure why
t88393 has quit [Remote host closed the connection]
<vectorshelve> shevy: if str.include? "substring" will work thats enough
<hoelzro> why shouldn't it?
<hoelzro> vectorshelve: I'm sure 'substring' is just an example =)
t10618 has joined #ruby
<shevy> vectorshelve I dont like & much
<shevy> vectorshelve it turns something in a block I think
<vectorshelve> shevy: what does it do ideally I am getting confused
<hoelzro> shevy: sort of
<hoelzro> it associates an object with a call as if it were a block
<hoelzro> (after calling to_proc)
<shevy> vectorshelve, update calls the .update method on each element there
<vectorshelve> shevy: https://github.com/mithunsasidharan/Game-of-Life/blob/master/lib/cell.rb the first question I asked u line 9 and now this question
<vectorshelve> shevy: help me with this lil one too please http://pastie.org/4651023
nim__ has quit [Ping timeout: 244 seconds]
baphled has joined #ruby
lindenle has joined #ruby
<shevy> ok
<shevy> you want to dynamically create methods
<shevy> use define_method() for this
<vectorshelve> shevy: yes bt I am not getting the syntax correct
LennyLinux has quit [Remote host closed the connection]
<shevy> well
<shevy> in the pastie you showed me
<shevy> you dont use define_method yet
<shevy> :)
mbk has quit [Ping timeout: 268 seconds]
<vectorshelve> shevy: one sec I will show you
johnjohnson has quit []
<vectorshelve> shevy: array.each do |a|
mneorr has joined #ruby
mneorr_ has joined #ruby
mneorr_ has quit [Remote host closed the connection]
<vectorshelve> define_method (:a) {puts a}
<vectorshelve> end
<shevy> that gives an error right?
<shevy> also
<shevy> :a is not a
<vectorshelve> shevy: ^^
<shevy> a.to_sym should work I think
<Hanmac> :"#{a}"
<vectorshelve> shevy: could you correct the line please define_method (:a) {puts a}
<vectorshelve> Hanmac: will try
<vectorshelve> Hanmac: "#{a}" can be a
<Hanmac> shevy forget about it ... he dont want to learn
<vectorshelve> Hanmac: I want to :(
<Hanmac> he did the same error at 16:23:42 today
<vectorshelve> thats why i am here
quest88 has quit [Quit: quest88]
kn330 has joined #ruby
<shevy> vectorshelve you did not try a.to_sym ?
<vectorshelve> Hanmac: yes... someone asked me to use the define_singleton_method(string) { __method__ }; string
<vectorshelve> ["hai","hello","hi"].each do |a| define_singleton_method("a") { __method__ }; a end => ["hai", "hello", "hi"]
lindenle has quit [Ping timeout: 260 seconds]
heisenmink has quit [Remote host closed the connection]
fayimora has quit [Quit: fayimora]
pskosinski has quit [Quit: http://www.redeclipse.net -- Fast-paced online FPS]
<vectorshelve> shevy: ['a','b'].each do |a| define_method(:a.to_sym) {puts a} end NoMethodError: undefined method `define_method' for main:Object
maletor has joined #ruby
karakedi has quit [Read error: Connection reset by peer]
quest88 has joined #ruby
mXr has quit [Read error: Connection reset by peer]
JodaZ has quit [Quit: No Ping reply in 180 seconds.]
<shevy> that Callback example works
<shevy> ugly code btw
<shevy> ruby's metamagic is as beautiful as perl code
JodaZ has joined #ruby
<hoelzro> shevy: be nice ;)
seanstickle has joined #ruby
<shevy> but really!
<shevy> metaclass = class << self; self; end
<shevy> metaclass.send(:define_method, :callback) do
<shevy> obj.send(meth)
schaerli has quit [Remote host closed the connection]
<vectorshelve> Hanmac: need help with the line 9 https://github.com/mithunsasidharan/Game-of-Life/blob/master/lib/cell.rb (explain) why there are 3 variables
brandon has joined #ruby
pskosinski has joined #ruby
<hoelzro> do you really need to call metaclass.send?
<shevy> dunno
<hoelzro> couldn't you just do define_method :callback, &body?
<shevy> is not my code btw, I just looked at it and thought how ugly it is
<shevy> it kinda works though
maletor has quit [Ping timeout: 252 seconds]
<Hanmac> vectorshelve WHY did you do "(:a.to_sym)" ?? no one told you todo
<vectorshelve> Hanmac: that was a bad syntax.. now its fine.. sorry
<Hanmac> this is fine too, the method is inteligent enough: (a)
<upasna> how to determine OS' name in Ruby?
<vectorshelve> shevy: thanks for the link
<shevy> upasna check content of the constant RUBY_PLATFORM
imami|afk is now known as banseljaj
<shevy> RUBY_PLATFORM # => "x86_64-linux"
<Hanmac> and dont use define method inside the metaclass ... define_singleton_method works TOO
<vectorshelve> Hanmac: yes.. that worked nicely.. thanks :)
<hoelzro> >> RUBY_PLATFORM
<al2o3cr> (String) "x86_64-linux"
<hoelzro> \o/
schaerli has joined #ruby
<vectorshelve> Hanmac: could you help me with https://github.com/mithunsasidharan/Game-of-Life/blob/master/lib/cell.rb as to why we have 3 variables.. that was to update the cell states latere ryt
mXr has joined #ruby
<upasna> thanks shevy , it's working :)
s1n4 has quit [Read error: Connection reset by peer]
<shevy> upasna \o/ I like simple problems
<upasna> :D
VictorMartins has quit [Quit: VictorMartins]
<Hanmac> vectorshelve:
<Hanmac> >> a = b = 3; p a , b
<al2o3cr> (Array) [3, 3], Console: 3, 3
cool has joined #ruby
gmci has quit [Quit: Computer has gone to sleep.]
<Hanmac> someone allready told you that ... and i knew the exact time!
ananthakumaran1 has quit [Quit: Leaving.]
<vectorshelve> Hanmac: I know that concept mate but I was more interested wrt to the context of the app
<vectorshelve> Hanmac: def update @state = @new_state end def state=(value) @new_state = value end
uris has joined #ruby
amskah has quit [Quit: Leaving]
<Hanmac> you need to init BOTH @state AND @new_state otherwise the update or the state method will fail or so something bad
digitalcakestudi has quit [Read error: Connection reset by peer]
<vectorshelve> Hanmac: ok... could you be a lil more precise.. so that I get that fundamental correct.. we have specified attr_reader :state so only read is possible.. so how were we able to instantiate it inside initialize /
<vectorshelve> Hanmac: using @state = @new_state = state
areil has quit [Remote host closed the connection]
adeponte has joined #ruby
<Hanmac> i think you need to understand how instance_variables work ...
flak has joined #ruby
flak is now known as Guest27575
digitalcakestudi has joined #ruby
frogprince_mac has quit [Quit: Leaving...]
mbk has joined #ruby
shadoi has joined #ruby
ringotwo has quit [Remote host closed the connection]
burgestrand has quit [Ping timeout: 240 seconds]
<vectorshelve> Hanmac: could me make it a lil clear further
gmci has joined #ruby
rippa has quit [Ping timeout: 244 seconds]
nim__ has joined #ruby
<Hanmac> http://www.ruby-lang.org/en/documentation/quickstart/2/ << last section and next page
<vectorshelve> Hanmac: I am kinda stuck up with it.. thats why.. just help me with it boss please..
eldariof has quit [Ping timeout: 248 seconds]
<Hanmac> if you are to lazy to read then i cant help you ... (i belive that you can read)
<vectorshelve> Hanmac: def initialize(name = "World") @name = name irb(main) end
karakedi has joined #ruby
mahmoudimus has joined #ruby
t10618 has quit [Remote host closed the connection]
<vectorshelve> Hanmac: here we do multiple assignments as well as attr_accessor
t43108 has joined #ruby
<Hanmac> you didnt look at the sample i give to you
kn330 has quit [Ping timeout: 260 seconds]
RubyPanther has quit [Quit: self.exit(:stage=>:left)]
Neil_ has quit [Remote host closed the connection]
kn330 has joined #ruby
<Hanmac> in short: you dont need attr_accessor when you want instance variables inside the instance itself ... attr is only for accessing them from the OUTSIDE
recycle has joined #ruby
<vectorshelve> Hanmac: ok..
recycle has quit [Remote host closed the connection]
kiyoura has joined #ruby
araujo has joined #ruby
araujo has quit [Changing host]
araujo has joined #ruby
mbk has quit [Ping timeout: 244 seconds]
schaerli has quit [Remote host closed the connection]
Guest27575 is now known as rippa
<vectorshelve> any suggestions on designing a good oop design for this game ?
brandon has quit [Remote host closed the connection]
<Hanmac> PS: you dont need attr_reader when you want to read instance_variables ... "get_instance_variable" works too
<vectorshelve> Hanmac: yes and attr_reader is kinda alias
<vectorshelve> object.state
tvw has quit [Remote host closed the connection]
mc0e has joined #ruby
perun_ has quit [Ping timeout: 272 seconds]
jorge has quit [Remote host closed the connection]
<vectorshelve> Hanmac: http://pastie.org/4652092
adeponte has quit [Remote host closed the connection]
Virunga has joined #ruby
<Hanmac> to few information ... what kind of cards? do they need extra objects? etc
<Hanmac> but i dont want to help you with this
<vectorshelve> Hanmac: no kind of like assume there is a deck of cards(class)
<vectorshelve> Hanmac: deck contains collection of cards
<vectorshelve> Hanmac: two player objects and game class
heisenmink has joined #ruby
berkes has quit [Ping timeout: 244 seconds]
<vectorshelve> Hanmac: so cards are equally alloted to each player
<vectorshelve> Hanmac: now they start putting out card one by one and if the card matches then he gets the other card as well.. so once the game is over the player having max cards wins
<Hanmac> you still not answer my question
fastred has joined #ruby
<vectorshelve> Hanmac: simple cards.. may be an attribute with a value.. and we compare these values for cards to see of the match card.value == "king"
fastred has quit [Client Quit]
<vectorshelve> Hanmac: like above.
mbk has joined #ruby
<vectorshelve> Hanmac: so game class initializes players.. players will have cards allocated equally b/w them.. player has a set of cards.. now we need a class (strategy pattern) which takes two players as parametres
<Hanmac> exact this is the reason i dont want to help you ... you dont answer questions, you dont respond to suggestions like matti post, and when you dont get what you want you are getting even more annoyable
<vectorshelve> when did matti post a suggestion now ?
Paradox has joined #ruby
<vectorshelve> Hanmac: so what next with the design ?
perun_ has joined #ruby
deryl has quit [Quit: deryl]
<Hanmac> (17:53:01) matti: >> a = 1 ; c = b = a ; p a, b, c
mc0e has quit [Ping timeout: 252 seconds]
gfontenot has quit []
<vectorshelve> Hanmac: I am being honest... I missed that comment since he didnt ping me directly..
Marshac has quit [Ping timeout: 245 seconds]
<shevy> vectorshelve you really should respond to people who talk to you man
<vectorshelve> shevy: I am honest shevy I didnt see that comment :(
Nisstyre_ has joined #ruby
<vectorshelve> shevy: or else why would I not respond when I know that someone is taking time out to help me .. Sorry matti
<shevy> vectorshelve no, not that comment alone, I mean before I asked whether you tried a.to_sym for instance and you never answered :D
elico has joined #ruby
khakimov has joined #ruby
<shevy> do you see only lines where your name is used on IRC?
<vectorshelve> shevy: I did reply back.. saying that line threw error
Nisstyre_ has quit [Remote host closed the connection]
<vectorshelve> shevy: mostly.. since I use earphone.. I get a voice when someone pings me
Nisstyre_ has joined #ruby
elico has quit [Read error: Connection reset by peer]
elico has joined #ruby
<Hanmac> shevy and even worse: when he dont get an respond, he ask the same message again
elico has quit [Read error: Connection reset by peer]
<vectorshelve> Hanmac: I got logged out couple of times mate.. I didnt want to miss any reply
elico has joined #ruby
<shevy> vectorshelve ahhh hehe. what IRC client do you use?
<vectorshelve> shevy: web browser
<Hanmac> wrong. there wasnt a logout since the two messages
jorge has joined #ruby
Morkel has quit [Read error: Connection reset by peer]
havenn has joined #ruby
A124 has quit [Quit: Leaving.]
chimay has quit [Quit: WeeChat 0.3.9-rc1]
<vectorshelve> Hanmac: there wasnt.. I dint know why when I actually got logged out when my connection was out and I tried relogin it said nick already in use.. and I tried couple of times to get in
<vectorshelve> need design help in these two http://pastie.org/4652092
Morkel has joined #ruby
<seanstickle> How many times are you going to post that?
Kiall has quit [Quit: ZNC - http://znc.sourceforge.net]
perun_ has quit [Ping timeout: 268 seconds]
Morkel has quit [Client Quit]
<Hanmac> (20:18:23) vectorshelve: & (20:22:11) vectorshelve: ... nearly exact same message
<vectorshelve> Hanmac: I have added one more question to it ;)
digitalcakestudi has quit [Ping timeout: 240 seconds]
<Hanmac> seanstickle once a time for every star in the sky
s1n4 has joined #ruby
<seanstickle> Haha
atmosx has joined #ruby
<shevy> lol
t43108 has quit [Remote host closed the connection]
t54512 has joined #ruby
<shevy> vectorshelve have you thought that your approach might be wrong?
<vectorshelve> shevy: for the card game ?
td123 has joined #ruby
<shevy> vectorshelve well, you show only a small document... and no code
<shevy> vectorshelve start with the code that you know you can reuse for your pacman game
<vectorshelve> shevy: I dont need code.. I need a good oop high level desgin for these two apps
<seanstickle> Well, then you don't need to be here.
<kiyoura> vectorshelve, maze generation is trivial: look into the randomized depth-first algorithm
<shevy> ehhh
<shevy> you dont need code??? hehehe
<seanstickle> Maybe try #architecture-astronauts
<vectorshelve> shevy: I need to design before I start coding.. that is the most imp part.
<shevy> ok easy way
<kiyoura> also Knuth shuffle for shuffling cards
<seanstickle> vectorshelve: so design something
<shevy> write down ANYTHING for it that makes ANY sense, no matter if it does or not
<vectorshelve> kiyoura: I am not looking at implementation now... rather design
<shevy> then you are finished
<seanstickle> vectorshelve: this isn't a channel for designing things for you
<kiyoura> vectorshelve, im quite sure they're intrinsic
<shevy> because if you dont need any code, you can write down anything about the design
<vectorshelve> seanstickle: I know.. but ppl could help ryt
<seanstickle> vectorshelve: it seems fairly apparent that you've mostly managed to piss people off
mrdodo has joined #ruby
<vectorshelve> shevy: you normally design first and then code ryt as per sdlc
<seanstickle> vectorshelve: so you might should rethink your approach
<shevy> kiyoura is knuth shuffle like LFMAO "everyday I am shuffling"
<Hanmac> vectorshelve wrong! some of my gems are completly redesigned more then four times ... because i evolv with my gems
mc0e has joined #ruby
vfuse has joined #ruby
<shevy> ok
<seanstickle> vectorshelve: SDLC?
<shevy> Hanmac turns into godzilla slowly
<seanstickle> vectorshelve: where are you, Carnegie Mellon?
<kiyoura> shevy, im sure ruby implements Fisher-Yates shuffle for its shuffle method
<vectorshelve> seanstickle: yes
<seanstickle> Ha
<vectorshelve> seanstickle: software development life cycle
<seanstickle> vectorshelve: I know what the SDLC is, numnuts
stepnem has quit [Ping timeout: 276 seconds]
<vectorshelve> seanstickle: :)
mneorr has quit [Quit: Leaving.]
burgestrand has joined #ruby
<seanstickle> vectorshelve: design something first, then come back for advices on whether you did a fair job.
<vectorshelve> atleast u guys could give me some idea onpacman game like.. there would be a grid class.. set of cells in it..
<Hanmac> shevy so i can destroy NewYork? okay :P
<vectorshelve> 4 ghost objects and 1 player object and a game class
<seanstickle> vectorshelve: or try #programming
<kiyoura> vectorshelve, ..ruby has a matrix
<seanstickle> vectorshelve: they are good for beginners
<kiyoura> ^
<shevy> hmm
<seanstickle> vectorshelve: your questions are not Ruby-related and thus off topic
<shevy> Hanmac, I meant the japanese godzilla
luckyruby has joined #ruby
<vectorshelve> shevy: game initializes player ghosts and grid
<shevy> vectorshelve yes! class Game... Class Grid, go with that
<shevy> I mean class Grid
<vectorshelve> thanks
<vectorshelve> shevy: yes
punkrawkR has quit [Read error: Connection reset by peer]
* Hanmac prefers the mothga
<shevy> yes, your game class loads the elements on the map
<seanstickle> Hanmac: mothra?
<kiyoura> shevy, dont tell him to reinvent the wheel
jasonkuhrt has quit [Quit: Leaving...]
<Hanmac> NO shevy, tell him to reinvent the wheel :P
<kiyoura> he wont design it properly if he does
<matti> Oh dear.
<shevy> lol
<matti> We are going to invent another Point object?
<matti> ;d
mrdodo has quit [Read error: Connection reset by peer]
<shevy> matti, I am starting to believe that Hanmac does not like vectorshelve
havenn has quit [Remote host closed the connection]
<matti> Like in every Java 101 book.
mrdodo has joined #ruby
<Hanmac> seanstickle: Mothra i mean
<vectorshelve> shevy: I wish that is not true :(
CarlB_the_great has joined #ruby
<shevy> vectorshelve ask Hanmac a question
<shevy> :)))
<vectorshelve> shevy: I dont wanna infuriate him any further
dangerousdave has quit [Quit: Leaving...]
ringotwo has joined #ruby
perun_ has joined #ruby
jasonkuhrt has joined #ruby
rakl has quit [Quit: sleeping]
<Hanmac> The Purple 8 Ball says: It's possible
<matti> Purple?!
t0rc has joined #ruby
Guest5516 has quit [Ping timeout: 268 seconds]
<Hanmac> matti my irc client has a /8ball command
<matti> Ah.
<Hanmac> i have a /sgball too for this:
<Hanmac> The Purple Stargate Ball says: According to quantum physics, it's theoretically possible...
td123 has quit [Ping timeout: 268 seconds]
<matti> LOL
<matti> Oh.
<matti> New Who.
elaptics is now known as elaptics`away
* Hanmac smells a doctor who fan :P
hipertracker has quit [Quit: hipertracker]
td123 has joined #ruby
<seanstickle> Not John Pertwee == not for me
banseljaj is now known as imami|afk
<matti> I only watch it for Amy Pond.
<Hanmac> yeah. amy was/is one of the coolest companions
<seanstickle> Not as good as Sarah Jane Smith. Or K-9
<seanstickle> Or Romana #2
specialGuest has joined #ruby
specialGuest has quit [Changing host]
specialGuest has joined #ruby
Kiall has joined #ruby
stepnem has joined #ruby
<Hanmac> one of the important's quotes are "You didn't always take me where I wanted to go. - No, but I always took you where you needed to go. "
rippa has quit [Ping timeout: 240 seconds]
<seanstickle> Well, that's rather paternalistic
wo66le has quit [Quit: Computer has gone to sleep.]
twu1 has joined #ruby
twu1 is now known as bd0
dangerousdave has joined #ruby
jgrevich_ has joined #ruby
<Hanmac> seanstickle what did you think about "the silence"?
jgrevich has quit [Ping timeout: 272 seconds]
jgrevich_ is now known as jgrevich
<seanstickle> Cheap chtulhians
ciopte7 has joined #ruby
savage- has joined #ruby
stepnem has quit [Quit: ZNC - http://znc.sourceforge.net]
ringotwo has quit [Remote host closed the connection]
<Hanmac> you mean like this: http://www.youtube.com/watch?v=5dpN6MR0sOI ?
vectorshelve has quit [Ping timeout: 245 seconds]
jgrevich_ has joined #ruby
jgrevich_ has joined #ruby
jgrevich_ has quit [Changing host]
td123 has quit [Quit: WeeChat 0.3.8]
dev_ryan70 has joined #ruby
stepnem has joined #ruby
t54512 has quit [Remote host closed the connection]
t14181 has joined #ruby
jgrevich has quit [Ping timeout: 244 seconds]
jgrevich_ is now known as jgrevich
voodoofish has quit [Ping timeout: 276 seconds]
s1n4 has quit [Quit: Lost terminal]
shadoi has quit [Quit: Leaving.]
savage- has quit [Remote host closed the connection]
ph^ has quit [Remote host closed the connection]
haxrbyte has joined #ruby
mc0e has quit [Ping timeout: 244 seconds]
mc0e1 has joined #ruby
deryl has joined #ruby
hipertracker has joined #ruby
bradhe has quit [Remote host closed the connection]
haxrbyte_ has joined #ruby
bradhe has joined #ruby
Agis__ has quit [Quit: Agis__]
<atmosx> what colorscheme do you people use on vim?
<TheMoonMaster> Custom version of tomorrow-night.
darkf has joined #ruby
<hoelzro> atmosx: I use peaksea atm
<hoelzro> but I'm testing out a few atm
qwerxy has joined #ruby
<atmosx> let's see
yxhuvud has quit [Ping timeout: 244 seconds]
<seanstickle> ir-black
specialGuest has quit [Ping timeout: 244 seconds]
johnjohnson has joined #ruby
haxrbyte has quit [Ping timeout: 240 seconds]
wo66le has joined #ruby
wo66le has quit [Client Quit]
karakedi has quit [Ping timeout: 246 seconds]
joephelius has joined #ruby
rubious has joined #ruby
wo66le has joined #ruby
wo66le has quit [Client Quit]
<atmosx> peaksea?
<atmosx> seriously?
<atmosx> doesn this turn you blind or something hoelzro ?
<Hanmac> atmosx: vim has colours? :D
Foxandxss has joined #ruby
<kiyoura> atmosx: wombat256
<kiyoura> or solarized
CarlB_the_great has quit [Remote host closed the connection]
* hoelzro wonders how Ruby code looks with peaksea
<hoelzro> I haven't done enough Ruby development to really say if peaksea is a good colorscheme for it
voodoofish has joined #ruby
meskyanichi has quit [Quit: Linkinus - http://linkinus.com]
<atmosx> hoelzro: I used peaksea with light bg, it comes with dark bg as well
<atmosx> I cannot look at a screen with code and light bg, turns me blind
CarlB_the_great has joined #ruby
wargasm has joined #ruby
<hoelzro> oh, that's probably why
<hoelzro> I use dark bg
* hoelzro really needs to find a Ruby equivalent to Dist::Zilla
<hoelzro> the closest thing I've seen (so far) is hoe
tommyvyo has joined #ruby
tommyvyo has quit [Changing host]
tommyvyo has joined #ruby
Virunga has quit [Remote host closed the connection]
adambeynon has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
Kiall is now known as zz_Kiall
<bd0> ...
ConstantineXVI has joined #ruby
ConstantineXVI has quit [Client Quit]
ConstantineXVI has joined #ruby
jenrzzz has quit [Ping timeout: 252 seconds]
brianpWins has joined #ruby
johnjohnson has quit []
rubious has quit [Quit: Linkinus - http://linkinus.com]
* atmosx is listening to Sting - I Was Brought To My Senses, from the album The Best Of 25 Years CD2 [5:49 mins] [320 kbps MPEG audio file] [14.01 MB] [played missing value times]
Virunga has joined #ruby
QKO has quit [Changing host]
QKO has joined #ruby
Virunga is now known as LennyLinux
wallerdev has joined #ruby
ringotwo has joined #ruby
zz_Kiall is now known as Kiall
<atmosx> I wrote my first 5+ lines function without making a single mistake (applaud plz).
* atmosx yeeha
_Vile has quit [Ping timeout: 256 seconds]
mrck has joined #ruby
<matti> Well, Who was...
ringotwo has quit [Remote host closed the connection]
JStoker has quit [Excess Flood]
jbw has quit [Ping timeout: 246 seconds]
cantonic has quit [Quit: cantonic]
t14181 has quit [Remote host closed the connection]
t56506 has joined #ruby
cantonic has joined #ruby
seanstickle has quit [Quit: seanstickle]
jgrevich has quit [Ping timeout: 276 seconds]
adeponte has joined #ruby
yoklov has quit [Quit: computer sleeping]
Russell^^ has quit [Quit: Russell^^]
uokesita has quit [Quit: Leaving]
wallerdev has quit [Quit: wallerdev]
adeponte has quit [Ping timeout: 244 seconds]
mrdodo has quit [Remote host closed the connection]
t0rc has quit [Quit: WeeChat 0.3.8]
jbw has joined #ruby
zii has joined #ruby
<zii> How do I make ruby think a string is binary/
<Paradox> i have a 2 dimensional hash that doesn't show anything when i run keys on it
<Paradox> yet the keys return values
<hoelzro> zii: what are you trying to do?
<hoelzro> Paradox: do you have some example code we could look at?
<Paradox> hoelzro, not really, i'm working with massive data
<Paradox> but basically
<Paradox> im iterating over a log
<Paradox> each log entry is a hash inside an array
<Paradox> so i use each to go over it
<Paradox> i take the author property
<Hanmac> zii what is your input and what your wanted output?
ben_alman has quit [Excess Flood]
<Paradox> and stick that as the first dimensional key in my new hash
<Paradox> then the other values and stick them as the second dimensional keys
<Paradox> i can't get a key listing of the first dimensions
yoklov has joined #ruby
cantonic has quit [Read error: Connection reset by peer]
<zii> Hanmac, hoelzro, Downloading a JPEG, doing stuff to it, slicing.
<zii> Through %x{curl
<matti> No, no.
cakehero has quit [Quit: Computer has gone to sleep.]
<matti> Get bindings to curl.
johnjohnson has joined #ruby
<zii> No.
<matti> Yes.
<matti> ;]
<zii> Why?
JStoker has joined #ruby
<zii> That won't solve anything.
cakehero has joined #ruby
<matti> :>
allsystemsarego has quit [Quit: Leaving]
<zii> And is too much to do for a little script.
<Hanmac> zii you could open the file in binary mode
<Paradox> hoelzro, basically, i am creating the hash with myhash = Hash.new(Hash.new(0))
<Paradox> so the default value is a hash
<Hanmac> Paradox that does not work :(
<Paradox> Hanmac, damnit
<Paradox> guess ill use an OpenStruct
<hoelzro> Paradox: you can do Hash.new { Hash.new(0) }, though
<Paradox> hah
<Mon_Ouie> That solves one of the two problems in the code
wargasm has quit [Ping timeout: 252 seconds]
<Mon_Ouie> The other problem is doing h[k] doesn't actually add the key to the hash, it just returns a value for it
<Mon_Ouie> You need { |h, k| h[k] = Hash.new(0) }
<zii> Hanmac, What happens with a string when it's read from a stream that has been set as "rb"
<Hanmac> Paradox:
<Hanmac> >> hash = Hash.new {|h,k| h[k] = Hash.new(0)}; p hash[:a][:x]; hash
<al2o3cr> (Hash) {:a=>{}}, Console: 0
<matti> Hi Mon_Ouie
<Mon_Ouie> (the other problem was that h[k] would always returns the very same object)
<Mon_Ouie> 'alut matti
<hoelzro> Mon_Ouie: ah, good call
matrixise has joined #ruby
<Paradox> thats probably it
specialGuest has joined #ruby
ben_alman has joined #ruby
wargasm has joined #ruby
mrdodo has joined #ruby
<Mon_Ouie> zii: On windows, "\r\n" gets translated to "\n"; also the encoding is set to binary
<Paradox> guess i'll have to explode it out to a more complex each block
<Mon_Ouie> Erm, other way around: it does *not* get translated to "\n"
<zii> Mon_Ouie, .force_encoding "binary"?
<Mon_Ouie> It's read as is in the file
<Mon_Ouie> That's equivalent to the second thing that happens, yes
<zii> Nice.
<Paradox> is there any quick += that turns a nil into a fixnum?
<Paradox> or do i have to do more logic
<Paradox> ie x = nil
<zii> What's good lib/tool to extract exif/jfif comments with?
<Paradox> x += 1
<Paradox> x = 1
twinturbo_ has joined #ruby
<Mon_Ouie> There isn't any such operator; although, with your hash's default value set to 0, you don't need to check for the value being nil, do you?
<Paradox> spose not
cobragoat has joined #ruby
daniel_hinojosa has joined #ruby
twinturbo has quit [Ping timeout: 276 seconds]
twinturbo_ is now known as twinturbo
ben_alman has quit [Excess Flood]
statarb3 is now known as proshot
Xeago has joined #ruby
johnjohnson has quit []
ben_alman has joined #ruby
rakunHo has joined #ruby
Axsuul has joined #ruby
heynerds has joined #ruby
<upasna> Hi all :) I'm having problems in running this program, http://pastie.org/private/hul9tprgub74sgqyxb04ag. Someone please tell me where I'm wrong.
<matti> upasna: RUBYLIB=. irb
workmad3 has joined #ruby
c0rn_ has joined #ruby
ph^ has joined #ruby
BullShark has joined #ruby
<BullShark> could somebody please help me with this error? http://vpaste.net/dAvSR?bg=dark
<upasna> matti: can you please elaborate?
<atmosx> matti: can't he use require_relative 'shit' for shit.rb on '.' ?
<atmosx> I wonder
<matti> atmosx: Probably.
<atmosx> upasna: then try it
<atmosx> and why do you named Mystaff.apple() ? … not MyStaffApple … and why the () anyway?>
<atmosx> it's empty
brianpWins has quit [Quit: brianpWins]
cobragoat has quit [Remote host closed the connection]
<matti> Why why why
<atmosx> BullShark: I take you did 'bundle install' on that dir right?
gfontenot has joined #ruby
<BullShark> atmosx -> yes i did
<atmosx> matti: too many questions...
<atmosx> BullShark: and how did it go?
<upasna> atmosx: Does that matter?
<BullShark> without error
<atmosx> upasna: nah, I just don't get it… I'm an amateur there are pro's here… don't bother answering just, see if requiare_relative works for u
<upasna> matti: I didn't get what you said.
<atmosx> BullShark: and you were root when you run the bundler
<atmosx> ?
kn330 has quit [Ping timeout: 244 seconds]
<BullShark> atmosx -> i can run it again if you need exact input and yes, ran as root
heisenmink has quit [Remote host closed the connection]
<upasna> atmosx: require_relative is another keyword, I think
<upasna> let me search
<atmosx> BullShark: is ruby installed system-wide? you're not using rvm etc right?
ph^ has quit [Ping timeout: 246 seconds]
<atmosx> I see ruby18, so system-wide via pkg-system would be okay
answer_42 has quit [Remote host closed the connection]
<atmosx> BullShark: which brings us to "I have no idea why, but the program does not locate the gems installed by your bundler"
Aerol has joined #ruby
fearoffish has joined #ruby
wallerdev has joined #ruby
<BullShark> Aerol -> let me show you what you missed
<BullShark> <atmosx> BullShark: is ruby installed system-wide? you're not using rvm etc right?
<BullShark> <atmosx> BullShark: which brings us to "I have no idea why, but the program does not locate the gems installed by your bundler"
<upasna> not working :(
kn330 has joined #ruby
<atmosx> upasna: try full path
<upasna> okay
joeyk has joined #ruby
Kiall is now known as zz_Kiall
<atmosx> upasna: irb -I .
<atmosx> then require 'file'
<upasna> okay
<upasna> let me do it
<BullShark> RUBY_HOME="/opt/ruby" GEMS_HOME="/opt/ruby"
<atmosx> BullShark: what OS is that? leenoux?
<BullShark> atmosx -> yes, centos 6
<atmosx> and how did yoyu install ruby?
haxrbyte_ has quit [Ping timeout: 246 seconds]
manizzle has quit [Ping timeout: 260 seconds]
<BullShark> cd ruby-enterprise-1.8.7-2011.03 ./installer
<BullShark> tar xzf ruby-enterprise-1.8.7-2011.03.tar.gz
khakimov has quit [Quit: Computer has gone to sleep.]
<atmosx> ah k
<upasna> atmosx: thanks, it's working now :)
<atmosx> upasna: cool :-)
<atmosx> upasna: you have a C background or something?
<upasna> yes atmosx
<BullShark> atmosx -> actually i got the latest version which is newer than when that guide was written, http://rubyenterpriseedition.googlecode.com/files/ruby-enterprise-1.8.7-2012.02
<atmosx> BullShark: don't you have an RPM or something that comes with CENTOS?
<upasna> I've a C background
<atmosx> upasna: yeah, i figure it out, good luck with ruby
<upasna> thanks atmosx :)
c0rn_ has quit [Ping timeout: 240 seconds]
<atmosx> BullShark: I think the problem is your paths
<atmosx> not the bundler
<BullShark> atmosx -> according to the guide, Now let’s install Ruby Enterprise Edition. The enterprise version of Ruby is still free, but it uses older, more stable components of Ruby, it’s also focused towards memory conservation (although it still compares to Java’s memory appetite). I would strongly recommend not using any other version/distribution of Ruby since I found many compatibility errors that caused me to have to start all
<BullShark> over again many times!
Criztian has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
<atmosx> I see
<atmosx> makes sense
<atmosx> but imho the ruby that comes with centos
<atmosx> is stable enough, which is surely 1.8 as in all distributions even bleeding edge like Gentoo, have 1.8 still in base-system
jonathanwallace has joined #ruby
<atmosx> following your distributions ruby, you won't have to mess with paths etc.
c0rn_ has joined #ruby
gfontenot has quit []
<Hanmac> my ubuntu version has 1.9.3 as default ruby
CarlB_the_great has quit [Remote host closed the connection]
<BullShark> atmosx -> so you are saying it is a fault of ruby enterprise?
<atmosx> BullShark: indirectly, probably. If the bundler is up-to-date and doesn't work it's becuase it cannot read the gems
justinmcp has joined #ruby
Bosox20051 has joined #ruby
noyb has joined #ruby
zz_Kiall is now known as Kiall
Xeago has joined #ruby
vitor-br has quit [Quit: Saindo]
c0rn_ has quit [Ping timeout: 252 seconds]
cakehero has quit [Quit: Computer has gone to sleep.]
twinturbo has quit [Ping timeout: 244 seconds]
c0rn_ has joined #ruby
mengu has quit [Remote host closed the connection]
pettsson has quit [Remote host closed the connection]
zarubin has quit [Remote host closed the connection]
vfuse has quit [Ping timeout: 244 seconds]
zarubin has joined #ruby
rakl has joined #ruby
baphled has quit [Ping timeout: 240 seconds]
jorge has quit [Remote host closed the connection]
t56506 has quit [Remote host closed the connection]
t48661 has joined #ruby
dangerousdave has quit [Quit: Linkinus - http://linkinus.com]
rakunHo has quit [Read error: Connection reset by peer]
Monie has quit [Ping timeout: 255 seconds]
digitalcakestudi has joined #ruby
Xeago has quit [Remote host closed the connection]
aef has quit [Remote host closed the connection]
aef has joined #ruby
jasonkuhrt has quit [Quit: Leaving...]
jasonkuhrt has joined #ruby
TheNullByte has joined #ruby
minijupe has quit [Quit: minijupe]
jimeh has joined #ruby
workmad3 has quit [Ping timeout: 260 seconds]
qwerxy has quit [Quit: offski]
Aerol has quit [Ping timeout: 248 seconds]
gfkjunior has quit [Quit: Leaving]
_whitelogger_ has joined #ruby
jorge has joined #ruby
jasonkuhrt has quit [Quit: Leaving...]
verto|off is now known as verto
manizzle has joined #ruby
mbk has quit [Ping timeout: 246 seconds]
jarred has joined #ruby
joephelius has quit [Ping timeout: 260 seconds]
robustus has quit [Ping timeout: 244 seconds]
joephelius has joined #ruby
r0bby has joined #ruby
r0bby has quit [Client Quit]
robbyoconnor has quit [Read error: Connection reset by peer]
robbyoconnor has joined #ruby
Speed has quit [Remote host closed the connection]
<becom33> why is https://gist.github.com/c5a69499b042991ae2b2 I want the request to loop not to exit from one timeout .
<becom33> how can I fix that ?
<canton7> look up the retry statement?
verto is now known as verto|off
<becom33> retry ?
<canton7> retry
qwerxy has joined #ruby
cdepue has joined #ruby
wargasm has quit [Ping timeout: 246 seconds]
fantazo has joined #ruby
Kiall has quit [Quit: ZNC - http://znc.sourceforge.net]
joephelius has quit [Ping timeout: 260 seconds]
alanp_ has joined #ruby
alanp_ has quit [Read error: Connection reset by peer]
alanp has quit [Read error: Connection reset by peer]
alanp has joined #ruby
joephelius has joined #ruby
qwerxy has quit [Client Quit]
mrdodo has quit [Remote host closed the connection]
fasta has quit [Ping timeout: 240 seconds]
Apocalypse has quit [Ping timeout: 240 seconds]
S2kx has joined #ruby
S1kx has quit [Read error: Connection reset by peer]
dju has quit [Excess Flood]
blazes816 has joined #ruby
becom33 has quit [Ping timeout: 246 seconds]
wargasm has joined #ruby
fasta_ has joined #ruby
Apocalypse has joined #ruby
dju has joined #ruby
maletor has joined #ruby
dev_ryan70 has quit [Remote host closed the connection]
<mdelcx> just released my first gem, it would be nice to have some feedback :) https://github.com/mdeltito/swift-file
fowl has joined #ruby
thnee has quit [Ping timeout: 272 seconds]
pskosinski has quit [Ping timeout: 252 seconds]
<blazes816> release more
<blazes816> for starters
pskosinski has joined #ruby
tommyvyo has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
<blazes816> looks nice and simple
cdepue has quit [Remote host closed the connection]
Spooner_ has joined #ruby
jorge has quit [Remote host closed the connection]
Spooner has quit [Ping timeout: 252 seconds]
kaushik_ has quit [Ping timeout: 246 seconds]
becom33 has joined #ruby
weeb1e_ has quit [Quit: No Ping reply in 180 seconds.]
weeb1e has joined #ruby
jorge has joined #ruby
rakl has quit [Quit: sleeping]
jorge has quit [Remote host closed the connection]
richardcreme has quit [Remote host closed the connection]
noyb has quit [Ping timeout: 252 seconds]
richardcreme has joined #ruby
t48661 has quit [Remote host closed the connection]
jorge has joined #ruby
<mdelcx> blazes816: thanks :)
t57457 has joined #ruby
<canton7> mdelcx, swift_upload.rb, line 5 or so: swiftfile_host looks constant? if so, make it a constant
stepnem has quit [Ping timeout: 244 seconds]
maletor has quit [Quit: Computer has gone to sleep.]
kirun has quit [Quit: Client exiting]
<mdelcx> my thought was that this would make it obvious that these can be overridden
<mdelcx> i guess that would be the case regardless
cad_ has joined #ruby
chimkan has quit [Quit: chimkan]
josh^ has joined #ruby
<canton7> yeah, I wasn't sure. would be nice to see some docs :)
<mdelcx> yeah for sure, that's my next move
<mdelcx> real repc and docs
tommyvyo has joined #ruby
tommyvyo has quit [Changing host]
tommyvyo has joined #ruby
SCommette has joined #ruby
noyb has joined #ruby
ciopte7 has quit [Quit: ciopte7]
SCommette has quit [Client Quit]
qwerxy has joined #ruby
qwerxy has quit [Client Quit]
SCommette has joined #ruby
<becom33> can anyone explain me how can I add a update function into a script ?
<blazes816> def update; end
<becom33> I cant seems to find any tutorials
<blazes816> what do you want it to do? update what?
jorge has quit [Remote host closed the connection]
jorge has joined #ruby
<becom33> blazes816, no no . I mean a method I can make project update . I have a simple project . which has like 5 ruby files . this is a demo project . Im gonna upload it to github . so I was thinking maby there is a way I can put a --update to the script to update from github if there is a latest version of it released
jorge has quit [Remote host closed the connection]
bier has quit [Ping timeout: 246 seconds]
<blazes816> ah, got it. so it depends on how your project installs
<blazes816> if it's just from the github repo, you can make the --update flag call "git pull" in the install dir
jorge has joined #ruby
yasushi has joined #ruby
<becom33> blazes816, but how can I check if Im having the latest version ?
<blazes816> for that you could shell out to git/github by running/parsing git status. but probably you want a place you can make an http call and get the current version and/or version history.
<mdelcx> if all you care about is getting the latest code, you don't need to worry about the version
<blazes816> example.com/current_fooburger_version
<blazes816> returns the current version e.g. "1.0.0"
<canton7> the main question is: do you want to rely on git? :P
chimkan has joined #ruby
<mdelcx> why wouldn't you?
<blazes816> for the installation handling it may not be the best option
<blazes816> if it's simple (sounds like this is), could work out great
<mdelcx> thats what I was thinking
<becom33> canton7, what do u suggest for a update function
specialGuest has quit [Ping timeout: 244 seconds]
yasushi has quit [Ping timeout: 246 seconds]
<canton7> becom33, it really depends on what you want to do. is this something which is installed as a gem, or instance? or something which is installed by cloning a github repo?
<canton7> s/or instance/for instance
<becom33> canton7, its a simple project be can be used cloning from github repo
seanwash has joined #ruby
<blazes816> options[:update] && `git pull`
<canton7> if that's how people *have* to install it, so the dir the script's in is always a git repo, just a git fetch && git reset --hard @{u} would be fine
<becom33> ruby has a inbuild git plugin right ?
thnee has joined #ruby
<blazes816> builtin plugin?
<blazes816> may be stale, never used it
seanwash has left #ruby [#ruby]
kyb3r has joined #ruby
<blazes816> becom33: https://github.com/mojombo/grit
seanwash has joined #ruby
seanwash has left #ruby [#ruby]
mercwith1mouth has joined #ruby
pingfloyd has joined #ruby
seanwash has joined #ruby
<ggreer> I never noticed that the jekyll guy is also the grit guy
<cad_> I am trying to deploy a redmine instance to openshift. I am following this sample project. But getting config/locales/pt-BR.yml): found unknown escape character while parsing a quoted scalar at line 994 column 35 (Psych::SyntaxError) error without hope.
pskosinski has quit [Ping timeout: 255 seconds]
<cad_> here is a link to the example project https://github.com/openshift/redmine-openshift-quickstart
<cad_> can anyone help? I am a newbie.
bier has joined #ruby
Iskorptix_ has joined #ruby
Iskorptix_ has left #ruby [#ruby]
guns has joined #ruby
cantonic has joined #ruby
richwestcoast has quit [Quit: ( www.nnscript.com :: NoNameScript 4.22 :: www.esnation.com )]
seanwash has quit [Client Quit]
bd0 has quit [Quit: ...]
dagnachewa has joined #ruby
seanwash has joined #ruby
SCommette has quit [Quit: SCommette]
becom33 has quit [Remote host closed the connection]
seanwash has quit [Client Quit]
seanwash has joined #ruby
seanwash has quit [Client Quit]
cakehero has joined #ruby
dmiller has quit [Remote host closed the connection]
ciopte7 has joined #ruby
<mdelcx> is it possible, with optparser, to detect if an optional switch has been supplied without a value?
<mdelcx> trying to get the "standard" -p functionality for passwords a la mysql
SCommette has joined #ruby
perryh has quit [Remote host closed the connection]
perryh has joined #ruby
seanwash has joined #ruby
jenrzzz has joined #ruby
seanwash has quit [Client Quit]
<canton7> it must be. it certainly is with trollop (which is the only option parser I know) :P
mrck has quit [Ping timeout: 244 seconds]
seanwash has joined #ruby
SCommette has quit [Client Quit]
chendo_ has quit [Ping timeout: 244 seconds]
<mdelcx> canton7: im just using optparse from teh stdlib
<mdelcx> trollop doesn't seem to handle passwords directly either
<mdelcx> ruby-password might work, but its quite a dependency (itself is dependent on cracklib)
chendo_ has joined #ruby
rubious has joined #ruby
t57457 has quit [Remote host closed the connection]
seanwash has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
t29180 has joined #ruby
CarlB_the_great has joined #ruby
qwerxy has joined #ruby
deryl has quit [Quit: deryl]
seanwash has joined #ruby
mikepack has joined #ruby
nari_ has joined #ruby
hackeye has joined #ruby
<hackeye> hi.. absolute ruby newbie here.. is there an equivalent of the linux shell's "sh -x" functionality in ruby? basically i wanna see line-by-line execution of code
seanwash has quit [Client Quit]
thnee has quit [Remote host closed the connection]
mrdodo has joined #ruby
<fowl> line-by-line evaluation won't show you problems when your method.calls.are.chained.and { inlined }
<fowl> the answer is no
<kiyoura> use your eyes plus the manual imo
TheNullByte has quit [Quit: TheNullByte]
larissa has joined #ruby
thnee has joined #ruby
<hackeye> kiyoura: thanks for the very informative answer which i knew nothing abt
<kiyoura> try it!
larissa has quit [Client Quit]
larissa has joined #ruby
TheNullByte has joined #ruby
SCommette has joined #ruby
mrdodo has quit [Ping timeout: 252 seconds]
<hackeye> and u should try to get a life rather than lurking in irc channels giving useless answers coz u have nothing better to do
<canton7> hey hey, less of the anger
<wvms> you'll upset the kids
larissa has quit [Client Quit]
<canton7> also, ruby-debug
jorge has quit [Remote host closed the connection]
larissa has joined #ruby
larissa has quit [Client Quit]
larissa has joined #ruby
<hackeye> thanks canton.. just thought there may be a simple switch or something.. i was looking at ruby-debug now
jenrzzz has quit [Ping timeout: 244 seconds]
larissa has quit [Read error: Connection reset by peer]
larissa has joined #ruby
minijupe has joined #ruby
<fowl> lol
<hackeye> as for the anger, how do you think a self-proclaimed newbie should react if he gets such an answer to what is basically a yes or no question?
<fowl> hackeron: with a grain of salt. its irc
larissa has quit [Client Quit]
<kiyoura> lol
larissa has joined #ruby
<canton7> people joke around. there was nothing malicious
* kiyoura still thinks that wasn't that bad advice, i've learned plenty from doing just that.
<fowl> hackeye: &
<fowl> **
cdepue has joined #ruby
larissa has quit [Client Quit]
<hackeye> kiyoura: and you think i'm coding blind, and i don't know abt. man pages or google?
aarwine has quit [Remote host closed the connection]
<canton7> you did the asking nicely and saying thanks bits right. the not-getting-wound-up-when-someone-doesn't-answer-your-exact-question could do with some work :P
<hackeye> so i just jump straight into the closest channel i find and ask away?
<kiyoura> hackeye, with that sort of question, and the usual visits to this channel. presumably, yes.
larissa has joined #ruby
* hackeye thinks getting a life wasn't bad advice either
<kiyoura> i like irc'ing from work :p, but that's off topic!
<fowl> :ROLLEYES:
<hackeye> anyway, for the others.. thanks for the pointers
hackeye has left #ruby [#ruby]
guns has quit [Quit: guns]
seanwash has joined #ruby
cdepue has quit [Ping timeout: 260 seconds]
blazes816 has quit [Read error: Connection reset by peer]
gfontenot has joined #ruby
blazes816 has joined #ruby
darkf_ has joined #ruby
proshot is now known as statarb3
tommyvyo has quit [Quit: Computer has gone to sleep.]
kn330 has quit [Ping timeout: 246 seconds]
jjang has joined #ruby
joephelius has quit [Ping timeout: 252 seconds]
kn330 has joined #ruby
tommyvyo has joined #ruby
tommyvyo has quit [Changing host]
tommyvyo has joined #ruby
darkf has quit [Ping timeout: 246 seconds]
darkf_ is now known as darkf
joephelius has joined #ruby
nari_ has quit [Ping timeout: 272 seconds]
cdepue has joined #ruby
xbayrockx has quit []
SCommette has quit [Quit: SCommette]
chimkan___ has joined #ruby
chimkan has quit [Ping timeout: 244 seconds]
chimkan___ is now known as chimkan
statarb3 has quit [Quit: Leaving]
luckyruby has quit [Ping timeout: 272 seconds]
deryl has joined #ruby
Takehiro has quit [Remote host closed the connection]
jenrzzz has joined #ruby
luckyruby has joined #ruby
havenn has joined #ruby
t29180 has quit [Remote host closed the connection]
t36717 has joined #ruby
havenn has quit [Remote host closed the connection]
verto|off is now known as verto
banisterfiend` has quit [Remote host closed the connection]
verto is now known as verto|off
minijupe has quit [Quit: minijupe]