apeiros_ changed the topic of #ruby to: Ruby 1.9.3-p327: http://ruby-lang.org (ruby-2.0.0-preview2) || Paste >3 lines of text on http://gist.github.com
nick_h has joined #ruby
banisterfiend has joined #ruby
<shevy> resudo boot!
Vert has quit [Remote host closed the connection]
punkrawkR has quit [Ping timeout: 246 seconds]
punkrawkR has joined #ruby
nazty has joined #ruby
punkjul has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
Hannes3 has quit [Remote host closed the connection]
<shevy> hmmm
<shevy> what would you guys recommend for a quick and simple ruby-gui ?
atal421 has joined #ruby
shemerey has quit [Quit: Linkinus - http://linkinus.com]
wedgeV has quit [Remote host closed the connection]
skcin7 has joined #ruby
banisterfiend has quit [Ping timeout: 265 seconds]
Proshot is now known as ProZzZz
horofox has joined #ruby
ikaros has quit [Quit: Ex-Chat]
c0rn has quit [Quit: Computer has gone to sleep.]
mockra has joined #ruby
jsilver has quit [Ping timeout: 245 seconds]
<shevy> hmm really?
<havenn> shevy: I dunno, what kinda gui are you looking for? What platforms do you wanna support?
tommyvyo has joined #ruby
<shevy> just linux, the quickest and dirtiest stuff
<shevy> with as few dependencies as possible :(
<shevy> I have a set of scripts that will generate some text
lolcathost has quit [Quit: leaving]
<shevy> and I'd love to do that in a GUI, with an editing like functionality
<blazes816> I like to use jruby+swing for guis but I know that many people disagree
<havenn> Ruby-Tk, Ruby-GNOME2 or wxRuby may be ones to look at.
<havenn> shevy: If you want minimal, tk is pretty easy: require 'tk'
tjbiddle has joined #ruby
<shevy> blazes816 hmm would I need to know java for that?
<blazes816> it would help. you can do it all in ruby, but some of the semantics are still rather java-ish
brianpWins has quit [Quit: brianpWins]
jtharris has quit [Quit: WeeChat 0.3.9.2]
marr has quit [Ping timeout: 248 seconds]
axl_ has quit [Quit: axl_]
fgro has quit [Ping timeout: 265 seconds]
mayhew has joined #ruby
thecreators has joined #ruby
joeycarmello has joined #ruby
axl_ has joined #ruby
seich- has quit [Ping timeout: 250 seconds]
maetthew has quit [Remote host closed the connection]
maetthew has joined #ruby
havenn has quit [Remote host closed the connection]
NiteRain has joined #ruby
seich- has joined #ruby
tjbiddle_ has joined #ruby
axl_ has quit [Ping timeout: 245 seconds]
elico has joined #ruby
icole has quit [Remote host closed the connection]
punkrawkR^Home has joined #ruby
tjbiddle has quit [Read error: Operation timed out]
tjbiddle_ is now known as tjbiddle
atal421 has quit [Quit: atal421]
tommyvyo_ has joined #ruby
love_color_text has quit [Remote host closed the connection]
lolcathost has joined #ruby
maetthew has quit [Quit: ZNC - http://znc.in]
maetthew has joined #ruby
punkrawkR has quit [Ping timeout: 244 seconds]
maetthew has quit [Client Quit]
maetthew has joined #ruby
ryanlecompte has quit [Remote host closed the connection]
maetthew has quit [Client Quit]
maetthew has joined #ruby
maetthew has left #ruby [#ruby]
qwerxy has joined #ruby
mrsolo has quit [Quit: Leaving]
krawchyk has joined #ruby
tjbiddle has quit [Quit: tjbiddle]
friskd has quit [Ping timeout: 250 seconds]
krawchyk has quit [Remote host closed the connection]
nanothief has joined #ruby
wargasm has joined #ruby
hackerdude has quit [Remote host closed the connection]
verto is now known as verto|off
kokainepizza has joined #ruby
Teddy2steper has quit [Remote host closed the connection]
maetthew has joined #ruby
emocakes has quit [Quit: emocakes]
maetthew has quit [Client Quit]
maetthew has joined #ruby
stkowski has joined #ruby
emocakes has joined #ruby
thams has quit [Quit: thams]
omg765 has quit [Read error: Operation timed out]
d34th4ck3r has quit [Ping timeout: 246 seconds]
tjbiddle has joined #ruby
Teddy2steper has joined #ruby
mayhew has left #ruby [#ruby]
frem has quit [Quit: Computer has gone to sleep.]
tvw has quit [Remote host closed the connection]
Squarepy has quit [Quit: Leaving]
jenrzzz has joined #ruby
tjbiddle has quit [Quit: tjbiddle]
g_bleezy has joined #ruby
emocakes has quit [Quit: emocakes]
squidBits has quit [Quit: whoops]
qwerxy has quit [Quit: offski]
sn0wb1rd has quit [Quit: sn0wb1rd]
rakl has joined #ruby
efrainolivares has quit [Quit: efrainolivares]
thecreators has quit [Quit: thecreators]
rakl has quit [Client Quit]
niklasb has joined #ruby
cousine has joined #ruby
cousine has quit [Remote host closed the connection]
phelps has joined #ruby
phelps has quit [Remote host closed the connection]
zarubin has quit []
whowantstolivefo has quit [Remote host closed the connection]
atno has quit [Quit: Leaving]
tommyvyo_ has quit [Quit: Computer has gone to sleep.]
h4mz1d has quit [Ping timeout: 255 seconds]
cmyers has joined #ruby
jenrzzz has quit [Read error: No route to host]
<cmyers> when using rspec, I want to print out a special message when an assertion fails, so I am doing something like this: "@foo.attribute.should == "value"" and make it so if it fails, the error message prints out "#{@foo.errors}" or something... does should have a way to include an error msg?
bricker is now known as bricker`away
Shadow_S has joined #ruby
punkrawkR^Home has quit [Ping timeout: 252 seconds]
passbe has joined #ruby
passbe has quit [Changing host]
passbe has joined #ruby
Teddy2steper has quit [Remote host closed the connection]
<alexspeller> cmyers: you need a custom matcher
bricker`away has quit [Ping timeout: 265 seconds]
<cmyers> alexspeller: awesome, thx
jenrzzz has joined #ruby
<alexspeller> Look at the "Custom failure messages" section specificially
zigomir has quit [Quit: zigomir]
horofox has quit [Quit: horofox]
jenrzzz has quit [Ping timeout: 252 seconds]
luckyruby has quit [Remote host closed the connection]
stkowski has quit [Quit: stkowski]
sepp2k has quit [Remote host closed the connection]
hiroyuki has quit [Read error: Connection reset by peer]
sn0wb1rd has joined #ruby
swex has joined #ruby
hiroyuki has joined #ruby
sn0wb1rd is now known as Guest71275
Guest71275 has quit [Client Quit]
swex_ has quit [Read error: Operation timed out]
joast has quit [Quit: Leaving.]
robbyoconnor has joined #ruby
miskander has joined #ruby
thecreators has joined #ruby
lolcathost has quit [Quit: leaving]
havenn has joined #ruby
benlieb has joined #ruby
yfeldblum has quit [Ping timeout: 272 seconds]
tommyvyo_ has joined #ruby
havenn has quit [Ping timeout: 265 seconds]
joast has joined #ruby
skcin7 has quit [Quit: Computer has gone to sleep.]
lolcathost has joined #ruby
kiyoura has quit [Ping timeout: 260 seconds]
thecreators has quit [Quit: thecreators]
blazes816 has quit [Quit: blazes816]
adkron has joined #ruby
joeycarmello has quit [Remote host closed the connection]
<shevy> can I get a "r"
lolcathost has quit [Ping timeout: 244 seconds]
miskander has quit [Quit: miskander]
miskander has joined #ruby
twoism has quit [Remote host closed the connection]
twoism has joined #ruby
v0n has joined #ruby
samuel02 has quit [Remote host closed the connection]
aaronmacy has joined #ruby
yfeldblum has joined #ruby
jenrzzz has joined #ruby
freeayu has joined #ruby
postmodern has joined #ruby
twoism has quit [Ping timeout: 250 seconds]
Virunga has quit [Remote host closed the connection]
miskander has quit [Quit: miskander]
h4mz1d has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
maesbn has joined #ruby
emocakes has joined #ruby
mockra has quit [Read error: Connection reset by peer]
tjbiddle has joined #ruby
moshee has quit [Ping timeout: 252 seconds]
moshee has joined #ruby
tjbiddle has quit [Read error: Connection reset by peer]
tjbiddle has joined #ruby
emocakes has quit [Ping timeout: 265 seconds]
yxhuvud2 has quit [Quit: Nettalk6 - www.ntalk.de]
Nisstyre-laptop has joined #ruby
yxhuvud has joined #ruby
joeycarmello has joined #ruby
blakeeb has quit [Ping timeout: 244 seconds]
io_syl_ has joined #ruby
vlad_starkov has joined #ruby
IrishGringo has joined #ruby
io_syl has quit [Read error: Connection reset by peer]
io_syl_ is now known as io_syl
maesbn has quit [Remote host closed the connection]
aharris6 has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
lolcathost has joined #ruby
joeycarmello has quit [Remote host closed the connection]
mahmoudimus has quit [Remote host closed the connection]
aaronmacy has quit [Quit: Leaving.]
Spaceghostc2c has quit [Excess Flood]
Spaceghostc2c has joined #ruby
tjbiddle has quit [Quit: tjbiddle]
Hanmac1 has joined #ruby
manizzle has quit [Ping timeout: 252 seconds]
jenrzzz has quit [Ping timeout: 256 seconds]
Hanmac has quit [Ping timeout: 265 seconds]
Russell^^ has joined #ruby
kenneth has quit [Quit: kenneth]
justincampbell has quit [Remote host closed the connection]
_adeponte has quit [Remote host closed the connection]
rwalker has joined #ruby
havenn has joined #ruby
niklasb has quit [Ping timeout: 252 seconds]
Jasko has joined #ruby
skcin7 has joined #ruby
Spaceghostc2c has quit [Excess Flood]
Spaceghostc2c has joined #ruby
blakeeb has joined #ruby
emergion has joined #ruby
vlad_starkov has joined #ruby
havenn has quit [Remote host closed the connection]
tommyvyo_ has quit [Quit: Computer has gone to sleep.]
vlad_sta_ has joined #ruby
kenneth has joined #ruby
kenneth has quit [Client Quit]
vlad_starkov has quit [Ping timeout: 250 seconds]
raz has quit [Ping timeout: 255 seconds]
moshee has quit [Ping timeout: 252 seconds]
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
vlad_sta_ has quit [Ping timeout: 250 seconds]
kiyoura has joined #ruby
thams has joined #ruby
The_8473 has joined #ruby
raz has joined #ruby
nerd has quit [Quit: WeeChat 0.3.9.2]
_alejandro has joined #ruby
The_8472 has quit [Ping timeout: 255 seconds]
alexspeller has quit [Remote host closed the connection]
kokainepizza has quit [Quit: My pooter is sleep.]
raz has quit [Ping timeout: 260 seconds]
hotovson has joined #ruby
io_syl has quit [Quit: Textual IRC Client: www.textualapp.com]
g_bleezy has quit [Remote host closed the connection]
hotovson has quit [Read error: No route to host]
hotovson has joined #ruby
twoism has joined #ruby
tommyvyo has quit [Quit: http://thomasvendetta.com]
wolfman2000 has joined #ruby
hotovson has quit [Read error: No route to host]
twoism has quit [Ping timeout: 252 seconds]
havenn has joined #ruby
Shadow_S has quit [Quit: Textual IRC Client: www.textualapp.com]
jimeh has quit [Quit: Computer has gone to sleep.]
Shadow_S has joined #ruby
Russell^^ has quit [Quit: Russell^^]
charliesome has joined #ruby
manizzle has joined #ruby
alanp has quit [Read error: Connection reset by peer]
alanjc_ has joined #ruby
alanp has joined #ruby
fir_ed has joined #ruby
_alejandro has quit [Remote host closed the connection]
kn330 has quit [Ping timeout: 246 seconds]
kn330 has joined #ruby
emergion has quit [Quit: Computer has gone to sleep.]
pu22l3r has joined #ruby
nga4 has quit []
emergion has joined #ruby
pu22l3r has quit [Remote host closed the connection]
<rwalker> dead night
dmerrick has joined #ruby
shiin has quit [Quit: Computer has gone to sleep.]
emergion has quit [Client Quit]
browndawg has joined #ruby
robbyoconnor has quit [Read error: Connection reset by peer]
keanehsiao has joined #ruby
dmerrick has quit [Client Quit]
keanehsiao has quit [Client Quit]
brianpWins has joined #ruby
adkron has quit [Ping timeout: 265 seconds]
sayan has joined #ruby
love_color_text_ has quit [Remote host closed the connection]
arkiver has joined #ruby
benlieb has quit [Quit: benlieb]
v0n has quit [Ping timeout: 246 seconds]
<shevy> rwalker hmmm we plan to take over the world with ruby one day
blakeeb has quit [Read error: No route to host]
tomzx_ has joined #ruby
v0n has joined #ruby
dross has quit [Ping timeout: 244 seconds]
io_syl has joined #ruby
goraxe has quit [Ping timeout: 245 seconds]
aharris6 has quit [Remote host closed the connection]
aedorn has joined #ruby
mguy has joined #ruby
internetishard has quit [Quit: Leaving.]
radic has quit [Disconnected by services]
radic_ has joined #ruby
benlieb has joined #ruby
robbyoconnor has joined #ruby
dross has joined #ruby
ryanlecompte has joined #ruby
rwalker has quit [Ping timeout: 255 seconds]
<charliesome> shevy: one day all of earth's people will speak ruby
<charliesome> and only ruby
<charliesome> and unicode will be rendered worthless
emocakes has joined #ruby
greenarrow has quit [Quit: IRC is just multiplayer notepad]
blakeeb has joined #ruby
tomzx_ has quit [Ping timeout: 250 seconds]
ewag has joined #ruby
dross has quit [Ping timeout: 246 seconds]
emocakes has quit [Ping timeout: 264 seconds]
v0n has quit [Ping timeout: 265 seconds]
c0rn has joined #ruby
kn330 has quit [Ping timeout: 252 seconds]
nari_ has joined #ruby
IrishGringo has quit [Ping timeout: 252 seconds]
kn330 has joined #ruby
wsylvest has joined #ruby
chord_ has joined #ruby
stevechiagozie has joined #ruby
manizzle has quit [Ping timeout: 250 seconds]
rondale_sc has joined #ruby
cirwin has joined #ruby
<rking> Hey RSpec fans. The top file doesn't do anything, the bottom one works perfectly. What's the trick to get it to work?: https://gist.github.com/4357513
<rking> NM, ryanf got it solved. It's that I should run it with 'rspec' the binary
c0rn has quit [Quit: Computer has gone to sleep.]
IrishGringo has joined #ruby
aharris6 has joined #ruby
vlad_starkov has joined #ruby
benlieb has quit [Quit: benlieb]
dross has joined #ruby
hadees has joined #ruby
tommyvyo has joined #ruby
vlad_starkov has quit [Ping timeout: 255 seconds]
lolcathost has quit [Ping timeout: 252 seconds]
pzol has joined #ruby
lolcathost has joined #ruby
blakeeb has quit [Ping timeout: 264 seconds]
<shevy> CodeRay is so cool
<ryanf> yes
<shevy> now in my shell when I do "cat bla.rb", and coderay is installed, it gets colourized happily
lolcathost has quit [Ping timeout: 244 seconds]
<shevy> the only thing that confuses me is, there is a "jump" to the top left screen at the beginning
chendo_ has quit [Ping timeout: 252 seconds]
alanjc_ has quit [Quit: alanjc_]
Guest9041 has quit [Ping timeout: 264 seconds]
Guest9041 has joined #ruby
chendo_ has joined #ruby
aapzak has quit [Ping timeout: 264 seconds]
aapzak has joined #ruby
gridaphobe has quit [Ping timeout: 265 seconds]
Guest9041 has quit [Remote host closed the connection]
fflush has quit []
Hanmac1 is now known as Hanmac
h4mz1d has quit [Ping timeout: 252 seconds]
<shevy> could this be the terminal "reset" command?
moshee has quit [Ping timeout: 246 seconds]
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
Bosox20051 has joined #ruby
Xeago has joined #ruby
<aedorn> how did you setup your highlighting via cat?
browndawg1 has joined #ruby
billy_ran_away has joined #ruby
skcin7 has quit [Quit: Computer has gone to sleep.]
<shevy> aedorn ah, 'cat' is just a substitute for read-content, in ruby ... let me try the real commandline cat
<shevy> ok aedorn
<shevy> this command here causes a jump too:
<shevy> puts CodeRay.scan('', :ruby).term
<shevy> I am going to look at what .term does
<ryanf> term just formats it for terminal output
<ryanf> i.e., puts in the highlighting as ansi codes
<aedorn> hmm, interesting.. mine does not reset
rondale_sc has left #ruby [#ruby]
<shevy> hmmmmmmm
browndawg has quit [Ping timeout: 265 seconds]
<shevy> aedorn oh... when you are in irb, and hit a few newlines, and then you do puts CodeRay.scan('', :ruby).term
<shevy> does it jump to the top left?
<aedorn> nope
Shadow_S has quit [Quit: Textual IRC Client: www.textualapp.com]
<shevy> :(
<shevy> hmm ok... then something is odd here with my setup
thams has quit [Read error: Connection reset by peer]
thams has joined #ruby
Guest9041 has joined #ruby
emocakes has joined #ruby
Nisstyre has quit [Quit: Leaving]
emocakes has quit [Ping timeout: 260 seconds]
Nisstyre-laptop has quit [Quit: Leaving]
joofsh has quit [Remote host closed the connection]
Nisstyre-laptop has joined #ruby
nari_ has quit [Ping timeout: 252 seconds]
havenn has quit [Remote host closed the connection]
woolite64 has joined #ruby
aapzak has quit [Ping timeout: 250 seconds]
kn330 has quit [Remote host closed the connection]
aapzak has joined #ruby
NiteRain has quit [Ping timeout: 246 seconds]
<aedorn> mmm can't seem to replicate what you're getting. I think you might be unique!
<shevy> aedorn :(
<shevy> hmm let's see if I can record this ...
tjbiddle has joined #ruby
<aedorn> what OS and shell are you using anyway?
tjbiddle has quit [Client Quit]
<shevy> bash, the OS is... linux (linuxmint) I think
wolfman2000 has quit [Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/]
<shevy> and gnome-terminal hmmmm
<aedorn> well then, let me get mint with gnome and see
<aedorn> oh right... they moved to mate and cinnamon .. well, shouldn't matter much
lolcathost has joined #ruby
ryanlecompte has quit [Remote host closed the connection]
<shevy> perhaps I have set some environment variable
<swarley> shevy; do, /exec -o echo "echo $SHELL `uname -a` | bash"
aharris6 has quit [Remote host closed the connection]
<shevy> hmm /bin/bash Linux computer4 3.5.0-17-generic #28-Ubuntu SMP Tue Oct 9 19:32:08 UTC 2012 i686 athlon i686 GNU/Linux | bash
kiyoura has quit [Ping timeout: 255 seconds]
<shevy> need to be away from the computer for some minutes
<swarley> you can tell your version from /etc/issue
wsylvest has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
aharris6 has joined #ruby
thams has quit [Read error: Connection reset by peer]
thams has joined #ruby
dmerrick has joined #ruby
arkiver has quit [Ping timeout: 260 seconds]
tk__ has joined #ruby
lolcathost has quit [Ping timeout: 246 seconds]
frogstarr78 has quit [Ping timeout: 244 seconds]
yshh has joined #ruby
djdb has joined #ruby
Godd2 has joined #ruby
R3dy has quit [Ping timeout: 265 seconds]
araujo has quit [Read error: Connection reset by peer]
dmerrick has quit [Quit: dmerrick]
araujo has joined #ruby
araujo has quit [Changing host]
araujo has joined #ruby
topriddy has joined #ruby
<aedorn> hmmm.. nope, still no issue with Mint using gnome-terminal
pencilcheck has joined #ruby
pen has quit [Ping timeout: 256 seconds]
sn0wb1rd has joined #ruby
lewis1711 has joined #ruby
<lewis1711> Hash[('a'...'z').zip [1, 2]] #is there anyway to do something like except instead of all the nils, you just get {"a"=> 1, "b" => 2} ?
IceDragon has quit [Quit: Space~~~]
<heftig> lewis1711: zip the other way around
emocakes has joined #ruby
<heftig> Hash[[1,2].zip('a'...'z').map(&:reverse)]
<lewis1711> oh yeah. why didn't I think of that
<lewis1711> pleasure playing golf with you heftig
ryanf_ has joined #ruby
emocakes has quit [Ping timeout: 245 seconds]
love_color_text has joined #ruby
keyvan has joined #ruby
keyvan has joined #ruby
keyvan has quit [Changing host]
ryanf has quit [Ping timeout: 250 seconds]
love_col_ has joined #ruby
love_color_text has quit [Read error: Connection reset by peer]
karupanerura has quit [Excess Flood]
havenn has joined #ruby
keyvan has quit [Ping timeout: 255 seconds]
karupanerura has joined #ruby
ananthakumaran has joined #ruby
Xeago has quit [Remote host closed the connection]
<lewis1711> another question - are there any test frameworks that don't require you to make a class? something where you can just require your file, and have top level methods like "check_equals"
havenn has quit [Ping timeout: 255 seconds]
love_col_ has quit [Read error: Connection reset by peer]
love_color_text has joined #ruby
love_color_text has quit [Read error: Connection reset by peer]
tar_ has joined #ruby
love_color_text has joined #ruby
love_color_text has quit [Remote host closed the connection]
wargasm has quit [Ping timeout: 265 seconds]
Debolaz has quit [Quit: ZNC - http://znc.in]
<heftig> lewis1711: test rocket?
love_color_text has joined #ruby
Juul has joined #ruby
phelps has joined #ruby
vlad_starkov has joined #ruby
keyvan has joined #ruby
keyvan has quit [Changing host]
keyvan has joined #ruby
lepht has joined #ruby
love_col_ has joined #ruby
love_color_text has quit [Ping timeout: 255 seconds]
vlad_starkov has quit [Ping timeout: 260 seconds]
love_col_ has quit [Read error: Connection reset by peer]
ryanlecompte has joined #ruby
keyvan has quit [Ping timeout: 260 seconds]
tchebb is now known as ZombieTchebb
ryanf_ has quit [Quit: broken pipes |||]
ZombieTchebb is now known as tchebb
browndawg has joined #ruby
Godd2 has quit [Quit: Page closed]
browndawg1 has quit [Ping timeout: 255 seconds]
<lewis1711> right, one last question. I am in directory a. inside b, is directory b, with file.rb
<lewis1711> require "./b/file.rb"; require "/b/file.rb"
ryanlecompte has quit [Ping timeout: 255 seconds]
<heftig> what?
<lewis1711> neither work
love_color_text has joined #ruby
pavilionXP has quit [Ping timeout: 264 seconds]
IrishGringo has quit [Remote host closed the connection]
<heftig> the former works
<Hanmac> lewis1711 you are maybe NOT into a, use require_relative
<heftig> require_relative "b/file" is relative to the source file it's in
<heftig> require "./b/file.rb" is relative to the working directory (Dir.pwd)
<lewis1711> :/
robustus has quit [Ping timeout: 255 seconds]
fasta has quit [Quit: No Ping reply in 180 seconds.]
* Hanmac prefers require_relative ... ther other one could be highjacked ...
<lewis1711> ok my mistake. I am confusing myself because I was calling a file in tests, that then tries to call a file above itself.
fasta has joined #ruby
robustus has joined #ruby
keyvan has joined #ruby
keyvan has quit [Changing host]
keyvan has joined #ruby
stevechiagozie has quit [Ping timeout: 250 seconds]
<lewis1711> ohh. the require paths get mangled depending on where you call it from. right I will try require relative
love_color_text has quit [Ping timeout: 260 seconds]
<lewis1711> right working. thanks
pavilionXP has joined #ruby
nari_ has joined #ruby
anarchist has joined #ruby
lewis1711 has quit [Ping timeout: 246 seconds]
Dreamer3 has quit [Quit: Computer has gone to sleep.]
alanjc_ has joined #ruby
<reactormonk> Hanmac, by setting PWD?
ryanf has joined #ruby
<Hanmac> or when you have an file with the same name on different locations
<reactormonk> huh? Isn't . PWD?
<anarchist> anyone here interested in payments processing and json-ld? http://payswarm.com
Bosox20051 has quit [Ping timeout: 244 seconds]
<reactormonk> anarchist, go take your ads somewhere else
keyvan has quit [Read error: Connection reset by peer]
<anarchist> reactormonk: i'm a socialist, i'm not into marketing
Paradox| is now known as Paradox
<anarchist> there's a php client and a node.js client but no ruby client
<anarchist> we want to integrate it with http://sharetribe.com/en which is in ruby
love_color_text has joined #ruby
Animawish has joined #ruby
<anarchist> https://github.com/digitalbazaar/payswarm.js/ <-- payswarm client is 1300 lines, 200 lines for listing an asset, 200 lines to purchase one
<Animawish> how do I unicode stuff with ruby? puts '\u2654' doesn't do anything, for example
browndawg has quit [Read error: Connection reset by peer]
<reactormonk> anarchist, so why the messages here?
<anarchist> need people that know ruby
<reactormonk> Animawish, you might want to use "", because '' barely interpret anything
Mon_Ouie has quit [Read error: Connection reset by peer]
<reactormonk> anarchist, sooo hire them
Mon_Ouie has joined #ruby
<Animawish> reactormonk: you're a wizard, thanks
<anarchist> it's more of a barter situation
<Animawish> i had no idea there was a difference
<reactormonk> Animawish, '' is mostly literal, "" is a lot of interpolation
tommyvyo has quit [Quit: Computer has gone to sleep.]
<reactormonk> go try interpolating #{} and stuff in ''
emocakes has joined #ruby
<reactormonk> anarchist, I haven't yet heard of anyone being hired here - but that doesn't mean anything
sayan has quit [Ping timeout: 244 seconds]
lewis1711 has joined #ruby
love_color_text has quit [Ping timeout: 256 seconds]
love_color_text has joined #ruby
tommyvyo has joined #ruby
lewis1711 has left #ruby [#ruby]
patrick99e99 has quit [Quit: Lost terminal]
<anarchist> reactormonk: this is to make a bank for occupy wall street. that's the only sense in which there's money involved
keyvan has joined #ruby
keyvan has quit [Changing host]
keyvan has joined #ruby
<reactormonk> anarchist, now that changes perspective.
Animawish has left #ruby [#ruby]
emocakes has quit [Ping timeout: 250 seconds]
<reactormonk> as far as I get it, the idea is similar to flattr
love_color_text has quit [Ping timeout: 260 seconds]
love_col_ has joined #ruby
keyvan has quit [Ping timeout: 252 seconds]
tommyvyo has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
havenn has joined #ruby
love_color_text has joined #ruby
alanjc_ has quit [Quit: alanjc_]
love_col_ has quit [Ping timeout: 260 seconds]
sayan has joined #ruby
<anarchist> oh if you like flattr you'll love this
<anarchist> 7 digit accuracy micro-crowdfunding
<anarchist> native cryptography
<anarchist> digital asset contract negotiation with licensing and thousands of contractees
<anarchist> contractors?
<anarchist> decentralized payments processing (flattr is centralized)
browndawg has joined #ruby
<anarchist> json-ld linked data standards
<anarchist> and last but not least, mint your own currency
<anarchist> again with native cryptography, decentralized payments processing, URIs are first class citizens
<anarchist> eventually the payments intents specification will be an open standard (preferably W3C) for kickstarter like crowd funding
<chord_> BITCOIN
<anarchist> also there are lines of grant, so you can put $.50 on your knitting websites account, $5 on your music account, $10 on your movie/tv account and let websites deduct either automatically or ask every time
<anarchist> it can also transact the BTC
<anarchist> it's a linked data standard for BTC
<anarchist> oh damn, that's who i should be asking
<anarchist> i bet there's some ruby knowing bitcoin people
nemesit has joined #ruby
<anarchist> refill those knitting, blog, music, movie accounts every month
<anarchist> if you want to give .0000001 of a cent to someone it only costs you 1%
<anarchist> instead of google's micropayments scheme where the minimum is 49 cents and they take a bigger cut (i'm guessing they take a bigger cut i don't know)
<anarchist> anyway i just saw the hobbit so if one of you would lend me your sword, another your bow and the last one your axe that'd be awesome :-)
Slivka has joined #ruby
havenn has quit [Remote host closed the connection]
Dreamer3 has joined #ruby
<anarchist> and of course since it's an open standard for the web you can start your own payments processor yourself (and then not pay the %1 to digital bazaar who wrote the standard). of course then you'll have to convince the banksters to allow you to, which will be aided greatly if digital bazaar is successful. or if we occupy them
eldariof has joined #ruby
_alejandro has joined #ruby
aharris6 has quit [Remote host closed the connection]
shemerey has joined #ruby
cirwin has quit [Remote host closed the connection]
rakl has joined #ruby
arietis has joined #ruby
adeponte has joined #ruby
Axsuul has quit [Ping timeout: 252 seconds]
_alejandro has quit [Remote host closed the connection]
ninegrid has quit [Ping timeout: 264 seconds]
sandGorgon has joined #ruby
obind has quit []
bluOxigen has joined #ruby
atmosx has joined #ruby
nemesit has quit [Quit: Leaving...]
topriddy has quit [Read error: Connection reset by peer]
sandGorgon1 has joined #ruby
Slivka has quit [Remote host closed the connection]
Slivka has joined #ruby
blueoxigen has joined #ruby
Slivka has quit [Remote host closed the connection]
<atmosx> Hello
<atmosx> I'm trying to load a css file into views/layout.haml without success. At views/layout.haml I have this line: %link(rel="stylesheet" href="css/styles.css") and the styles.css is located at public/css/ any ideas why that happens? :/ I'm using sinatra as a framework
Slivka has joined #ruby
love_color_text has quit [Read error: Connection reset by peer]
S0da has joined #ruby
love_color_text has joined #ruby
bluOxigen has quit [Ping timeout: 255 seconds]
love_color_text has quit [Read error: Connection reset by peer]
codezombie has joined #ruby
love_color_text has joined #ruby
love_color_text has quit [Remote host closed the connection]
topriddy has joined #ruby
browndawg has quit [Quit: Leaving.]
Slivka has quit [Quit: Slivka]
hero has joined #ruby
hero has quit [Changing host]
hero has joined #ruby
love_color_text has joined #ruby
Monie has quit [Read error: Connection reset by peer]
keyvan has joined #ruby
keyvan has quit [Read error: Connection reset by peer]
love_color_text has quit [Read error: Connection reset by peer]
love_color_text has joined #ruby
S0da has quit [Remote host closed the connection]
<chord_> anarchist: WE NEED BITCOIN TO TAKE OFF
Slivka has joined #ruby
<anarchist> chord_: would you be willing to help build a transaction processor for bitcoin (but also many other currencies as well) using a JSON-LD parser for ruby?
adeponte has quit [Remote host closed the connection]
love_color_text has quit [Read error: Connection reset by peer]
love_color_text has joined #ruby
<chord_> anarchist: would you be willing to teach me how in god's hell the cryptography in bitcoin works ;)
<anarchist> i could teach you a lot about bitcoin
<anarchist> including where the first bitcoins came from
<anarchist> i don't know a lot about cryptography specifically though
jgrevich has quit [Quit: jgrevich]
<chord_> how can you build a bitcoin processor without knowing how the cryptography works
<anarchist> well the mining part doesn't change, this is just adding structured data so that people know there was a transaction, what size it was for, who made the transaction (if that information is made public on the web), some other things
sandGorgon1 has quit [Read error: Operation timed out]
pavilionXP has quit [Ping timeout: 265 seconds]
<chord_> isn't that good enough
<anarchist> so if you have FOAF (friend of a friend) information, or SIOC (semantically interconnected online communities) talking about specific transactions that could all work together
elkclone has joined #ruby
<anarchist> it's pretty structured already, what this would do is create the same structured data for transactions in ALL currencies not just bitcoin
<anarchist> it HAS structure but it's not yet JSON-LD
<chord_> wait why in hell would anyone tel lyou about their credit card transactions
<anarchist> well think about social movements
<anarchist> occupy wall street for instance
sandGorgon has quit [Ping timeout: 260 seconds]
<chord_> why would they need to know
squidBits has joined #ruby
<anarchist> participatory budgeting needs there to be some transparency of financial information
<anarchist> or else it's not an open collaborative process and there's accounting questions like happened with occupy
<chord_> so you build some website, why should anyone believe the data on the website
<atmosx> anarchist: my problem with BT is the exchange, I cannot exchange the money *at any given time*
<atmosx> anarchist: other than that, I'd gladly use it
<anarchist> actually it's not a website, it's a payment standard for all programming languages, starting with php, then node.js and hopefully now ruby
<chord_> what do you mean payment standard, bitcoin already exists right?
<anarchist> so that means every php site, every node.js site, every ruby site that transacts in BTC, dollars, yen or even new currencies that people make up
emocakes has joined #ruby
<anarchist> i mean a standard that interoperates with the linked data cloud
<chord_> so why would anyone use something that has a single point of eavesdropping
<anarchist> or even if that standard is not linked data in itself, although if it were payswarm it would be, then at least it should transact as many currencies as possible
<anarchist> well if you're talking about the actual currency mint that's almost always centralized bitcoin being the notable exception
<anarchist> if you're talking about transactions processing that's decentralized in payswarm
<anarchist> so there's two kinds of things, payment authorities and payments processors
<anarchist> in the case of bitcoin the payment authority is the big ol' blockchain in the sky
<anarchist> but anybody could be a payments processor using JSON-LD and the Payswarm standard
_lepht has joined #ruby
<chord_> wtf is payswarm
emocakes has quit [Ping timeout: 252 seconds]
<anarchist> one second i'll give you a datasheet
love_color_text has quit [Remote host closed the connection]
<chord_> i'm not getting it what is the point of payswarm if bitcoin already exists
adambeynon has joined #ruby
lenovodroid has joined #ruby
<anarchist> to make that data interoperable with other ontologies for linked data that already exist like FOAF, SIOC or that will exist in the future like ontologies for parts suppliers and parts numbers for electronics and where to buy them
<anarchist> it doesn't make bitcoin more centralized, in fact it allows bitcoin to interoperate with ontologies and linked data that are highly decentralized
<chord_> you are making no sense, need a concrete example of how this gets used
<anarchist> well let's say you're writing accounting software for a workers' coop that makes paraffin wax heaters and you want to open source your business model so others can build the heaters because you'd rather have cheaper heaters so you can get started open sourcing more technologies
adambeynon has quit [Client Quit]
<chord_> ok
<anarchist> you need a way to expose data about what parts you're buying, how much you bought, what departments bought what, how to link that to the exact time in the archived audio/video conference where you made the decision, relevant keyword searches from the minutes for that meeting
<anarchist> maybe some of your donors want to see how you're spending the money or they won't give
lapinferoce has left #ruby ["Konversation terminated!"]
<chord_> so you have a sql database whats the problem
<anarchist> so you want a way of showing how their exact transaction got spent exactly on the thing you said you'd spend it on
lepht has quit [Quit: wat was that i dont even]
<anarchist> well the problem with a sql database is that the data lives in a silo
_lepht has quit [Quit: ZNC - http://znc.in]
<anarchist> you can say you're exposing it on the web, but nobody else can use your sql database the way you do
<chord_> the data has to be on same computer
<anarchist> makes it very hard to do forensic accounting
<chord_> so you gotta put the data on some computer
<anarchist> yeah but even when you put data on the same computer, if in one table "name" means the person's name but in another table "name" means a username
<anarchist> and both datasets are about usernames on a website
<anarchist> then they can't seamlessly interoperate
topriddy has quit [Read error: Connection reset by peer]
lepht has joined #ruby
<chord_> so how is payswarm relevant at all to this
shtirlic_ has joined #ruby
<anarchist> because it's written in JSON-LD (javascript serialized objection notation for linking data)
<anarchist> so it's interoperable with other linked data
<chord_> and why is json-ld going to fix everything
<anarchist> not fix everything
<anarchist> fix the interoperability of data problem
<chord_> how do you plan on forcing people to use json-ld
<anarchist> same way people are 'forced' to use any web technology. because that's what all the cool stuff runs on
love_color_text has joined #ruby
Slivka has quit [Remote host closed the connection]
love_color_text has quit [Remote host closed the connection]
Slivka has joined #ruby
<chord_> so whats the api that is exposed?
love_color_text has joined #ruby
Slivka has quit [Remote host closed the connection]
<anarchist> sparql endpoints instead of sql silos
arkiver has joined #ruby
Slivka has joined #ruby
<anarchist> here's an example of an application that consumes linked data http://www.slideshare.net/metade/bbc-linked-data-and-the-music-bore
topriddy has joined #ruby
Slivka has quit [Remote host closed the connection]
shtirlic_ has quit [Remote host closed the connection]
<anarchist> http://vimeo.com/5561309 video her
<anarchist> e
love_color_text has quit [Read error: Connection reset by peer]
arkiver has quit [Max SendQ exceeded]
love_color_text has joined #ruby
djdb has quit [Quit: Ухожу я от вас (xchat 2.4.5 или старше)]
arkiver has joined #ruby
<anarchist> chord_: did you see Watson Jr. ?
<anarchist> on jeopardy
blakeeb has joined #ruby
<anarchist> can beat any human opponent
<chord_> yah
<anarchist> let's say i were to ask you on jeopardy. these are the names of the top 10 largest holders of bitcoins
<anarchist> or "the second and seventh largest holders of bitcoins earned their bitcoins primarily by doing this"
Slivka has joined #ruby
<anarchist> well linked data can answer questions like that on the fly
love_color_text has quit [Remote host closed the connection]
<anarchist> because the intelligence is in the data not in the application
<chord_> so whats the point of using sqarql and not sql
<anarchist> so the answer to that question would just be a sparql query against databases that store relevant information no matter where the data is at on the web
<chord_> or something else like couchdb
<chord_> how would a sparql query know where the databases are
<anarchist> there's a standard place for sparql endpoints and standardized linked data for how to get all the sparql endpoints programmatically from any website you consume linked data from
<anarchist> so it's probably in the standard place, and if it's not, there could be a programmatic way of finding out the sparql endpoint just because you happened on a link to that data from someplace random
<chord_> and how does data get added to these databases and what does this data look like
<anarchist> it looks like this http://directory.occupy.net/node/20080.jsonld
love_color_text has joined #ruby
<anarchist> json-ld is just one way of making linked data. json-ld interoperates with rdf-xml for example
<anarchist> that lets you browse the ontology
yacks has quit [Ping timeout: 260 seconds]
<anarchist> it basically means automating application development once there are linked data content management systems (not to produce data which is simple but to consume it)
Kuifje has joined #ruby
Kuifje has quit [Changing host]
Kuifje has joined #ruby
<anarchist> instead of a programmer taking a week an ontological philosopher could write an app in an hour
<anarchist> intelligent agents basically
g_bleezy has joined #ruby
<chord_> i'm not getting what exactly is this app suppose to do?
<anarchist> the occupy ontology is not an app itself it's just the data model
<anarchist> music bore is an app though
browndawg has joined #ruby
Monie has joined #ruby
<anarchist> it browses music datasets, dbpedia, and other linked data to do the job of a disc jockey
<chord_> so you are thinking about some website that lets you browse json-ld that has somehow been submitted?
g_bleezy has quit [Ping timeout: 256 seconds]
<anarchist> the json-ld is generated alongside a normal human readable application
<anarchist> but when you do an http GET on an http URI you hope to return RDF
<anarchist> instead of a human readable page
<anarchist> and that RDF data allows you to dereference other URIs that may be of interest
yxhuvud2 has joined #ruby
<anarchist> so the musicbore doesn't know what it's going to find, it just follows its nose. it would be hard to write an application that tells you how the last artist in a random playlist is connected to the current artist playing otherwise
<chord_> you need to make like some prototype gui that shows exactly what this is suppose to do, because i'm just not getting it
<anarchist> the thing is it's very much not about the GUI
<anarchist> it might as well be a SIRI like app that just speaks to you directly with text to speech
<anarchist> the reason for GUIs is human readability
<chord_> a prototype to show what the transaction json data is suppose to look like
<anarchist> oh sure http://dev.payswarm.com
<anarchist> there's some way to see financial transaction data on there, i forget exactly where
<chord_> why you need another payswarm
<chord_> if it already exists
Slivka has quit [Remote host closed the connection]
<anarchist> nothing else out there replicates what payswarm can do
yxhuvud has quit [Ping timeout: 260 seconds]
<anarchist> there are also payswarm specs that don't have a reference implementation yet like payment intents
<anarchist> although payment intents will never work on bitcoin
<chord_> so payswarm already does what you need, you're done
<anarchist> right it just doesn't have a ruby client yet
Slivka has joined #ruby
nemesit has joined #ruby
<anarchist> basically payswarm would allow an open source kickstarter
<anarchist> it would be the first kickstarter using micropayments with 7 digit accuracy
<chord_> so your real issue is that there isn't a programmatic way at getting at payswarm data?
blueoxigen has quit [Ping timeout: 250 seconds]
<anarchist> the client hasn't been built in ruby
<anarchist> the json-ld parser has been built in ruby though which helps a lot
<chord_> so use the other languages
<anarchist> want to integrate it into a specific ruby app
<anarchist> figured other people in here might relate to that
nomenkun has joined #ruby
<chord_> migrate the ruby app to the other language
<anarchist> that's actually not a horrible approach for us
<anarchist> still there's been a lot of work put in by the occupy community on http://sharetribe.com/en
codezombie has quit [Quit: Linkinus - http://linkinus.com]
<anarchist> it does pretty much what we want
<anarchist> and a payswarm client in ruby should be ~1300 lines of code
ProZzZz is now known as Proshot
Guest25886 has joined #ruby
blakeeb has quit [Ping timeout: 250 seconds]
Vert has joined #ruby
blacktulip has joined #ruby
daniel_hinojosa has quit [Quit: Leaving.]
h4mz1d has joined #ruby
yacks has joined #ruby
blacktulip has quit [Remote host closed the connection]
<oxman> the next Datamapper 2 will be awesome :)
luckyruby has joined #ruby
arkiver has quit [Ping timeout: 252 seconds]
h4mz1d has quit [Ping timeout: 252 seconds]
Guest25886 has quit [Ping timeout: 265 seconds]
marr has joined #ruby
sayan has quit [Ping timeout: 252 seconds]
workmad3 has joined #ruby
yacks has quit [Read error: Operation timed out]
Tux-Tn has joined #ruby
Guest25886 has joined #ruby
arkiver has joined #ruby
jwang has quit [Quit: Leaving]
emocakes has joined #ruby
whowantstolivefo has joined #ruby
emocakes has quit [Read error: Operation timed out]
arkiver has quit [Ping timeout: 255 seconds]
workmad3 has quit [Quit: Lost terminal]
vlad_starkov has joined #ruby
rakl has quit [Quit: sleeping]
emocakes has joined #ruby
vlad_starkov has quit [Ping timeout: 255 seconds]
cantonic has quit [Quit: cantonic]
lenovodroid has quit [Read error: Connection reset by peer]
lenovodroid has joined #ruby
lkba has quit [Ping timeout: 246 seconds]
lenodroid has joined #ruby
lenovodroid has quit [Read error: Connection reset by peer]
sayan has joined #ruby
Banistergalaxy has joined #ruby
cantonic has joined #ruby
ikaros has joined #ruby
havenn has joined #ruby
yxhuvud has joined #ruby
pavilionXP has joined #ruby
woolite64 has quit [Ping timeout: 245 seconds]
lenodroid has quit [Read error: Connection reset by peer]
lenodroid has joined #ruby
yxhuvud2 has quit [Ping timeout: 255 seconds]
thone has joined #ruby
lenodroid has quit [Read error: Connection reset by peer]
Neomex has joined #ruby
lenodroid has joined #ruby
Neomex has quit [Client Quit]
rakl has joined #ruby
thone_ has quit [Ping timeout: 252 seconds]
Virunga has joined #ruby
havenn has quit [Remote host closed the connection]
Slivka has quit [Remote host closed the connection]
aapzak has quit [Ping timeout: 250 seconds]
aapzak has joined #ruby
maesbn has joined #ruby
cantonic has quit [Quit: cantonic]
rippa has joined #ruby
arkiver has joined #ruby
nari_ has quit [Ping timeout: 252 seconds]
ozgor has joined #ruby
lenodroid has quit [Ping timeout: 250 seconds]
maesbn has quit [Remote host closed the connection]
wallerdev has quit [Quit: wallerdev]
verto|off is now known as verto
generalissimo has joined #ruby
marr has quit [Ping timeout: 255 seconds]
generalissimo has quit [Remote host closed the connection]
lkba has joined #ruby
sayan has quit [Read error: Connection reset by peer]
_64k has joined #ruby
samuel02 has joined #ruby
<emocakes> i never knew ricky martin was gay :\
<atmosx> emocakes: seriously?
<atmosx> emocakes: I don't want to ruin your childhoot, but Keanu Reeves is gay too.
lkba has quit [Quit: Bye]
pmros has joined #ruby
lkba has joined #ruby
<pmros> hi
TheFuzzball has quit [Ping timeout: 255 seconds]
banisterfiend has joined #ruby
<emocakes> bullshit atmosx
<emocakes> really?
berserkr has joined #ruby
<atmosx> well, yeah..
<emocakes> thanks for spoiling my xmas
<whowantstolivefo> how can i kill webrick from bash ? it says from bash i say rails server and i get the following error /home/aslan/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/webrick/utils.rb:85:in `initialize': Address already in use - bind(2) (Errno::EADDRINUSE)
atno has joined #ruby
<emocakes> ps -A | grep webrick
<emocakes> :p
<emocakes> kill pid
<emocakes> or killall webrick
<atno> morning
rakl has quit [Quit: gone]
<emocakes> those are rumors atmosx
<emocakes> :\
<atmosx> Sure, I don't know him in person.
<atmosx> You probably need to figure why someone being queer bothers you.
Nuck has joined #ruby
xbob has joined #ruby
_bart has quit [Quit: _bart]
maesbn has joined #ruby
Xeago has joined #ruby
<apeiros_> atmosx +1
horofox has joined #ruby
* apeiros_ never got why other people's sexual preference bothers people
<apeiros_> ZOMG it destroys the sanctity of marriage! *eyeroll*
<apeiros_> ah, no, that was gay marriage *needstowakeup*
nomenkun_ has joined #ruby
nomenkun has quit [Read error: Connection reset by peer]
nari_ has joined #ruby
<maetthew> :)
maesbn has quit [Remote host closed the connection]
<apeiros_> "they *generally* don't do this" - lol, so ocassionally they do? :D
<maetthew> :D
<maetthew> "how am i supposed to tell my child that two men are getting married"
<maetthew> "i don't know it's your shitty kid"
<maetthew> :D
darthdeus has joined #ruby
<apeiros_> I have a solution for that: "see kid, the get married."
<apeiros_> *they
yxhuvud2 has joined #ruby
_bart has joined #ruby
<apeiros_> how hard was that?
aharris6 has joined #ruby
<maetthew> :D
niklasb has joined #ruby
nomenkun has joined #ruby
nomenkun_ has quit [Read error: No route to host]
Juul has quit [Quit: Leaving]
eka has joined #ruby
banisterfiend has quit [Ping timeout: 264 seconds]
yxhuvud has quit [Ping timeout: 252 seconds]
maesbn has joined #ruby
_bart has quit [Ping timeout: 246 seconds]
darthdeus has quit [Ping timeout: 252 seconds]
sayan has joined #ruby
samphippen has joined #ruby
sayan has quit [Max SendQ exceeded]
elkclone has quit [Quit: It's never too late to unplug and run.]
sayan has joined #ruby
eka has quit [Quit: chant Hare Krishna and be Happy]
<topriddy> saved my file with .rb in vim….still doesn't do any syntax highlighting. anyone know why?
havenn has joined #ruby
_bart has joined #ruby
eka has joined #ruby
maesbn has quit [Remote host closed the connection]
radic_ has quit [Ping timeout: 264 seconds]
anarchist has quit [Ping timeout: 265 seconds]
radic has joined #ruby
marr has joined #ruby
havenn has quit [Ping timeout: 252 seconds]
verto is now known as verto|off
<oxman> :syntax on
banisterfiend has joined #ruby
crackfu has quit [Remote host closed the connection]
Xeago has quit [Remote host closed the connection]
banisterfiend has quit [Read error: Connection reset by peer]
banister_ has joined #ruby
nari_ has quit [Ping timeout: 264 seconds]
hoelzro|away is now known as hoelzro
sepp2k has joined #ruby
lenodroid has joined #ruby
lenodroid has quit [Read error: Connection reset by peer]
shiin has joined #ruby
sayan has quit [Read error: Connection reset by peer]
nomenkun has quit [Ping timeout: 260 seconds]
horofox_ has joined #ruby
banister_ has quit [Ping timeout: 256 seconds]
_bart has quit [Quit: _bart]
chord_ has quit [Quit: Page closed]
aharris6 has quit [Remote host closed the connection]
horofox has quit [Ping timeout: 255 seconds]
horofox_ is now known as horofox
Xeago has joined #ruby
nomenkun has joined #ruby
zigomir has joined #ruby
Nisstyre-laptop has quit [Ping timeout: 252 seconds]
darthdeus has joined #ruby
elaptics`away is now known as elaptics
sayan has joined #ruby
maesbn has joined #ruby
hoelzro is now known as hoelzro|away
pmros has quit [Quit: Konversation terminated!]
maesbn has quit [Remote host closed the connection]
nemesit has quit [Quit: Leaving...]
Tumulte has joined #ruby
zigomir has quit [Quit: zigomir]
marr has quit [Ping timeout: 265 seconds]
nomenkun has quit [Ping timeout: 250 seconds]
arkiver has quit [Quit: Leaving]
Divinite_ has joined #ruby
Divinite_ has left #ruby [#ruby]
nomenkun has joined #ruby
aapzak has quit [Ping timeout: 265 seconds]
aapzak has joined #ruby
Dreamer3 has quit [Ping timeout: 255 seconds]
EyesIsMine has quit [Quit: Leaving]
Xeago has quit [Remote host closed the connection]
greenarrow has joined #ruby
yxhuvud has joined #ruby
Xeago has joined #ruby
Dreamer3 has joined #ruby
yxhuvud2 has quit [Ping timeout: 244 seconds]
My_Hearing has joined #ruby
My_Hearing has quit [Changing host]
My_Hearing has joined #ruby
Mon_Ouie has quit [Disconnected by services]
My_Hearing is now known as Mon_Ouie
PragCypher has quit [Quit: Leaving]
yacks has joined #ruby
d34th4ck3r has joined #ruby
squidBits has quit [Ping timeout: 255 seconds]
<Tumulte> Hi people !
<Tumulte> I'm still struggling to set up a rail server (currently passenger)
banisterfiend has joined #ruby
Vainoharhainen has joined #ruby
<Tumulte> All I can have is the list of files or "Option Multiviews not allowed here" when this option is enabled
Takehiro has joined #ruby
<Takehiro> is there a way to check where a variable is set?
rippa has quit [Read error: Connection reset by peer]
<Takehiro> i want to know where this `controller` was defined https://github.com/rails/rails/blob/master/actionpack/lib/action_view/routing_url_for.rb#L92
<Takehiro> :(
freeayu has quit [Remote host closed the connection]
<Hanmac> Tumulte look #rubyonrails
<Tumulte> Ok cool
<banisterfiend> Takehiro: is it a local variable or a method?
<Takehiro> local variable
<Takehiro> if its a method, i would use method(:controller).source_location
<banisterfiend> Takehiro: if it's a local it should be extremely obvious, as it must be within the same scope
<Takehiro> banisterfiend:
<banisterfiend> Takehiro: so it'll be defined in the same method
<Takehiro> well its not ... :(
<banisterfiend> Takehiro: then it's not a local :)
<Takehiro> since its a module
<banisterfiend> Takehiro: it's definitely a method
<Takehiro> really :O
<banisterfiend> Takehiro: what makes u think it's not a method?
havenn has joined #ruby
<Takehiro> hmmm,,, true,,, i guess i was dumb...
<Takehiro> thx, ill try method(:controller).source_location
banisterfiend has quit [Remote host closed the connection]
<Takehiro> :)
<Takehiro> oooooo ,,, it was a method... th
<Takehiro> thx
Squarepy has joined #ruby
Squarepy has quit [Changing host]
Squarepy has joined #ruby
Zoup has joined #ruby
EyesIsMine has joined #ruby
rippa has joined #ruby
heftig has quit [Quit: leaving]
havenn has quit [Remote host closed the connection]
berserkr has quit [Quit: Leaving.]
_bart has joined #ruby
tenmilestereo has joined #ruby
darthdeus has quit [Ping timeout: 245 seconds]
Vainoharhainen has quit [Read error: Connection reset by peer]
Kneferilis has joined #ruby
Vainoharhainen has joined #ruby
<Kneferilis> hello
<Kneferilis> I need some help with this ruby code: http://pastebin.com/NUdb4YVD
<Kneferilis> what code.chomp! does?
<Kneferilis> what is chunk[/\A([a-z]\w*)/, 1] for? Regular expressions matcher?
<Xeago> Kneferilis: refer to the docs
darthdeus has joined #ruby
Vainoharhainen has quit [Client Quit]
nanothief has quit [Ping timeout: 250 seconds]
_64k has quit [Ping timeout: 246 seconds]
DaZ has quit [Ping timeout: 255 seconds]
<Kneferilis> I was hoping, I could get some fast help.
skcin7 has joined #ruby
moos3 has quit [Quit: Off to blow shit up!]
<shevy> Kneferilis .chomp removes trailing newlines
<shevy> and .chmop! is like .chomp, but t replaces in place
<shevy> chunk[/\A([a-z]\w*)/, 1] seems to be a regex, extracting the first match? hmm not sure
<shevy> the part inside the () in the regex there
<shevy> you could test this in irb
<Kneferilis> I see, thanks a lot!
<shevy> test
Xeago has quit [Remote host closed the connection]
<shevy> damn it
<shevy> I can not copy paste
<shevy> "abc def"[/\A([a-z]\w*)/, 1] # => "abc"
<shevy> it seems to snatch the first word
emergion has joined #ruby
phelps has quit [Quit: Textual IRC Client: www.textualapp.com]
moos3 has joined #ruby
x0F has quit [Disconnected by services]
x0F_ has joined #ruby
x0F_ is now known as x0F
Gooder has joined #ruby
yxhuvud2 has joined #ruby
LouisGB has joined #ruby
yxhuvud has quit [Ping timeout: 260 seconds]
LouisGB has quit [Client Quit]
<Hanmac> shevy what about this: "abc def"[/\A(?<first>[a-z]\w*)/, :first]
nemesit has joined #ruby
Vivid_ has joined #ruby
razibog has joined #ruby
razibog1 has joined #ruby
<Kneferilis> what this chunk = code[i..-1] does?
d34th4ck3r has quit [Quit: Konversation terminated!]
razibog1 has quit [Client Quit]
Divinite_ has joined #ruby
<shevy> Hanmac dunno, wasn't my code, my brain can only process my own code efficiently :(
<shevy> Kneferilis the .. is a range
<Hanmac> kneferilis: it means from i to the end
<Kneferilis> i to -1?
<shevy> when you see it used inside [] you know that the .. is applied to elements
<Kneferilis> I see.
<shevy> yes. -1 means "end of"
LouisGB has joined #ruby
<shevy> so i..-1 means, wherever i starts, to the end
<shevy> for instance, if i is 3
<shevy> 3..-1
<shevy> means from, the fourth element, up to the last
<shevy> "abcdef"[3..-1] # => "def"
Divinite_ has left #ruby [#ruby]
emergion has quit [Quit: Computer has gone to sleep.]
Vert has quit [Remote host closed the connection]
TheFuzzball has joined #ruby
ToTo has joined #ruby
slainer68 has joined #ruby
crackfu has joined #ruby
maesbn has joined #ruby
Zoup has quit [Quit: Lost terminal]
aapzak has quit [Ping timeout: 264 seconds]
aapzak has joined #ruby
zigomir has joined #ruby
Averna has quit [Quit: Leaving.]
shemerey has quit [Quit: Linkinus - http://linkinus.com]
Vivid_ has quit [Remote host closed the connection]
horofox has quit [Quit: horofox]
Russell^^ has joined #ruby
rippa has quit [Quit: Changing server...]
rippa has joined #ruby
aapzak has quit [Ping timeout: 260 seconds]
aapzak has joined #ruby
withnale has quit [Ping timeout: 252 seconds]
rippa has quit [Ping timeout: 250 seconds]
rippa has joined #ruby
m_3 has quit [Quit: leaving]
m_3 has joined #ruby
shemerey has joined #ruby
spinagon has joined #ruby
rippa has quit [Ping timeout: 250 seconds]
DaZ has joined #ruby
withnale has joined #ruby
freeayu has joined #ruby
sayan has quit [Read error: Connection reset by peer]
lkba has quit [Ping timeout: 252 seconds]
graeme has joined #ruby
moshee has quit [Ping timeout: 260 seconds]
moshee has joined #ruby
moshee has joined #ruby
moshee has quit [Changing host]
yxhuvud has joined #ruby
ozgor has quit [Quit: ozgor]
yxhuvud2 has quit [Ping timeout: 244 seconds]
ananthakumaran1 has joined #ruby
ananthakumaran has quit [Ping timeout: 255 seconds]
charliesome has quit [Quit: Textual IRC Client: www.textualapp.com]
GodFather has joined #ruby
kil0byte has joined #ruby
<GodFather> newbie trying to find doc on '!' in this context cmd.chomp! help please
<Mon_Ouie> It's just part of the name of the method (chomp and chomp! are two different methods)
<Mon_Ouie> In this case, it means it mutates the object you call the method on, instead of returning a new one
nemesit has quit [Quit: Leaving...]
<Mon_Ouie> More generally it denotes something dangerous (in particular, a "dangerous" variant of another method)
shemerey has quit [Quit: Leaving...]
rwalker has joined #ruby
sayan has joined #ruby
ToTo has quit [Quit: Leaving...]
lawgic has joined #ruby
Takehiro has quit [Remote host closed the connection]
slainer68 has quit [Remote host closed the connection]
lawgic has quit [Client Quit]
love_color_text has quit [Remote host closed the connection]
Takehiro has joined #ruby
<GodFather> Mon_Ouie, thank you, and happy holidays
<Mon_Ouie> No problem ;) and same to you
freeayu has quit [Remote host closed the connection]
Guest25886 has quit [Read error: Connection reset by peer]
GodFather has quit [Quit: Leaving]
yacks has quit [Ping timeout: 255 seconds]
wf2f has quit [Ping timeout: 256 seconds]
yfeldblum has quit [Quit: Leaving]
elaptics is now known as elaptics`away
xbayrockx has joined #ruby
xbayrockx is now known as wf2f
<samuel02> does anyone now of a lib that can get me a title an summary of a web page?
rwalker is now known as reppard
<samuel02> *and a summary...
<Mon_Ouie> Depends on what you mean by "summary". Finding the title of the page should pretty simple using an HTML/XML parser
F1skr has joined #ruby
<Mon_Ouie> (e.g. Nokogiri)
Takehiro has quit [Remote host closed the connection]
<samuel02> Mon_Ouie, yeah I've been experimenting a bit with Nokogiri and Pismo but I guess I need something that can do some language processing or write it all myself..
trying has joined #ruby
shtirlic has quit [Remote host closed the connection]
<samuel02> Mon_Ouie: Have you used the Flipboard app for iOS?
<Mon_Ouie> Nope
<samuel02> Mon_Ouie, ok well basically it gives the first paragraphs of the text and manages to not show other stuff like the navigation, sidebars, ads etc.
shemerey has joined #ruby
<samuel02> or kind of like what Google does for search results
lolcathost has joined #ruby
Goles has joined #ruby
<Mon_Ouie> I'm not sure exactly what google does, but I think they start with simply checking a meta node in the page's header
<samuel02> Mon_Ouie, I'm not positive either but I don't think that's true, most people don't care about adding all that meta data
pavilionXP has quit [Ping timeout: 265 seconds]
<samuel02> Mon_Ouie, e.g. wikipedia
<Mon_Ouie> Sure, but I think it does have precedence if it's there
<trying> http://tree.oooo.tw/ <- can someone do this with ruby?
<samuel02> Mon_Ouie, sure
<Mon_Ouie> An ASCII christmase tree? Sure. You could even make one in Brainfuck.
<Kneferilis> what is .size?
ozgor has joined #ruby
<Kneferilis> e.g. code.size?
<Mon_Ouie> Is the "?" part of the example or just the question mark of your question?
<Mon_Ouie> Usually, code.size simply returns the size of something (for arrays, strings, etc.); size? I don't think I have seen so far
nari_ has joined #ruby
EyesIsMine has quit [Quit: Leaving]
graeme has quit [Quit: graeme]
slainer68 has joined #ruby
slainer68 has quit [Remote host closed the connection]
<Kneferilis> Mon_Ouie: thanks
frogstarr78 has joined #ruby
malkomalko has joined #ruby
Hanmac has quit [Ping timeout: 260 seconds]
thone has quit [Read error: Connection reset by peer]
thone has joined #ruby
<Kneferilis> but what chunk = code[i..-1] does?
mfridh has quit [Ping timeout: 250 seconds]
mfridh_ has joined #ruby
mfridh_ is now known as mfridh
browndawg has quit [Ping timeout: 255 seconds]
tenmilestereo has quit [Quit: Leaving]
browndawg has joined #ruby
<nipar> I'm a newbie too, but to me it would seem both "chunk", "code" and "i" are simply variables in some code we can't see
<nipar> that leaves only the statement [i..-1] to figure out, which is a range from a defined number "i" to -1
<Kneferilis> nipar: here is the code: http://pastebin.com/NUdb4YVD
<Kneferilis> I don't understand, what kind of loop is that?
hotovson has joined #ruby
F1skr has quit [Quit: WeeChat 0.3.9.2]
yxhuvud2 has joined #ruby
<nipar> basically, for each letter in variable code, it will run through the loop once
reppard has quit [Ping timeout: 252 seconds]
yxhuvud has quit [Ping timeout: 244 seconds]
nerd has joined #ruby
<Mon_Ouie> Hadn't shevy answered your question earlier?
<Kneferilis> I mean in while i < code.size chunk = code[i..-1] I undestand while i < code.size, but what is chunk = code[i..-1] does?
<Kneferilis> I am new in ruby
<Kneferilis> never seen var = var2[i..-1] before
radic has quit [Read error: Operation timed out]
<waxjar> Kneferilis: http://rubydoc.org/stdlib/core/String#%5B%5D-instance_method
browndawg has quit [Ping timeout: 252 seconds]
Goles has quit [Quit: Computer has gone to sleep.]
shemerey has quit [Quit: Linkinus - http://linkinus.com]
ebouchut has joined #ruby
love_color_text has joined #ruby
chussenot has joined #ruby
jbw has quit [Ping timeout: 272 seconds]
Banistergalaxy has quit [Ping timeout: 260 seconds]
skcin7 has quit [Quit: Computer has gone to sleep.]
chussenot has quit [Read error: Connection reset by peer]
Goles has joined #ruby
chussenot has joined #ruby
thejefflarson_ has quit [Ping timeout: 245 seconds]
nomenkun has quit [Remote host closed the connection]
yfeldblum has joined #ruby
<yfeldblum> join #ruby-lang
octarine_ has quit [Ping timeout: 250 seconds]
EyesIsMine has joined #ruby
browndawg has joined #ruby
lorn has quit [Ping timeout: 264 seconds]
love_color_text has quit [Ping timeout: 244 seconds]
<Kneferilis> I see. Thanks.
radic has joined #ruby
lorn has joined #ruby
Bosox20051 has joined #ruby
slainer68 has joined #ruby
matrixise has joined #ruby
percival__ has quit [Remote host closed the connection]
dekz__ has quit [Remote host closed the connection]
xerxas_ has quit [Write error: Broken pipe]
yeban has quit [Remote host closed the connection]
davidboy has quit [Remote host closed the connection]
patricksroberts_ has quit [Remote host closed the connection]
kapowaz_ has quit [Remote host closed the connection]
kaichanvong___ has quit [Remote host closed the connection]
jhowarth__ has quit [Remote host closed the connection]
tommyvyo[cloud]_ has quit [Remote host closed the connection]
lectrick has quit [Remote host closed the connection]
shiroginne_ has quit [Remote host closed the connection]
pvh___ has quit [Remote host closed the connection]
lucaspiller___ has quit [Remote host closed the connection]
TheDeadSerious_ has quit [Remote host closed the connection]
dkannan_ has quit [Write error: Broken pipe]
fcoury_ has quit [Write error: Broken pipe]
rcsheets has quit [Remote host closed the connection]
pkondzior__ has quit [Remote host closed the connection]
Spaceghost|cloud has quit [Remote host closed the connection]
bluehavana_ has quit [Read error: Connection reset by peer]
spanx___ has quit [Write error: Broken pipe]
NimeshNeema has quit [Write error: Broken pipe]
Banistergalaxy has joined #ruby
s1n4 has joined #ruby
chussenot has quit [Read error: Connection reset by peer]
chussenot has joined #ruby
<apeiros_> :( no Math.avg
<apeiros_> SHAME!
Bedry has joined #ruby
sayan has quit [Ping timeout: 252 seconds]
matrixise has quit [Ping timeout: 252 seconds]
Takehiro has joined #ruby
<Kneferilis> does if identifier = chunk[/\A([a-z]\w*)/, 1] declares identifier ?
xAndy is now known as xandy
<Kneferilis> I suppose? http://pastebin.com/NUdb4YVD
reppard has joined #ruby
jbw has joined #ruby
<Kneferilis> and what it does?
<shevy> Kneferilis but you saw the .. before
dgethings has joined #ruby
<shevy> Kneferilis did I not tell you it is a range, did you not listen :(
<shevy> x = y is always an assignment
<shevy> x = y[] is still an assignment
pavilionXP has joined #ruby
<Kneferilis> I mean, I got one character and return it if it matches the regular expression then?
<shevy> foo = "bla" <--- the name of the variable is foo
<shevy> one character?
<shevy> where do you get one character?
<shevy> but yeah
<shevy> if x = "bla" will assign
<shevy> = is always assignment
<shevy> == is comparison
<Kneferilis> cool
<shevy> you wont see that often btw
Bedry has left #ruby [#ruby]
<shevy> the "if x = y" part
<shevy> most often, people do stuff like "if x == y", or just "if x" as this is shorter
<Kneferilis> what is the ,1 though?
<shevy> and even then with assignment... they would tend to do
<dgethings> hi all. I am having problems running the debugger via rspec
<shevy> if (x = y)
<dgethings> I'm getting a compile time error
<shevy> Kneferilis this is regex part
<shevy> if you use () in your regex, you can access them with 1, 2, 3, 4
<dgethings> gem file and error message can be found at this gist: https://gist.github.com/4359512
<Kneferilis> well, why would you do an assignment with an if?
<shevy> Kneferilis you must read up on regexes, they are the same in most languages, ruby, perl, python etc... http://www.regular-expressions.info/
chussenot_ has joined #ruby
<shevy> Kneferilis do not ask me. it is not my code, I would not write it in this way. you showed this code
<shevy> :D
<Kneferilis> ok
<shevy> Kneferilis one reason could be, you gain one line
<shevy> x = bla
<shevy> if x
<shevy> vs
<shevy> if (x = bla)
<shevy> but I dont like the latter
chussenot has quit [Read error: Connection reset by peer]
<Kneferilis> if true?
<shevy> the simpler the code structure, the better
chussenot has joined #ruby
<shevy> yeah, but a variable in this case
<shevy> x = true
<dgethings> looks like a possible bug in the ruby-debug19 gem
<shevy> if x
Hanmac has joined #ruby
<dgethings> anyone able to take a look and confirm?
nari_ has quit [Ping timeout: 252 seconds]
neersighted has quit [Ping timeout: 240 seconds]
<shevy> I cant even run "rspec --debugger"
<shevy> which gem installs it?
horofox has joined #ruby
reppard has quit [Ping timeout: 250 seconds]
chussenot_ has quit [Ping timeout: 252 seconds]
lolcathost has quit [Read error: Connection reset by peer]
Catnaroek has joined #ruby
Catnaroek is now known as lolcathost
<dgethings> beg pardon. found the source of the problem. is a bug in ruby-debug19. Just awaiting official fix. http://blog.wyeworks.com/2011/11/1/ruby-1-9-3-and-ruby-debug/
<Kneferilis> I can't find information on what the ,1 does
chussenot has quit [Read error: Connection reset by peer]
chussenot_ has joined #ruby
dgethings has quit [Quit: dgethings]
nemesit has joined #ruby
<shevy> Kneferilis no you search incorrectly!
<shevy> especially this part: "Names and Numbers for Capturing Groups"
<shevy> you can ignore the names for now, just focus on the numbers!
JoeHazzers has joined #ruby
<maetthew> shevy, teach me how to search correctly please
<shevy> maetthew you must have a clear picture in mind what you need first
vlad_starkov has joined #ruby
<shevy> then you use the google oracle
<shevy> you quickly discard the 80% shit
<shevy> and focus on the 20% goodies
<shevy> and from this, you quickly pick the most proper and fitting match
JoeHazzers is now known as JoeHazzers_
JoeHazzers_ is now known as JoeHazzers
<maetthew> shevy, what if none exist?
pcarrier has quit [Read error: Connection reset by peer]
Hanmac has quit [Ping timeout: 260 seconds]
<csmrfx> google google for "how to do google searches efficiently?" or similar
<shevy> maetthew hmmm then you must use other means than google oracle
<shevy> maetthew like public libraries
<csmrfx> you can google for googles suggestions for similar
<maetthew> shevy, it's THIS i want to know
<maetthew> :)
<csmrfx> lol
<maetthew> i know the other stuff
<csmrfx> off topic, troll
<csmrfx> ha!
chussenot_ has quit [Quit: chussenot_]
<shevy> maetthew well, not everything is available digitally
<csmrfx> library > school > internet
baroquebobcat has joined #ruby
vlad_starkov has quit [Ping timeout: 265 seconds]
ddd has joined #ruby
yeban has joined #ruby
s1n4 has quit [Quit: leaving]
davidboy has joined #ruby
dekz__ has joined #ruby
Spaceghost|cloud has joined #ruby
bluehavana_ has joined #ruby
kapowaz_ has joined #ruby
thejefflarson_ has joined #ruby
xerxas_ has joined #ruby
shiroginne_ has joined #ruby
jhowarth__ has joined #ruby
ryanlecompte has joined #ruby
pvh___ has joined #ruby
patricksroberts_ has joined #ruby
ltsstar has joined #ruby
tommyvyo[cloud]_ has joined #ruby
NimeshNeema has joined #ruby
<Kneferilis> any ideas of how I convert this: identifier = chunk[/\A([a-z]\w*)/, 1] into JavaScript?
spanx___ has joined #ruby
percival__ has joined #ruby
track7 has quit [Read error: Connection reset by peer]
neersighted has joined #ruby
chussenot has joined #ruby
iamjarvo has quit [Quit: Leaving.]
<apeiros_> Kneferilis: you match against the regex, then use RegExp.lastMatch
lectrick has joined #ruby
<apeiros_> ah, actually in your case, you'd use RegExp.$1
<Kneferilis> apeiros_: can you give me an example?
lucaspiller___ has joined #ruby
rippa has joined #ruby
TheDeadSerious_ has joined #ruby
<apeiros_> /foo/.test(string); RegExp.$1
kaichanvong___ has joined #ruby
Iszak has joined #ruby
slainer68 has quit [Remote host closed the connection]
rcsheets has joined #ruby
pkondzior__ has joined #ruby
dkannan_ has joined #ruby
octarine_ has joined #ruby
chussenot has quit [Client Quit]
fcoury_ has joined #ruby
<Kneferilis> $1?
tvw has joined #ruby
slow has joined #ruby
<Kneferilis> and test?
<apeiros_> dude
<apeiros_> fire up a browser and try it
yxhuvud has joined #ruby
banisterfiend has joined #ruby
spinagon has quit [Ping timeout: 250 seconds]
slow has quit [Client Quit]
spinagon has joined #ruby
sayan has joined #ruby
rippa has quit [Ping timeout: 250 seconds]
Hanmac has joined #ruby
yxhuvud2 has quit [Ping timeout: 255 seconds]
stevechiagozie has joined #ruby
yacks has joined #ruby
slainer68 has joined #ruby
Bosox20051 has quit [Ping timeout: 245 seconds]
sonai has joined #ruby
sonai has quit [Remote host closed the connection]
topriddy has quit [Read error: Connection reset by peer]
hero has quit [Read error: Connection reset by peer]
hero has joined #ruby
hero has quit [Changing host]
hero has joined #ruby
philips_ has quit [Excess Flood]
S1kx has quit [Quit: Leaving]
pcarrier has joined #ruby
stevechiagozie has quit [Quit: leaving]
stevechiagozie has joined #ruby
<Kneferilis> apeiros_: it works, I didn't know there was a js function regularexpresion.test()
clocKwize has joined #ruby
Jackneill has joined #ruby
Jackneill has quit [Changing host]
Jackneill has joined #ruby
<apeiros_> the class is RegExp
foxtrot101 has joined #ruby
<apeiros_> google for "MDN RegExp"
malkomalko has quit [Remote host closed the connection]
<apeiros_> MDN is generally a good source for JS docs
<apeiros_> also in your browser's js console, try `dir(RegExp)`
<apeiros_> (should work in chrome and safari, most likely works in firefox - IE? fuck that)
sonai has joined #ruby
<sonai> hi
wermel has joined #ruby
Goles has quit [Quit: Computer has gone to sleep.]
postmodern has quit [Quit: Leaving]
matip has joined #ruby
benlieb has joined #ruby
<matip> Hello guys
trying has quit [Ping timeout: 245 seconds]
_64k has joined #ruby
_64k has quit [Client Quit]
baroquebobcat has quit [Quit: baroquebobcat]
foxtrot101 has quit [Quit: Colloquy for iPad - http://colloquy.mobi]
foxtrot101 has joined #ruby
tjbiddle has joined #ruby
ebouchut has quit [Quit: This computer has gone to sleep]
<matip> what do you use when you need to insert hundreds of rows per second?
<matip> datamapper doesn't look as a fast approach
jenrzzz has joined #ruby
<matip> at least not as fast as pgsql's COPY TO
jrajav has joined #ruby
heftig has joined #ruby
foxtrot101 has quit [Client Quit]
xbob has quit [Quit: Leaving]
<Kneferilis> does this expects the string to begin with A : identifier = chunk[/\A([a-z]\w*)/, 1] ? http://pastebin.com/NUdb4YVD
<Kneferilis> the comment above it suggests otherwise
nwertman has quit [Ping timeout: 250 seconds]
<matip> you mean the regexp?
sonai has quit [Remote host closed the connection]
wallerdev has joined #ruby
<matip> why would you escape the A?
<heftig> no, \A is anchor for the start of the string
<Kneferilis> I wouldn't, the code is not mine
<matip> isn't it ^?
<Kneferilis> it's from a book
Dario_ has joined #ruby
<heftig> matip: that may also be start of line
<matip> I've never used \A, interesting
<heftig> ri Regexp
<matip> well.. what do you think about the performance of datamapper regarding insertions?
ltsstar has quit [Quit: ltsstar]
nemesit|osx has joined #ruby
ebouchut has joined #ruby
ebouchut has quit [Client Quit]
Hanmac has quit [Quit: Leaving.]
Hanmac has joined #ruby
nemesit has quit [Ping timeout: 260 seconds]
baroquebobcat has joined #ruby
philips_ has joined #ruby
Takehiro_ has joined #ruby
jenrzzz has quit [Ping timeout: 265 seconds]
baroquebobcat has quit [Quit: baroquebobcat]
jzig has joined #ruby
<Kneferilis> but why: http://jsfiddle.net/Q6vvZ/4/ is supposed to return anything besides the first character?
Takehiro has quit [Ping timeout: 265 seconds]
shiin has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<Kneferilis> it's also unable to return a match for lower case letters: http://jsfiddle.net/Q6vvZ/5/
Iszak has quit []
clocKwize has quit [Quit: clocKwize]
<Kneferilis> in ruby this works differently than javascript: http://codepad.org/zFLZNd4g
Dario_ has quit [Ping timeout: 250 seconds]
<matip> in JS \A is the same as A
<matip> it seems that \A in Ruby is somehow similar to ^
<Kneferilis> so this http://codepad.org/zFLZNd4g is not equal to this: http://jsfiddle.net/Q6vvZ/6/
phelps has joined #ruby
ewag has quit [Read error: Operation timed out]
aharris6 has joined #ruby
aharris6 has quit [Remote host closed the connection]
<matip> no, it's not the same
Gooder has quit [Read error: Connection reset by peer]
<Kneferilis> yes, this must be the equivalent javascript version: http://jsfiddle.net/Q6vvZ/8/
<jzig> which room do you go to for ruby noob help?
Goles has joined #ruby
<matip> it's not exactly the same, ^ matches the beginning of LINES, whereas \A the beginning of the STRING
<matip> in this case it's the same, I agree
benlieb has quit [Quit: benlieb]
Goles has quit [Client Quit]
Takehiro_ has quit [Remote host closed the connection]
Takehiro has joined #ruby
Takehiro has quit [Read error: Connection reset by peer]
<Kneferilis> hmm, matip how would I match the beginning of a string in javascript?
Goles has joined #ruby
benlieb has joined #ruby
<matip> I'm sure you really need "^"
<Kneferilis> ok
<matip> check this
RomainT has joined #ruby
<matip> it seems it's not possible to match only the beginning of strings, interesting...
<oxman> could you explain me how this code works "class Node < Struct.new(:name)" how could you inherit from an object ?
<matip> anyway, ^ is all you need in 99.97% of the problems :P
<jzig> isn't a struct a class too?
g_bleezy has joined #ruby
<matip> maybe "[^.]^" == "\A", it should work..
ryanlecompte has quit [Remote host closed the connection]
ryanlecompte has joined #ruby
hero has quit [Ping timeout: 246 seconds]
<yxhuvud> oxman: Struct.new returns a class. You can inherit from classes.
<oxman> why this class have a pointer reference ?
<oxman> irb(main):010:0> Struct.new(:bouh)
<oxman> => #<Class:0x007f88c392b870>
<oxman> irb(main):011:0> Struct.new(:bouh)
<oxman> => #<Class:0x007f88c3924340>
maetthew has quit [Quit: ZNC - http://znc.in]
cousine has joined #ruby
<moshee> all classes are instances of the Class class
Goles has quit [Quit: Computer has gone to sleep.]
<moshee> you just don't usually use them like that
<heftig> matip: no, that's nonsense
SqREL has joined #ruby
cousine has quit [Remote host closed the connection]
g_bleezy has quit [Ping timeout: 260 seconds]
<matip> why?
cousine has joined #ruby
<matip> (I didn't try it, it was just an idea..)
<oxman> so why :
<oxman> irb(main):028:0> class A;end
<oxman> => nil
<heftig> that's "any character but a dot followed by a start of a line"
<oxman> irb(main):029:0> A
<oxman> => A
<oxman> show me A and not #Class:0x... ?
tvw has quit [Read error: Connection reset by peer]
rdw200169 has joined #ruby
love_color_text has joined #ruby
rdw200169 has left #ruby [#ruby]
<moshee> syntatic sugar
yxhuvud2 has joined #ruby
<moshee> irb(main):006:0> Class.new(Object)
<moshee> => #<Class:0x8020cf44>
havenn has joined #ruby
<RomainT> How does Struct constructor return something other than the instance while "normal" constructors can't do such things?
<oxman> what's the sense to do that ? To use that ? Do you have any tutorial ?
<apeiros_> RomainT: Class.new
<heftig> RomainT: it does. the constructor is nothing special
<apeiros_> and it cheats, Struct.new(…).is_a?(Struct) # => false
<oxman> irb(main):039:0> class B;def initialize;c = Class.new;c;end;end
<oxman> => nil
<oxman> irb(main):040:0> B.new
<oxman> => Class
<oxman> i don't have a Class reference
<apeiros_> heftig: technically the Struct constructor does not construct a Struct :)
<apeiros_> RomainT: also you need to understand that "the constructor" is really just a plain normal method in ruby
yxhuvud has quit [Ping timeout: 250 seconds]
<matip> ah, sure.. the problem is that "." withing "[]" is like "\." ;)
<apeiros_> class Foo; def self.new; "haha!"; end; end; Foo.new # => "haha!"
<matip> within*
pkondzior__ has quit [Ping timeout: 264 seconds]
tommyvyo[cloud]_ has quit [Ping timeout: 264 seconds]
<banisterfiend> apeiros_: iirc u wanted stn like this http://showterm.io/284e45769064cc6639da8#fast
love_color_text has quit [Ping timeout: 244 seconds]
<yxhuvud2> Most classes are plain factories. Struct is a factory factory.
<RomainT> :/
<swarley> It seems stupid to me that OpenStruct doesn't have a #[]
<Hanmac> like a bead toaster maker :D
johnmilton has joined #ruby
ryanlecompte has quit [Ping timeout: 252 seconds]
<oxman> could you give me a sample to copycat the Struct class ?
nilg has quit [Ping timeout: 265 seconds]
<SqREL> Hi. Can anybody help me with openssl? I need to write this "openssl dgst -sign some_cert_with_keys.pem -out output.txt -md5 input.txt" on ruby's OpenSSL. When i do this http://pastebin.com/m3yjMwYX i get a little different code, that native openssl generates
hoelzro|away is now known as hoelzro
alanjc_ has joined #ruby
<apeiros_> banisterfiend: very nice
wallerdev has quit [Quit: wallerdev]
<apeiros_> banisterfiend: why `rake pry`? o0
<banisterfiend> apeiros_: ah that's just what we use when we're working on HEAD
<banisterfiend> it loads the development version
nick_h has quit [Ping timeout: 260 seconds]
<apeiros_> o0
vlad_starkov has joined #ruby
<apeiros_> weird way to do that :)
<banisterfiend> apeiros_: easier than: ruby -I./lib pry.rb
havenn has quit [Remote host closed the connection]
topriddy has joined #ruby
<apeiros_> alias ;-)
love_color_text has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
kirun has joined #ruby
reppard has joined #ruby
hydrozen has joined #ruby
havenn has joined #ruby
<Kneferilis> I started getting how to build a lexer: https://github.com/sp2012/powerjs-source
<apeiros_> banisterfiend: also, shouldn't that be `ruby -Ilib bin/pry` ?
aedorn has quit [Quit: Konversation terminated!]
<Kneferilis> I remember back in the university they tought us about compilers and we had to built a simple compiler in Java, but that was long ago.
g_bleezy has joined #ruby
ryanlecompte has joined #ruby
love_color_text has quit [Ping timeout: 260 seconds]
<banisterfiend> apeiros_: probably :) hence why i put it in a rake file, cos i'd never remember it hehe
Takehiro has joined #ruby
<Kneferilis> so, apeiros_ do you program in ruby for a living, or is it for hobby?
<apeiros_> Kneferilis: rails for a living, ruby for fun
<Kneferilis> well, rails is ruby too
maesbn has quit [Remote host closed the connection]
nick_h has joined #ruby
<_bart> Hi, this API wrapper is not thread safe right: https://github.com/DomainTools/api-ruby
<apeiros_> I beg to differ
<_bart> They are using @ variables
eka has quit [Quit: Computer has gone to sleep.]
<apeiros_> rails is its completely own universe
<apeiros_> (it got a bit better, though)
<Kneferilis> you mean you program ruby cli programs for fun?
<Kneferilis> or windows programs?
<jzig> Can anybody give me a fresh set of eyes on a piglatin function from alex chafee's test first ruby?
<apeiros_> eeeeeew, windows…
slainer68 has quit [Remote host closed the connection]
<apeiros_> _bart: the use or non-use of @vars does not determine whether something is threadsafe or not
<apeiros_> also, define threadsafe (depending on your definition, nothing is)
AlSquire has quit [Quit: This computer has gone to sleep]
<apeiros_> also, you can use about everything in a threaded environment if you coordinate access to it (see Mutex & co)
<_bart> apeiros_: I want to run it inside a sidekiq worker
Takehiro has quit [Read error: Connection reset by peer]
<_bart> apeiros_: but I'm unsure wether that'd be safe or not
hydrozen has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
hydrozen has joined #ruby
<apeiros_> _bart: I don't know sidekiq (apart from what it is), but I'd assume that workers have no shared state
<apeiros_> if that's so, then there's no problem
tjbiddle has quit [Quit: tjbiddle]
slainer68 has joined #ruby
<_bart> apeiros_: it's celluloid, which means it's actually in threads.
<apeiros_> only access to shared resources is a problem wrt threading.
hoelzro is now known as hoelzro|away
jaygen has joined #ruby
pmros has joined #ruby
vlad_starkov has joined #ruby
<Kneferilis> ok, I need some more help, but it seems after that, I won't need much more help
<Kneferilis> what this does? if KEYWORDS.include?(identifier) tokens << [identifier.upcase.to_sym, identifier]
ebouchut has joined #ruby
sayan has quit [Ping timeout: 252 seconds]
cousine has quit [Remote host closed the connection]
<Hanmac> Kneferilis: is "identifier" user input? if yes, dont use to_sym
<Kneferilis> it has two if in it then? so the first if has to be true?
hydrozen has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
zigomir_ has joined #ruby
<Kneferilis> I don't understand what the second line does
<Hanmac> it ceate tokens
aapzak has quit [Ping timeout: 265 seconds]
benlieb has quit [Quit: benlieb]
<Kneferilis> << is push?
<Kneferilis> upcase is upper case then and to_sym? what is to_sym?
zigomir has quit [Ping timeout: 252 seconds]
zigomir_ is now known as zigomir
kiyoura has joined #ruby
<Kneferilis> << push to array
reppard has quit [Ping timeout: 260 seconds]
aapzak has joined #ruby
solidresolve has quit [Quit: Leaving]
<apeiros_> Kneferilis: meet `ri` (command line tool to access docs) and/or http://ruby-doc.org
<jzig> Why does https://gist.github.com/4359896 work without the " < 2" at the elsif, but not otherwise?
<apeiros_> alternatively, use pry with ? and $
aedorn has joined #ruby
S1kx has joined #ruby
anarchist has joined #ruby
Dario_ has joined #ruby
heftig has quit [Ping timeout: 245 seconds]
solidresolve has joined #ruby
zigomir has quit [Quit: zigomir]
<apeiros_> jzig: "doesn't work" is a useless problem description.
timonv has quit [Remote host closed the connection]
heftig has joined #ruby
Goles has joined #ruby
mockra has joined #ruby
<jzig> Great, I'm new! That's a useless problem description of my problem description as well. How should I rephrase it?
nemesit|osx has quit [Quit: Linkinus - http://linkinus.com]
Squarepy has quit [Quit: Leaving]
nemesit has joined #ruby
gsj has quit [Quit: Leaving.]
<yfeldblum> apeiros_, "doesn't work" may be a euphemism for PEBKAC
Jasko has quit [Read error: No route to host]
<oxman> c = Class.new(B) the c object should have all methods of B class ?
v0n has joined #ruby
Dario_ has quit [Ping timeout: 255 seconds]
mockra has quit [Remote host closed the connection]
<jzig> very helpful yfeld!
<yfeldblum> oxman, c will be a class, and it will inherit B (B will be its base class)
<oxman> yes i know that, so c should have all methods of B class, right ?
sayan has joined #ruby
kiyoura has quit [Ping timeout: 255 seconds]
jimeh has joined #ruby
<banisterfiend> oxman: yes
<yfeldblum> oxman, yes, in the sense of ruby's class inheritance
fyolnish has joined #ruby
<yfeldblum> jzig, please, when using gist, name your file to end with ".rb" so that gist will highlight it as ruby
<jzig> Thanks, I will do that in the future.
<oxman> irb(main):003:0> class B;def set(v);@b=v;end;end
<oxman> => nil
<oxman> irb(main):004:0> c = Class.new(B); c.set("bouh")
<oxman> NoMethodError: undefined method `set' for #<Class:0x007fd2c9148040>
<apeiros_> jzig: so why is me telling you that your problem description doesn't work not good enough?
<yfeldblum> jzig, and please be sure to indent your code correctly, especially whenever you want someone else to look at it
<oxman> as you see, it don't work, why ?
<yfeldblum> jzig, the convention in ruby is to use two spaces for each level of indentation
<apeiros_> oxman: c is a class
<apeiros_> c.new.set(…)
<jzig> I pasted from sublime text
Jasko has joined #ruby
<oxman> hum ok
<oxman> thanks :)
<jzig> Is there a better way to paste from sublime text?
topriddy has quit [Quit: topriddy]
<yfeldblum> jzig, indent it in your editor
samuel02 has quit [Remote host closed the connection]
<jzig> well, it is
<jzig> I've just been going by the default indenting
Dario_ has joined #ruby
berserkr has joined #ruby
horofox has quit [Quit: horofox]
<yfeldblum> jzig, well, re-indent it in gist ... the reason is that if you want someone to help you, you should try to make it easier for them
<swarley> oxman; I got wrapped up in my own metaprogramming and forgot to show you
horofox has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
dsdeiz has joined #ruby
<swarley> my bad :(
<oxman> :)
<swarley> Well, this is my fancy not the best way to do it. It's not complete, but still, meta-meta-meta!
<jzig> I understand I should make it as easy as possible for anyone to help me, I guess I just don't understand what is wrong with the default indenting from sublime text or why it indents ruby code in a way that is not the convention.
<swarley> jzig; just go to your syntax settings and change tabs to spaces and tab width to two
<swarley> For ruby only
<oxman> thanks
<swarley> That's my setting on sublime
<jzig> awesome, thanks
slainer68 has quit [Remote host closed the connection]
Dario_ has quit [Ping timeout: 264 seconds]
Takehiro has joined #ruby
<swarley> jzig; add
<swarley> { "translate_tabs_to_spaces": false, "tab_size": 2 }
<swarley> without the { } if you already have a base configuration
chussenot has joined #ruby
whowantstolivef1 has joined #ruby
<aedorn> is there some way of seeing gems released recently on rubygems.org?
ltsstar has joined #ruby
<jzig> swarley: Looks great, thanks
<jzig> little things the tutorials don't tell you
Takehiro has quit [Read error: Connection reset by peer]
reppard has joined #ruby
_bart has quit [Ping timeout: 246 seconds]
yxhuvud has joined #ruby
tjbiddle has joined #ruby
iamjarvo has joined #ruby
Virunga has quit [Remote host closed the connection]
horofox has quit [Quit: horofox]
anarchist has quit []
yxhuvud2 has quit [Ping timeout: 256 seconds]
<matip> what type do you use when you want a time column with timezone in datamapper?
sepp2k1 has joined #ruby
banisterfiend has quit [Ping timeout: 245 seconds]
sepp2k has quit [Ping timeout: 265 seconds]
pyr0commie has joined #ruby
<matip> type DataTime and Time creates a column with type "timestamp without time zone" in postgresql
nerd has quit [Quit: WeeChat 0.3.9.2]
wermel has quit [Remote host closed the connection]
chussenot has quit [Ping timeout: 252 seconds]
jimeh has quit [Quit: Computer has gone to sleep.]
regedarek has quit [Quit: Lost terminal]
kiyoura has joined #ruby
<Kneferilis> why you need two ifs here: if KEYWORDS.include?(identifier) in javascript you would do if( keywords.indexOf(identifier) !== -1 )
reppard has quit [Ping timeout: 260 seconds]
maesbn has joined #ruby
<apeiros_> where do you see two if's there?
<Kneferilis> there is a ? in the there
<Kneferilis> what does it do?
<jrajav> That's just part of the name of the method
icole has joined #ruby
<Kneferilis> looked like the alternative if syntax
<jrajav> Nope
<jrajav> And that's not an alternative if you're thinking of, it's the ternary operator
browndawg has quit [Quit: Leaving.]
<jrajav> There are subtle differences
jlwestsr has quit [Read error: Operation timed out]
<jrajav> Generally, in Ruby, if you see a method that has ? at the end, it's to indicate that it's a method that tests some condition and returns a boolean value
h4mz1d has joined #ruby
<Kneferilis> I see.
jenrzzz has joined #ruby
<jrajav> There are other such conventions - for instance, a method ending in ! means that instead of returning a new object with the given operation applied, it instead applies that operation to the original object (the ! stands for "dangerous", since it's mutating the object)
banisterfiend has joined #ruby
iamjarvo has quit [Quit: Leaving.]
<Kneferilis> does this add a string to the array?
<Kneferilis> tokens << [identifier.upcase.to_sym, identifier] it doesn't look like a string
maesbn has quit [Remote host closed the connection]
bigmac has joined #ruby
maesbn has joined #ruby
dsdeiz has quit [Ping timeout: 265 seconds]
jgrevich has joined #ruby
slainer68 has joined #ruby
atno has quit [Ping timeout: 255 seconds]
iamjarvo has joined #ruby
<swarley> Kneferilis; no it does not
<Kneferilis> what does it add?
<swarley> an Array
skcin7 has joined #ruby
<swarley> [1] pry(main)> [1,2,3] << [1,2]
<swarley> => [1, 2, 3, [1, 2]]
pmros has quit [Read error: Connection reset by peer]
hoelzro|away is now known as hoelzro
pmros has joined #ruby
<Kneferilis> I see!
tjbiddle has quit [Quit: tjbiddle]
bluOxigen has joined #ruby
<Kneferilis> and what is this: else tokens << [:IDENTIFIER, identifier] end
Teddy2steper has joined #ruby
<Kneferilis> the :IDENTIFIER?
kirun has quit [Ping timeout: 265 seconds]
Jasko has quit [Read error: Connection reset by peer]
banisterfiend has quit [Ping timeout: 245 seconds]
Jasko has joined #ruby
Karasuhebi has joined #ruby
Karasuhebi has left #ruby [#ruby]
squidBits has joined #ruby
<shevy> Kneferilis a symbol
<shevy> Kneferilis do you have irb
<shevy> start irb
<shevy> then do this:
sepp2k1 has quit [Ping timeout: 265 seconds]
<shevy> :IDENTIFIER.class
<shevy> go start irb now Kneferilis!!!!!
<shevy> a symbol is always unique
<shevy> memory efficient, always the same
<Kneferilis> ok
<shevy> :foo.object_id # => 153778
<shevy> :foo.object_id # => 153778
stevechiagozie has quit [Ping timeout: 255 seconds]
<shevy> it has always the same object id
<shevy> compare to string "foo":
<aedorn> way too excited about symbols there
<shevy> "foo".object_id # => -616078768
<shevy> "foo".object_id # => -616081358
<iamjarvo> i have been doing some pratice probs and i am noticing a pattern but cant describe it. so say you have a hash. the keys are words to be replaced and values are the new words. my initial thought process was to loop through the string and do the replacing but they looped through the hash
<Kneferilis> but shevy the example folder does not have an identifier class
<shevy> Kneferilis what does that mean
<shevy> Kneferilis do you try to decipher code written by someone else? :\
<Kneferilis> shevy: yes
<shevy> it's not good...
<Kneferilis> I don't know much ruby
<shevy> you need your brain to be active
gener1c has quit [Remote host closed the connection]
<Kneferilis> I use codeideon
<Kneferilis> codepad
<shevy> your brain needs to tell you this "man, this code sucks"
slainer68 has quit [Ping timeout: 256 seconds]
SqREL has quit [Remote host closed the connection]
<Kneferilis> so I have this: http://codepad.org/bk1MJTnX
<Kneferilis> but it doesn't do anything
dsdeiz has joined #ruby
timonv has joined #ruby
<shevy> what should it do either
<shevy> if you write "foo"
<shevy> it does not do anything either
ebouchut has quit [Quit: This computer has gone to sleep]
solidresolve has quit [Quit: Leaving]
Teddy2steper has quit [Remote host closed the connection]
<shevy> Time for your brain to ask good questions :)
maesbn has quit [Remote host closed the connection]
graeme has joined #ruby
solidresolve has joined #ruby
<Kneferilis> yes
banister_ has joined #ruby
ltsstar has quit [Ping timeout: 260 seconds]
maetthew has joined #ruby
trying has joined #ruby
dsdeiz has quit [Ping timeout: 244 seconds]
tjbiddle has joined #ruby
Shadow_S has joined #ruby
iamjarvo has quit [Ping timeout: 252 seconds]
codebiff has joined #ruby
ebouchut has joined #ruby
sepp2k has joined #ruby
codebiff has quit [Client Quit]
jekotia has joined #ruby
<Kneferilis> so, :IDENTIFIER is a string?
<Kneferilis> I have never seen this before
<hoelzro> Kneferilis: it's a symbol
<Kneferilis> in PHP IDENTIFIER would be a constant
<apeiros_> constants are a kind of variable
<apeiros_> variables are NOT objects
<Kneferilis> ok, but how would I translate that symbol in JavaScript?
cj3kim has quit [Quit: This computer has gone to sleep]
<hoelzro> Kneferilis: :IDENTIFIER and IDENTIFIER are different
<apeiros_> "foo" and :bar and [] are object (literal objects, as opposed to constructed objects, like Array.new
<apeiros_> Kneferilis: JS doesn't have symbols
<apeiros_> you'd use a string
adeponte has joined #ruby
<yxhuvud> yes, especially since it plays very well with method dispatch.
<hoelzro> symbols are a very distinct feature
<hoelzro> used in fairly few languages
<yxhuvud> ie access a method through obj[name] instead of obj.name.
v0n has quit [Ping timeout: 265 seconds]
cj3kim has joined #ruby
Dario_ has joined #ruby
<Kneferilis> I see.
otters has quit [Ping timeout: 244 seconds]
<Kneferilis> yes, strings are all right
ebouchut has quit [Quit: This computer has gone to sleep]
dsdeiz has joined #ruby
jgrevich has quit [Ping timeout: 255 seconds]
hotovson has quit [Remote host closed the connection]
skcin7 has quit [Quit: Computer has gone to sleep.]
pencilcheck has quit [Remote host closed the connection]
chussenot has joined #ruby
<shevy> javascript!
maesbn has joined #ruby
alanjc_ has quit [Quit: alanjc_]
<shevy> Kneferilis well if javascript does not have something like symbols...
<shevy> ... then I am not sure how you want to translate it
<shevy> you could try a constant perhaps
Virunga has joined #ruby
solidresolve has quit [Quit: Leaving]
solidresolve has joined #ruby
<Kneferilis> shevy: you seem to be very fond of JavaScript
chussenot_ has joined #ruby
<shevy> hehe
<shevy> if only I could use ruby in a browser ...
maesbn has quit [Remote host closed the connection]
<hoelzro> <script type='text/ruby'>alert 'Hello, World!'</script>
<hoelzro> wouldn't that be nice?
Dario_ has quit [Ping timeout: 265 seconds]
tenmilestereo has joined #ruby
<shevy> lol
clocKwize has joined #ruby
<shevy> at least that will give us a GUI :D
<shevy> sadly not with ruby...
<Kneferilis> here: http://gestalt.codeplex.com/
<Kneferilis> but it is a hack
<shevy> cool idea
chussenot has quit [Ping timeout: 256 seconds]
chussenot_ is now known as chussenot
Bedry has joined #ruby
yxhuvud2 has joined #ruby
jimeh has joined #ruby
vlad_starkov has joined #ruby
tommyvyo[cloud]_ has joined #ruby
sayan has quit [Ping timeout: 252 seconds]
pkondzior__ has joined #ruby
maetthew has quit [Quit: bye]
thams has quit [Read error: Connection reset by peer]
love_color_text has joined #ruby
thams has joined #ruby
chussenot has quit [Ping timeout: 252 seconds]
<aedorn> I'm sure it wouldn't take much effort to use mruby in a browser plugin to do that .. of course, as a means to have a GUI I don't think it's worth it for that alone.
yfeldblum has quit [Ping timeout: 252 seconds]
yxhuvud has quit [Ping timeout: 264 seconds]
<hoelzro> aedorn: I've thought of doing something like that
vlad_starkov has quit [Ping timeout: 250 seconds]
<hoelzro> but I think that the future (at least for now) is compiling to JS
Bedry has left #ruby [#ruby]
<apeiros_> go both ways
<apeiros_> have a plugin which can do it natively
<apeiros_> and a ruby.js runtime as fallback for all the others
<hoelzro> that would be nice
love_color_text has quit [Ping timeout: 265 seconds]
maetthew has joined #ruby
omg765 has joined #ruby
ozgor has quit [Quit: ozgor]
<aedorn> well, we experimented with a full ruby environment called from firefox to do "inline ruby" in the browser
<apeiros_> nice
<apeiros_> how did it go?
wargasm has joined #ruby
_bart has joined #ruby
<aedorn> Not too bad. You don't much overhead if you're just talking to a separate process and feeding information back and forth as required. And it's actually not too much code to do it
jonathanwallace1 has quit [Quit: WeeChat 0.3.9.2]
<aedorn> You don't get* even ..
g_bleezy has quit [Remote host closed the connection]
hackerdude has joined #ruby
<aedorn> In fact, the only reason we scrapped the whole thing was because it was going to take too long to remove stuff we didn't want, rather than add the things we did.
<Kneferilis> aedorn: someone could write a javascript library that parses ruby code
<Kneferilis> what I do now is a language that runs on javascript
<Kneferilis> and it's a javascript library
yfeldblum has joined #ruby
<Kneferilis> why this is done in the code number.to_i ? http://pastebin.com/NUdb4YVD
<Kneferilis> I mean, why would you want to turn e.g. 123abc to 123?
jonathanwallace has joined #ruby
<Kneferilis> oh, I see now
stevechiagozie has joined #ruby
<Kneferilis> it just converts the string into an integer
kil0byte_ has joined #ruby
<Kneferilis> it justs happens that it also removes alphabetical characters too
<aedorn> Kneferilis: sure, but then you have a much bigger project on your hands.
lorn has quit [Quit: ZNC - http://znc.sourceforge.net]
kil0byte has quit [Ping timeout: 265 seconds]
nick_h has quit [Ping timeout: 244 seconds]
slainer68 has joined #ruby
nick_h has joined #ruby
lorn has joined #ruby
michaelmartinez has joined #ruby
BBonifield has quit [Ping timeout: 276 seconds]
codebiff has joined #ruby
kirun has joined #ruby
BBonifield has joined #ruby
seanstickle has joined #ruby
codebiff has left #ruby [#ruby]
codebiff has joined #ruby
kokainepizza has joined #ruby
locriani has quit [Remote host closed the connection]
squidBits has quit [Read error: Connection reset by peer]
ebouchut has joined #ruby
seanstickle has quit [Client Quit]
h4mz1d has quit [Ping timeout: 252 seconds]
kokainepizza has quit [Client Quit]
tjbiddle has quit [Quit: tjbiddle]
elevine has joined #ruby
kokainepizza has joined #ruby
otters has joined #ruby
codebiff has left #ruby [#ruby]
reppard has joined #ruby
codebiff has joined #ruby
kirun_ has joined #ruby
codebiff has quit [Client Quit]
cj3kim has quit [Quit: This computer has gone to sleep]
clocKwize has quit [Quit: clocKwize]
nateberkopec has joined #ruby
jekotia has quit [Quit: ChatZilla 0.9.89-rdmsoft [XULRunner 1.9.0.17/2009122204]]
kirun has quit [Ping timeout: 252 seconds]
nateberkopec has quit [Client Quit]
clocKwize has joined #ruby
ikaros has quit [Quit: Ex-Chat]
clocKwize has quit [Client Quit]
F1skr has joined #ruby
eka has joined #ruby
txdv has quit [Read error: Connection reset by peer]
txdv has joined #ruby
Nisstyre-laptop has joined #ruby
horofox has joined #ruby
ebouchut has quit [Quit: This computer has gone to sleep]
stevechiagozie has quit [Ping timeout: 245 seconds]
kiyoura has quit [Ping timeout: 255 seconds]
whowantstolivef1 has quit [Ping timeout: 252 seconds]
crackfu has quit [Remote host closed the connection]
Nisstyre has joined #ruby
vlad_starkov has joined #ruby
v0n has joined #ruby
Nisstyre has quit [Read error: Connection reset by peer]
shiin has joined #ruby
skcin7 has joined #ruby
mockra has joined #ruby
Dario_ has joined #ruby
yfeldblum has quit [Ping timeout: 252 seconds]
Teddy2steper has joined #ruby
adeponte has quit [Remote host closed the connection]
Dario_ has quit [Ping timeout: 260 seconds]
crackfu has joined #ruby
mockra_ has joined #ruby
mockra has quit [Ping timeout: 265 seconds]
vlad_starkov has quit [Ping timeout: 245 seconds]
omg765 has quit [Quit: Computer has gone to sleep.]
heftig has quit [Ping timeout: 245 seconds]
shevy has quit [Read error: Operation timed out]
kiyoura has joined #ruby
chussenot has joined #ruby
nomenkun has joined #ruby
Teddy2steper has quit [Remote host closed the connection]
reppard has quit [Ping timeout: 260 seconds]
Shadow_S has quit [Quit: Computer has gone to sleep.]
yxhuvud has joined #ruby
lkba has joined #ruby
yxhuvud2 has quit [Ping timeout: 260 seconds]
mockra_ has quit [Remote host closed the connection]
skcin7 has quit [Quit: Computer has gone to sleep.]
graeme has quit [Quit: graeme]
kirun_ has quit [Ping timeout: 240 seconds]
yfeldblum has joined #ruby
wargasm1 has joined #ruby
ryanlecompte has quit [Remote host closed the connection]
michaelmartinez has quit [Quit: Check it, Wreck it http://www.caffeineindustries.com/blog]
wargasm has quit [Ping timeout: 265 seconds]
tk__ has quit [Quit: ばいばい]
skcin7 has joined #ruby
Guest has joined #ruby
benlieb has joined #ruby
<Kneferilis> how do you translate this /\A\:\n( +)/m to javascript regex?
shevy has joined #ruby
spinagon has quit [Ping timeout: 250 seconds]
<csmrfx> off topic
<csmrfx> go to ##javascript
<csmrfx> no, wait
<csmrfx> 8)
stevechiagozie has joined #ruby
arturaz has joined #ruby
_bart has left #ruby [#ruby]
<csmrfx> whats ( +)? one or more spaces?
snearch has joined #ruby
<csmrfx> anyway
<csmrfx> rubular.com + browser js console, then cross test that they match the same in multiple test strings
Jackneill has quit [Remote host closed the connection]
blakeeb has joined #ruby
chussenot has quit [Quit: chussenot]
pmros has quit [Quit: Konversation terminated!]
The_8473 is now known as The_8472
Guest has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
phelps has quit [Quit: Textual IRC Client: www.textualapp.com]
skcin7 has quit [Quit: Computer has gone to sleep.]
chussenot has joined #ruby
cantonic has joined #ruby
hackerdude has quit [Remote host closed the connection]
jaygen has quit [Read error: Operation timed out]
stevechiagozie has quit [Ping timeout: 265 seconds]
thams has quit [Read error: Connection reset by peer]
thams has joined #ruby
thomsch_ has joined #ruby
Jasko has quit [Read error: Connection reset by peer]
Jasko has joined #ruby
crackfu has quit [Remote host closed the connection]
reppard has joined #ruby
chussenot has quit [Quit: chussenot]
chussenot has joined #ruby
<havenn> Compile mruby to JavaScript with emscripten: https://github.com/xxuejie/webruby
reppard has quit [Ping timeout: 252 seconds]
arturaz has quit [Ping timeout: 245 seconds]
F1skr has quit [Ping timeout: 252 seconds]
<csmrfx> Whats regex '\:' do?
h8R has joined #ruby
joeycarmello has joined #ruby
joeycarmello has quit [Client Quit]
<swarley> just escapes :
arturaz has joined #ruby
<canton7> does : need escaping?
wargasm1 has quit [Ping timeout: 252 seconds]
atadesk has joined #ruby
alexspeller has joined #ruby
atadesk has left #ruby [#ruby]
blakeeb has quit [Ping timeout: 244 seconds]
Dario_ has joined #ruby
<swarley> I'm not sure actually
ozgor has joined #ruby
<canton7> Doesn't seem to. Probably someone being over-zealous
love_color_text has joined #ruby
VegetableSpoon has joined #ruby
stevechiagozie has joined #ruby
QKO has joined #ruby
Dario_ has quit [Ping timeout: 255 seconds]
brianpWins has quit [Quit: brianpWins]
love_color_text has quit [Ping timeout: 252 seconds]
lolcathost has quit [Quit: leaving]
horofox has quit [Ping timeout: 246 seconds]
snearch has quit [Quit: Verlassend]
Takehiro has joined #ruby
Takehiro has quit [Read error: Connection reset by peer]
QKO_ has quit [Ping timeout: 272 seconds]
slainer68 has quit [Remote host closed the connection]
Catnaroek has joined #ruby
nomenkun has quit [Remote host closed the connection]
voodoofish has joined #ruby
nyuszika7h has quit [Quit: Here we are, going far to save all that we love - If we give all we've got, we will make it through - Here we are, like a star shining bright on your world - Today, make evil go away!]
slainer68 has joined #ruby
kenneth has joined #ruby
<kenneth> hey, can you make a gem spec draw its dependencies form the gemfile?
<kenneth> instead of repeating them
nyuszika7h has joined #ruby
<canton7> kenneth, other way around: specify gems in your gemspec, and "import" those into your gemfile
yxhuvud2 has joined #ruby
<kenneth> gotcha
<kenneth> sounds good
yxhuvud has quit [Ping timeout: 245 seconds]
cantonic_ has joined #ruby
thibauts has joined #ruby
F1skr has joined #ruby
<thibauts> Hi, what would be a clean way to serialize to json an object whose properties can be objects or arrays of objects (with arbitrary nesting depth) ?
<canton7> thibauts, and the json library doesn't handle it properly?
cantonic has quit [Ping timeout: 260 seconds]
cantonic_ is now known as cantonic
<canton7> (the answer is "recursively" - each object defines a #to_json, which builds its json representation by calling its members' #to_json methods. But the json library should do that)
<thibauts> canton7: I tried to_json but it renders sub-objects as string representation of themselves. For some context i'm trying to serialize output from ruby-whois
<alexspeller> require 'json'; {:foo => {:bar => [:baz]}, :bar => [:baz]}.to_json
<alexspeller> => "{\"foo\":{\"bar\":[\"baz\"]},\"bar\":[\"baz\"]}"
<canton7> thibauts, then define #to_json on those objects, and do it properly
havenn has quit [Remote host closed the connection]
<alexspeller> thibauts: I think you need to define to_json on those sub object
<canton7> there's some docs about that somewhere iirc
<alexspeller> ^^ what he said
<alexspeller> :)
F1skr has quit [Quit: WeeChat 0.3.9.2]
<canton7> thibauts, http://flori.github.com/json/
<thibauts> I'd like to touch the original gem the less possible, you know ..
havenn has joined #ruby
havenn has quit [Read error: Connection reset by peer]
<canton7> see the first example
havenn has joined #ruby
<thibauts> actually, the "sub-objects" are Structs
<canton7> and this isn't about modifying the gem at all
pavilionXP has quit [Ping timeout: 255 seconds]
<thibauts> canton7: That looks pretty cool
manizzle has joined #ruby
havenn has quit [Ping timeout: 252 seconds]
daniel_hinojosa has joined #ruby
atmosx has quit [Quit: Computer has gone to sleep.]
<thibauts> Thanks guys, i only had to make Struct serializeable, and all subclasses provided by ruby-whois serialized fine. I hadn't practiced ruby for a few years and I had forgotten those nice features. That's amazing :)
<canton7> awesome :)
<csmrfx> thats freakin
stevechiagozie has quit [Quit: leaving]
ryanlecompte has joined #ruby
arturaz has quit [Ping timeout: 245 seconds]
<shevy> cool
<shevy> serializeable structs
<thibauts> For me it really is. I didn't expect to solve that so easily
<shevy> immortal objects residing on the www
joeycarmello has joined #ruby
ananthakumaran1 has quit [Quit: Leaving.]
Axsuul has joined #ruby
<csmrfx> I'd prefer marshal any day tho
nathan28 has joined #ruby
joeycarmello has quit [Remote host closed the connection]
<nathan28> anyone got a handy piece of regex to reject html color hex values from an array of strings?
<thibauts> csmrfx: for a web service ? BTW if you can point me to a clean solution to putting this queryable via HTTP i will be thankful
cousine has joined #ruby
<csmrfx> nathan28: css?
<csmrfx> just extracting color hex values from any arbitrary string is going to lead to problems
<shevy> guys, I have a module, let's say module Foo. In that module, I have a debug constant, let's call it DEBUG. I can access it via Foo::DEBUG, by default this variable is false. I believe I can set it to Foo::DEBUG = false, but constants should not be changed or? so I wonder, what else to use, if I want to "store" state in a module
<shevy> I meant Foo::DEBUG = true
<csmrfx> for example, "abba" and "caffee" are both valid hex strings
<nathan28> csmrfx: yeah ii'm trying to parse rss feeds and some of them are full of html color codes but [a-f0-9] looks dangerous
<thibauts> shevy: use an instance variable and store your constant's value in it ?
<shevy> the reason I want to have this is so I can toggle it on a per-project base actually, in one place, for the whole project
<shevy> hmm that would work thibauts?
havenn has joined #ruby
topriddy has joined #ruby
rburton- has joined #ruby
<nathan28> csmrfx: looks like more than regex would be necessary, got to yank out any inline tags i guess
<canton7> shevy, thibauts +1
<csmrfx> thibauts: so the answer is 'css syntax'?
<apeiros_> `class Item < Struct.new(:id, :name); end` <-- eeew
<apeiros_> just `Item = Struct.new(:id, :name)`, no need to create an unused class.
<thibauts> shevy: not sure it will work for your case.
<csmrfx> sorry, I meant:
<csmrfx> nathan28: so the answer is 'css syntax'?
<nathan28> csmrfx: these are other ppl's feeds
ryanlecompte has quit [Ping timeout: 265 seconds]
<thibauts> So what's the simplest way to turn a function to a webservice in ruby ?
<csmrfx> nathan28: already have forgotten what rss might include
<csmrfx> thibauts: cant you just open a http port
<nathan28> csmrfx: a bunch of ugly crap apparently! w/e
<nathan28> here i was thinking that an rss feed would just have text and no formatting and the nytimes was like "trololol <IMG />"
<csmrfx> nathan28: if you can could on things like is between ":" and ";"...
<csmrfx> +count
fphilipe has joined #ruby
<nathan28> good idea, imma hafta rebork this some to sanitize the input more
benlieb has quit [Ping timeout: 252 seconds]
pen has joined #ruby
<thibauts> csmrfx: open an http port ?
<nathan28> csmrfx: thx
jaygen has joined #ruby
topriddy has quit [Ping timeout: 260 seconds]
<thibauts> csmrfx: well, i'd prefer not to reimplement http if possible ^^
crackfu has joined #ruby
<csmrfx> thibauts: see the code example under "A simple server would look like"
<apeiros_> um, bad idea
<csmrfx> on its own, probably so
<apeiros_> csmrfx: "a webservice" is lingo for "SOAP Webservice"
<csmrfx> yeah
<apeiros_> Socket is quite a bit too low level for that.
<csmrfx> with a nice simple function, might be all you need
<canton7> for me, sinatra every time for simple web stuff
WanderingGlitch has quit [Changing host]
WanderingGlitch has joined #ruby
<nathan28> ^
<nathan28> sinatra is great
<apeiros_> thibauts: I'd google or go to ruby-toolbox, there's probably some gems for rails, sinatra or rack which make creating webservices rather easy
<canton7> or eventmachine + one of the http extensions/plugins/whatever they're called
<apeiros_> thibauts: I think one such lib is RABL
omg765 has joined #ruby
<thibauts> i come from python, i'm used to mount functions in a few lines of code with wsgi. i'm looking for something similar in ruby
chussenot has quit [Quit: chussenot]
<apeiros_> thibauts: the wsgi equivalent would be Rack
bluebie has left #ruby [#ruby]
<apeiros_> and this is a valid rack app: proc { |env| [200, {:"content-type" => "text/plain"}, ["Hello World!"]] }
<csmrfx> do you really need rack if thats all you need?
<thibauts> apeiros_: That looks *awesome* :p
<apeiros_> i.e., anything that responds to "call", accepts 1 param (env, containing the request and a bit more) and returns an array with 3 items (status code, headers, body)
eldariof has quit []
<apeiros_> csmrfx: try and see how much time you need to do even a minimal implementation of what rack does for you…
cousine has quit [Remote host closed the connection]
<csmrfx> yeah, probably
<thibauts> does rack have an embedded web server ?
<apeiros_> hint, if it's more than 1h, reading racks docs is probably the easier route.
<csmrfx> haha
<apeiros_> thibauts: no idea, but since there's like twenty thousand ruby based webservers (one in stdlib), there's no real need I guess
<apeiros_> I'd assume that rack can run standalone and will use webrick (the stdlib webserver)
<csmrfx> apache or nginx
<canton7> apeiros_, sounds right
<apeiros_> ah, yes, I remember, rack can run standalone, see rackup
<thibauts> apeiros_: Ok, i should be able to find my way
<apeiros_> thibauts: anyway, rack is sufficiently documented iirc
<canton7> or it can use thin, etc
<apeiros_> and if you can't find your way around, you can still come back and ask :-p
<apeiros_> yeah, thin, unicorn, nginx or apache are recommended
<apeiros_> first 2 are ruby based webservers, last 2 you probably know from elsewhere
<thibauts> Just out of curiosity, how does it interface with nginx ? fastcgi ?
<apeiros_> passenger
<apeiros_> passenger-phusion, an extension. same one for apache.
<apeiros_> (or phusion-passenger? memory is low atm)
<thibauts> ok, looks like uwsgi for ruby
<canton7> the latter
<canton7> or you can reverse-proxy to thin, unicorn, etc
<apeiros_> when in doubt, canton7
<apeiros_> we do nginx reverse-proxy to unicorn at work
omg765 has quit [Quit: ["Textual IRC Client: www.textualapp.com"]]
<shevy> hehe
<shevy> funny to read :)
chussenot has joined #ruby
bluOxigen has quit [Ping timeout: 260 seconds]
<shevy> I do kaboom straight-direct to hamster at work
thomsch_ has quit [Ping timeout: 245 seconds]
shemerey has joined #ruby
benlieb has joined #ruby
topriddy has joined #ruby
<canton7> ruby is a bit insane like that
<canton7> in what other language can you say your app runs on rainbows?
<shevy> in a true hipster language
<apeiros_> canton7: ruby, the language where you daemonize a unicorn!
<canton7> hah!
Bosox20051 has joined #ruby
cousine has joined #ruby
<apeiros_> better even: ruby, the domain, created by puppets, where god watches the daemonized unicorns
karakedi has joined #ruby
mockra has joined #ruby
jkarayusuf has joined #ruby
mockra has quit [Remote host closed the connection]
<csmrfx> should I laugh or not
<csmrfx> hmm
<csmrfx> even the skynet has been implemented in ruby
fphilipe has quit []
Dario_ has joined #ruby
benlieb has quit [Quit: benlieb]
wargasm has joined #ruby
elico has quit [Ping timeout: 252 seconds]
jkarayusuf has quit [Remote host closed the connection]
elevine has quit [Quit: Leaving]
<shevy> really?
<shevy> what is curious is that there are virtually no games in, or using ruby :(
<hoelzro> shevy: most games (it seems) embed either Lua or (much less often) Python
fphilipe has joined #ruby
Dario_ has quit [Ping timeout: 252 seconds]
fphilipe has quit [Client Quit]
elico has joined #ruby
fphilipe has joined #ruby
atmosx has joined #ruby
robhor has joined #ruby
Nisstyre has joined #ruby
<atmosx> hello
skcin7 has joined #ruby
fphilipe has quit [Remote host closed the connection]
parzorep has joined #ruby
zommi has joined #ruby
yxhuvud has joined #ruby
jlwestsr has joined #ruby
benlieb has joined #ruby
robhor has quit [Quit: robhor]
yxhuvud2 has quit [Ping timeout: 255 seconds]
benlieb has quit [Client Quit]
jlwestsr has quit [Client Quit]
chussenot has quit [Quit: chussenot]
jenrzzz has quit [Read error: Operation timed out]
zigomir has joined #ruby
nomenkun has joined #ruby
slainer68 has quit [Remote host closed the connection]
timonv has quit [Remote host closed the connection]
wf2f has quit []
benlieb has joined #ruby
samphippen has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
samphippen has joined #ruby
nomenkun has quit [Ping timeout: 252 seconds]
cousine has quit [Remote host closed the connection]
<shevy> hmmm
<shevy> foo.instance_variable_get('@b')
<shevy> is that possible all the time?
<shevy> I wonder a bit about public vs. private in ruby
marr has joined #ruby
<hoelzro> shevy: it is
<hoelzro> well
<hoelzro> you *could* override instance_variable_get
gh has joined #ruby
<hoelzro> but I'm sure there's a way to get around it, even then
<canton7> private's more a statement that the method is part of the internal api, and don't rely on it not breaking
<shevy> interesting
xbayrockx has joined #ruby
xbayrockx is now known as wf2f
gh has quit [Client Quit]
rburton- has quit [Quit: Linkinus - http://linkinus.com]
<thibauts> This seems to work fine. Any critics on the code for a ruby noob ? https://github.com/thibauts/whois
wf2f has quit [Client Quit]
EhyehAsherEhyeh has joined #ruby
zommi has quit [Quit: Leaving.]
<canton7> thibauts, 1) don't require rubygems (unless you're running 1.8). 2) line 35: if ARGV.empty? Also exit with a non-zero code, but that's not really ruby-related. Also, why mongrel?
<canton7> otherwise looks good
<thibauts> canton7: i'm running 1.8 (apt-get ..), is it "wrong" ? mongrel because i lazily copy pasted code that used it :p
<canton7> thibauts, aha. 1.8 is not really recommended, but hey. that'll explain how you got mongrel to work anyway (iirc mongrel + ruby1.9 = no worky)
nemesit has quit [Quit: Leaving...]
<thibauts> canton7: if i install 1.9, what would be the best bet for a handler ? also, i'm worried that i won't be able to plug my code to passenger in case i want to, is there a "portable" way to make it work both as an embedded app and s a standalone server ?
benlieb has quit [Quit: benlieb]
Proshot has quit [Quit: Leaving]
Catnaroek has quit [Ping timeout: 265 seconds]
<canton7> thibauts, I'd use thin instead of mongrel, either way. Look at config.ru. That's what passenger uses to start your rack app
slainer68 has joined #ruby
Catnaroek has joined #ruby
<canton7> then a call to 'rackup' will start your app using whatever handler (thin, mongrel, etc), and passenger can just start it natively
<havenn> unicorns and rainbows!
v0n has quit [Read error: Connection reset by peer]
EhyehAsherEhyeh has quit [Ping timeout: 265 seconds]
benlieb has joined #ruby
love_color_text has joined #ruby
lenovodroid has joined #ruby
Averna has joined #ruby
icole has quit [Remote host closed the connection]
statarb3 has joined #ruby
love_color_text has quit [Ping timeout: 260 seconds]
statarb3 is now known as Proshot
reppard has joined #ruby
alanp has quit [Read error: Connection reset by peer]
alanp has joined #ruby
koshii has joined #ruby
tchebb has quit [Ping timeout: 252 seconds]
ninegrid has joined #ruby
johnmilton has quit [Quit: Leaving]
Dario_ has joined #ruby
tchebb has joined #ruby
RomainT has left #ruby [#ruby]
<thibauts> canton7: this looks much better now .. running on thin
<canton7> cools. with rackup?
jaygen has quit [Remote host closed the connection]
Dario_ has quit [Ping timeout: 255 seconds]
<thibauts> canton7: yes
jrajav has quit [Read error: Connection reset by peer]
jrajav has joined #ruby
forcefsck has joined #ruby
icole has joined #ruby
<canton7> thibauts, nice :)
mercwithamouth has joined #ruby
mage_ has left #ruby [#ruby]
bobrossasaurus has joined #ruby
yfeldblum has quit [Ping timeout: 256 seconds]
Takehiro has joined #ruby
Takehiro has quit [Read error: Connection reset by peer]
mockra has joined #ruby
Kneferilis has left #ruby [#ruby]
yxhuvud2 has joined #ruby
yxhuvud has quit [Ping timeout: 264 seconds]
mockra has quit [Ping timeout: 252 seconds]
alanjc_ has joined #ruby
skcin7 has quit [Quit: Computer has gone to sleep.]
benlieb has quit [Quit: benlieb]
berserkr has quit [Quit: Leaving.]
reppard has quit [Ping timeout: 244 seconds]
pen has quit [Read error: Connection reset by peer]
eka has quit [Quit: Computer has gone to sleep.]
pen has joined #ruby
Tumulte has quit [Remote host closed the connection]
eka has joined #ruby
tenmilestereo has quit [Quit: Leaving]
wargasm has quit [Ping timeout: 265 seconds]
havenn has quit [Remote host closed the connection]
tr4656 has quit [Ping timeout: 250 seconds]
vlad_starkov has joined #ruby
lenovodroid has quit [Remote host closed the connection]
squidBits has joined #ruby
kiyoura` has joined #ruby
parzorep has quit [Remote host closed the connection]
parzorep has joined #ruby
neurotech has joined #ruby
<shevy> hmm I just noticed something
<shevy> in .rb files, you can do stuff like this
jaygen has joined #ruby
<shevy> cd '/tmp/foo-1.0'
<shevy> and cd() could be a call to Dir.chdir()
<shevy> that is almost as good as bash shell scripts
<shevy> except that in the latter, you could do this:
<bobrossasaurus> You can run just shell scripts too.
<shevy> cd /tmp/foo-1.0
<bobrossasaurus> system("cd ~/") works
koshii has quit [Read error: Connection reset by peer]
<hoelzro> isn't there a shell gem or something that does that?
emergion has joined #ruby
<bobrossasaurus> Maybe, there's almost a gem for everything. But I wouldn't see why you'd need one given that you can just pipe all your shell commands through Ruby's system() call or use backticks in your scripts
<bobrossasaurus> Example: `cat ~/somefile.txt`
<canton7> bobrossasaurus, that doesn't change the wd of the script, though
<bobrossasaurus> canton7: True, you'd have to use Dir.chdir() for that I believe
rakl has joined #ruby
<shevy> bobrossasaurus hmm, ruby code is easier to read when it becomes very complex in my opinion
<canton7> bobrossasaurus, yup
<canton7> shevy, what did you do to make your `cd '/tmp/foo-1.0'` work in a ruby script? What am I missing?
<shevy> well, cd 'bla' is valid ruby code
<shevy> where cd() would be a method
<canton7> aah, you define 'cd'
<canton7> gotcha
<shevy> so that is quite short
<shevy> bash, in this example, can be even shorter though
<shevy> cd bla
<canton7> I was wondering what you were requiring...
<atmosx> shevy: chitin
koshii has joined #ruby
<atmosx> although chitin is somewhat the opposite of what hyou described, it's ruby in bash/zsh (shell)
<shevy> huh?
<shevy> you could do:
<atmosx> you can use ruby to handle files, which can turn pretty handy
<shevy> cd bla/ble
<shevy> with this?
<thibauts> canton7: now running on 1.9, that's even better. Thanks again for your help (and the others too ...)
<canton7> thibauts, cool! yeah no worries
vlad_starkov has quit [Ping timeout: 264 seconds]
jenrzzz has joined #ruby
Iszak has joined #ruby
<thibauts> now i want to learn more ruby, hehe. could you give me some pointers to cool things to learn about the language / ecosystem ?
<shevy> well
<shevy> not sure about the ecosystem
<atmosx> our ecosystem
<shevy> thibauts, it may be very boring BUT I recommend you to read through the _names_ of the methods in the classes first
<atmosx> it's echo-system
<shevy> http://www.ruby-doc.org/core-1.9.3/String.html Array Hash... Enumerator. these four at least
<bobrossasaurus> thibauts: If you want to learn Ruby, try playing with Ruby Warrior
arietis has quit [Quit: Textual IRC Client: http://www.textualapp.com/]
<bobrossasaurus> It's basically an RPG game in Ruby designed to teach you some neat things about the language
jenrzzz has quit [Read error: Connection reset by peer]
<bobrossasaurus> This link seems to be down at the moment, but here's the gem's Github page: https://github.com/ryanb/ruby-warrior
<thibauts> shevy: i see, used to dir() in python, good idea
<canton7> yeah, the standard library for ruby is amazing. and large. It's generally worth having the relevant page from ruby-doc open when writing stuff, and always check to see whether the method you're about to write exists already
benlieb has joined #ruby
<bobrossasaurus> I remember being blown away by some of the stuff Ruby does for you for free. For example, subtracting two arrays from each other to find the difference: [0,1,2,3] - [1,2,3] returns [0]
thams has quit [Read error: Connection reset by peer]
thams has joined #ruby
g_bleezy has joined #ruby
<thibauts> i was looking into Array, just saw it, the stdlib seems easily on par with python
Slivka has joined #ruby
<canton7> way better imo
<canton7> python does have a set of idioms for doing common operations ("there's one obvious way to do it"), so to do a given operation to this data structure you use these lines of code. Ruby has a function to do it
<canton7> imo way cleaner and easier to learn / referene / interpret / etc
<thibauts> you may well be right
<canton7> *reference
<canton7> also python loves its global methods. urgh
<thibauts> years passing, i tend to favor language constructs that make usual operations *very* concise, i'm bored dealing with usual logic
jslowe has joined #ruby
<thibauts> yeah there are may things not quite right in python, but the libs are very good
<thibauts> how do you manipulate lists in ruby ?
xcvd`` has joined #ruby
<canton7> what do you want to do to them?
<canton7> (and they're arrays in ruby)
g_bleezy has quit [Ping timeout: 245 seconds]
<thibauts> [a.get('foo') for a in as if a] for exemple
icole has quit [Remote host closed the connection]
shemerey has quit [Quit: Leaving...]
Iszak has quit []
<thibauts> i really love this in python, make operations on large lists with one liners
<canton7> as.compact.map{ |a| a.get('foo') }
jslowe has quit [Ping timeout: 246 seconds]
<canton7> it's more readable in ruby ;)
<banister_> thibauts: "a.get('foo') for a in as if a" is not even grammatical
<banister_> i mean it doesn't make sense in english
<canton7> (if the test was more complex, I'd use #select instead of #compact)
<canton7> banister_, s/as/myarray, and it's *sort of* readonable
<canton7> (readable
<thibauts> i think it may be even more readable with combinators, i read something about this not long ago, like a method to run a getter on elements of an array
tar_ has quit [Quit: farewell]
kokainepizza has quit [Quit: My pooter is sleep.]
<thibauts> banister_: yes you're right ..
<bobrossasaurus> I just discovered a new method the other day: partition. You pass it a conditional in a block and it'll partition the array into two sections, one being where the condition returned true, the other false.