<lewix>
I understand that the + method returns a new array whereas << return the original array changed. However, I don't see how it affect the the inject method when it's recalled' since string is a temporary variable
<lewix>
maletor has quit [Quit: Computer has gone to sleep.]
freeayu has quit [Quit: 离开]
idkazuma has joined #ruby
heliumsocket has quit [Quit: heliumsocket]
jamesfung14 has joined #ruby
sleetdrop has joined #ruby
kofno has quit [Ping timeout: 248 seconds]
lupinstein has quit [Ping timeout: 260 seconds]
<shevy>
lewix what?
johnnygoodmancpa has left #ruby [#ruby]
<shevy>
whereas << return the original array changed.
echobinary has joined #ruby
echobin10 has quit [Read error: Connection reset by peer]
<shevy>
<< just appends to the object referenced to by string, the variable
<shevy>
hmm
<shevy>
I am not sure if a new object is created there
kofno has joined #ruby
<lewix>
tchip
<shevy>
we need a smart person to answer that
<shevy>
is there?
robbyoconnor has quit [Ping timeout: 276 seconds]
<shevy>
I think there is!
robbyoconnor has joined #ruby
<lewix>
shevy: I know it appends to the object. I'm just saying when << is used to an array, it updates the array and returns it
pdamer has quit [Quit: pdamer]
palladium has joined #ruby
<palladium>
what up my peoples
sambao21 has quit [Ping timeout: 276 seconds]
<lewix>
the fact and the matter is every time the inject method is recalled (with {|string,name| string << name}) it seems that string acts like a local variable
elux has quit [Quit: Leaving...]
<lewix>
I mean out of the blockscope
maletor has joined #ruby
<lewix>
19:05 shevy: we need a smart person to answer that: lewix points back to shevy
<ryanf>
lewix: I'm not totally sure I understand the question
<ryanf>
"+" works because the point of inject is to take the return value and pass it into the block as string
palladium has quit [Read error: Connection reset by peer]
<ryanf>
"<<" works because it happens to return the string after modifying it
palladium has joined #ruby
crazymykl has quit [Remote host closed the connection]
crazymykl has joined #ruby
<lewix>
ryanf: no you don't understand the question.
<lewix>
ryanf: I'll try to rephrase it when I'm done eating
chrisnicola has joined #ruby
<lewix>
ryanf: basically create a string names, try to run names.inject {|string,name| string << name} many times over and see what happen. do the same thing with names.inject {|string,name| string + name} and see what happen
bonhoeffer has quit [Quit: bonhoeffer]
preller has quit [Ping timeout: 260 seconds]
<ryanf>
lewix: strings don't have an inject method. do you mean an array of strings?
<ryanf>
oh, I see
<ryanf>
it's because if you don't give an initial value to inject, it passes the first two elements of the array as string and name
<ryanf>
for the first iteration
<ryanf>
so when you use <<, it's mutating the first element of the array and passing it through the rest of the iterations
iamjarvo has quit [Quit: Leaving.]
pdamer has joined #ruby
hasimo has joined #ruby
altivec has quit [Read error: Operation timed out]
altivec has joined #ruby
chrisnicola has quit [Quit: Leaving]
banseljaj has quit [Ping timeout: 252 seconds]
tish has quit [Quit: Leaving.]
MikeH has quit [Ping timeout: 264 seconds]
xsdg has quit [Ping timeout: 248 seconds]
adamholt has quit [Ping timeout: 264 seconds]
peter1 has quit [Ping timeout: 248 seconds]
DrShoggoth has quit [Ping timeout: 248 seconds]
Phoop has quit [Ping timeout: 252 seconds]
mva3212 has quit [Ping timeout: 252 seconds]
jaimef has quit [Ping timeout: 252 seconds]
Rix has quit [Ping timeout: 252 seconds]
<aedornm>
I am out of hearts!
MikeH has joined #ruby
adamholt has joined #ruby
<shevy>
aedornm what does that mean
sambao21 has joined #ruby
jaimef has joined #ruby
sayan has joined #ruby
sayan has quit [Changing host]
sayan has joined #ruby
danman has joined #ruby
froy has quit [Ping timeout: 264 seconds]
xsdg has joined #ruby
Phoop has joined #ruby
<aedornm>
It means I have to try again! And again .. I'm doing language learning with duolingo.com
Guest36011 has quit [Ping timeout: 248 seconds]
slainer68 has joined #ruby
banseljaj has joined #ruby
DrShoggoth has joined #ruby
froy has joined #ruby
pdamer has quit [Quit: pdamer]
<shevy>
hehe
brandon_ has joined #ruby
peter1 has joined #ruby
idkazuma has quit [Remote host closed the connection]
<lewix>
ryanf: i guess you still don't understand my question
iamjarvo has joined #ruby
hasimo has quit [Ping timeout: 248 seconds]
uris has quit [Quit: Leaving]
<ryanf>
lewix: guess not
palladium has quit [Ping timeout: 255 seconds]
Takehiro has joined #ruby
fermuch has joined #ruby
<lewix>
ryanf: oh actually
<fermuch>
hey
<lewix>
ryanf: you answered
rvmeier has joined #ruby
Rix has joined #ruby
tish has joined #ruby
jmorton has joined #ruby
jmorton has left #ruby [#ruby]
agjacome has quit [Quit: leaving]
aed has joined #ruby
preller has joined #ruby
gommo has joined #ruby
akashj87 has joined #ruby
mva3212 has joined #ruby
<lewix>
ryanf: thanks. grr i always forget to think at the level of the individual elements
akashj87 has quit [Client Quit]
V8Energy has joined #ruby
<V8Energy>
i have a loop: 5.times do .....if condition.... end... end...
<V8Energy>
I would like to break the loop inside the if condition block
<V8Energy>
break didn't work
Nightmare has quit [Quit: DDoS has died, DDoS has risen, DDoS comin' again]
Nightmare has joined #ruby
<fermuch>
V8Energy: use return
<V8Energy>
won't return exit the method?
mmitchell has quit [Remote host closed the connection]
<fermuch>
oh, you're right
jarray52 has joined #ruby
IceDragon has quit [Ping timeout: 248 seconds]
<lewix>
V8Energy: paste the code
havenwood has quit [Remote host closed the connection]
<fermuch>
thecodethinker: you should give it a try :)
pdamer has joined #ruby
hasimo has joined #ruby
<waxjar>
give rbenv / chruby a look too, they're great tools as well
<aedornm>
I actually reloaded my laptop and started using chruby. Pretty nice when I need to test something against Rubinius (because everyone else uses JRuby and I like to rebel.)
<lewix>
lol
<waxjar>
rubinius has nice backtraces :p
<lewix>
what are your favorite ruby links to learn
<lewix>
aedornm: isn't it for the android
<fermuch>
talking about that, guys
Guest70723 has quit [Read error: Operation timed out]
hackeron has quit [Read error: Operation timed out]
<fermuch>
is it better to use ree at *these* days?
hackeron has joined #ruby
<aedornm>
lewix: no, you're thinking rubymotion, maybe...
fred has joined #ruby
<lewix>
aedornm: no
<lewix>
aedornm: rubymotion is for ios
<thecodethinker>
rvm looks cool
fred is now known as Guest94480
Drewch has quit [Ping timeout: 248 seconds]
<fermuch>
thecodethinker: I use it at my job. For example, we have some code with ruby 1.8
<fermuch>
but these days we're using 1.9
<aedornm>
oh, hmm... Rubinius is just a C++ rewrite
<fermuch>
so switching is easy-peasy
lusory has joined #ruby
<thecodethinker>
is there any advantages to rubinius? I saw a talk on it once
cespare has quit [Ping timeout: 248 seconds]
<aedornm>
Pretty sure you could just use jruby if you wanted to do something on Android though. Someone correct me if wrong
cespare has joined #ruby
xpen has quit [Ping timeout: 248 seconds]
hbpoison has quit [Ping timeout: 255 seconds]
Drewch has joined #ruby
<fermuch>
thecodethinker: I haven't tried, but I readed there's a lot of improvement with the memory manager
<thecodethinker>
I found ruboto for android
maletor has quit [Quit: Computer has gone to sleep.]
<fermuch>
aedornm: well, you can use Ruboto
<fermuch>
Ruboto is just a wrapper between android and jruby
<thecodethinker>
fermuch: can I get rubinius through rvm?
adeponte has joined #ruby
<fermuch>
thecodethinker: yes, you can
<aedornm>
ah. maybe one day I'll give up webOS and do something on Android, but Android just makes me angry =p
<fermuch>
aedornm: webOS... isn't that just HTML5?
hbpoison has joined #ruby
hasimo has quit [Ping timeout: 264 seconds]
echobinary has quit [Disconnected by services]
echobin90 has joined #ruby
<aedornm>
It's HTML5 and JS if you want to do something top layer.. (but then that got extracted as EnyoJS.)
eAlchemi_ has joined #ruby
emmanuelux has quit [Ping timeout: 248 seconds]
aapzak has quit [Ping timeout: 260 seconds]
<fermuch>
and what's the base language?
<fermuch>
talking about interpreters made me remember, you guys should try Opal
<fermuch>
it's a ruby-to-javascript compiler
mikepack has joined #ruby
<waxjar>
thecodethinker, rubinius allows you to run things in parallel (in threads), MRI Ruby only allows one thread to do something at once, with the exception of a few things (like network i/o)
<aedornm>
Really whatever you wanted, but the PDK was mostly C or C++
aapzak has joined #ruby
kn330 has quit [Ping timeout: 255 seconds]
eAlchemist has quit [Ping timeout: 255 seconds]
<thecodethinker>
waxjar: On the ruby-lang.org's about page it sats ruby has multithreading
<fermuch>
it has, but not _real_ multithreading
<fermuch>
ehrm
<fermuch>
1.8 doesn't have, but 1.9 has
kn330 has joined #ruby
<waxjar>
it's called the global interpreter lock, there have been quite a few articles written on it lately
IceDragon has joined #ruby
<waxjar>
it's not something to worry about, if you're just starting out though :)
<thecodethinker>
yeah
<waxjar>
but that's the main advantage of rubinius
radic has joined #ruby
<fermuch>
it's not _that_ blocking either
<fermuch>
neither **
sambao21 has joined #ruby
mneorr has quit [Remote host closed the connection]
<thecodethinker>
So ruby libraries are called gems
<thecodethinker>
?
<fermuch>
in some sort of way, yes
<thecodethinker>
or is that just a manager
<fermuch>
a gem is more like a package
hiroyuki_ has quit [Read error: Connection reset by peer]
radic_ has quit [Ping timeout: 260 seconds]
hasimo has joined #ruby
rvmeier has quit [Quit: Leaving]
atno has quit [Remote host closed the connection]
hasimo has quit [Remote host closed the connection]
sepp2k has quit [Remote host closed the connection]
io_syl has joined #ruby
generalissimo has quit [Remote host closed the connection]
sepp2k has joined #ruby
echobinary has quit [Read error: Connection reset by peer]
icole has quit [Remote host closed the connection]
echobinary has joined #ruby
hashmal has quit [Quit: Computer has gone to sleep.]
tealmage has joined #ruby
icole has joined #ruby
codecop has joined #ruby
mockra has joined #ruby
Xeago has joined #ruby
|Daz| has joined #ruby
<|Daz|>
Hello. Slightly off topic, but I'm currently looking at Capistrano as a potential solution for our deployments at work (it's for php projects). It all seems to be working up - but by default it symlinks the root of the release folder to my public_html directory. I can't figure out how to symlink the public_html directory to the public_html directory in the release folder. Google has been little
<|Daz|>
help - I was hoping someone could point me in the right direction?
tealmage has quit [Ping timeout: 248 seconds]
modelo8121 has joined #ruby
modelo8121 has left #ruby [#ruby]
mockra has quit [Ping timeout: 260 seconds]
<cantonic>
|Daz|: you know that you are cross posting in channels?
Zolo has joined #ruby
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
sleetdrop has quit [Ping timeout: 248 seconds]
statarb3 has quit [Read error: Connection reset by peer]
statarb3 has joined #ruby
<|Daz|>
Obviously.
ryanf has quit [Ping timeout: 256 seconds]
k610 has quit [Quit: Leaving]
idkazuma has quit [Remote host closed the connection]
Guest85414 has quit [Ping timeout: 245 seconds]
pkondzior__ has quit [Ping timeout: 240 seconds]
sleetdrop has joined #ruby
adeponte has joined #ruby
ryanf has joined #ruby
jgrevich has quit [Remote host closed the connection]
io_syl has quit [Ping timeout: 248 seconds]
alup_ has quit [Ping timeout: 245 seconds]
spanx has quit [Ping timeout: 245 seconds]
chiel has quit [Ping timeout: 245 seconds]
madhatter has quit [Remote host closed the connection]
madhatter has joined #ruby
chiel has joined #ruby
alup_ has joined #ruby
girija has joined #ruby
io_syl has joined #ruby
kn330 has quit [Ping timeout: 264 seconds]
RomainT has joined #ruby
daniel_- has joined #ruby
<Amfy>
Sorry that I annoy this channel again. I was coding in Node over the last months, and there I always was able to debug everything by just console.log(); - now Datamapper isn't working here, already trying since hours, how can I better debug this?
adeponte has quit [Ping timeout: 276 seconds]
itsdavem has joined #ruby
icole has quit [Remote host closed the connection]
<apeiros_>
Amfy: `p obj`, or install pry and use `binding.pry`
averiso has quit [Ping timeout: 276 seconds]
<Amfy>
apeiros_ if I make puts domain - I get #<Domain:0x007fed4b95eee0>
<Amfy>
which is not that helpful :P
<apeiros_>
Amfy: well, then print stuff which is more helpful
<apeiros_>
also usually you want p, not puts
<Amfy>
apeiros_ oh, cool, yes, that's a bit more detailed
<apeiros_>
puts calls to_s, p calls inspect, the latter is often more useful for debugging. not for this case, though, since #<Domain:0x007fed4b95eee0> already is the .inspect output
itsdavem has quit [Ping timeout: 248 seconds]
<apeiros_>
require 'pp', then `pp obj` if you have larger structures
<Amfy>
ok, will try that, too, thanks
ananthakumaran1 has joined #ruby
braoru has joined #ruby
ananthakumaran has quit [Ping timeout: 252 seconds]
mikurubeam has quit [Ping timeout: 255 seconds]
idkazuma has joined #ruby
<aedornm>
hmmmm... speaking of pry, somehow it's using 100% CPU. Wonder what I did
|Daz| has left #ruby [#ruby]
xbob has joined #ruby
atmosx has joined #ruby
subbyyy has quit [Ping timeout: 248 seconds]
<Amfy>
lol, why is Datamapper sometimes working and sometimes not?
<Amfy>
not far away from some randomness
chussenot has joined #ruby
<atmosx>
Amfy: better use sequel, datamapper is somewhate abandoned
<Amfy>
damn, atmosx, don't want to rewrite everything :P
<atmosx>
I know how you feel I have to do the same thing
lkba has joined #ruby
v0n has quit [Ping timeout: 276 seconds]
senayar has joined #ruby
lewix_ has quit [Remote host closed the connection]
malkomalko has joined #ruby
<Amfy>
atmosx: Especially since I recommended sequel to a friend - but chose Datamapper for my own :(
Spooner has joined #ruby
spider-mario has joined #ruby
kn330 has joined #ruby
<atmosx>
Amfy: funny :-P
idkazuma has quit [Remote host closed the connection]
nari has joined #ruby
girija has quit [Ping timeout: 245 seconds]
marr has joined #ruby
adambeynon has joined #ruby
DarthGandalf has joined #ruby
maxmanders has quit [Ping timeout: 240 seconds]
sam113101 has quit [Quit: WeeChat 0.3.8]
Pochacco has joined #ruby
horrror has joined #ruby
<horrror>
I have hash that contains Arrays with elements of another Hash. is there a way to sort the arrays according to a specific value in the inner hash?
eka has quit [Quit: Computer has gone to sleep.]
sam113101 has joined #ruby
<kojul>
short answer: yes. example?
gommo has quit [Remote host closed the connection]
decoponio has quit [Quit: Will take to stop a load on my PC]
sonda has joined #ruby
Astral_ has joined #ruby
horrror_ has joined #ruby
Banistergalaxy has quit [Ping timeout: 248 seconds]
masaya_ has joined #ruby
tealmage has quit [Ping timeout: 248 seconds]
Astralum has quit [Ping timeout: 248 seconds]
maxmanders has quit [Ping timeout: 276 seconds]
Eldariof-ru has joined #ruby
idkazuma has joined #ruby
masaya has quit [Ping timeout: 260 seconds]
masaya_ is now known as masaya
horrror has quit [Ping timeout: 248 seconds]
horrror_ is now known as horrror
mockra has quit [Ping timeout: 264 seconds]
dangerousdave has joined #ruby
eldariof has quit [Ping timeout: 248 seconds]
<horrror>
kojulZzZ: https://gist.github.com/anonymous/b84f8d15a2a197835585 . Basically I want to compare the :rank key of each hash in the arrays of master_hash and sum up the score for each identical item (based on their id) (:rank += :rank2)
<horrror>
blah it's phrased as sh*** hope u understand
gommo has quit [Remote host closed the connection]
karnowski has joined #ruby
Eldariof-ru has quit [Read error: Operation timed out]
tish has joined #ruby
Eldariof-ru has joined #ruby
maxmanders has joined #ruby
lkba has quit [Ping timeout: 240 seconds]
maxmande_ has joined #ruby
<Spooner>
horrror, You said a minute ago that you wanted to sort, not sum the values.
<Spooner>
Not as clear as you could be.
maxmanders has quit [Ping timeout: 245 seconds]
<Spooner>
Well, to sum up the ranks within an array, you could use sum = arr.inject(0) {|h, m| m + h[:rank] }
kristofers has joined #ruby
<apeiros_>
wrong argument order
<apeiros_>
it's |accumulator, object|
<Spooner>
Oops, I got confused between inject and with_object. Thanks!
<apeiros_>
yw
<Spooner>
horrror, So yes, it should be |m, h| in my example.
io_syl has quit [Ping timeout: 248 seconds]
altivec has quit [Quit: WeeChat 0.3.7]
hashmal has joined #ruby
io_syl has joined #ruby
kevinfagan has joined #ruby
bluOxigen has joined #ruby
idkazuma has quit [Remote host closed the connection]
hasimo has joined #ruby
<horrror>
Spooner: thanks!
hasimo has quit [Remote host closed the connection]
<Spooner>
horrror, But your requirements seemed a lot more complicated that just that. Feel free to explain them more clearly ;)
shock_one has joined #ruby
<horrror>
Spooner: yes because what you wrote will apply only to if there are identical keys in the specific hash
<horrror>
let me try to rephrase it ;o
<Spooner>
You might want to select {|h| h[:id] == required_id } before you inject then.
<apeiros_>
you'd probably do well to rethink how you wrap this up into objects
Neomex has joined #ruby
Neomex has quit [Client Quit]
pen has quit [Remote host closed the connection]
arturaz has joined #ruby
maxmande_ has quit [Ping timeout: 248 seconds]
MrZYX|off is now known as MrZYX
hasimo has joined #ruby
maxmanders has joined #ruby
<horrror>
So basically the gist illustrates the data structure of a specific user likes. User has Likes (Hash) and each like has Array of related likes (second_hash). I want to compare every related hash in every array. if there are identical ids i want to sum up the score
one has quit [Ping timeout: 276 seconds]
Es0teric has quit [Quit: Computer has gone to sleep.]
<horrror>
Spooner: is it more clear?
ner0x has quit [Quit: Leaving]
<Spooner>
Then maybe you want to group_by id then inject (to sum). We aren't here to write your code though ;)
maxmanders has quit [Ping timeout: 276 seconds]
chussenot has quit [Quit: chussenot]
InFlames has joined #ruby
maxmanders has joined #ruby
<InFlames>
anyone ever messed with xpaths in nokogiri?
<Spooner>
InFlames, Many of us, but just ask your question.
<apeiros_>
InFlames: no one ever did, no
<horrror>
Spooner: i know and i appreciate your help so far but i'm clueless about how to implement it, should i iterate the entire master hash and then its arrays and then its inner hash? should I combine the entire Arrays into one array and array#each_slice(4) (for example) and then iterate it?
<InFlames>
I was wondering how I can read the meta tags and find the few i want and extract the contents
keyvan has joined #ruby
keyvan has joined #ruby
keyvan has quit [Changing host]
<InFlames>
i assumed the best means to grab them is xpaths, but i seem to be formatting my xpaths wrong
<InFlames>
p doc.xpath('html/head/meta@property')
<InFlames>
that seems to error
<Spooner>
You can use css pathing too. Both work.
<InFlames>
can you read the meta tags with css3?
<InFlames>
i support that might be easier...
<Spooner>
Personally, I use Chrome and just ask it to tell me the xpath :D
<InFlames>
spooner, the one issue i had with that was it gave me the meta tags as an arrayu (i used firebug)
<InFlames>
array*
<Spooner>
Dunno. I use "Inspect element" then "copy xpath" in Chrome and it works fine with Nokogiri.
<Spooner>
You always get an array from an xpath though.
<InFlames>
but i can't use an array, as i need to read this on incoming urls
love_color_text has quit [Ping timeout: 260 seconds]
<InFlames>
and they won't be consistant
<Spooner>
Just use #first if you know there can't be more than one result.
<InFlames>
i know there will be many many meta tags
<Spooner>
I don't quite understand.
<InFlames>
so i need to find the ones i am looking for and extract the contents
<InFlames>
so for instance, i was trying to read the locale off that site
echobin79 has quit [Read error: Connection reset by peer]
<Spooner>
Right. Just get all the meta tags at once and look through them.
echobinary has joined #ruby
<InFlames>
so just use html/head/meta and iterate the array?
<Spooner>
Right, it is using a namespace (og:) which is messing you up?
<InFlames>
yea, would like to pull all the open graph and twitter in
blueOxigen has joined #ruby
<InFlames>
so i was looking to do it via xpath, but i could use a css selector, either or
tealmage has joined #ruby
bonhoeffer has joined #ruby
bluOxigen has quit [Ping timeout: 256 seconds]
<Spooner>
Yeah, might be easier to just grab all the metas and #find what you want in code (rather than xcode). Hmm, you can use ends-with(@property, 'locale') then it would not care about the namespace prefix.
mockra has joined #ruby
<InFlames>
.ends-with?
<InFlames>
what is that?
<Spooner>
In xpath.
<InFlames>
i was originally looking for a good explination of xpath, but all i found was massive documents my brain can't handle
<InFlames>
i mean, i get it, i just don't get all of it
<InFlames>
i tried p doc.at_css('meta[property=locale]') but i get nil
<Spooner>
But look at the next bit about #remove_namespaces to make it easy peasy :D
<InFlames>
Lazy == Efficient, so no judgements. :)
<InFlames>
haha
mockra has quit [Ping timeout: 264 seconds]
chussenot has joined #ruby
samphippen has joined #ruby
hbpoison has quit [Ping timeout: 248 seconds]
horrror has quit [Quit: horrror]
<Spooner>
InFlames, This is Ruby. Lazy is the name of the game :D
<InFlames>
haha, slop, awesome
<InFlames>
that is the best solution for sure, works great, thanks a ton
<InFlames>
i can read all the tags i like with this ;]
<InFlames>
oh and i can easily read the attribute i want via [:attribute] awesome
<InFlames>
much appreciated
<Spooner>
I learned something too. I only know as much Nokogiri as I need, but I'll probably need more ;)
zetabyte has quit [Read error: Connection timed out]
zetabyte has joined #ruby
itsdavem has joined #ruby
sirish has quit [Ping timeout: 245 seconds]
horrror has joined #ruby
dblack has joined #ruby
<InFlames>
i really like how well nokogiri handles parsing xml
<InFlames>
i came from php where we used to do it by hand with regex
<Spooner>
XML is a blight.
hasimo has quit [Remote host closed the connection]
<InFlames>
well the way they go about it is the most ideal i'm sure
idkazuma has quit [Remote host closed the connection]
m8 has joined #ruby
<Spooner>
If only the web were designed around "normal" data structure (you know, something like JSON), the world would be a shinier place!
akashj87 has quit [Ping timeout: 276 seconds]
bluOxigen has joined #ruby
<whitequark>
Spooner: the web isn't designed around XML
RomainT has left #ruby [#ruby]
Eldariof93-ru has joined #ruby
<whitequark>
and representing markup in JSON is... foolish, at best
<InFlames>
i think markup in json suffers from a similar problem to xml
itsdavem has quit [Ping timeout: 264 seconds]
<InFlames>
but json for it's proper use is fantastic, i prefer it over xml any day
<InFlames>
but i do like xml
blueOxigen has quit [Ping timeout: 256 seconds]
<Spooner>
whitequark, Why is json any more messy than xml?
<whitequark>
Spooner: I never said that
fuzai_ has joined #ruby
<Spooner>
Not saying it is perfect; just that having something that is actually based on programming structures, rather than being a pain to manipulate, would have been a boon.
Eldariof-ru has quit [Ping timeout: 255 seconds]
fuzai has quit [Ping timeout: 255 seconds]
fuzai_ is now known as fuzai
idkazuma has joined #ruby
hbpoison has joined #ruby
katherinem13 has quit [Read error: Operation timed out]
nkr has joined #ruby
jtperreault has quit [Read error: Operation timed out]
ocnam has quit [Ping timeout: 248 seconds]
russfrank has quit [Ping timeout: 264 seconds]
haxrbyte has joined #ruby
eka has joined #ruby
keyvan has quit [Read error: Connection reset by peer]
<InFlames>
well json is basically a hash, but how is xml not based on programming structures? isn't it essentially a tree directory?
<Spooner>
Json is Hashes and Arrays. XML doesn't represent either Hashes or Arrays directly. Although a tag is like a hash, it has both a name and attributes. Arrays are usually implemented with a group of same-named tags inside another tag.
<InFlames>
i think if tomorrow some said "build me a website in html or json!" i'd have to go with html though...
mikurubeam has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
<InFlames>
i can conceptually imagine it in json, but that just seems like a nightmare to write out manually
* Hanmac
thinks that xml is better structured than json
<Spooner>
The difference I am stating, however, is that JSON.parse(text) gives you a straight data structure that you can manipulate any way you want. If you parse XML, then you have to jump through hoops to actually get data out of the mess created.
<InFlames>
the more simplistic approach of html really lowered the learning curve for us web designers ;]
<InFlames>
hanmac, while i might agree, when i have to parse, i generally prefer json, also json is lighterweight, is it not?
<Spooner>
HTML isn't simpler. It is just that the early browsers (and IE at any time) pretty much let you write it any way you wanted.
<InFlames>
spooner, EXACTLY ;]
love_color_text has joined #ruby
<InFlames>
i recall the early days of html, those were dark times for semantic markup :[
<Spooner>
Which although making life easier for non-developers, has been pissing in the eyes of developers ever since :D
<InFlames>
and the capslock key :/
<Spooner>
Hanmac, How is HTML better?
<InFlames>
well i say html is great, but when i must parse returned data, json over anything
<Hanmac>
Spooner i said xml, not html
<Spooner>
Right, sorry.
<InFlames>
in fact, when i write rails ajax requests, instead of returning a javascript file, i always return json
bonhoeffer has quit [Quit: bonhoeffer]
haxrbyte_ has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
dangerousdave has joined #ruby
katherinem13 has joined #ruby
russfrank has joined #ruby
jtperreault has joined #ruby
philcrissman has joined #ruby
lkba has joined #ruby
haxrbyte has quit [Ping timeout: 276 seconds]
Xeago has quit [Read error: Connection reset by peer]
Xeago has joined #ruby
nomenkun_ has joined #ruby
DrCode has quit [Remote host closed the connection]
marr has quit [Ping timeout: 264 seconds]
DrCode has joined #ruby
LouisRoR has joined #ruby
haxrbyte_ has quit [Ping timeout: 260 seconds]
nomenkun has quit [Ping timeout: 260 seconds]
hasimo has joined #ruby
axhlf has joined #ruby
Matip has quit [Quit: Leaving]
timonv has joined #ruby
samphippen has joined #ruby
niky_mm has joined #ruby
<niky_mm>
salutare
echobinary has quit [Read error: Connection reset by peer]
echobinary has joined #ruby
hbpoison has quit [Ping timeout: 240 seconds]
d3vic3 has joined #ruby
tealmage has joined #ruby
hasimo has quit [Read error: Connection reset by peer]
hasimo has joined #ruby
skipi has joined #ruby
zmike has joined #ruby
wallclockbuilder has joined #ruby
dcwu has quit [Read error: Connection reset by peer]
dblack has quit [Quit: dblack]
mockra has joined #ruby
tealmage has quit [Ping timeout: 264 seconds]
hiroyuki has joined #ruby
wallclockbuilder has quit [Ping timeout: 264 seconds]
bluOxigen has quit [Ping timeout: 257 seconds]
mockra has quit [Ping timeout: 248 seconds]
itsdavem has joined #ruby
pen has quit [Remote host closed the connection]
atmosx has joined #ruby
itsdavem has quit [Remote host closed the connection]
zmike has quit [Quit: Выходжу]
hbpoison has joined #ruby
Takehiro has quit [Remote host closed the connection]
itsdavem has joined #ruby
rubarlion has joined #ruby
pen has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
<thecodethinker>
aboudreault: type that into the term
averiso has joined #ruby
<aboudreault>
Haven't ask anything about linux. Everything is already working like a charm
<thecodethinker>
aboudreault: ruby <filepath> to run a .rb file. irb to open the interpreter
amcsi_work has quit [Ping timeout: 252 seconds]
<thecodethinker>
aboudreault: rvm.io
<thecodethinker>
aboudreault: grap that for mac.
<thecodethinker>
command line tool. installs ALL versions of ruby
<thecodethinker>
even jruby and rubinius
<havenwood>
thecodethinker: rvm requires brew though
<thecodethinker>
havenwood: I'm not sure
<havenwood>
thecodethinker: chruby and rbenv as well
<aboudreault>
Ok.
<havenwood>
Or somehow you have to get the RVM requirements installed `rvm requirements`.
mulinux has joined #ruby
<havenwood>
aboudreault: Oh, so you are a Linux user installing Ruby on OS X? That took me a while to understand...
<thecodethinker>
btw do any of you get this error with ruboto?
<thecodethinker>
/usr/lib/ruby/gems/1.9.1/gems/ruboto-0.10.1/bin/ruboto:3:in ``': No such file or directory - android list (Errno::ENOENT)
<aboudreault>
havenwood, yeah, just wanted to test my tutorial on a MacOSX.
V8Energy has joined #ruby
<havenwood>
ini: I heard they were nearly ready with JRuby 2.0.0-compatibility but dunno release date.
hasimo has quit [Ping timeout: 245 seconds]
pdamer has joined #ruby
<havenwood>
aboudreault: Tokaido is gunna be the way-of-the-future for OS X, with statically linked builds. Actually, you could probably grab a Tokaido build for 1.9.3 or 2.0.0 and that would work. Just a matter of finding one, not primetime yet.
<havenwood>
RVM actually uses Tokaido Ruby builds when available now.
chussenot has joined #ruby
tish has quit [Quit: Leaving.]
tomzx_mac has joined #ruby
<havenwood>
So maybe RVM is the way to go, if you choose a statically linked build no need for brwe.
<havenwood>
s/brwe/brew
echobin49 has quit [Read error: Connection reset by peer]
echobinary has joined #ruby
<aboudreault>
I know homebrew is awesome... so I will just point it to my users. I will just not test it myself. At I least I won't suggest something relatively deprecated.
palladium has joined #ruby
<palladium>
howdy
tish has joined #ruby
banisterfiend has joined #ruby
<havenwood>
hiya
fermuch has quit [Quit: leaving]
tish has quit [Client Quit]
cyberflux has joined #ruby
<thecodethinker>
Anyone here good with ruboto?
__Big0__ has quit [Remote host closed the connection]
<havenwood>
Never done android stuff. Fun?
<thecodethinker>
not so far -_- I get an error
sleetdrop has quit [Remote host closed the connection]
<thecodethinker>
/usr/lib/ruby/gems/1.9.1/gems/ruboto-0.10.1/bin/ruboto:3:in ``': No such file or directory - android list (Errno::ENOENT)
<thecodethinker>
any idea?
sleetdrop has joined #ruby
<havenwood>
thecodethinker: Have you installed the Android SDK?
kevinfagan has quit [Quit: Leaving...]
<thecodethinker>
yep
<thecodethinker>
/opt/android-sdk
AlSquirrel has joined #ruby
__Big0__ has joined #ruby
tealmage has joined #ruby
butblack has joined #ruby
palladium has quit [Remote host closed the connection]
realDAB has joined #ruby
__Big0__ has quit [Remote host closed the connection]
AlSquire has quit [Read error: Connection reset by peer]
AlSquirikou has joined #ruby
mockra has joined #ruby
hbpoison has quit [Ping timeout: 264 seconds]
AlSquirrel has quit [Ping timeout: 252 seconds]
tealmage has quit [Ping timeout: 248 seconds]
slainer68 has joined #ruby
slainer68 has quit [Remote host closed the connection]
AlSquirikou has quit [Ping timeout: 264 seconds]
Davey has joined #ruby
averiso has quit [Ping timeout: 250 seconds]
averiso has joined #ruby
sambao21 has joined #ruby
__Big0__ has joined #ruby
nouitfvf has joined #ruby
AlSquire has joined #ruby
eldariof has joined #ruby
postmodern has quit [Quit: Leaving]
mockra has quit [Ping timeout: 248 seconds]
Amnesthesia has quit [Remote host closed the connection]
Eldariof28-ru has quit [Ping timeout: 240 seconds]
thecodethinker has quit [Quit: Lost terminal]
daniel_- has joined #ruby
chussenot has quit [Quit: chussenot]
AlSquirrel has joined #ruby
Takehiro has joined #ruby
akashj87 has joined #ruby
AlSquirrel has quit [Read error: Connection reset by peer]
AlSquire has quit [Read error: Connection reset by peer]
itsdavem has joined #ruby
Rioji has quit [Remote host closed the connection]
hasimo has joined #ruby
tealmage has joined #ruby
aed has joined #ruby
_bart has joined #ruby
mulinux has quit [Quit: mulinux]
ini has quit [Read error: Connection reset by peer]
iamjarvo has joined #ruby
xpen_ has quit [Ping timeout: 250 seconds]
testingb0t has quit [Quit: Leaving.]
Ivo has joined #ruby
yacks has joined #ruby
hasimo has quit [Ping timeout: 248 seconds]
Ivo has quit [Quit: WeeChat 0.4.0]
wallclockbuilder has joined #ruby
backjlack has joined #ruby
carloslopes has joined #ruby
Catbuntu has joined #ruby
<Catbuntu>
Hi
sambao21 has quit [Quit: Computer has gone to sleep.]
pdamer has quit [Quit: pdamer]
<havenwood>
hi
daniel_- has quit [Ping timeout: 248 seconds]
AlSquire has joined #ruby
<shevy>
hmm
Ivo has joined #ruby
<realDAB>
hello
<Ivo>
Hi there. I'm using ruby with rbenv on archlinux. I'm trying to update rubygems. I have ruby set to the system version. When I try to install rubygems, it still installs it to ~/.gems (i used sudo?). gem update --system then says it can't find rubygems-update. Any advice on how to rpoceed?
mikurubeam has joined #ruby
v0n has quit [Ping timeout: 264 seconds]
Mattix has joined #ruby
kn330 has quit [Ping timeout: 264 seconds]
<MrZYX>
Ivo: iirc archlinux sets the user install option in /etc/gemrc by default
mockra has quit [Remote host closed the connection]
dhruvasagar has quit [Ping timeout: 248 seconds]
maxmanders has quit [Ping timeout: 240 seconds]
sambao21 has joined #ruby
__Big0__ has quit [Remote host closed the connection]
maxmanders has joined #ruby
echobinary has quit [Read error: Connection reset by peer]
statarb3 has quit [Quit: Leaving]
echobinary has joined #ruby
lewix has joined #ruby
pdamer has quit [Quit: pdamer]
hbpoison has joined #ruby
hasimo has joined #ruby
dzied has joined #ruby
i42n_ has joined #ruby
maletor has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
beiter has quit [Quit: beiter]
tyebud has joined #ruby
sullenel has joined #ruby
<i42n_>
hey guys, hope someone can help me. I parse json and convert it into a ruby array. Now I need to remove some array elements while iterating. Is this the right way to do that? http://pastebin.com/TMhsgbK9
yshh has quit [Read error: Connection reset by peer]
yshh has joined #ruby
<havenwood>
i42n_: might want to use #keep_if instead of #each with #delete.
eka has quit [Client Quit]
<havenwood>
i42n_: #reverse_each is better than #reverse.each, since instead of sort then iterate it just iterates in reverse
kornnflake_zzz is now known as kornnflake
<MrZYX>
modifying while iterating always feels bad to me though
mikurubeam has quit [Quit: When I come back, please tell me in what new ways you have decided to be completely wrong.]
cobrahorse has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
<MrZYX>
so +1 to #keep_if
<shevy>
MrZYX why are you not called MrXYZ ?
<MrZYX>
because of exactly that
<havenwood>
i42n_: or delete_if
<i42n_>
MrZYX: alternative is to duplicate usable entries to a second array...
julian-delphiki has joined #ruby
daniel_- has joined #ruby
hasimo has quit [Ping timeout: 248 seconds]
mikurubeam has joined #ruby
<i42n_>
havenwood: thanks for the tips :)
butblack has quit [Quit: butblack]
bluesm has joined #ruby
<bluesm>
Is codeschool is worthwhile ?
akashj87 has quit [Ping timeout: 264 seconds]
<MrZYX>
bluesm: yep, do the free courses and you'll get coupons saving $5 (not sure if they stack, if so you could get a month for free in theory)
love_color_text has quit [Read error: Connection reset by peer]
Mon_Ouie has quit [Ping timeout: 248 seconds]
prime has quit [Read error: Connection reset by peer]
prime has joined #ruby
butblack has joined #ruby
prime has quit [Changing host]
prime has joined #ruby
<bluesm>
MrZYX: So in theory every finished free course give you $5 coupon :) ?
<MrZYX>
yes
<MrZYX>
some of the paid courses yield other cool stuff
<MrZYX>
like a free month of railscasts pro
mockra has joined #ruby
<MrZYX>
or a free peepcode episode
<MrZYX>
so if you got some time the $25 do more than pay off
sayan has quit [Read error: Connection reset by peer]
Faris has joined #ruby
<kornnflake>
bluesm i would recommend the courses only to beginners
daniel_- has quit [Quit: WeeChat 0.3.9.2]
<MrZYX>
oh yeah, I thought that's obvious
<kornnflake>
:D
Virunga has quit [Remote host closed the connection]
<bluesm>
kornnflake: Question is, beginners with programming or beginners with ruby ?
F1skr has joined #ruby
mockra has quit [Ping timeout: 245 seconds]
<MrZYX>
beginner in the particular field is enough
maxmanders has quit [Ping timeout: 252 seconds]
<bluesm>
kornnflake: Because I have some experience in script languages.
<MrZYX>
you'll be able to go a bit faster through them with previous programming experience for sure but it doesn't make them boring IMO
<dasdasdas>
kinda off topic question, but what would you prefer guys? 1024MB ram + 150ms latency or 512MB ram + 50ms latency ? simple applications but ajax intensive. probably 512 would be enough but it looks very poor
<kornnflake>
the ruby syntax if pretty unique, better go for the course bluesm
Shadow_S has joined #ruby
<Amfy>
oh hey kornnflake
samphippen has joined #ruby
tealmage has quit [Remote host closed the connection]
<kornnflake>
hey :p
<Amfy>
dasdasdas hm, if it's Ajax intensive I would say the 512M one with 50ms latency
maxmanders has joined #ruby
<dasdasdas>
yea i trought so, for example 140ms would ruin "search as you type" probably
<Amfy>
^ exactly
<bluesm>
kornnflake: Ok. Thank you very much :)
<whitequark>
dasdasdas: what are you talking about
<whitequark>
the RAM numbers
Xeago has joined #ruby
<dasdasdas>
512 vs 1024
<Amfy>
dasdasdas about which locations are you talking? Maybe I can help you out
backjlack has quit [Remote host closed the connection]
backjlack has joined #ruby
kop has quit [Ping timeout: 246 seconds]
aytch_ has joined #ruby
Eldariof-ru has joined #ruby
jpfuentes2 has joined #ruby
tjbiddle has quit [Quit: tjbiddle]
punkrawkR has joined #ruby
kop has joined #ruby
jurassic has joined #ruby
aytch has quit [Ping timeout: 256 seconds]
Virunga has joined #ruby
eldariof has quit [Ping timeout: 276 seconds]
carloslopes has quit [Remote host closed the connection]
kofno has joined #ruby
Morkel has joined #ruby
raggedjack has joined #ruby
i42n_ has quit [Quit: i42n_]
lupinstein has quit [Remote host closed the connection]
mikurubeam has quit [Quit: When I come back, please tell me in what new ways you have decided to be completely wrong.]
hasimo has joined #ruby
timonv has quit [Remote host closed the connection]
endzyme has joined #ruby
unsay_ has joined #ruby
unsay_ has quit [Client Quit]
kofno has quit [Remote host closed the connection]
motto has joined #ruby
dhruvasagar has joined #ruby
atmosx has joined #ruby
endzyme has quit [Remote host closed the connection]
m8 has quit [Ping timeout: 256 seconds]
motto has quit [Max SendQ exceeded]
motto has joined #ruby
motto has quit [Max SendQ exceeded]
eAlchemist has quit [Remote host closed the connection]
motto has joined #ruby
eAlchemist has joined #ruby
X-Jester has quit [Quit: leaving]
motto has quit [Max SendQ exceeded]
motto has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
hasimo has quit [Ping timeout: 248 seconds]
echobinary has quit [Read error: Connection reset by peer]
motto has quit [Max SendQ exceeded]
echobinary has joined #ruby
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
motto has joined #ruby
pepper_chico has joined #ruby
amcsi_work has joined #ruby
generalissimo has joined #ruby
hbpoison has quit [Ping timeout: 245 seconds]
motto has quit [Max SendQ exceeded]
motto has joined #ruby
kornnflake is now known as kornnflake_zzz
tommyvyo has joined #ruby
tommyvyo has quit [Client Quit]
motto has quit [Max SendQ exceeded]
motto has joined #ruby
mneorr has joined #ruby
sepp2k has quit [Ping timeout: 252 seconds]
sepp2k1 has joined #ruby
motto has quit [Max SendQ exceeded]
motto has joined #ruby
samphippen has quit [Ping timeout: 248 seconds]
motto has quit [Max SendQ exceeded]
motto has joined #ruby
sayan has joined #ruby
chussenot has joined #ruby
pepper_chico has quit [Quit: Computer has gone to sleep.]
tommyvyo has joined #ruby
shock_one has quit [Quit: Ex-Chat]
motto has quit [Max SendQ exceeded]
Chryson has joined #ruby
rubarlion has quit []
motto has joined #ruby
kofno has joined #ruby
X-Jester has joined #ruby
jgrevich has joined #ruby
aces1up has quit [Read error: Connection reset by peer]
freezway has joined #ruby
atmosx has quit [Quit: And so the story goes…]
chrishunt has quit [Quit: ZzZzZz...]
mityaz has joined #ruby
chrishunt has joined #ruby
dhruvasagar has quit [Read error: Operation timed out]
lewix has quit [Remote host closed the connection]
erry has quit [Changing host]
erry has joined #ruby
amnay_ has joined #ruby
markalanevans has quit [Quit: markalanevans]
Xeago has quit [Remote host closed the connection]
amnay_ has quit [Client Quit]
h4mz1d has joined #ruby
markalanevans has joined #ruby
<Faris>
Hi. is Wirble still mainstream for colors and completion ?
razibog has joined #ruby
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
sailias has quit [Quit: Leaving.]
sailias has joined #ruby
jellosea_ has joined #ruby
mneorr has quit [Remote host closed the connection]
statarb3 has quit [Quit: Leaving]
niklasb has quit [Ping timeout: 260 seconds]
Zolo has quit [Remote host closed the connection]
kornnflake_zzz is now known as kornnflake
hasimo has joined #ruby
mockra has joined #ruby
aLeSD_ has joined #ruby
<aLeSD_>
hi all
hbpoison has joined #ruby
mootpointer has joined #ruby
arthurstomp has joined #ruby
Faris has quit [Ping timeout: 240 seconds]
<aLeSD_>
how to run the ruby interpreter ?
<aLeSD_>
and is there a good Ruby IDE ?
BizarreCake has joined #ruby
braoru has quit [Read error: Operation timed out]
arthurstomp has quit [Client Quit]
tommyvyo has quit [Quit:]
<Hanmac>
aLeSD_ run interpreter "ruby", or interactive "irb" or "pry" ... good IDEs are many ... depending if you need Rails or not
generalissimo has quit [Remote host closed the connection]
jjbohn is now known as jjbohn|afk
jellosea_ has quit [Quit: jellosea_]
hbpoison has quit [Ping timeout: 245 seconds]
mockra has quit [Ping timeout: 264 seconds]
razibog has quit [Ping timeout: 245 seconds]
Bry8Star has joined #ruby
fugetsu has joined #ruby
realDAB has quit [Quit: realDAB]
arturaz has joined #ruby
tealmage has joined #ruby
echobinary has quit [Ping timeout: 248 seconds]
tommyvyo has joined #ruby
pepper_chico has joined #ruby
pepper_chico has quit [Max SendQ exceeded]
mneorr has joined #ruby
pepper_chico has joined #ruby
h4mz1d has quit [Ping timeout: 276 seconds]
jblack has joined #ruby
<aLeSD_>
Hanmac, thanks
ephemerian has joined #ruby
browndawg has quit [Quit: Leaving.]
jgrevich_ has joined #ruby
tealmage has quit [Ping timeout: 248 seconds]
subbyyy has quit [Ping timeout: 260 seconds]
jgrevich has quit [Ping timeout: 276 seconds]
jgrevich_ is now known as jgrevich
kornnflake is now known as kornnflake_zzz
lolmaus has quit [Read error: Connection reset by peer]
hasimo has quit [Ping timeout: 255 seconds]
girija has quit [Ping timeout: 245 seconds]
sulaco_ has joined #ruby
lewix has joined #ruby
lewix has quit [Changing host]
lewix has joined #ruby
_bart has quit [Quit: leaving]
ddd__ has joined #ruby
Ivo has quit [Quit: WeeChat 0.4.0]
ddd has quit [Ping timeout: 245 seconds]
_bart has joined #ruby
lewix has quit [Remote host closed the connection]
sulaco has quit [Ping timeout: 260 seconds]
<_bart>
I hope that one day, all mobile apps are programmable in Ruby, with bindings to proper APIs. (Not like iOS and Android..)
m8 has joined #ruby
mercwithamouth has joined #ruby
<banisterfiend>
_bart: have you heard of rubymotion?
Faris has joined #ruby
<Hanmac>
my does not trust closed sourced Mac shit
motto has quit [Ping timeout: 256 seconds]
<havenwood>
MobiRuby is another alternative to RubyMotion
Politoed has quit [Read error: Operation timed out]
Politoed has joined #ruby
ddd__ has quit [Ping timeout: 245 seconds]
Stilo has joined #ruby
carloslopes has joined #ruby
<shevy>
Hanmac hehehe
butblack has quit [Quit: butblack]
mneorr has quit [Read error: Connection timed out]
lewix has joined #ruby
lewix has quit [Changing host]
lewix has joined #ruby
<Hanmac>
shevy that all closet source
<shevy>
hahaha
mneorr has joined #ruby
mootpointer has quit [Quit: Computer has gone to sleep.]
Seventoes has joined #ruby
jjbohn|afk is now known as jjbohn
jblack has quit [Ping timeout: 250 seconds]
hbpoison has joined #ruby
maletor has quit [Quit: Computer has gone to sleep.]
carloslopes has quit [Ping timeout: 248 seconds]
d2dchat has joined #ruby
h4mz1d has joined #ruby
becom33 has joined #ruby
kornnflake_zzz is now known as kornnflake
iamjarvo has quit [Quit: Leaving.]
eka has joined #ruby
tommyvyo has quit [Quit:]
mikurubeam has joined #ruby
<_bart>
banisterfiend, havenwood: I like the initiative, but with those you're still stuck with the poor/different APIs of Android and iOS
subbyyy has quit [Ping timeout: 264 seconds]
<banisterfiend>
_bart: well providing the same api to both platforms is a huge job
<banisterfiend>
probably hard to get someone to do that for free
<havenwood>
impossibru
<banisterfiend>
_bart: esp. given the development tools for rubymotion are quite advanced *and* ios specific
<_bart>
And yes, RubyMotion is closed source, and doesn't do so much magic in my opinon, it just adds ';' to every line and defines some types and boom, it's obj-c again..
dcwu has joined #ruby
<banisterfiend>
_bart: so you'd also need to develop good development tools of comparable power to rubymotion ones
<banisterfiend>
_bart: i dont think it's as simple as that..
iamjarvo has joined #ruby
hakunin_ is now known as hakunin
subbyyy has joined #ruby
nazty has quit [Ping timeout: 256 seconds]
<_bart>
banisterfiend: hmm maybe, but if you're able to do the programming in rubymotion, you should also be fine with objective-c, it's mainly syntax sugar right?
<banisterfiend>
_bart: are you kidding?
iamjarvo has quit [Client Quit]
hasimo has joined #ruby
tommyvyo has joined #ruby
<banisterfiend>
obj-c is a totally different language, its semantics are very different. It's a c-based language, it has pointers, header files, it's a completely different language.
kristofers has quit [Read error: Connection reset by peer]
iamjarvo has joined #ruby
iamjarvo has quit [Client Quit]
* Hanmac
thinks that C++ is better than Obj-C or C#
kristofers has joined #ruby
<Spooner>
C# is just Java++ anyway ;)
<havenwood>
Hanmac: C vs C++?
jjbohn is now known as jjbohn|afk
<Hanmac>
hm i like C++ more than C ... its a bit nicer with the pointers ...
mneorr has quit [Read error: Connection timed out]
<banisterfiend>
Hanmac: obj-c is cooler than C++
<banisterfiend>
Hanmac: obj-c is very very ruby-like
mneorr has joined #ruby
e-dard has joined #ruby
<banisterfiend>
Hanmac: imagine C had sexual relations with Ruby, obj-c would be their baby
<Hanmac>
C# has a compiler directive only for GROUPING code ... something like #include only for structureing ... it inst even as good as namespaces
<Hanmac>
banisterfiend: you mean unloved?
<e-dard>
Hi, what exactly does "gem 'foo', :require => "foo/base"" mean in a GemFile?
<e-dard>
when would you add these require parts to the gem specifications?
<Hanmac>
because of lazyness?
m8 has quit [Read error: Operation timed out]
arturaz has quit [Ping timeout: 245 seconds]
k610 has joined #ruby
<becom33>
http://pastebin.com/Ar0pFGsq In here if I do script.rb -n Mick -a "is reading " it will give a output a "Mick is reading"
mercwithamouth has quit [Ping timeout: 248 seconds]
<becom33>
now I wanna do is . If I give it a list of names it should go trough each name and put out with the action I've mention before
Astral_ has quit [Ping timeout: 255 seconds]
m8 has joined #ruby
<becom33>
or if I have given one name and list of action it should go trought each action I've given before
zetabyte has quit []
elux has quit [Quit: Leaving...]
<e-dard>
I as under the impression that the :require => 'foo/base' means that the name of the gem to require is different to the install name - is that right?
<becom33>
and if i gave name and also the actions also a list it should go trough each and each action
wargasm has joined #ruby
<becom33>
I'm confused how to do it
Seventoes has left #ruby [#ruby]
<Hanmac>
e-dard maybe yeah, i do not trust Gemfiles
<becom33>
Hanmac, that will do for the last question I asked
<MrZYX>
e-dard: sort of, bundler will by default run require 'gemname', the require option just lets you specify what should be placed instead there (false disables the automatic require)
m8 has quit [Max SendQ exceeded]
Astralum has joined #ruby
m8 has joined #ruby
<e-dard>
MrZYX: hmm, I wondered if that was it, but I'm still finding I need to add require 'foobar' to my ruby files anyway, as if bundler is not requiring them for me.
<e-dard>
Maybe the issue with that is something else..
<MrZYX>
e-dard: actually there's Bundler.require too (which optionally takes an array of the groups to require)
whitedawg has quit [Quit: Leaving.]
<e-dard>
MrZYX: seems there is a lot of configuration/environment magic in Ruby… Still trying to get my head around config.ru, and wether it's interpreted or parsed, and by what/who :D
tommyvyo has quit [Quit:]
mockra has joined #ruby
<MrZYX>
.ru is just plain ruby and a indicator that this file is the main entry point to a rack application
<Hanmac>
e-dard hm a bit wrong, that is not Ruby, bundler is third-party software
<MrZYX>
also ^, same for rack and sinatra
Zolo has quit [Remote host closed the connection]
<e-dard>
s/Ruby/Ruby Frameworks/
<e-dard>
So config.ru is interpreted and I can put Ruby code in there?
<MrZYX>
yep
Targen has quit [Ping timeout: 245 seconds]
fugetsu has quit [Quit: WeeChat 0.4.0]
<Mon_Ouie>
Most of those things are just evaluated, sometimes in a special context (e.g. with changed self; I believe that's the case of Rack's config.ru)
mneorr has quit [Read error: Connection timed out]
<e-dard>
OK, I think Bundler.require is what I want, and then I can specify the set for testing/dev etc in my config.ru by looking at environment variables. *crosses fingers*
<MrZYX>
yep, the convention is to use RACK_ENV as then variable name
<e-dard>
wohoo, worked! :)
tealmage has joined #ruby
mikurubeam has quit [Quit: +1 (Yes). -1 (No). i (WTF?). j (So you...). k (... want quaternions too?).]
mneorr has quit [Remote host closed the connection]
chussenot has joined #ruby
jurassic has quit [Quit: jurassic]
Mon_Ouie has quit [Ping timeout: 256 seconds]
tealmage has quit [Ping timeout: 248 seconds]
bobdobbs has quit [Ping timeout: 245 seconds]
rvmeier has joined #ruby
motto has joined #ruby
<e-dard>
OK, just so I understand, this is my GemFile and config.ru — are these considered pretty reasonable settings? http://dpaste.com/1018508/
<MrZYX>
e-dard: I'd probably require './views/layout/ inside app.rb and dry up the Bundler.require stuff like so: groups = [:default]; groups << ENV["RACK_ENV"] if ENV["RACK_ENV"]; Bundler.require(*groups); also the convention goes to use test instead of testing for the tests related group, but doesn't look entirely wrong to me :)
averiso has quit [Quit: Computer has gone to sleep.]
<e-dard>
MrZYX: Cool, that all makes sense. Thanks for the pointers.
generalissimo has joined #ruby
__Big0__ has quit [Remote host closed the connection]
<e-dard>
I find when coming over to a new language 50% of the learning seems to be idioms :-)
<MrZYX>
yeah, sure
BizarreCake has joined #ruby
itsdavem has quit [Remote host closed the connection]
<MrZYX>
though ruby might change some of your thinking in the long term as it doesn't put any restrictions on you, it's all just conventions ;)
motto has quit [Ping timeout: 276 seconds]
sirish has joined #ruby
m3pow has quit [Read error: Operation timed out]
lewix has quit [Remote host closed the connection]
colonolGron has joined #ruby
joeycarmello has joined #ruby
one has joined #ruby
hasimo has joined #ruby
jellosea_ has joined #ruby
bricker`1A has joined #ruby
paritosh has joined #ruby
becom33 has quit [Quit: Leaving]
<shevy>
e-dard ruby will spoil you
<shevy>
it makes things often simpler
otters has quit [Ping timeout: 252 seconds]
yacks has quit [Quit: Leaving]
<shevy>
so when you use another language it will often feel harder than it should be :(
bricker`LA has quit [Ping timeout: 245 seconds]
sayan has quit [Read error: Connection reset by peer]
pepper_chico has quit [Quit: Computer has gone to sleep.]
<e-dard>
shevy: we shall see :)
solidoodlesuppor has quit [Remote host closed the connection]
__Big0__ has joined #ruby
<paritosh>
hey friends , i saw following notification There were 4 Ruby vulnerability reports in the last 14 days. 2 medium, 1 low, 1 undetermined. Most recent: CVE-2013-1656
h4mz1d has quit [Ping timeout: 276 seconds]
<paritosh>
and the link is dead . what is that ?
nicoulaj has quit [Read error: Connection reset by peer]
jjbohn|afk is now known as jjbohn
otters has joined #ruby
sirish has quit [Ping timeout: 264 seconds]
mneorr has joined #ruby
mneorr_ has joined #ruby
__Big0__ has quit [Remote host closed the connection]
Takehiro has quit [Remote host closed the connection]
sirish has joined #ruby
carraroj has joined #ruby
<Hanmac>
paritosh: there was all rails bugs :P
Catbuntu has quit [Quit: Leaving]
thone_ has joined #ruby
<MrZYX>
wasn't one yaml and one json?
jellosea_ has quit [Quit: jellosea_]
pyreal has quit [Ping timeout: 245 seconds]
jurassic has joined #ruby
mneorr has quit [Ping timeout: 276 seconds]
<Hanmac>
MrZYX yeah, but it was because the users was to dump to understand the usage of it ... (and that you should check your user input)
<paritosh>
why it is highlighted in red ... it is giving dangerous looks . why ruby is so excited about rails bugs and vulnerability
ananthakumaran1 has quit [Quit: Leaving.]
<Hanmac>
MrZYX do you want to see something scary? look at that:
<Hanmac>
paritosh i dont know and maybe we will never know until the site is back
realDAB has joined #ruby
<Hanmac>
MrZYX its the accactly the same problem with yaml and json ... that symbols chould be generated
jurassic has quit [Client Quit]
blob has quit [Ping timeout: 276 seconds]
<Spooner>
Rails is vulnerable because the average Rails users is a muppet ;) No amount of patches will fix that.
Takehiro has joined #ruby
Takehiro has quit [Read error: Connection reset by peer]
kojulZzZ is now known as kojul
hasimo has quit [Ping timeout: 250 seconds]
<Hanmac>
MrZYX the normal Rails user that mook about creating symbols does not understand that EVERY SHTITY method they define create an symbol too
<shevy>
hehe
axhlf has quit [Remote host closed the connection]
<shevy>
paritosh I am not excited about rails
pepper_chico has joined #ruby
daniel_- has joined #ruby
mootpointer has quit [Quit: Computer has gone to sleep.]
malkomalko has joined #ruby
BizarreCake has quit [Ping timeout: 250 seconds]
Takehiro has joined #ruby
Takehiro has quit [Read error: Connection reset by peer]
kofno has quit [Remote host closed the connection]
jjbohn is now known as jjbohn|afk
<Hanmac>
defining classes, defining methods, setting instance variables, setting class variables, setting constants, setting LOCAL variables ... all of this create Symbols ... but the Fails ah i mean Rails users mook about Yaml and Json
wallerdev has quit [Quit: wallerdev]
Zolo has joined #ruby
wallerdev has joined #ruby
Takehiro has joined #ruby
tjbiddle has joined #ruby
nazty has joined #ruby
h4mz1d has joined #ruby
<Hanmac>
shevy did i forgot something in this list?
__Big0__ has joined #ruby
dagnachew has quit [Quit: Leaving]
lewix has joined #ruby
lewix_ has joined #ruby
JarJar has joined #ruby
Takehiro has quit [Ping timeout: 245 seconds]
jjbohn|afk has quit [Quit: Leaving...]
kofno has joined #ruby
<realDAB>
Hanmac: global variables
<realDAB>
Hanmac: and modules :-)
timonv has joined #ruby
<Hanmac>
ah ok yeah they both too ... (or for short, everything you do in ruby create Symbols :P)
<shevy>
Hanmac hahaha
<realDAB>
indeed
lewix has quit [Ping timeout: 250 seconds]
sonda has quit [Remote host closed the connection]
<MrZYX>
hmmm, puts "foo" does create one? (lets not count the initialization process, that's nothing _I_ do :P)
<realDAB>
MrZYX: no, only when you create identifiers
<realDAB>
MrZYX: or create symbols explicitly, of course (puts :foo)
pepper_chico has quit [Quit: Computer has gone to sleep.]
Xeago has joined #ruby
<MrZYX>
lets say I shadow the puts method, puts = foo, does that create a new one?
<MrZYX>
"foo" of course
<realDAB>
MrZYX: that would not create a new symbol. the :puts symbol already exists in the symbol table.
<Hanmac>
MrZYX: yeah it defines a local variable and a symbol called "foo"
__Big0__ has quit [Remote host closed the connection]
jrajav has joined #ruby
<MrZYX>
hm? defining a string already creates the symbol of the same content?
<Hanmac>
i mean yeah its a "puts" symbol but it already exist
<MrZYX>
so
<realDAB>
MrZYX: you can reuse symbols, so def x; end and x = 1 results in one :x symbol
Nuck has quit [Quit: Nuck Off]
<realDAB>
whoops
<realDAB>
i mean colon-x
<realDAB>
stupid emoticons
__Big0__ has joined #ruby
<MrZYX>
didn't render as one for me :P
<realDAB>
ah, good :-)
Nuck has joined #ruby
banseljaj is now known as imami|afk
<MrZYX>
so, one could write a ruby program doing fairly complex work without every creating a symbol by just reusing what's there after ruby was loaded
<realDAB>
MrZYX: well, that would be rather limiting
<MrZYX>
sure
<MrZYX>
the point is
<MrZYX>
I proved Hanmac wrong :D
kofno has quit [Remote host closed the connection]
jellosea_ has joined #ruby
<MrZYX>
not everything creates a symbol
<Hanmac>
"... or used an already created one"
<realDAB>
MrZYX: well, it creates it if it's not already created
<realDAB>
yeah
kofno has joined #ruby
baroquebobcat has joined #ruby
<realDAB>
MrZYX: you can use Symbol.all_symbols to explore this
__Big0__ has quit [Remote host closed the connection]
h4mz1d has quit [Ping timeout: 260 seconds]
Guest9026 has joined #ruby
mockra has joined #ruby
<Hanmac>
realDAB not so limited as you can think ... running pure ruby gives me 2245 symbols, without gems still 1593
marr has joined #ruby
<realDAB>
Hanmac: it's still very limiting in the sense that you'd have to choose existing ruby identifiers for all your local variable, method, instance variable… etc. names
kofno has quit [Read error: Operation timed out]
<MrZYX>
I'm sure one could figure out a converter script for that
Morkel has quit [Read error: Operation timed out]
<realDAB>
attr_writer = 1 :-)
Morkel has joined #ruby
neku has joined #ruby
Rioji has joined #ruby
rvmeier has quit [Quit: Leaving]
<realDAB>
MrZYX: converter script for what/
<MrZYX>
ruby script creating new symbols -> ruby script not creating new symbols
<MrZYX>
not that it would be useful for anything
hasimo has joined #ruby
timonv has quit [Remote host closed the connection]
mockra has quit [Ping timeout: 245 seconds]
tealmage has joined #ruby
__Big0__ has joined #ruby
whowantstolivef1 has quit [Ping timeout: 248 seconds]
R_Macy_ has joined #ruby
statarb3 has joined #ruby
statarb3 has quit [Changing host]
statarb3 has joined #ruby
__Big0__ has quit [Remote host closed the connection]
jpfuentes2 has joined #ruby
aspiers has quit [Ping timeout: 256 seconds]
<Hanmac>
>> [/@@/,/^@[^@]/,/^[[:upper:]]/].each {|m| p [m, Symbol.all_symbols.count{|s|s.to_s.match(m)}]};nil
<Hanmac>
realDAB and be happy, the bot is Hanmac-proof :P
<realDAB>
heh
Takehiro has joined #ruby
itsdavem has joined #ruby
<realDAB>
Hanmac: where are you (geographically)?
* realDAB
is in new york
stkowski has joined #ruby
itsdavem has quit [Remote host closed the connection]
<Hanmac>
realDAB i am near Dresden
<realDAB>
ach so
tjbiddle has quit [Quit: tjbiddle]
<realDAB>
never been there
<Hanmac>
you should its a nice place
sambao21 has joined #ruby
AndChat| has quit [Ping timeout: 248 seconds]
<realDAB>
i've been to a bunch of german cities, including berlin a number of times, back in the days when i was freelancing and traveling a lot
adeponte has joined #ruby
<Hanmac>
dresden & saxony may has a nazi problem ... but i think new york has a similar problem with rats too
wallerdev has quit [Quit: wallerdev]
<realDAB>
heh
freakazoid0223 has quit [Quit: Leaving]
<realDAB>
a rat crossed /me's path the other night
mneorr_ has quit [Remote host closed the connection]
bluesm has left #ruby [#ruby]
sirish has quit [Ping timeout: 248 seconds]
mneorr has joined #ruby
hasimo has quit [Ping timeout: 248 seconds]
<Hanmac>
RealDAB: about Rats ... "Iran deploys sniper teams in Tehran to battle 'mutant' rats". Quote: For the first time, snipers have deployed in Tehran to combat a plague of "mutant" rats that are increasingly resistant to poison and have grown so big that cats are scared of them.
<Spooner>
Actually, it makes no sense that -1 is December of the previous year, since 0 is invalid. Think of it more like an array. -1 is the last month.
<kraljev>
how should i do that properly
<Spooner>
-1 is the last element, -2 is the second to last (November).
i42n_ has joined #ruby
<swarley>
>> require 'date'; p Date.ordinal(2010, -1, 1)
<kraljev>
trying to transform PostgreSQL interval datatype
chussenot has joined #ruby
<kraljev>
which can have negative values
<Spooner>
That data sounds terribly broken to me.
banisterfiend has joined #ruby
<i42n_>
hey guys, I need to pass a second :except here, but I do not know how to write that in ruby. can you help me? http_basic_authenticate_with :name => "test", :password => "test", :except => "info", :except => "overview"
<Spooner>
But you could do Date.new(m < 0 ? y : y - 1, m, d)
Choobie has joined #ruby
<Spooner>
i42n_, Probably :except => ["overview", "info"] (if it is possible).
<MrZYX>
i42n_: sounds like rails, so -> #rubyonrails but you probably can just pass an array into it
Choobie has left #ruby [#ruby]
<swarley>
okay, this is how you deal with dates. Like a unix programmer
<Spooner>
swarley, You can just do Date.new(...) - 31 to move back 31 days ;)
<becom33>
>> Array(a || b)
<eval-in>
becom33 => /tmp/execpad-da2973288af7/source-da2973288af7:2:in `<main>': undefined local variable or method `a' for main:Object (NameError) (http://eval.in/12339)
<i42n_>
Spooner: thanks! Your array solution worked. I tried before :except => {"overview", "info"}. Did not work. What happens in this case? Can you tell me why this does not work?
Gadgetoid has quit [Read error: Connection reset by peer]
<becom33>
Hanmac, oh I think I get it
<becom33>
wait wait let me try
<_bart>
Isn't setting forState:(UIControlStateNormal|UIControlStateSelected|UIControlStateHighlighted) the same as setting it for the three states seperately?
Xeago has quit [Killed (rajaniemi.freenode.net (Nickname regained by services))]
Xeago_ is now known as Xeago
Husel has joined #ruby
<becom33>
I'm slow learner sorry for that
aed has joined #ruby
arturaz has joined #ruby
jekotia has joined #ruby
kirotan has joined #ruby
<Hanmac>
i have seen more dumb ones :P
Elhu has joined #ruby
Elhu has quit [Client Quit]
<_bart>
Ah haha Hanmac, I asked this is the wrong channel, but thanks for the kind response
chussenot has quit [Quit: chussenot]
raggedjack has joined #ruby
mockra has joined #ruby
cjk101010 has quit [Ping timeout: 252 seconds]
Gadgetoid has joined #ruby
havenwood has quit [Remote host closed the connection]
mneorr has joined #ruby
<becom33>
Hanmac, i got a give u little more trouble how can I do validations like -u suppose to be a string but if I give it the text file it will throw a error `foreach': can't convert nil into String (TypeError)
pencilcheck has quit [Remote host closed the connection]
paritosh has quit [Quit: Leaving]
wallerdev has joined #ruby
rippa has quit [Ping timeout: 240 seconds]
hasimo has quit [Ping timeout: 245 seconds]
jrajav has quit [Quit: I tend to be neutral about apples]
cjk101010 has joined #ruby
jurassic has joined #ruby
mockra has quit [Ping timeout: 245 seconds]
kofno has joined #ruby
i42n_ has quit [Quit: afk.]
mritr_ has joined #ruby
joeycarmello has quit [Remote host closed the connection]
io_syl has joined #ruby
mneorr_ has joined #ruby
david_a_black has quit [Quit: david_a_black]
jpfuentes2 has quit [Quit: Computer has gone to sleep.]
Takehiro has joined #ruby
nazty has quit [Read error: No route to host]
nazty has joined #ruby
kofno has quit [Ping timeout: 250 seconds]
mneorr has quit [Ping timeout: 245 seconds]
zz_R_Macy is now known as R_Macy
kojul has quit [Quit: kojul]
objectivemo has quit [Quit: objectivemo]
<Mattix>
Hanmac, even if there's a ruby1.9.1-full, it doesn't install the ruby interpreter, just some libs.. or so it seems
Takehiro has quit [Ping timeout: 252 seconds]
sambao21 has quit [Quit: Computer has gone to sleep.]
Guest85414 has quit [Read error: Operation timed out]
iaj has quit [Read error: Operation timed out]
iaj has joined #ruby
atmosx has quit [Quit: And so the story goes…]
teamon has quit [Read error: Operation timed out]
teamon has joined #ruby
Guest85414 has joined #ruby
sepp2k1 has quit [Quit: Leaving.]
Chryson has quit [Ping timeout: 248 seconds]
mritr_ has quit [Ping timeout: 240 seconds]
jetblack has joined #ruby
danman has quit [Quit: danman]
pen has quit [Remote host closed the connection]
Neomex has joined #ruby
Neomex has quit [Client Quit]
huoxito has joined #ruby
jurassic has quit [Quit: jurassic]
jurassic has joined #ruby
banisterfiend has quit [Ping timeout: 248 seconds]
juarlex_ has joined #ruby
icole has quit [Remote host closed the connection]
m8 has joined #ruby
mockra has joined #ruby
rgoodwin has joined #ruby
juarlex has quit [Ping timeout: 252 seconds]
<rgoodwin>
probably a very simple question, but if you have an array of objects, and then want to iterate through them, how do you specify the proper class type for those objects so you can use their methods/attributes?
<MrZYX>
might not be faster but I prefer compact in such cases
<rgoodwin>
but it should work without that right?
Chryson has joined #ruby
<e-dard>
Hi, if I have instance methods on a Sinatra::Base application can I test them using rspec without running the app in a server?
<e-dard>
Or do i have to use rack testing stuff?
<Hanmac>
all three ways can keep nils away: 1) because nil is false in an if, 2) class check, because nil is its own class 3) duck-typing, check not the class, but check the method you want
blacktulip has joined #ruby
<rgoodwin>
yup makes total sense. i suspect maybe it's also because i traversed into an objective C/cocoa array, instead of a ruby native, which seems silly now that i think about it
<Hanmac>
MrZYX depends if you want have an array or Enumerator, ... compact does create an big Array, there might be better ways
Bosox20051 has quit [Remote host closed the connection]
<Mattix>
OMG, something is wrong with all binaries/gems related to ruby/rails
<Mattix>
I can't even execute gem
<Mattix>
I need to use gem1.9.1 instead
<Mattix>
same for bundle, it's not found as "bundle"
hasimo has quit [Read error: Connection reset by peer]
<Mattix>
any idea?
adeponte has joined #ruby
<MrZYX>
debian doesn't put gem binaries into your $PATH
hasimo has joined #ruby
<rgoodwin>
meh. ok i'm just going to tell myself "use is_a? to keep the nils away)
<rgoodwin>
"
kraljev has quit [Ping timeout: 250 seconds]
<MrZYX>
rgoodwin: just don't let them in in the first place :P
<Hanmac>
rgoodwin: you can also do: unless obj.nil?
bonhoeffer has quit [Quit: bonhoeffer]
<rgoodwin>
yah i'm not sure how a nil is getting there
ryanf_ has quit [Quit: broken pipes |||]
<Mattix>
you mean I have to add /var/lib/gems/1.9.1/bin to PATH in .profile MrZYX?
<MrZYX>
yeah it was something like that if I recall correctly
<Hanmac>
Mattix: there are some ruby binarys you want to link too, like gem, rdoc and ri
<Mattix>
why doesn't it work by default?
<MrZYX>
because debian always knows it better than upstream
<Mattix>
if I'm not wrong, I didn't have to do so in this computer (debian testing)
kirun has quit [Quit: Client exiting]
<rgoodwin>
oh, rgoodwin, is it because you are traversing over the source data's limits because of 0 based counting screwup?
<e-dard>
I tried require 'path/to/config.ru' but got a LoadError.
<apeiros_>
that wouldn't work anyway
<apeiros_>
while it is plain ruby code, it is expected to be evaluated in a specific context.
<apeiros_>
check e.g. the rackup executable
KRF has joined #ruby
butblack has quit [Quit: butblack]
<canton7>
what exactly are you trying to do?
<apeiros_>
additionally, when you `require path`, path must be relative to any dir in $LOAD_PATH, and I think it requires a known suffix (so .ru is out)
realDAB has joined #ruby
<e-dard>
I'm trying to run spec tests in Sinatra app
<MrZYX>
move your environment setup into a separate file in require that from config.ru and your test setup file
Stilo has joined #ruby
<e-dard>
OK.
<davidcelis>
% gem update --system # => ERROR: Gem names are not allowed with the --system option
<davidcelis>
That's happening on 2.0.0 under OS X
Mon_Ouie has joined #ruby
<davidcelis>
obviously i am not supplying an gem names
<e-dard>
It seems as soon as you get something sorted for shotgun I need to redo it for testing :-/
malkomalko has joined #ruby
<canton7>
e-dard, tried sinatra-reloader?
<e-dard>
canton7: no, but that sounds like exactly what shotgun gives me anyway?
<e-dard>
(a server that detects changes and reloads)
* apeiros_
sobs silently and goes back to reading silly webcomics
Mon_Ouie has quit [Changing host]
Mon_Ouie has joined #ruby
zomgbie has quit [Ping timeout: 245 seconds]
pepper_chico has quit [Quit: Computer has gone to sleep.]
<canton7>
e-dard, not quite. shotgun works by forking your app every time it's called, then discarding the fork straight after. sinatra-reloader manually reloads files as they change
<apeiros_>
davidcelis: afaik 2.0.0 and 2.0.1 were broken
<canton7>
so shotgun works as a utility which runs your sinatra app, and sinatra-reloader is just an extension - you use thin or whatever to run the app
mephux has quit [Quit: w0ots...]
Blaze_Boy has quit [Remote host closed the connection]
pedahzur has joined #ruby
h4mz1d has quit [Ping timeout: 240 seconds]
Guest90776 has joined #ruby
<whitequark>
apeiros_: what makes you so sad?
<Hanmac>
apeiros_ i think thats why he trys to update rubygems :D
<pedahzur>
Howdy. New to ruby. Looking at the latest Pick Axe book (currently in beta). It says it covers 1.9 and 2.0, while explaining the changes from 1.8 to 1.9. We have existing apps in 1.8, but going forward they will probably be written in 1.8 or later. Does the latest book explain enough of 1.8 that I'd be able to work on the old apps without too much confusion? And I realize, the existing Ruby docs would always be available to me.
tealmage has quit [Remote host closed the connection]
<rubarlion>
where is +make+. that I need to Run to compile from source?
<whitequark>
rubarlion: ./configure it first
<rubarlion>
did
F1skr has quit [Quit: WeeChat 0.4.0]
s__dana has quit [Ping timeout: 260 seconds]
<canton7>
pedahzur, there's not *that* much difference between 1.8 and 1.9
<whitequark>
rubarlion: wait you lack `make`? try `gmake` then
<whitequark>
(just guessing)
samphippen has joined #ruby
<Hanmac>
pedahzur: 1.8 will be DIE this year ...
<canton7>
it's not like python 2 and python 3. you can pick up the main differences in 10 mins or so
<Hanmac>
canton7 a bit wrong there are stuff that keeps 1.9 from runing 1.8 code ... like case obj; when val: xyz
dmoctezuma has joined #ruby
atmosx has quit [Quit: And so the story goes…]
kornnflake is now known as kornnflake_zzz
Guest90776 has quit [Ping timeout: 248 seconds]
<rubarlion>
whitequark: Makefile.in
<rubarlion>
?
<whitequark>
rubarlion: no, you should have `Makefile` after configure succeeds
mephux_ has joined #ruby
<andrewh>
does anyone here use stdlib option parsing libraries or just go for something like thor?
mephux_ is now known as Guest25251
emocakes has joined #ruby
Guest25251 has quit [Excess Flood]
<e-dard>
Thanks all, I made a config/boot.rb and required it from various places.