<elemenopy>
i make web pages ad-free for a free video game
<elemenopy>
everything is in .NET right now we are converting
emmesswhy has joined #ruby
codecop has quit [Remote host closed the connection]
arescorpio has joined #ruby
emmesswhy has quit [Client Quit]
<jhass>
that's javascript, not json
<elemenopy>
so how should i go about getting all of those objects into something i can iterate through?
charliesome has quit [Quit: zzz]
nonks has joined #ruby
<jhass>
I'm not sure there's a robust sane way
<elemenopy>
well let me ask you this, what would be the best way to just pick out that piece?
<jhass>
I guess you parsed the page with nokogiri already
<jhass>
you can get the last script tags content with doc.css('script').last.text
<jhass>
but that's fragile already, it'll break once even just the order of the script tags there changes or another one is appended to the botoom
<rpag>
you'll also need to mangle through javascript before you get to something that could be parsed as JSON
<elemenopy>
ok well i found a simple 5 line class on the next that lets me extract just that string now
fuhgeddaboudit has joined #ruby
<rpag>
then you'll need to remove the JS parts, like function() {}, new R(..,) etc
KC9YDN-2 has joined #ruby
drPoggs has quit [Ping timeout: 256 seconds]
byprdct_ has joined #ruby
jimbach has quit [Remote host closed the connection]
phutchins has quit [Ping timeout: 256 seconds]
Alina-malina has quit [Ping timeout: 272 seconds]
KC9YDN has quit [Ping timeout: 265 seconds]
byprdct has quit [Ping timeout: 244 seconds]
nfk has quit [Quit: yawn]
emmesswhy has joined #ruby
oleo has quit [Read error: Connection reset by peer]
oleo has joined #ruby
Alina-malina has joined #ruby
exadeci has quit [Quit: Connection closed for inactivity]
tlarevo_ has joined #ruby
Channel6 has quit [Quit: Leaving]
omosoj has quit [Quit: leaving]
kaspergrubbe has joined #ruby
tier has joined #ruby
davidhq has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
slawrence00 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<elemenopy>
ok i've got it pulling the pure js out now
<elemenopy>
now how am i gonna make this js an object?
tlarevo has quit [Ping timeout: 272 seconds]
<rpag>
strip everything up until R(, then keep going til you see ); on the other end, it'd be very unreliable though the slightest change would break it
dmst has quit [Quit: Connection closed for inactivity]
narcan has joined #ruby
Jake has joined #ruby
<elemenopy>
hmmm according to JSLint this is valid JSON
davidhq has joined #ruby
<elemenopy>
are you sure this isn't JSON?
Jake has left #ruby ["WeeChat 1.0.1"]
user343242314234 has joined #ruby
<rpag>
the object passed to R is valid json yes
<user343242314234>
hi
sinkensabe has joined #ruby
<user343242314234>
i need help
skolman_ has joined #ruby
<rpag>
but it's just using javascript object literals
KC9YDN has quit [Read error: Connection reset by peer]
jimbach has joined #ruby
dkb20k has quit [Ping timeout: 264 seconds]
rkalfane has quit [Ping timeout: 264 seconds]
volty has joined #ruby
dion has joined #ruby
kotk_ has quit [Read error: Connection reset by peer]
<siwica>
puppet_nob: it pretty sorts fstab_mounts and does something with each element
Fire-Dragon-DoL has quit [Ping timeout: 265 seconds]
oo_ has joined #ruby
kotk has joined #ruby
KC9YDN has joined #ruby
KC9YDN-2 has joined #ruby
arup_r has joined #ruby
Sp4rKy_ has joined #ruby
diegoviola has quit [Remote host closed the connection]
<volty>
anyone knows how to configure apache's RewriteRule (and the rest) for a ruby script to be invoked? My current config currently shows the content of the cgi file instead of executing it.
mistermocha has joined #ruby
Scotteh_ has joined #ruby
KC9YDN-2 has quit [Read error: Connection reset by peer]
<siwica>
puppet_nob: When an element of fstab_mounts looks something like "foo1|foo2|foo3" it uses string comparison for "foo2" to sort
<siwica>
volty: cgi or ruby?
zorak8 has quit [Ping timeout: 244 seconds]
kaspergrubbe has quit [Remote host closed the connection]
<Yanik>
it's not that i must do it, i just want to learn to become a great ruby programmer!
<sevenseacat>
ok, so rank_up returns a string "Ranked up"
hmsimha_ has joined #ruby
<sevenseacat>
so you can't call say_hello on that string
<Yanik>
along with an increase of rank
armyriad has joined #ruby
<sevenseacat>
or the other way around
<Yanik>
sevenseacat: why not?
<Yanik>
sorry i'm such a noob
<sevenseacat>
because a string doesn't have the method say_hello
<sevenseacat>
a Player instance does
<Yanik>
that's so confusing
<Yanik>
but if it's defined in player shouldn't it run?
<sevenseacat>
typing up some stuff that might help
pdtpatri1k has quit [Quit: leaving]
<Yanik>
i know that it works if i type player2.rank_up and player2.say_hello without chaining them it will work
pdtpatr11k has joined #ruby
pdtpatr11k has quit [Client Quit]
<sevenseacat>
does that comment help?
<Yanik>
i wish it did
<Yanik>
i'm super confused and i'm super stupid i guess
michaeldeol has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<sevenseacat>
ok
<Yanik>
can you explain to me like i'm a toddler, why i can't chain those methods
<sevenseacat>
so you've defined rank_up on the player class, so you can call it on instances of Players
<sevenseacat>
but your say_hello method doesnt return a player, it returns a string
triple_b has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Yanik>
yes, it returns a string
<Radar>
Yanik: You probably want to use puts for the messages and then return a person at the end of those methods instead
aspires has quit []
<sevenseacat>
so how can you call rank_up on a string?
<sevenseacat>
what does it mean to rank_up a string?
<Yanik>
oh thank you so much\
<Yanik>
the order matters
<Yanik>
now i get it
<Yanik>
thank you very much! :)
<sevenseacat>
well no, because if you change the order of the method calls you'll have the same problem
<Yanik>
oh boy
<sevenseacat>
player2.rank_up.say_hello will have the exact same problem
hmsimha_ has quit [Ping timeout: 260 seconds]
SouL_ has quit [Ping timeout: 264 seconds]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<Yanik>
sorry guys the things you're saying are going over my head, but i know how to fix the problem, but i don't understand why it's not workign
drPoggs has joined #ruby
<Yanik>
i know a fix, but i don't know THE fix
<Radar>
Yanik: The fix is to return player objects instead of strings.
<elemenopy>
if im just running a ruby file over and over (no web pages involved) what is the way to connect and execute commands from ruby into MySQL
<Radar>
elemenopy: use the mysql2 gem
<sevenseacat>
or just not chain things because it doesnt really make sense here.
<Yanik>
Radar: i thought strings were objects
<Radar>
elemenopy: Or you could go one level higher and use the sequel gem
<Radar>
Yanik: strings are objects. Those types of objects don't have the methods that you're expecting them to have.
<Yanik>
this is so confusing...
<Yanik>
i'm going to need a lot more practice
<elemenopy>
can i (from a single ruby file) insert data into MySQL? either through the use of gems or some other means?
<Radar>
Yanik: Can you fry a steak?
<Radar>
Yanik: Can you fry an apple?
<Yanik>
yeah
<Yanik>
that's easy
heftig_ is now known as heftig
<Radar>
Steak is good fried
<Yanik>
this is frying my brain :P
<Radar>
Apples are not good fried
<sevenseacat>
elemenopy: the sequel gem is really great for database manipulation.
<elemenopy>
perfect , thx again
<Radar>
Steak and apples are two different TYPES of food.
<elemenopy>
very helpful as usual
<Radar>
players and strings are different TYPES of Ruby objects.
jonr22 has quit [Remote host closed the connection]
tlarevo_ has quit [Ping timeout: 244 seconds]
<Radar>
Yanik: The only things that respond to a TYPE's methods in Ruby is instances of that TYPE or subclasses of that TYPE
<Yanik>
but what if the player needs to know a message?
<Radar>
what kind of message>?
<sevenseacat>
i suck at explaining this really low-level stuff.
<Yanik>
like a stutus
<Radar>
Yanik: Shouldn't that message just be output?
<Radar>
Yanik: Which you can do with the puts method?
<Yanik>
i wish i was as good as you guys :(
<Yanik>
puts player2.rank_up.say_hello
<Yanik>
?
davasaurous has quit [Remote host closed the connection]
Cache_Money has joined #ruby
<Radar>
noooo
<Yanik>
that's what i thought i was doing with that, but i guess it's not how it works, i appreciate you guys trying to help and i'm sorry i'm not understanding this stuff
<Radar>
putting "self" on the last line of the method will return the Player instance
Synthead has joined #ruby
hephaestus_rg has joined #ruby
<hephaestus_rg>
i have a list of at least 4 things
<Yanik>
the course taught me self, but i didn't understand what they were talking about so i moved on to the next lesson because i didwell on the exercises
<hephaestus_rg>
and i want to select everything after the 3rd thing
<hephaestus_rg>
how do i do that
IceDragon has quit [Ping timeout: 245 seconds]
djbkd_ has quit [Quit: Leaving...]
xenomorph is now known as {xenomorph}
<Yanik>
thank you so much Radar and sevenseacat
<hephaestus_rg>
is there a slice like array[3:] or something
<Yanik>
i really appreciate your help1
<Radar>
Yanik: Do you understand now? :)
<Yanik>
kinda
<Radar>
hephaestus_rg: did you try array[3:]?
<Yanik>
i do understand that i need to fully understand how self works
<Radar>
Actually I think that's Go that I'm thinking of.
<Radar>
Areessell_: Do you see why Base64 is bad now?
<Areessell_>
Sure do. I'm a dummy.
<Radar>
Areessell_: Not a dummy, just likely that you didn't know any better.
<Areessell_>
Definitely.
jasooon has quit [Ping timeout: 245 seconds]
<Blizzy>
so basically, I would hash the password, save it to the database, then compare the value in the database to the password the user entered?
<Radar>
Blizzy: Yes.
<Blizzy>
ok then. thanks, Radar.
<sevenseacat>
you would hash the value the user provided, and compare it to whats in the db.
mengu has quit [Ping timeout: 258 seconds]
<mdarby>
hash the password, save it, then upon login, hash the submitted password and see that it matches the DB version
<sevenseacat>
if they match, then its the same password.
<Blizzy>
thanks mdarby and sevenseacat. :P
<sevenseacat>
yw
drPoggs has quit [Ping timeout: 256 seconds]
<mdarby>
:)
ARCADIVS has joined #ruby
<mdarby>
Also note that bcrypt is by default slow(er), and will increase in slowness based on the level of hashing. FWIW 10 is average for passes?
elliotlarson has joined #ruby
<mdarby>
nothing too crazy, but a bit of a heads up
<Blizzy>
thxs again, mdarby. :P
graydot has joined #ruby
levity_island has joined #ruby
frozon has joined #ruby
mdarby has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
echevemaster has quit [Quit: WeeChat 1.0.1]
echevemaster has joined #ruby
echevemaster has quit [Changing host]
echevemaster has joined #ruby
elliotlarson has quit [Quit: WeeChat 1.0.1]
graydot has quit [Client Quit]
zubov has quit [Quit: Bye Bye!]
jusmyth has joined #ruby
jusmyth has left #ruby [#ruby]
mistermocha has joined #ruby
jxf has quit [Quit: Leaving]
echevemaster has quit [Quit: WeeChat 1.0.1]
echevemaster has joined #ruby
echevemaster has quit [Changing host]
echevemaster has joined #ruby
TankC has joined #ruby
<TankC>
Hello!
<TankC>
Is there a way to expand a hash into keyword arguments expected by a function? I'm basically looking for the equivalent of python's "foo(**bar)"
Darryl_ has quit [Quit: Connection closed for inactivity]
<Areessell_>
Can you rephrase that?
levity_island has quit [Quit: levity_island]
<TankC>
Areessell_: Given foo = {"bar" => 1} and def "baz(bar: nil) puts bar end", I want to expand foo as the argument list for baz
echevemaster has quit [Quit: WeeChat 1.0.1]
echevemaster has joined #ruby
<TankC>
"def baz(bar: nil) puts bar end"
Cache_Money has quit [Quit: Cache_Money]
<Areessell_>
def baz(options={}); options['bar']; end
<Areessell_>
Something like that?
<TankC>
Areessell_: yes, but using the new-style keyword arguments
mostlybadfly has quit [Quit: Connection closed for inactivity]
<TankC>
arrays can be expanded using the "splat" operator but it seems hashes can not
<elemenopy>
ty fo rthe help, cya guys tomorrow!
elemenopy has quit [Quit: Leaving...]
<Areessell_>
You can. `def say(options); puts "Hello #{ options[:word] }!"; end` Then `say( word: 'World' )`
echevemaster has quit [Client Quit]
echevemaster has joined #ruby
<Areessell_>
The keyword style arguments are simply converted into a new Hash instance and passed as an argument.
<Areessell_>
I think.. I have answered incorrectly already today lol.
oo_ has quit [Remote host closed the connection]
echevemaster has quit [Client Quit]
echevemaster has joined #ruby
echevemaster has quit [Changing host]
echevemaster has joined #ruby
Yanik has quit [Ping timeout: 246 seconds]
<TankC>
Areessell_: Yeah.. but I guess what I'm getting at is that I can't declare the function as "def say(word: "World") puts "Hello #{word}!" end"
<Areessell_>
The merge line is what's known as a reverse merge. The Hash declared on that line is the defaults and the given argument is merged into it.
Takle has quit [Ping timeout: 260 seconds]
davedev24_ has quit []
SouL has joined #ruby
parabolize has quit [Quit: ERC Version 5.3 (IRC client for Emacs)]
psy_ has quit [Read error: No route to host]
psy_ has joined #ruby
rshetty has quit [Remote host closed the connection]
Channel6 has quit [Remote host closed the connection]
oo_ has joined #ruby
byprdct_ has joined #ruby
byprdct has quit [Ping timeout: 250 seconds]
JBreit has joined #ruby
pietr0 has joined #ruby
pietr0 has quit [Client Quit]
echevemaster has quit [Quit: WeeChat 1.0.1]
echevemaster has joined #ruby
linojon has joined #ruby
oo_ has quit [Ping timeout: 250 seconds]
terlar has joined #ruby
robbyoconnor has quit [Ping timeout: 244 seconds]
robbyoconnor has joined #ruby
dmyers has quit [Quit: Bye]
echevemaster has quit [Client Quit]
echevemaster has joined #ruby
jenrzzz has joined #ruby
TripTastic has joined #ruby
oleo has quit [Quit: Verlassend]
linojon_ has joined #ruby
JBreit has quit [Ping timeout: 256 seconds]
renderful has joined #ruby
linojon has quit [Ping timeout: 256 seconds]
linojon_ is now known as linojon
Boohbah has quit [Ping timeout: 246 seconds]
echevemaster has quit [Client Quit]
echevemaster has joined #ruby
Morkel has quit [Read error: Connection reset by peer]
SouL has quit [Ping timeout: 245 seconds]
arup_r has joined #ruby
msmith_ has joined #ruby
Gabri has joined #ruby
Morkel has joined #ruby
renderful has quit [Ping timeout: 255 seconds]
Boohbah has joined #ruby
o0oo0o has joined #ruby
jasooon has joined #ruby
alem0lars|away is now known as alem0lars
echevemaster has quit [Client Quit]
msmith_ has quit [Ping timeout: 244 seconds]
chipotle has quit [Quit: cya]
yfeldblum has joined #ruby
oo_ has joined #ruby
mistermocha has quit [Remote host closed the connection]
tvw has joined #ruby
jasooon has quit [Ping timeout: 265 seconds]
armyriad has quit [Ping timeout: 244 seconds]
drPoggs has joined #ruby
charliesome has quit [Quit: zzz]
armyriad has joined #ruby
TripTastic has quit [Ping timeout: 265 seconds]
skolman has quit [Remote host closed the connection]
abuzze has joined #ruby
mengu has joined #ruby
TripTastic has joined #ruby
Gabri has quit [Remote host closed the connection]
TripTastic is now known as JBreit2
drPoggs has quit [Ping timeout: 256 seconds]
armyriad has quit [Remote host closed the connection]
linojon has quit [Quit: linojon]
descala has quit [Ping timeout: 245 seconds]
weemsledeux has quit [Ping timeout: 265 seconds]
dseitz has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
razieliyo has quit [Ping timeout: 245 seconds]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
tagrudev has joined #ruby
oo_ has quit [Ping timeout: 240 seconds]
noop has joined #ruby
starkhalo has quit [Ping timeout: 258 seconds]
Synthead has quit [Remote host closed the connection]
gaaz has joined #ruby
skolman_ has joined #ruby
louism2wash has joined #ruby
skolman_ has quit [Remote host closed the connection]
weemsledeux has joined #ruby
abuzze_ has joined #ruby
timonv_ has joined #ruby
michael_mbp has quit [Excess Flood]
x1337807x has joined #ruby
abuzze has quit [Ping timeout: 265 seconds]
michael_mbp has joined #ruby
levity_island has joined #ruby
patric100e99 has joined #ruby
matrixise has quit [Remote host closed the connection]
rshetty has joined #ruby
last_staff has joined #ruby
klaut has joined #ruby
poulet_a has joined #ruby
anarang has joined #ruby
Macaveli has joined #ruby
govg has quit [Read error: Connection reset by peer]
patric100e99 has quit [Ping timeout: 245 seconds]
fr1eza has joined #ruby
jonr22 has joined #ruby
rshetty has quit [Remote host closed the connection]
NightMonkey has quit [Ping timeout: 244 seconds]
kp666 has joined #ruby
govg has joined #ruby
kamil has joined #ruby
NightMonkey has joined #ruby
shortCircuit__ has joined #ruby
emmesswhy has joined #ruby
jonr22 has quit [Ping timeout: 264 seconds]
timonv_ has quit [Read error: Connection reset by peer]
aganov has joined #ruby
weemsled_ has joined #ruby
dc_ has quit []
timonv_ has joined #ruby
weemsledeux has quit [Ping timeout: 265 seconds]
mchelen1 has quit [Ping timeout: 255 seconds]
bal has joined #ruby
keen_________ has quit [Read error: Connection reset by peer]
dc_ has joined #ruby
timonv_ has quit [Remote host closed the connection]
balazs has quit [Ping timeout: 258 seconds]
amundj has joined #ruby
keen_________ has joined #ruby
slawrence00 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
b1nd has quit [Ping timeout: 245 seconds]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
SouL has joined #ruby
emmesswhy has quit [Quit: Leaving]
tlarevo has quit [Ping timeout: 256 seconds]
end_guy has quit [Remote host closed the connection]
Boohbah_ has joined #ruby
end_guy has joined #ruby
dumdedum has joined #ruby
b1nd has joined #ruby
Boohbah has quit [Remote host closed the connection]
codecop has joined #ruby
x1337807x has joined #ruby
x1337807x has quit [Client Quit]
b1nd has quit [Max SendQ exceeded]
oo_ has joined #ruby
tlarevo has joined #ruby
poulet_a has quit [Remote host closed the connection]
b1nd has joined #ruby
mchelen has joined #ruby
gaaz has quit [Ping timeout: 246 seconds]
x1337807x has joined #ruby
weemsled_ is now known as weemsledeux
weemsledeux has quit [Changing host]
weemsledeux has joined #ruby
descala has joined #ruby
oo_ has quit [Ping timeout: 256 seconds]
b1nd has quit [Max SendQ exceeded]
b1nd has joined #ruby
lsmola has joined #ruby
luriv has joined #ruby
b1nd has quit [Ping timeout: 265 seconds]
jasooon has joined #ruby
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mchelen has quit [Ping timeout: 255 seconds]
b1nd has joined #ruby
charliesome has joined #ruby
drPoggs has joined #ruby
jasooon has quit [Ping timeout: 264 seconds]
Areessell_ has quit [Quit: (null)]
Morkel has quit [Quit: Morkel]
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
MrDoctor has quit [Remote host closed the connection]
drPoggs has quit [Ping timeout: 256 seconds]
MrDoctor has joined #ruby
cajone has left #ruby [#ruby]
rshetty has joined #ruby
Areessell_ has joined #ruby
fr1eza has quit []
jenrzzz has quit [Ping timeout: 265 seconds]
AndChat| has quit [Quit: Bye]
lkba has joined #ruby
jenrzzz has joined #ruby
olivier_bK has quit [Ping timeout: 256 seconds]
cajone has joined #ruby
andrewlio has joined #ruby
cmxu has joined #ruby
nacho-chips has joined #ruby
patteh has quit [Ping timeout: 245 seconds]
fabrice31 has joined #ruby
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Takle has joined #ruby
qba73 has joined #ruby
Takle has quit [Ping timeout: 264 seconds]
mityaz has joined #ruby
thsig has joined #ruby
oo_ has joined #ruby
JohnBat26 has joined #ruby
tlarevo_ has joined #ruby
tlarevo has quit [Ping timeout: 250 seconds]
francisfish has joined #ruby
CustosLimen has quit [Ping timeout: 256 seconds]
jheg has joined #ruby
oo_ has quit [Ping timeout: 258 seconds]
govg has quit [Quit: leaving]
andikr has joined #ruby
jenrzzz has quit [Ping timeout: 265 seconds]
davidhq has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
thsig has quit [Remote host closed the connection]
Juanchito has joined #ruby
decoponio has joined #ruby
oo_ has joined #ruby
francisfish has quit [Remote host closed the connection]
klaut has quit [Remote host closed the connection]
jsaak has joined #ruby
msmith_ has joined #ruby
oo_ has quit [Ping timeout: 260 seconds]
<dc_>
would it be faster to use filter or to use reduce and build up objects with transients/persistents?
<dc_>
woops, wrong channel
Dude007 has quit [Remote host closed the connection]
msmith_ has quit [Ping timeout: 245 seconds]
atraylen has joined #ruby
jarto has joined #ruby
Nahra has quit [Ping timeout: 265 seconds]
livathinos has joined #ruby
jarto has quit [Client Quit]
oo_ has joined #ruby
byprdct_ has quit []
Xeago has joined #ruby
shortCircuit__ is now known as supermanBlack
sk87 has joined #ruby
jusmyth1 has joined #ruby
bayed has joined #ruby
RitterJack has joined #ruby
sinkensabe has quit [Remote host closed the connection]
unshadow has joined #ruby
oo_ has quit [Ping timeout: 244 seconds]
<unshadow>
I want to load a string from a file and add veriables to it, I tried setting the string as "blabla#{my veriable}blabla" but ruby wont detect the #{} in the loaded string
jusmyth1 has quit [Ping timeout: 255 seconds]
jheg has quit [Quit: jheg]
jusmyth has joined #ruby
<j416>
unshadow: that's two problems in one, 1) read file, 2) replace contents of string
<canton7>
unshadow, nope, and it won't. there are some evil eval-y hacks you can do to get ruby to do that, but imo using erb in the file is better
<j416>
and 3) write file??
* j416
shrugs
jasooon has joined #ruby
CustosLimen has joined #ruby
<unshadow>
j416: only one problem, getting ruby to detect where to inject veriables in a string loaded from a file, I know how to 'read' the string... and write ?? where did you take that from ? only replaceing the #{} in the loaded string
patteh has joined #ruby
<unshadow>
canton7: thanks, I'll look into erb
ta_ has joined #ruby
olivier_bK has joined #ruby
ta has quit [Ping timeout: 250 seconds]
jusmyth has quit [Ping timeout: 255 seconds]
<tmoore>
unshadow: there's the sprintf approach too
<j416>
unshadow: your problem statement was ambiguous
<tmoore>
so if you use %{} instead of #{} then you can substitute values from a hash
drPoggs has joined #ruby
<j416>
unshadow: there is at least two problems 1) read file, 2) replace content of string
<tmoore>
at runtime
jasooon has quit [Ping timeout: 260 seconds]
rippa has joined #ruby
hamakn has quit [Remote host closed the connection]
psy_ has quit [Ping timeout: 244 seconds]
jusmyth has joined #ruby
hamakn has joined #ruby
<unshadow>
tmoore: this sound much more elegant of a solution then using erb, ill look into it, thanks
<j416>
unshadow: if your stringlooks like 'foo #{bar} baz' when you load it you still have to parse that safely
<j416>
unshadow: so a templating language might be more handy
einarj has joined #ruby
ta_ has quit [Read error: Connection reset by peer]
<j416>
unshadow: just evaluating 'foo #{bar} baz' is dangerous because #{bar} can contain _any_ ruby code
<j416>
not just a variable
danjordan has joined #ruby
sinkensabe has joined #ruby
<unshadow>
this is a great point j416, thanks I'll keep that in mind
<j416>
:)
<tmoore>
The %{} / sprintf solution doesn't have that problem, since it can only access what you pass in the hash, and can't evaluate arbitrary expressions
<j416>
yup
jusmyth has quit [Ping timeout: 264 seconds]
<j416>
good point that
jusmyth has joined #ruby
workmad3 has joined #ruby
nonks has quit [Ping timeout: 246 seconds]
<tmoore>
although you would need to watch out to escape any other sprintf formatting characters
<tmoore>
in the source text
visof has joined #ruby
Xeago_ has joined #ruby
jonr22 has joined #ruby
bigkevmcd has joined #ruby
davidhq has joined #ruby
alem0lars is now known as alem0lars|away
banisterfiend has quit [Read error: Connection reset by peer]
arup_r has quit [Remote host closed the connection]
Xeago has quit [Ping timeout: 256 seconds]
emmesswhy has joined #ruby
jonr22 has quit [Ping timeout: 255 seconds]
nonks has joined #ruby
davidhq has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<adac>
I currently get a pages html blob with mechanize like this: "blob = @agent.get('http://example.com').content" now this returns me ASCII-8BIT encoding. Any ideas on how to get UTF8 enconding back?
64MAAYGF9 has quit [Client Quit]
1JTAAVIF2 has quit [Client Quit]
dreamfighter has quit [Quit: Leaving]
ta has joined #ruby
VanillaGoat has joined #ruby
soasme has quit [Remote host closed the connection]
soasme has joined #ruby
anarang has quit [Quit: Leaving]
<elaptics>
adac: you can force the encoding on a string with #force_encoding
VanillaGoat_ has quit [Ping timeout: 255 seconds]
<arup_r>
elaptics: Any idea? How can I make it work?
braincrash has quit [Ping timeout: 244 seconds]
Takle has quit [Remote host closed the connection]
tlarevo_ has quit [Remote host closed the connection]
soasme has quit [Ping timeout: 265 seconds]
<shevy>
his secret underground network
<adac>
elaptics, I see aI can do it directly on the string
<apeiros>
adac: determine the proper encoding the document has (http headers, html head), String#force_encoding to set it to that, then String#encode to transcode it to utf-8
drawingthesun has quit [Ping timeout: 260 seconds]
<adac>
hmm is this a good idea? Can there nothing go wrong?
<apeiros>
elaptics: blind force_encoding is a bad advice.
<arup_r>
This is a JSON I see.. But I am writing a crawler.. where I need to crawl through the page... to get out data
shelling_ has joined #ruby
<apeiros>
adac: if you just blindly force_encode, you can end up with garbled data. the content must be valid utf-8 for just using force_encode to work
triple_b has joined #ruby
TinkerTyper has quit [Ping timeout: 265 seconds]
Zesty has joined #ruby
shazaum has quit [Quit: This computer has gone to sleep]
Takle has joined #ruby
<elaptics>
apeiros: yeah, planned to type more info - got sidetracked as I'm in the middle of running some updates for a client
<adac>
apeiros, I see. Hmm so my situation is: The sting/blob I get is according to "LOG.debug(blob.encoding)" ASCII-8BIT S
<elaptics>
but you basically added everything I was going to say :)
TinkerTyper has joined #ruby
<apeiros>
adac: ascii-8bit is an IMO bad name for "binary". as said, your first step is either knowing, or figuring, which encoding the content correctly should have.
_5kg has joined #ruby
<adac>
so now what do I need to do exactly again? "determine the proper encoding the document has" -> does this mean detect the strings encoding?
<elaptics>
adac: the site where you're requesting the data from - what's the encoding on the headers
<adac>
ok So I need to get the headers encoding
jbw has joined #ruby
<elaptics>
adac: e.g. if you open the page in a web browser and inspect the response headers what does that tell you
<apeiros>
adac: you don't need the headers encoding. you need the header which tells you content-type+encoding.
<apeiros>
but it doesn't always contain encoding. also it sometimes conflict with what the html part reports.
william3_ has joined #ruby
<apeiros>
and if you find all of this very finicky - yes, it is.
<adac>
Ok so, lets make an example, with http header plgun of firefox I determined that the page I fetch with mechanize has "Content-Type: text/html; charset=utf-8
<adac>
". So now what is the next step, knowing the content type and the charset?
<apeiros>
force_encode('utf-8')
<apeiros>
and since that's already the target encoding, no further step is required.
<adac>
apeiros, and if the page would show another content type/ enconding?
benzrf|offline is now known as benzrf
<adac>
what would be the steps then?
jottr has quit [Ping timeout: 258 seconds]
<apeiros>
if you had "Content-Type: text/html; charset=iso8859-1", then: content = content.force_encoding('iso-8859-1').encode('utf-8')
<adac>
apeiros, now I see! Thank you very much!
<adac>
elaptics, also to you mate, thanks a lot!
jasooon has quit [Ping timeout: 265 seconds]
<apeiros>
however, note that: a) header and html can have conflicting information, b) both header and html may tell you it's encoding X, but the content is not valid in encoding X
jimbach has quit [Remote host closed the connection]
<adac>
apeiros, oh wow that would be bad
<elaptics>
adac: the usual sign of that is weird characters on the web page like squares
<apeiros>
e.g. your website might tell you it's utf-8, yet contain byte sequences which are invalid in utf-8. populare examples: pages with user generated content which don't properly sanitize and thus embedd e.g. iso-8859-1 without converting first.
<apeiros>
adac: it is bad. the situation is rather horrible. it's a potpourri of utter bullshit :-(
<elaptics>
it's especially bad when you have user generated content that is added to a database which is encoded differently
<jhass>
all just because people like shevy refuse to use utf-8 by default :P
<apeiros>
with encodings like utf-8, you have a chance to spot it, using .valid_encoding?. but with e.g. windows-1252 or mac-roman, you have very little chance since those are binary encodings where every byte is valid.
mgorbach has quit [Ping timeout: 256 seconds]
oo_ has quit [Remote host closed the connection]
rylev has joined #ruby
<apeiros>
lets face it: coders suck at encodings. they suck at planning for encodings. and they fail at sanitizing.
oo_ has joined #ruby
MrDoctor has quit [Ping timeout: 245 seconds]
ndrei has quit [Ping timeout: 244 seconds]
psy_ has joined #ruby
ndrei_ has quit [Ping timeout: 260 seconds]
mgorbach has joined #ruby
benzrf is now known as benzrf|offline
soasme has quit [Remote host closed the connection]
phutchins has joined #ruby
oo_ has quit [Ping timeout: 244 seconds]
tier has joined #ruby
jenrzzz has joined #ruby
<shevy>
21 September 2014: <jhass> meh, still unicode is still broken
<jhass>
shevy: still out of context
sinkensabe has quit [Remote host closed the connection]
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jbw has quit [Ping timeout: 256 seconds]
jenrzzz has quit [Ping timeout: 264 seconds]
arya_ching has joined #ruby
shelling_ is now known as shelling
avril14th has quit [Remote host closed the connection]
<hanmac1>
02 November 2014: <shevy> still out of context
mdarby has joined #ruby
moritzs has joined #ruby
yfeldblum has joined #ruby
<shevy>
wat
<shevy>
ok
<shevy>
let me find a hanmac quote
alem0lars|away is now known as alem0lars
mrfoto has quit []
yfeldblum has quit [Ping timeout: 272 seconds]
it0a has joined #ruby
supermanBlack has quit [Remote host closed the connection]
Timgauthier is now known as timgauthier_away
devdazed has quit [Quit: Computer has gone to sleep.]
sinkensabe has joined #ruby
timgauthier_away has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
bmurt has joined #ruby
rshetty has joined #ruby
arup_r has quit [Remote host closed the connection]
arya_ching has quit []
rismoney1 has joined #ruby
enebo has joined #ruby
sailias has joined #ruby
jbw has joined #ruby
adriancb has joined #ruby
linojon has joined #ruby
jimbach has joined #ruby
_maes_ has joined #ruby
jhwhite has joined #ruby
tier_ has joined #ruby
danfried has quit [Quit: WeeChat 0.4.2]
ldnunes has quit [Ping timeout: 256 seconds]
jonr22 has joined #ruby
tier has quit [Ping timeout: 272 seconds]
msmith_ has joined #ruby
zorak8 has joined #ruby
zorak8 has quit [Max SendQ exceeded]
<shevy>
damn hanmac1
<shevy>
I can't find a memorable quote from you
zorak8 has joined #ruby
IceDragon has joined #ruby
msmith_ has quit [Client Quit]
oo_ has joined #ruby
msmith_ has joined #ruby
kaspergrubbe has joined #ruby
jonr22 has quit [Ping timeout: 244 seconds]
kaspergr_ has quit [Read error: Connection reset by peer]
tier_ has quit [Remote host closed the connection]
nonks has quit [Remote host closed the connection]
tier has joined #ruby
jzinedine has joined #ruby
<shevy>
you people need to become funnier so I can collect more quotes from you
<pontiki>
you just need to get better at recognizing humour
oo_ has quit [Ping timeout: 260 seconds]
razieliyo has joined #ruby
allcentury has joined #ruby
o0oo0o has joined #ruby
Hightower666 has quit [Read error: Connection reset by peer]
psy_ has quit [Read error: Connection reset by peer]
Avahey has joined #ruby
sk87 has joined #ruby
renderful has joined #ruby
blenny has quit [Ping timeout: 245 seconds]
jottr has joined #ruby
jottr has quit [Client Quit]
jottr has joined #ruby
tier_ has joined #ruby
kamil has joined #ruby
vyorkin has joined #ruby
o0oo0o has quit [Ping timeout: 246 seconds]
tier_ has quit [Remote host closed the connection]
moritzs has quit [Remote host closed the connection]
tier has quit [Read error: Connection reset by peer]
blenny has joined #ruby
tier has joined #ruby
niKeITA has joined #ruby
willywos has joined #ruby
<niKeITA>
hi
<shevy>
hi niKeITA
Alina-malina has quit [Ping timeout: 255 seconds]
renderful has quit [Ping timeout: 255 seconds]
beef-wellington has joined #ruby
<niKeITA>
i would you rewrite this: parse if @feeds && @feeds.entries.any?
<canton7>
rewrite how?
<shevy>
well you check two conditions here
Alina-malina has joined #ruby
<niKeITA>
shevy, yes
<shevy>
you could write a method that checks for both
moritzs has joined #ruby
<shevy>
but the original logic can not become much smaller unless you find a way to eliminate at least one of those requirements
<niKeITA>
the first one shortcut to avoid nomethod in case there is no @feeds
droidburgundy has joined #ruby
Channel6 has joined #ruby
iamjarvo has joined #ruby
<shevy>
yeah, that is what people usually do when they use &&
<shevy>
exit if game_over? and player_is_frustrated?
<elaptics>
@feeds.try(:entries).any?
<shevy>
exit if @game_over and @player_is_frustrated
lw has quit [Quit: s]
<niKeITA>
i was think of : parse if @feeds.entries.try(:any?)
<shevy>
what is .try?
<niKeITA>
assuming htere is entries for a feed
<elaptics>
niKeITA: that's no good if @feeds itself is nil
<niKeITA>
then shoud go this way: parse if @feeds.try(:entries).try(:any?)
iamjarvo has quit [Client Quit]
<niKeITA>
but the i prefere the first one with &&
<elaptics>
niKeITA: if you can guarantee that @feeds is not nil and is a feed object then there'd be no need to test for @feeds in the first place
SqREL has joined #ruby
<niKeITA>
cannot guarantee, @feeds object is returned from a service
momomomomo has quit [Quit: momomomomo]
jimbach has quit [Remote host closed the connection]
<niKeITA>
shey, try method Invokes the public method whose name goes as first argument just like public_send does, except that if the receiver does not respond to it the call returns nil rather than raising an exception.
<Fire-Dragon-DoL>
how SEXY is ruby! There is no other definition. When you watch a woman you can clearly says if it's sexy or not. Same goes for ruby, when you watch it, you can clearly say it's sexy
<niKeITA>
shevy
jimbach has joined #ruby
krz has joined #ruby
<jhass>
shevy: ActiveSupport magic
oo_ has joined #ruby
sepp2k has joined #ruby
dblessing has joined #ruby
<niKeITA>
jhass, i think that try method is not an ActiveSupport magic but it belong to Object
<jhass>
niKeITA: You think wrong
<jhass>
it's added to Object and NilClass by ActiveSupport
havenwood has joined #ruby
<niKeITA>
try is defined on Object,
Alina-malina has quit [Ping timeout: 244 seconds]
<niKeITA>
ah ok
<niKeITA>
np
<shevy>
k
<shevy>
Fire-Dragon-DoL are you a bot test
<Fire-Dragon-DoL>
shevy: nope! :P
<shevy>
k
<Fire-Dragon-DoL>
lol
davedev24_ has joined #ruby
<Fire-Dragon-DoL>
shevy: I'm just a happy ruby programmer, lol
<shevy>
that is good
jasooon has joined #ruby
_whitelogger has joined #ruby
<Areessell_>
That's how you'd read any file. Parsing the file on the other hand..
bigkevmcd has quit [Ping timeout: 264 seconds]
<Areessell_>
If the string is is plain ascii, then you should be able to just File.read. I would scan it, though.
<shevy>
you mean first read it in anyway or?
techminer has joined #ruby
<Areessell_>
Read from the file line by line.
davedev2_ has joined #ruby
davedev24_ has quit [Read error: Connection reset by peer]
<Areessell_>
Why load the whole thing into memory when you only need the first bit
<Areessell_>
File.open, then File.read line until it results in something containing /\/Count/,
freezey has joined #ruby
<Areessell_>
Once it finds that line, stop reading, parse out the digit.
<shevy>
page_analysis.pages.size # <-- like 50 pages
<shevy>
ok Areessell_
theotherstupidgu has quit [Quit: leaving]
<Areessell_>
Oh, right on.
<Areessell_>
All that work for nothing...
<Areessell_>
Just kidding =p I just wanted to see if it really was that easy.
oo_ has quit [Ping timeout: 256 seconds]
<Areessell_>
The only part I missed was it needed to be open with the binary mode.
<shevy>
well it was not necessarily for nothing
<shevy>
I would be content loading all into memory!!!
theotherstupidgu has joined #ruby
Takle_ has quit [Remote host closed the connection]
<Areessell_>
I found Prawn to be excellent at generating PDFs, but had horrible experiences parsing anything but text with it. This was about 3 years ago, though.
davedev2_ has quit [Read error: Connection reset by peer]
oleo has joined #ruby
davedev24_ has joined #ruby
<shevy>
hehe
<shevy>
yeah, I have had problems with it years ago too
robh71 has joined #ruby
<shevy>
lots of warnings were spit out onto the commandline due to another program
robh71 has quit [Max SendQ exceeded]
freezey has quit [Remote host closed the connection]
<shevy>
they fixed that since then, and I also found out that you can simply reassign to $VERBOSE or whatever it was... while ugly, at least it suppresses the warning messages, then I can restore the original setting again once it is all loaded
robh71 has joined #ruby
jobewan has joined #ruby
freezey has joined #ruby
<Areessell_>
Sounds like a bit of a headache
mostlybadfly has quit [Quit: Connection closed for inactivity]
pandaant has quit [Quit: Lost terminal]
rodfersou has quit [Read error: Connection reset by peer]
pandaant has joined #ruby
Timgauthier has joined #ruby
nateberkopec has quit [Quit: Leaving...]
Timgauthier is now known as timgauthier_away
rodfersou has joined #ruby
lolmaus has joined #ruby
krz has quit [Quit: WeeChat 1.0.1]
DivineEntity has joined #ruby
linojon has quit [Quit: linojon]
DaniG2k_ has joined #ruby
rylev_ has joined #ruby
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
mary5030 has quit [Remote host closed the connection]
ndrei has joined #ruby
<shevy>
do you run your .rb files with the -w switch?
DaniG2k has quit [Read error: Connection reset by peer]
<Areessell_>
I've been working in MRuby lately. I just completely wiped my macbook, copied my projects on, `cd`'d into my MRuby project, built it, and it just worked first try. It's a huge project too with database models and CLI/GUI interfaces... I change to a Rails project which is just a blog with Twitter Bootstrap.. Took me almost an hour and a half to hash out the problems to get it
<Areessell_>
running.
<Areessell_>
The only thing that sucks is I often have to remake my gems as MRuby gems.
adamholt has quit [Ping timeout: 260 seconds]
Morrolan has quit [Ping timeout: 260 seconds]
danshultz has quit [Ping timeout: 260 seconds]
mary5030 has joined #ruby
ndrei_ has joined #ruby
moritzs has joined #ruby
<Areessell_>
Naw.
gf3 has quit [Excess Flood]
<Areessell_>
I rarely run my ruby files directly.
gf3 has joined #ruby
sk87 has joined #ruby
Morrolan has joined #ruby
danshultz has joined #ruby
rylev has quit [Ping timeout: 255 seconds]
mattp_ has quit [Read error: Connection reset by peer]
<Areessell_>
I build every application as if it is a library, then I make an executable file that loads the library and runs the main loop. Or create a command line interface to the libraries methods.
mattp_ has joined #ruby
adamholt_ has joined #ruby
mengu has quit []
lkba has joined #ruby
mesamoo has joined #ruby
ursooperduper has joined #ruby
rkalfane has joined #ruby
iamjarvo has joined #ruby
ldnunes has joined #ruby
psy_ has joined #ruby
timgauthier_away has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Takle has joined #ruby
snath has quit [Ping timeout: 255 seconds]
gregf has joined #ruby
blenny has quit [Ping timeout: 256 seconds]
davedev24_ has quit [Ping timeout: 272 seconds]
sk87 has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
nateberkopec has joined #ruby
charliesome has quit [Quit: zzz]
tzero has joined #ruby
blenny has joined #ruby
benzrf|offline is now known as benzrf
chipotle has joined #ruby
sk87 has joined #ruby
davedev24_ has joined #ruby
arya_ching has joined #ruby
axl_ has joined #ruby
centrx has joined #ruby
niKeITA is now known as niKeITA_away
zorak8 has quit [Ping timeout: 256 seconds]
sevenseacat has quit [Quit: Leaving.]
anddam has joined #ruby
<anddam>
when called as regular user does gem only install stuff into user's directory?
lampd1 has quit []
gsd has joined #ruby
Boohbah_ has quit [Ping timeout: 246 seconds]
Boohbah has joined #ruby
panini has joined #ruby
PaulePanter has quit [Ping timeout: 250 seconds]
otherj has joined #ruby
<canton7>
anddam, depends. some distros set an option in .gemrc which forces this, I think by default it'll try and install system-wide and fail because of permissions
iamjarvo has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ohcibi has quit [Ping timeout: 260 seconds]
lest has quit [Ping timeout: 250 seconds]
ccooke has quit [Ping timeout: 245 seconds]
zly has quit [Ping timeout: 272 seconds]
drizz has quit [Ping timeout: 272 seconds]
caveat- has quit [Ping timeout: 260 seconds]
rikai has quit [Quit: No Ping reply in 180 seconds.]
end_guy has quit [Ping timeout: 246 seconds]
zly has joined #ruby
caveat- has joined #ruby
<anddam>
canton7: confirmed
ohcibi has joined #ruby
renderful has joined #ruby
<anddam>
I'll hit man/google to install as user, thanks
AkashicLegend has quit [Ping timeout: 246 seconds]
lest has joined #ruby
<canton7>
--user-install iirc
<canton7>
pass it to gem, or put it in .gemrc
iamjarvo has joined #ruby
Spami has quit [Quit: This computer has gone to sleep]
iamjarvo has quit [Client Quit]
AlHafoudh has quit [Ping timeout: 255 seconds]
jxf has joined #ruby
hanmac1 has quit [Quit: Leaving.]
vyorkin has quit [Read error: No route to host]
sonOfRa has quit [Ping timeout: 250 seconds]
parus has quit [Ping timeout: 258 seconds]
kalleth has quit [Read error: Connection reset by peer]
haasn has quit [Ping timeout: 250 seconds]
drkyro has joined #ruby
sonOfRa has joined #ruby
yano has quit [Read error: Connection reset by peer]
parus has joined #ruby
kalleth has joined #ruby
tagrudev has quit [Remote host closed the connection]
zB0hs has joined #ruby
noop has quit [Ping timeout: 265 seconds]
ccooke has joined #ruby
slawrence00 has joined #ruby
jasooon has joined #ruby
drizz has joined #ruby
Channel6 has quit [Quit: Leaving]
AlHafoudh has joined #ruby
jenrzzz has joined #ruby
rikai has joined #ruby
starkhalo has left #ruby ["WeeChat 1.1-dev"]
livathinos has quit [Remote host closed the connection]
gsd has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
PaulePanter has joined #ruby
<anddam>
installing, thanks again
benzrf is now known as benzrf|offline
<anddam>
gem help install, useful reading
DrCode has quit [Ping timeout: 246 seconds]
havenwood has quit [Ping timeout: 246 seconds]
benzrf|offline is now known as benzrf
vyorkin has joined #ruby
moritzs has quit [Ping timeout: 255 seconds]
jasooon has quit [Ping timeout: 256 seconds]
jenrzzz has quit [Ping timeout: 265 seconds]
benzrf is now known as benzrf|offline
haasn has joined #ruby
Boohbah has quit [Ping timeout: 246 seconds]
St_Marx has quit [Ping timeout: 246 seconds]
last_staff has quit [Remote host closed the connection]
moritzs has joined #ruby
snath has joined #ruby
rkalfane has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rikai has quit [Quit: No Ping reply in 180 seconds.]
otherj has quit [Quit: .]
rkalfane has joined #ruby
dkb20k has quit [Remote host closed the connection]
bal1 has quit [Quit: bal1]
livathinos has joined #ruby
mikepack has joined #ruby
Spami has joined #ruby
Spami has quit [Changing host]
Spami has joined #ruby
arya_ching has quit [Ping timeout: 264 seconds]
lmickh has joined #ruby
livathinos has quit [Client Quit]
rkalfane has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
aganov has quit [Remote host closed the connection]
apeiros has quit [Remote host closed the connection]
Macaveli has quit [Ping timeout: 265 seconds]
roolo has quit [Ping timeout: 272 seconds]
sinkensabe has quit [Remote host closed the connection]
<anddam>
see you
apeiros has joined #ruby
anddam has left #ruby ["WeeChat 1.0"]
Xeago has joined #ruby
Spami has quit [Client Quit]
jimmyhoughjr has joined #ruby
rostam has quit [Remote host closed the connection]
gmacka has joined #ruby
mikepack has quit []
sinkensabe has joined #ruby
oo_ has joined #ruby
thsig has quit [Remote host closed the connection]
roolo has joined #ruby
rostam has joined #ruby
mikepack has joined #ruby
mdarby has quit [Remote host closed the connection]
jfran has joined #ruby
mdarby has joined #ruby
apeiros has quit [Ping timeout: 264 seconds]
rikai has joined #ruby
SpaceKookie has quit [Ping timeout: 260 seconds]
WhereIsMySpoon_ has quit [Quit: No Ping reply in 180 seconds.]
<canton7>
2.1.3 learned how to parse merging strings, whereas 1.9.3 errors
chrishough has joined #ruby
louism2wash has joined #ruby
<canton7>
so something like 'default-df: *darker-grey works
thsig has quit [Remote host closed the connection]
<alem0lars>
yeah but if you also use anchors it won't
<canton7>
yeah
jasooon has joined #ruby
jenrzzz has joined #ruby
<alex86>
hey I have a design question...I am trying to construct a mirror of a page and update it every hour. Right now I am simply downloading the other page before my site loads in the same process, but its too slow and unreliable. So... (continuing)
tkuchiki has quit [Remote host closed the connection]
Rahul_Roy_ has joined #ruby
Bish_ is now known as Bish
shredding has joined #ruby
<alex86>
The two choices Im thinking of, are to use JavaScript to make a "loading" page that loads immediately while I load the actual mirror from the other site, or use Amazon Web Services to host a copy of the other site that I pull in the same process that loads my page
Alina-malina has joined #ruby
<twohlix>
alex86: its not really a mirror if you're loading the page everytime you hit your app, its a proxy.
<alex86>
Ok
terlar has quit [Ping timeout: 258 seconds]
<alex86>
Well its a thing that has to the show a copy of the other page, thats all :)
cpt_yossarian has quit [Ping timeout: 255 seconds]
<twohlix>
if you want a mirror, you duplicate once and serve from your app, every so often you check for changes. if theres a change, you swap out the old stuff to the new stuff
<twohlix>
okay.
robh71 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jenrzzz has quit [Ping timeout: 244 seconds]
michael_mbp has quit [Excess Flood]
michael_mbp has joined #ruby
spyderman4g63 has joined #ruby
jasooon has quit [Ping timeout: 244 seconds]
<alex86>
The thing is that I cant just simply use a proxy, because actually I am going to modify the page
spyderman4g63 has quit [Remote host closed the connection]
cndiv has joined #ruby
spyderman4g63 has joined #ruby
red_horned_rihno has quit [Ping timeout: 265 seconds]
red_horned_rihno has joined #ruby
moritzs has quit [Ping timeout: 264 seconds]
timonv_ has quit [Remote host closed the connection]
<twohlix>
alex86: so you dont want to load the page every time you hit your app
dseitz has joined #ruby
j_mcnally has joined #ruby
<twohlix>
alex86: you need to store it on your side, then modify it, then serve it up, and if your process runs for long periods of time you have to approach one of the harder problems in computer science: cache invalidation
mikecmpbll has quit [Quit: ciao.]
AlexRussia has quit [Ping timeout: 255 seconds]
Alina-malina has quit [Ping timeout: 256 seconds]
<alex86>
What I am thinking of maybe doing, because the page is pretty reliable, is loading every time I hit the app but just having a JavaScript thing that says "loading" so the user knows its loading. But with this solution, I dont understand how I know the page has actually loaded and maybe I need to use polling or something
treehug88 has joined #ruby
centrx has quit [Quit: The plan is programmed into every one of my one thousand robots]
spyderman4g63 has quit [Ping timeout: 245 seconds]
davidhq has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<alem0lars>
canton7, jhass, pontiki: I didn't found a way to do that... If you're interested I've added a temporary bad fix (but the only that I know) as a comment in https://gist.github.com/alem0lars/f5694ed5c2bd38e66388 ..
beneggett has joined #ruby
<canton7>
alem0lars, what you're trying to do isn't valid yaml
<canton7>
so it's no wonder that it doesn't do what you expect
<canton7>
<< is only for hashes, nothing more
<alem0lars>
canton7: oh.. not '<<:'
<alem0lars>
??
<canton7>
that works for hashes
<canton7>
you can't merge single values: it makes no sense
<canton7>
something like 'default-fg: *darker-grey' does what you want, except that it doesn't create a reference
tlarevo_ has joined #ruby
<canton7>
I'd expect 'default-fg: &default-fg\n *darker-grey' to work, but it doesn't
<twohlix>
alex86: just load some static html that defaults to "LOADING" being shown and use some javascript to hit your app and wait on teh results. No polling needed then
tier_ has joined #ruby
<twohlix>
it'll wait or timeout
chipotle has quit [Quit: cya]
<alem0lars>
canton7: yeah, and apparently there isn't a simple way to fix that... I took a look at psych but it's a pain
patric100e99 has joined #ruby
Takle has quit [Remote host closed the connection]
<canton7>
yeah - that is a pain :P
IceDragon has quit [Ping timeout: 240 seconds]
<canton7>
but I wouldn't rely on invalid yaml and hack around a weird implementation of that invalidness :P
<alem0lars>
canton7: yeah you're right..
beneggett has quit [Client Quit]
IceDragon has joined #ruby
fsapo has quit [Ping timeout: 256 seconds]
<alem0lars>
canton7: because in that way i'm exploiting a (in my opinion) bug: using '<<:' in that way should raise an exception
<canton7>
yeah, and it does under 1.9.3
einarj has quit [Remote host closed the connection]
<canton7>
your ruby version just thinks it's a hash key
tlarevo has quit [Ping timeout: 258 seconds]
tier has quit [Ping timeout: 245 seconds]
robh71 has joined #ruby
pauly_oc has joined #ruby
gnzh has quit [Ping timeout: 265 seconds]
DaniG2k_ has quit [Quit: Lost terminal]
patric100e99 has quit [Ping timeout: 255 seconds]
BadQuanta has joined #ruby
aspires has quit []
nyanz has quit []
aspires has joined #ruby
beneggett has joined #ruby
aspires has quit [Client Quit]
tier_ has quit [Remote host closed the connection]
helpa has quit [Remote host closed the connection]
helpa has joined #ruby
gsd has joined #ruby
alex88 has quit []
<alex86>
twohlix the page request to the other website though is happening on the server side, so I think for my JavaScript to know that this is complete, I need polling right?
tier has joined #ruby
<twohlix>
no, just make it wait on it
lsmola has quit [Ping timeout: 245 seconds]
b1nd has quit [Ping timeout: 255 seconds]
b1nd has joined #ruby
aspires has joined #ruby
benzrf|offline is now known as benzrf
bigkevmcd has quit [Ping timeout: 256 seconds]
andikr has quit [Remote host closed the connection]
<michael_mbp>
ah no CoreOS is a fabulous little kernel.
iamjarvo has joined #ruby
<michael_mbp>
you can build clusters in minutes
<michael_mbp>
and it's Docker first.
oo_ has joined #ruby
<michael_mbp>
any process you hand to the cluster will always be kept alive; if a node goes down, it'll automigrate that instance (being a container, it'll simply start it on a new node).
reinaldob has quit [Remote host closed the connection]
vyrus001 has quit [Ping timeout: 258 seconds]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
mistermocha has quit [Remote host closed the connection]
<rubie>
hi all: suppose you have an array length n, its sorted in acending order, how would you iterate over that list so that the first time around it iterates on every element, the second time around it starts on the second element and only iterates on every second element thereafter, then it moves to the third element and iterates over ever third element...
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<wallerdev>
two loops?
<rubie>
right
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<rubie>
but i can only get the faster loop to iterate by 1
reinaldob has quit [Remote host closed the connection]
claw___ has joined #ruby
<havenwood>
though, step_by
kireevco has joined #ruby
reinaldob has joined #ruby
claw__ has quit [Ping timeout: 264 seconds]
livingstn has joined #ruby
aspires has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
tlarevo has joined #ruby
chrishou_ has joined #ruby
benzrf|offline is now known as benzrf
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
chrishough has quit [Ping timeout: 245 seconds]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
matti has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<Hanmac>
havenwood: i would say, go for that: 10.times.map {|i| 10.downto(i + 1).to_a } or something ...
<Hanmac>
apeiros: spambot fiodoo
Hijiri has joined #ruby
yfeldblum has joined #ruby
reinaldob has joined #ruby
livingstn has quit [Ping timeout: 256 seconds]
wldcordeiro has joined #ruby
<benzrf>
Hanmac: grose
reinaldob has quit [Remote host closed the connection]
<graft>
can someone explain this one to me? I apparently don't know how to use Hash.new() properly... http://pastebin.com/CSjidAPu
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
thsig has quit []
<graft>
i seem to recall reading a nice post about this phenomenon, but i don't know why it happens or how to avoid it
lw has quit [Quit: s]
<jhass>
graft: use the block form
freezey has joined #ruby
claymore has quit [Quit: Leaving]
<havenwood>
Hash.new { |h, k| h[k] = [] }
aspires has quit []
rkalfane has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
reinaldob has joined #ruby
<jhass>
passing it as an arg will always use the _same_ object, it doesn't #dup it
<graft>
jhass: okay, i think i can see that, but why doesn't it show up in the parent hash at least?
momomomomo has joined #ruby
shredding has joined #ruby
g0bl1n has quit [Quit: g0bl1n]
sinkensabe has joined #ruby
aspires has joined #ruby
reinaldob has quit [Remote host closed the connection]
<graft>
i guess i never assign it anywhere, can't avoid that
<jhass>
Hash#default is just returned, not automatically assigned to the hash
skolman has quit [Remote host closed the connection]
<jhass>
*to the key
dANO_ has quit []
reinaldob has joined #ruby
livingstn has joined #ruby
aspires has quit [Client Quit]
yfeldblum has quit [Ping timeout: 240 seconds]
reinaldob has quit [Remote host closed the connection]
TPBallbag has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
g0bl1n has joined #ruby
niKeITA is now known as niKeITA_away
klaut_ has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
rubie has quit [Quit: Page closed]
chrishou_ has quit [Ping timeout: 272 seconds]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<jhass>
think about the behavior if you don't set a default or default_proc
<jhass>
then the default is nil
<jhass>
you wouldn't want every key access to create the key in the hash with nil assigned
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
olivier_bK has quit [Ping timeout: 264 seconds]
chrishough has joined #ruby
aspires has joined #ruby
failshell has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
sinkensabe has quit [Ping timeout: 255 seconds]
klaut has quit [Ping timeout: 255 seconds]
lolmaus has quit [Quit: Konversation terminated!]
joelwallis has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
tier has quit [Read error: Connection reset by peer]
<joelwallis>
Hello everyone. I'm running Ruby through JRuby, installed by RVM. I need to install the Oracle driver on it. Does anyone can help me doing this?
reinaldob has joined #ruby
tier has joined #ruby
skolman_ has joined #ruby
<havenwood>
joelwallis: Oracle DatabasE?
reinaldob has quit [Remote host closed the connection]
lw has joined #ruby
<joelwallis>
havenwood yeah
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has quit [Remote host closed the connection]
<havenwood>
\o/
<headius>
havenwood: should be jdbc-oracle gem to go with sequel or whatever DB library you're using
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
jimms has quit []
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<pipework>
havenwood: Do I recall that you'll be at rubyconf?
<havenwood>
headius: aha, i've never actually used oracle :O
<havenwood>
pipework: Yup yup. Looking forward to going.
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
znst has joined #ruby
<joelwallis>
I'm not coding Ruby, just trying to run a server side project which runs on top of Java and Ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<znst>
how correct is using keyword arguments to a function like this: def obvious_total(subtotal:, tax:, discount:)
<pipework>
Jruby or java and ruby separately?
zz_jrhorn424 is now known as jrhorn424
niKeITA_away has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<joelwallis>
pipework sorry. jRuby
<joelwallis>
we use the Migrate of Rails to control database states. just that
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<joelwallis>
I'm trying to run rake db:migrate from the project, that runs on top of JRuby, but it can't find the Oracle driver
<headius>
znst: looks fine
BadQuanta1 has quit [Quit: Leaving.]
<headius>
joelwallis: `bundle install` should make sure all necessary libraries are installed
<headius>
from that same dir
<znst>
headius: thank you, needed a sanity check, only recently on ruby 2.*
adac has joined #ruby
<headius>
znst: yeah, that feature was my suggestion :-)
jonr22 has joined #ruby
<pipework>
`jruby -S bundle install` right?
BadQuanta has joined #ruby
<headius>
pipework: he may have jruby in PATH, but yes
<headius>
or rather he may be using rake etc installed in JRuby, so -S would not always be necessary
niKeITA has joined #ruby
<pipework>
headius: There's something I read about that I can't find. There was a switch that you could pass to JRuby so that the command passed after was already ran in the context of the bundler bundle.
<pipework>
So rather than -S bundle exec <command>, it was -<something> <command>, right?
ClarusCogitatio has quit [Ping timeout: 272 seconds]
<headius>
-G
<headius>
it doesn't do the full process isolation or subshell env setup, but it will load Gemfile before RubyGems
<headius>
that's the biggest piece of bundle exec
reinaldob has joined #ruby
<znst>
headius: nice suggestion, glad to see keyword arguments implemented
skolman_ has quit [Remote host closed the connection]
crack_user has joined #ruby
<crack_user>
hello guys
<crack_user>
I try to made I deploy but when I run bundle install I get " Could not find rake-10.3.2 in any of the sources"
rshetty has joined #ruby
reinaldob has quit [Remote host closed the connection]
rkalfane has joined #ruby
noop has quit [Ping timeout: 255 seconds]
BTRE has quit [Quit: Leaving]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
jonr22 has quit [Ping timeout: 255 seconds]
jasooon has joined #ruby
shosti has joined #ruby
<pipework>
headius: Ah, Gemfile is the pneumonic. Thank you sir.
ClarusCogitatio has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
tier_ has joined #ruby
zB0hs has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
tier_ has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
tier_ has joined #ruby
tier has quit [Read error: Connection reset by peer]
rshetty has quit [Ping timeout: 240 seconds]
ndrei has joined #ruby
ndrei_ has joined #ruby
graft has quit [Ping timeout: 272 seconds]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<havenwood>
crack_user: Paste a Gist showing your Gemfile?
<apeiros>
Hanmac: thx
reinaldob has joined #ruby
josephndenton has joined #ruby
<crack_user>
I just fixed that, havenwood, thx :D
fiodoo was kicked from #ruby by apeiros [no spam.]
fiodoo has joined #ruby
josephndenton has left #ruby [#ruby]
fiodoo was banned on #ruby by apeiros [*!*@240.Red-2-138-160.dynamicIP.rima-tde.net]
fiodoo was kicked from #ruby by apeiros [no spam.]
<jhass>
oh, policy change?
<apeiros>
it's a bit of a windmill fight. but well…
fabrice31 has joined #ruby
jasooon has quit [Ping timeout: 264 seconds]
reinaldob has quit [Remote host closed the connection]
Darryl_ has quit [Quit: Connection closed for inactivity]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
jshultz has joined #ruby
chrishough has quit [Ping timeout: 255 seconds]
maestrojed has joined #ruby
jenrzzz has quit [Ping timeout: 245 seconds]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
Rahul_Roy_ has quit [Quit: Connection closed for inactivity]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
xorax has joined #ruby
drocsid has joined #ruby
robbyoconnor has quit [Read error: Connection reset by peer]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
mumm_ra has joined #ruby
chrishough has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
lw has quit [Quit: s]
gsd has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
josephndenton has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
tier has joined #ruby
fabrice31 has quit [Ping timeout: 264 seconds]
aclearma_ has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
jrhorn424 is now known as zz_jrhorn424
<josephndenton>
Hullo
gsd has joined #ruby
zz_jrhorn424 is now known as jrhorn424
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
earfin has joined #ruby
<jhass>
hollu
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
red_horned_rihno has quit [Ping timeout: 258 seconds]
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
aclearman037 has quit [Ping timeout: 244 seconds]
<pipework>
hollabackgurl
reinaldob has joined #ruby
rodfersou has quit [Quit: leaving]
jrhorn424 is now known as zz_jrhorn424
levity_island has quit [Read error: Connection reset by peer]
bauruine_ has joined #ruby
tuelz has joined #ruby
zB0hs has joined #ruby
tier_ has quit [Ping timeout: 265 seconds]
JBreit has joined #ruby
josephndenton has quit [Quit: leaving]
zB0hs has quit [Read error: Connection reset by peer]
<louism2wash>
hey guys, I am trying to write an integration test for a script that reads data from STDIN, performs operations on that data, and then writes the result to STDOUT. The test I have linked fails saying that STDIN receives the read method 0 times when it expects to receive it once. Any help would be greatly appreciated. Thanks. https://gist.github.com/louism2/2a83e88eedffd8c38824
reinaldob has quit [Remote host closed the connection]
zz_jrhorn424 is now known as jrhorn424
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
JBreit has left #ruby [#ruby]
oo_ has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
elaptics is now known as elaptics`away
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
SolarSailor has quit [Ping timeout: 245 seconds]
reinaldob has joined #ruby
jrhorn424 is now known as zz_jrhorn424
kireevco has quit [Quit: Leaving.]
reinaldob has quit [Remote host closed the connection]
kireevco has joined #ruby
kireevco has quit [Client Quit]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
kireevco has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
Tricon_ has quit [Remote host closed the connection]
end_guy has joined #ruby
kireevco has quit [Client Quit]
ARCADIVS has quit [Quit: ARCADIVS]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
kireevco has joined #ruby
chrishough has quit [Ping timeout: 265 seconds]
zz_jrhorn424 is now known as jrhorn424
kireevco has quit [Client Quit]
reinaldob has joined #ruby
momomomomo has quit [Ping timeout: 240 seconds]
reinaldob has quit [Remote host closed the connection]
aspires has quit []
kireevco has joined #ruby
oo_ has quit [Ping timeout: 256 seconds]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
kireevco has quit [Client Quit]
rkalfane has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
reinaldob has joined #ruby
momomomomo has joined #ruby
reinaldob has quit [Remote host closed the connection]
jamto11 has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
olivier_bK has joined #ruby
tier has quit [Remote host closed the connection]
aspires has joined #ruby
josephndenton has joined #ruby
reinaldob has joined #ruby
freerobby has quit [Quit: Leaving.]
reinaldob has quit [Remote host closed the connection]
freerobby has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
Musashi007 has quit [Quit: Musashi007]
<shevy>
yay!
<shevy>
down with the spambots!
jimms has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
bauruine_ has quit [Ping timeout: 265 seconds]
chrishough has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has quit [Remote host closed the connection]
<shevy>
I am just chatty
<soahccc>
Hmm can I use pry with a script which is using readline? It works generally but pry doesn't revert readline settings after the session ends (history, completion procs, etc.).
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
benzrf is now known as benzrf|offline
bklane has quit [Remote host closed the connection]
nerium has joined #ruby
<nerium>
Is there a fast way of converting a string from hex to int?
luckyruby has quit [Ping timeout: 255 seconds]
<jhass>
nerium: .to_i(16)
_2easy has quit [Quit: leaving]
adac has quit [Ping timeout: 255 seconds]
<nerium>
jhass: That one is flow
<nerium>
*slow
<gr33n7007h>
nerium, .hex
<jhass>
and .unpack
<jhass>
doubt any of these is faster
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
gmacka has joined #ruby
jamto11 has quit [Remote host closed the connection]
reinaldob has joined #ruby
wallerdev has quit [Quit: wallerdev]
tier has joined #ruby
<havenwood>
nerium: Need a sub-millisecond response? Doing millions of em? How long does it take overall? Just curious.
jenrzzz has joined #ruby
reinaldob has quit [Remote host closed the connection]
<shevy>
he is building facebook 2.0
<nerium>
havenwood: About 7 sec atm
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
yfeldblum has joined #ruby
<havenwood>
nerium: Massive string size or operations or both?
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<nerium>
havenwood: A big string
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
jamto11_ has joined #ruby
<havenwood>
nerium: we might be able to help optimize if you can Gist some code
auxbuss has joined #ruby
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
pauly_oc has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
reinaldob has joined #ruby
atmosx has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
djbkd has quit [Remote host closed the connection]
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
mdarby has quit [Max SendQ exceeded]
tkuchiki has quit [Ping timeout: 240 seconds]
louism2wash has quit [Quit: This computer has gone to sleep]
TPBallbag has quit [Remote host closed the connection]
jamto11 has joined #ruby
reinaldob has joined #ruby
mdarby has joined #ruby
reinaldob has quit [Remote host closed the connection]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
n_blownapart is now known as geezer
altamic has quit [Quit: altamic]
mdarby has quit [Max SendQ exceeded]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
redondos is now known as Guest50681
mdarby has joined #ruby
<geezer>
hi anyone have time to explain this recursion prog real quick? I forget how it works: http://pastie.org/9694075
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
<pipework>
geezer: It calls itself
rkalfane has joined #ruby
linojon has quit [Quit: linojon]
ghostmoth has quit [Quit: ghostmoth]
mdarby has quit [Max SendQ exceeded]
<geezer>
pipework: thanks, I'm *re*learning some programming after a few years. how does return work here?
sinkensa_ has quit [Read error: No route to host]
reinaldob has joined #ruby
reinaldob has quit [Remote host closed the connection]
mdarby has joined #ruby
<tuelz>
geezer: until a condition is true it repeats itself.
<pipework>
geezer: It returns early and prevents any further execution, making the value that was returned the value of the method.
sinkensabe has joined #ruby
jasooon has quit [Ping timeout: 272 seconds]
bricker`1ork has joined #ruby
djbkd has joined #ruby
jamto11 has quit [Ping timeout: 245 seconds]
mdarby has quit [Max SendQ exceeded]
<pontiki>
no, atmosx, the before block has to be *inside* a describe or context block
<pontiki>
and line 12 makes no sense at all
mdarby has joined #ruby
<geezer>
tuelz: pipework thanks I'm looking at it...staring at it.
linojon has joined #ruby
mdarby has quit [Max SendQ exceeded]
bricker`1ork is now known as bricker
Cheezebox has quit [Remote host closed the connection]
<pontiki>
atmosx: i still don't know why you are setting @user when you never use it, though
bricker`work has quit [Ping timeout: 258 seconds]
mikecmpbll has joined #ruby
mdarby has joined #ruby
klaut has joined #ruby
klaut_ has quit [Ping timeout: 245 seconds]
zz_jrhorn424 is now known as jrhorn424
<tuelz>
geezer: just think about a recursive loop like this. It's executing top to bottom, right? Well the last thing it does at the bottom is call a method. So the last thing it does is call a method. That method happens to be itself so it literally just pretends it's just using a new instance of that method. Remove the condition `if 1==n` thing and it'll loop forever until zues comes back to save us all
<tuelz>
geezer: return basically says IDGAF and leaves the loop, but you aren't returning unless you meet the condition
<pipework>
tuelz: what is this zues you speak of?
<tuelz>
pipework: do you have a moment to learn about thorsday and its significance to your insignificant mortal life?
<jenrzzz>
geezer: it might make more sense if you use an example that actually does something
<pipework>
tuelz: I've got Zeus for that.
<tuelz>
pipework: you'll be receiving pamplets in the mail shortly. You're welcome.
<pipework>
tuelz: Praise valhalla.
<geezer>
did you see valhalla rising?
<tuelz>
pipework: damnit, go back to nazi germany, you beautiful nordic man
<pipework>
D'aw. D:
fmcgeough has quit [Quit: fmcgeough]
skolman has joined #ruby
djbkd has quit [Ping timeout: 272 seconds]
<geezer>
jenrzzz: what sort of program would be more illustrative?
<tuelz>
geezer: if you still don't get it I just thought of a badass analogy to illustrate recursive loops
<atmosx>
pontiki: User needed to be created to run some tests. The thing that I was not able to use it before, probably something wrong with my syntax. Now I changed before's syntax and works though :-)
<geezer>
tuelz: excellent
<atmosx>
pontiki: heh ty
finisherr has joined #ruby
<finisherr>
Do all threads terminate when a script terminates?
Timgauthier has joined #ruby
josephndenton has quit [Quit: leaving]
shosti has quit [Ping timeout: 272 seconds]
<tuelz>
geezer: okay, you're picking your nose, and if you find a booger, you keep picking. The method here is nose_picking. So you start nose_picking and you finish nose_picking. Well, during nose_picking you met the condition, the condition was that you found a booger, so what do you do at the end of nose_picking?
josephndenton has joined #ruby
<geezer>
tuelz: pipework the first n remains 5 and is not reduced by 1 ?
<jenrzzz>
geezer: if you just add n to the recursive call, it will actually do what the name says it does
<havenwood>
finisherr: Yeah, all Threads belong to the default ThreadGroup and go poof.
<finisherr>
Ok. Good to know
<finisherr>
whew
<tuelz>
you call nose_picking again. You found another booger, so you call nose_pciking again. This time you didn't find a booger, so you return from nose_picking and gtfo
<geezer>
thanks jenrzzz looking at that
ghostmoth has joined #ruby
freerobby has joined #ruby
<tuelz>
meh, I'm pretty sure you were only confused about how n gets smaller in value and my nose_picking analogy didn't help at all, but it was still badass
TPBallbag has quit [Remote host closed the connection]
<finisherr>
For some reason this wasn’t happening last week
pietr0 has quit [Ping timeout: 264 seconds]
pietr0_ is now known as pietr0
pietr0 has quit [Remote host closed the connection]
5EXABF34A has joined #ruby
pietr0 has joined #ruby
<finisherr>
And it hangs when it gets to the second node it’s working on
<finisherr>
of 3
kireevco has joined #ruby
Wolland has joined #ruby
5EXABF34A has quit [Remote host closed the connection]
yfeldblum has joined #ruby
Wolland has quit [Read error: Connection reset by peer]
<jenrzzz>
finisherr: do you need a mutex to access return_status_array?
Wolland has joined #ruby
<jenrzzz>
finisherr: or maybe pass a timeout to thread#join?
max96at is now known as max96at|off
<finisherr>
Oh crap. So maybe both threads are trying to append the array?
<jenrzzz>
finisherr: in theory the GIL should make that work correctly but idk
<jenrzzz>
finisherr: to me it seems like a lot of magic is involved
<jenrzzz>
finisherr: are you running this on OS X?
ramfjord has joined #ruby
jrhorn424 is now known as zz_jrhorn424
<finisherr>
CentOS 6.4
zz_jrhorn424 is now known as jrhorn424
<jenrzzz>
bummer. dtrace could be handy here
<finisherr>
It’s so bizzare. It was working like a charm when I was testing the script last week
nerium has quit [Quit: nerium]
<jenrzzz>
same environment?
<finisherr>
Yep
<jenrzzz>
what version of ruby?
niKeITA_away is now known as niKeITA
<finisherr>
1.8.7
niKeITA has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rippa has quit [Read error: Connection reset by peer]
<jenrzzz>
ouch
<havenwood>
finisherr: Use a supported Ruby, 1.9.3+. I'm kinda distracted but you might consider whether there's a mutated object mid-each, which could be prevented with: threads.first.join until threads.empty?
rippa has joined #ruby
freerobby has quit [Quit: Leaving.]
aclearman037 has joined #ruby
<finisherr>
Don’t have control over the ruby version on this node unfortunately
aclearma_ has quit [Read error: Connection reset by peer]
<havenwood>
mm
sinkensabe has quit [Ping timeout: 256 seconds]
<jenrzzz>
finisherr: any particular reason you want to use threads here?
<finisherr>
I want to run these checks so the deployments are faster
<finisherr>
concurrently
olivier_bK has quit [Ping timeout: 256 seconds]
benzrf|offline is now known as benzrf
<jenrzzz>
they will never actually run concurrently on MRI ruby
<jenrzzz>
the slowest part is the HTTP request, right?
linojon has quit [Quit: linojon]
<finisherr>
Hmm
<havenwood>
jenrzzz: things run concurrently on MRI ;P
<finisherr>
I suppose I don’t need to use threading
<jenrzzz>
havenwood: yeah, but it's not the same as native threads
<jenrzzz>
havenwood: in my experience it usually won't give you much of a performance boost and makes things significantly more complicated
jrhorn424 is now known as zz_jrhorn424
renderful has quit [Remote host closed the connection]
<havenwood>
jenrzzz: i'm not suggesting it's a good idea to use threads, just that they're perfectly concurrent in MRI
mary5030 has joined #ruby
j_mcnally has joined #ruby
<havenwood>
jenrzzz: one Ruby thread is backed by one native, operating system thread
<jenrzzz>
havenwood: in 1.8.7?
<havenwood>
no, green threads
<havenwood>
jenrzzz: touche
<jenrzzz>
havenwood: hehehe. i was questioning myself too
<gsd>
we're on both of these - just not getting many great submissions.
<gsd>
assetavenue.com is our site
Hijiri has quit [Ping timeout: 265 seconds]
<havenwood>
toretore: yeah, i've re-implemented them. i was considering wrapping cognitect-labs' transsducers-ruby library too, since it's neat stuff but they don't accept pull requests.
<gsd>
jenrzzz: usually, they hate when people go there to try and recruit
<toretore>
man i am so sick of rusty
<gsd>
why don't you apply?
<gsd>
:D
<jenrzzz>
gsd: really? that's half the fun
<pipework>
gsd: I don't mind recruiting, I just dislike recruiting companies that show up to events.
<gsd>
interesting - so you think devs go specifically for the purpose of being recruited
<havenwood>
unless they bring pizza and beer**
<havenwood>
and don't talk*
<gsd>
ha
<pipework>
I don't show up to your events looking for a date, which reminds me do you have a sister?
<jenrzzz>
gsd: no, but if you are an interesting company or have interesting work, people will be interested
<gsd>
well, thankfully i'm an engineer myself and not a recruiter
nateberkopec has joined #ruby
<jenrzzz>
gsd: then you'll fit in :)
<gsd>
but i know from my own experience how annoying actual recruiters can be
<toretore>
engineers make the best recruiters
jrhorn424 is now known as zz_jrhorn424
<pipework>
gsd: Be not only open to remote developers, but be awesome at being a part of a distributed team, you'll have a better shot at getting some pretty awesome developers.
<toretore>
they know wtf they're actually looking for
Morkel has quit [Quit: Morkel]
<pipework>
toretore: They also know how to party. :D
<gsd>
we're about to close a $20M Series A and need engineers to help build out our real estate lending platform
<havenwood>
gsd: i haven't been lately but i've met some good people at Carbon Five high night in Santa Monica
<jenrzzz>
gsd: hmmm, I guess LA ruby is a bit more uptight about it than SD Ruby
zz_jrhorn424 is now known as jrhorn424
<toretore>
pipework: no party like a well-engineered party
<gsd>
pipework: that's good feedback
<pipework>
toretore: har har
<pipework>
:D
Hijiri has joined #ruby
freerobby has quit [Client Quit]
<havenwood>
/s/high/hack >.>
<toretore>
high night lol
<havenwood>
can't chock that up to dyslexia
freerobby has joined #ruby
<gsd>
there's a lot of opportunity here for the right engineer - we're basically going to be ramping up from a handful of engineers to dozens more in the next year
momomomomo has quit [Ping timeout: 256 seconds]
<gsd>
i suppose the other question i have is: what excites you guys the most about a new job opportunity? this will help me set us up to attract top engineers as well as keep them (culture is at the top of my personal list)
jrhorn424 is now known as zz_jrhorn424
<havenwood>
1% battery... buh bye
<jenrzzz>
kyle__: just call #unlink on the tempfile after calling Tempfile.new
mary5030 has quit [Remote host closed the connection]
zz_jrhorn424 is now known as jrhorn424
<toretore>
gsd: the work itself is very important
<pipework>
havenwood: Are transducers stateless?
mary5030 has joined #ruby
<havenwood>
pipework: no, not necessarily
<gsd>
toretore: tell me more
djbkd has joined #ruby
fabrice31 has joined #ruby
<pipework>
havenwood: interesting :D
<havenwood>
i need to find a place to plug in
<toretore>
gsd: what sort of work you'll be doing, how you'll be doing it, etc
<gsd>
if i told you that you'd be working on building a billion dollar crowdfunded lending platform - is that exciting
pabloh has quit [Quit: Saliendo]
havenwood has quit [Remote host closed the connection]
<toretore>
i mean more like the technical stuff
<gsd>
in a startup, it can be difficult to pitch what you'll be doing technically 6 months or a year from now
<toretore>
it's important to know what it's for though
<toretore>
sure
<jenrzzz>
gsd: are you excited about it?
<gsd>
fuck yea
<toretore>
one big one for me is the amount of freedom i'd be given to do stuff my way
<kyle__>
jenrzzz: Allright. I was just hoping there was some cleaner way people who programmed more than once a month knew about :)
<toretore>
and trust
<gsd>
i mean, i left a really great gig to join this company. we have adam chapnick, cofounder indiegogo
<kyle__>
Or once every three months, as things have been going lately for me.
<gsd>
we have so many great startup stars here - it helps that i also love real estate
yairgo has joined #ruby
momomomomo has joined #ruby
<gsd>
toretore: tell me more about trust - what do you mean?
jimmyhoughjr has quit [Quit: My Mac Mini has gone to sleep. ZZZzzz…]
<toretore>
gsd: if you trust me to do my job and that i know what i'm doing
<toretore>
trust in my decisions
<toretore>
aka don't tell me what to do
<gsd>
interesting
mistermocha has joined #ruby
<yairgo>
if I do resolver = Resolv::DNS.new; resolver.getaddress('google.com'); the result is not honoring my hosts file. Is there an easy way to make ruby check the hosts file for resolving dns entries before hitting a dns server?
<gsd>
i'm not sure i agree with just hiring engineers and letting them do whatever they want (if that's what you're saying)
<pipework>
Trust – Something you should have very little of.
timonv_ has joined #ruby
<toretore>
what i mean is it shouldn't be top-down decisions all the time
<jenrzzz>
yairgo: what OS are you on?
<yairgo>
redhat
<gsd>
you mean you want more input into product decisions or technical decisions or both
shosti has joined #ruby
<gsd>
because that's not really trust
chrishough has joined #ruby
mary5030 has quit [Remote host closed the connection]
<toretore>
but then again, i'm never going to be an employee as long as i can avoid it
<gsd>
that's something different
<gsd>
haha
<gsd>
fair
fabrice31 has quit [Ping timeout: 245 seconds]
<pipework>
gsd: I bet you'd get a lot of people's attention if, at the engineering level, you implemented a holacracy or meritocratic structure over a job-title hierarchy.
<pipework>
But that's a bit on the edgy side.
<jenrzzz>
yairgo: i think you need to use a Resolv::Hosts
chipotle has joined #ruby
<toretore>
gsd: i mean, tell me, in broad terms, what the goal is and trust me to make the technical decisions to best get there
<gsd>
being an engineer myself, i can recognize (or i'd like to think I can) great talent when it happens. in those cases, i ALWAYS try to find ways to give that person more and more responsiblity
<gsd>
smart people get bored quickly
<toretore>
might be different when you have an engineer as a manager
aspires has joined #ruby
aclearman037 has quit [Quit: I'm out!]
<yairgo>
jenrzzz: my problem is that using faraday to post to another computer I need to use an internal ip address instead of the external, I don't think I have access to that level
<yairgo>
jenrzzz: I was wondering if there is a goofy config setting somewhere
<yairgo>
jenrzzz: if I run ping on the machine it gives me the correct IP. I thought ruby would use the same ip that ping finds but apparently not
TinkerTyper has quit [Ping timeout: 260 seconds]
<jenrzzz>
access to what level? if you're using a Resolv::DNS instance, it will always ask the nameservers configured in resolv.conf
<toretore>
yairgo: a hack: `host example.com`
<jenrzzz>
if you want to have it do the right thing, just call the class #getaddress
<jenrzzz>
i.e: Resolv.getaddress('localhost')
jasooon has joined #ruby
paulfm has quit []
shredding has quit [Quit: shredding]
St_Marx has joined #ruby
m8 has quit [Quit: Sto andando via]
jhwhite has quit [Quit: jhwhite]
<gsd>
i am offering a $500 referral fee if someone refers me a great dev
supermanBlack has quit [Ping timeout: 245 seconds]
djbkd has quit [Remote host closed the connection]
willgorman has quit [Ping timeout: 240 seconds]
decoponyo has joined #ruby
jheg has quit [Quit: jheg]
renderful has joined #ruby
bmurt has quit []
spyderman4g63 has quit [Remote host closed the connection]
spyderman4g63 has joined #ruby
<pipework>
gsd: That's a bit on the low side of referral fees these days
dkphenom has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<pipework>
.Most recruiters offer between 1 iPad and $1000.
nyanz has joined #ruby
robbyoconnor has joined #ruby
<pipework>
Though I value iPads on the low end, because it takes effort to convert it back to cash.
znst has quit [Ping timeout: 244 seconds]
willgorman has joined #ruby
danman has quit [Quit: danman]
chudler has joined #ruby
JohnBat26 has quit [Ping timeout: 245 seconds]
decoponio has quit [Ping timeout: 255 seconds]
tier has quit [Remote host closed the connection]
auxbuss has quit [Quit: I'm gone.]
goodenough has joined #ruby
skolman has quit [Remote host closed the connection]
<gsd>
pipework: i personally haven't seen many companies offering a public referral fee like we are
tsunamie has quit [Ping timeout: 264 seconds]
<gsd>
most work through recruiters (which we are also doing)
<gsd>
or have internal referral programs that offer more, which we also do
spyderman4g63 has quit [Ping timeout: 255 seconds]
tsunamie has joined #ruby
tsunamie has quit [Max SendQ exceeded]
psyprus has quit [Read error: Connection reset by peer]
skolman_ has joined #ruby
djbkd has joined #ruby
psyprus has joined #ruby
failshell has quit []
<pipework>
gsd: Well, $500 is a bit of a really low referral fee compared to everything I've seen except for large corporations that also pay $250 for any patents an employee can procure.
momomomomo has quit [Quit: momomomomo]
timonv^ has joined #ruby
narcan has joined #ruby
claymore has quit [Quit: Leaving]
<geezer>
pipework: still wondering jenrzzz , does that recursion problem use a sort of container? i.e. where is the simple addition going on being stored?
<pipework>
gsd: It's not being stored, it's being passed into the recursive tail call.
tsunamie has joined #ruby
tsunamie has quit [Max SendQ exceeded]
djbkd has quit [Remote host closed the connection]
<jenrzzz>
geezer: on the stack
<chudler>
When in irb, I type class < A; def self.to_s; 'boo';end;end. Then I type A followed by newline. A.to_s is executed. My question is, what --if anything--- is executed inside of a normal script having the same?
<pipework>
jenrzzz: That's not really an important thing to note in ruby.
tsunamie has joined #ruby
<jenrzzz>
pipework: it is when you are trying to grok recursion
<geezer>
pipework: that is what is holding me up. I know its simple and I can do it in my head, but could you explain the stack in this case?
<pipework>
jenrzzz: Egh, not really.
<jenrzzz>
yeah, let me draw it
timonv_ has quit [Ping timeout: 272 seconds]
marr has quit [Ping timeout: 250 seconds]
<pipework>
geezer: You're getting a value and passing it into the next call of that method.
<pipework>
It does that until the return condition is met.
tsunamie has quit [Max SendQ exceeded]
djbkd has joined #ruby
<geezer>
but when the value returned is 3, the next round is (3-1)+3 is 5, not 6.
supermanBlack has joined #ruby
<geezer>
*which is
<pipework>
Can you link the source again?
jdj_dk has quit [Remote host closed the connection]
lmickh has quit [Remote host closed the connection]
Scotteh has quit [Ping timeout: 244 seconds]
zorak8 has joined #ruby
gmacka has joined #ruby
andrewlio has quit [Quit: Leaving.]
<pipework>
Notice the difference between your source, which just calls the method with n-1 and what jenrzzz wrote which has n + the method call with n - 1
<geezer>
a dude name creek has a video but it confused the sh*t out of me.
<pipework>
geezer: What other languages are you familiar with?
cassianoleal_ has joined #ruby
Squarepy has joined #ruby
Scotteh has joined #ruby
<geezer>
English, French seriously I'm teaching myself at a late age.
Azure has quit [Ping timeout: 258 seconds]
<geezer>
age 53
<jenrzzz>
nice
<pipework>
geezer: Is ruby your first programming language?
<geezer>
very kind of you. pipework It will sink in sometime today. I got it a couple years ago.
<jenrzzz>
chudler: nope. only irb/pry will call inspect on the output
e4xit has quit [Quit: Right I'm out!]
<jenrzzz>
chudler: when you just run it with the interpreter, it's a noop
<chudler>
And the interpreter will "optimize" my useless A out? I am writing a toy DSL where it could be useful ;-)
<jenrzzz>
chudler: though i think it will cause the script to return a truthy value (i.e. 0)
<geezer>
it's easier to see with a container pipework as per your example.
jrhorn424 is now known as zz_jrhorn424
<jenrzzz>
chudler: just calling a constant by name doesn't do anything. you'd need to define a method
<chudler>
I know it cannot be a complete noop, since maybe const_get is called?
<chudler>
oh nevermind, thats something else.
momomomomo has quit [Quit: momomomomo]
<jenrzzz>
chudler: hmmm. i'm actually not sure how the constant lookup works in that case. i don't think it's a noop since it actually results in a value
<jenrzzz>
but in that context, it doesn't do anything
timonv^ has quit [Remote host closed the connection]
<jenrzzz>
chudler: what are you trying to do?
<chudler>
I know it doesnt do anything, that is what I am trying to change. This is for my learning, nothing much else.
jamto11 has quit [Remote host closed the connection]
Alayde has joined #ruby
skolman_ has quit [Remote host closed the connection]
<Alayde>
I did a bit of Google searching and felt like I couldn't quite come up with what I wanted, figured I'd ask here. Anyone here have any tutorials handy for writing a really basic restful API using ruby?
bklane has quit [Remote host closed the connection]
bklane has joined #ruby
<jenrzzz>
Alayde: client or server?
<Alayde>
jenrzzz: Server.
beef-wellington has quit [Ping timeout: 264 seconds]
<jenrzzz>
Alayde: have you looked into sinatra or any other microframeworks?
chipotle has quit [Quit: cya]
shosti has quit [Ping timeout: 256 seconds]
supermanBlack has quit [Ping timeout: 264 seconds]
zz_jrhorn424 is now known as jrhorn424
djbkd has quit [Remote host closed the connection]
<jenrzzz>
chudler: what do you want it to do?
<geezer>
jenrzzz: I saw a book on sinatra.. do you think there are any good books on the subj?
<Alayde>
jenrzzz: I have, my plan was to use sinatra actually. I guess my brain just isn't connecting all the dots when it comes to writing an API, so I figured if there was a tutorial out there that kind of started at the most basic level and moved up, that'd be awesome
<chudler>
Ideally, I want to override the method it would call, no matter where it lies. Otherwise I will bark up another meta tree
<geezer>
I looked at padrino. but not much written on it..
ptrrr has quit [Quit: ptrrr]
djbkd has joined #ruby
Squarepy has quit [Quit: Leaving]
jrhorn424 is now known as zz_jrhorn424
allcentury has quit [Ping timeout: 245 seconds]
bklane has quit [Ping timeout: 264 seconds]
danman has joined #ruby
ptrrr has joined #ruby
<jenrzzz>
chudler: you can't override the default constant lookup behavior. you could override Object#const_get but that won't do what you want
djbkd has quit [Remote host closed the connection]
<jenrzzz>
chudler: since the identifier starts with a capital letter, ruby will always use its inbuilt constant lookup
DrCode has quit [Remote host closed the connection]
<jenrzzz>
geezer: it's not the most educational ruby book but definitely the most fun
<mdarby>
rubbish?
gmacka has quit [Ping timeout: 264 seconds]
<pipework>
mdarby: I haven't read through it just yet, but it's being pitched as something a company accepts money in order to teach you.
<zenspider>
I dunno the neo part, but the ruby koans are very good
TPBallbag has joined #ruby
<mdarby>
yeah, I haven't heard of pay-to-play from them
<geezer>
mdarby: the student asked 'what is zen?' the master said 'did you eat your porridge?' 'yes', said the student. 'then go wash out your bowl.'
gmacka has joined #ruby
<mdarby>
:)
djbkd has quit [Remote host closed the connection]
<mdarby>
It was the EdgeCase Ruby Koans, but then we were bought out
<pipework>
mdarby: I don't know if it's the same company, just some drivel on HN.
<mdarby>
ah, who knows. :)
jerius has quit []
alvaro_o has quit [Quit: Ex-Chat]
<zenspider>
oh ... I thought you meant someone forked it for a "new" version. :)
<zenspider>
right
<geezer>
the second one is 'neo'?
x1337807x has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<mdarby>
"rebranded" :)
<mdarby>
Yes. We were EdgeCase, then NewContext, then Neo
<mdarby>
Same core company; fast growth
<geezer>
worth looking at all of them?
<mdarby>
all the same thing really; just "who" wrote them.
govg has quit [Quit: leaving]
<geezer>
I have the sandi metz book. just started it ..again.
<josephndenton>
geezer: Definitely worth looking at. When I started learning, I finished the koans in a few hours after I finished reading Well Grounded Rubyist
<geezer>
josephndenton: yeah I read well-grounded 3 years ago. gotta brush off the dust..
tkuchiki has joined #ruby
S0da has quit [Read error: No route to host]
<zenspider>
the koans have fantastic pedagogy. very much recommend them for someone getting into ruby
djbkd has joined #ruby
<geezer>
zenspider: sweet
<geezer>
will do
<josephndenton>
geezer: Really though, the best thing to learn quickly isn't going to be reading, its going to be doing. Refresh the basics, then make something to automate a task or to make life easier.
djbkd has quit [Remote host closed the connection]
<jenrzzz>
geezer: yeah, highly recommend doing a project that is interesting/useful to you
tuelz has quit [Ping timeout: 272 seconds]
<jenrzzz>
geezer: learning for the sake of learning doesn't stick the same way
<geezer>
josephndenton: jenrzzz no clue how to begin. I have a linux machine.. I've been doing ssh and set up lamp on an instance.
<geezer>
vm ^
Azure has joined #ruby
<kyle__>
I still prefer learning it from an enranged and insane mountain hermit, where you can't tell if he really sees what he's raving about, or just using it to teach you.
<josephndenton>
geezer: Are you trying to do web stuff? or Ruby in general?
<kyle__>
Also known as, "why's poignent guide"
vlad_starkov has joined #ruby
jobewan has quit [Quit: Leaving]
<geezer>
I decided to get very good at a major oop lang.
<geezer>
kyle__: your first reference to mountain hermit was the koans?
<kyle__>
It gets you far enough to learn on your own, and tinker, even if it's compleetly ignoring what would be considered "good programming" style and habits.
<kyle__>
geezer: No, to why.
<pontiki>
that's _why to you
benzrf|offline is now known as benzrf
<geezer>
pontiki: was helping me with _why about a year ago.. kind soul.
<geezer>
I'll get it pontiki -- many thanks all.
jrhorn424 is now known as zz_jrhorn424
Spami has joined #ruby
Musashi007 has quit [Quit: Musashi007]
jasooon has quit [Ping timeout: 264 seconds]
Musashi007 has joined #ruby
Soda has quit [Remote host closed the connection]
badhatter has quit [Read error: Connection reset by peer]