fflush changed the topic of #ruby to: Ruby 1.9.3-p194: http://ruby-lang.org || Paste > 3 lines of text on pastebin.com
DrShoggoth has joined #ruby
bradleyprice has quit [Remote host closed the connection]
r1ddl3r has quit [Quit: Leaving.]
bradleyprice has joined #ruby
sneakyness_wk has quit [Quit: bro]
lggr has quit [Ping timeout: 256 seconds]
jenrzzz has joined #ruby
csmrfx has left #ruby ["ciao"]
sarmiena_ has quit [Quit: sarmiena_]
JetAway has joined #ruby
CaptainJet has quit [Disconnected by services]
JetAway is now known as CaptainJet
awarner has joined #ruby
lggr has joined #ruby
erichmenge has joined #ruby
iamjarvo has joined #ruby
<bricker>
When I define a class inside of another class, like class Audio; class Uploaded; end; end;, it's at Audio::Uploaded. Has "Audio" been turned into a module? Can I do module Audio in another file, or does it have to always be class Audio?
murz has joined #ruby
newtnik has joined #ruby
r1ddl3r has joined #ruby
davidcelis has joined #ruby
rakl has quit [Quit: sleeping]
lggr has quit [Ping timeout: 256 seconds]
slainer68 has joined #ruby
glyytchy has quit [Quit: Leaving...]
bradleyprice has quit [Remote host closed the connection]
<blazes816>
bricker, no, it is not a module. it's still a class
cburyta has quit [Remote host closed the connection]
riley526 has joined #ruby
<blazes816>
the class simply contains a new constant, who's value is the new class (Uploaded)
Tearan has joined #ruby
lggr has joined #ruby
cburyta has joined #ruby
rubious has quit [Remote host closed the connection]
ckrailo has quit [Quit: Computer has gone to sleep.]
bradyl0ve has joined #ruby
yshh has joined #ruby
CJNE has joined #ruby
rubious has joined #ruby
sarmiena_ has joined #ruby
iamjarvo has quit [Ping timeout: 245 seconds]
slainer68 has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 260 seconds]
Coad has quit [Ping timeout: 276 seconds]
eignerchris has quit [Remote host closed the connection]
rakl has joined #ruby
devtro has quit [Quit: devtro]
newtnik has quit [Quit: Leaving]
lggr has joined #ruby
mikepack has quit [Remote host closed the connection]
CJNE has quit [Ping timeout: 252 seconds]
AndChat- has joined #ruby
<bricker>
blazes816: I see. So namespace (Audio::) has nothing to do with inheritance, subclasses, etc.
Banistergalaxy has quit [Ping timeout: 260 seconds]
Virunga has quit [Read error: Connection timed out]
lggr has quit [Ping timeout: 255 seconds]
LouisGB has joined #ruby
Virunga has joined #ruby
tvw has joined #ruby
manizzle has joined #ruby
dr_bob has quit [Read error: Connection reset by peer]
dr_bob has joined #ruby
Eplemosen has joined #ruby
chussenot has joined #ruby
wargasm has quit [Read error: No route to host]
lggr has joined #ruby
wargasm has joined #ruby
vectorshelve has quit [Ping timeout: 240 seconds]
timmow has joined #ruby
justsee has quit [Quit: Leaving...]
ndrei has joined #ruby
corlinfive has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
chimay has joined #ruby
lggr has joined #ruby
ndrei has quit [Remote host closed the connection]
roadt has quit [Ping timeout: 260 seconds]
Agis__ has joined #ruby
<Agis__>
do you guys use bundle gem <name> for creating a new gem? or ?
statarb3 has quit [Quit: Leaving]
pitty has joined #ruby
triptec has joined #ruby
fyolnish_ has quit [Remote host closed the connection]
nilg` has joined #ruby
rakl has joined #ruby
pitty has quit [Read error: Connection reset by peer]
banisterfiend has joined #ruby
nilg has quit [Ping timeout: 240 seconds]
lggr has quit [Ping timeout: 248 seconds]
cascalheira has joined #ruby
clocKwize has joined #ruby
pitty has joined #ruby
CodeFriar has quit [Quit: Leaving...]
lggr has joined #ruby
banisterfiend has quit [Ping timeout: 268 seconds]
Eplemosen has quit [Ping timeout: 245 seconds]
noxoc has joined #ruby
pskosinski has joined #ruby
banisterfiend has joined #ruby
pitty has quit [Ping timeout: 245 seconds]
roadt has joined #ruby
lggr has quit [Ping timeout: 240 seconds]
Criztian has joined #ruby
lggr has joined #ruby
wargasm1 has joined #ruby
wargasm has quit [Read error: Connection reset by peer]
swistak35 has quit [Ping timeout: 246 seconds]
_mak has quit [Remote host closed the connection]
ttt has joined #ruby
postmodern has quit [Ping timeout: 252 seconds]
workmad3_ has joined #ruby
wargasm has joined #ruby
samphippen has quit [Quit: Computer has gone to sleep.]
wargasm1 has quit [Read error: Connection reset by peer]
monkegjinni has quit [Ping timeout: 260 seconds]
CodeFriar has joined #ruby
tonini has quit [Remote host closed the connection]
workmad3 has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 248 seconds]
vitoravelino`afk is now known as vitoravelino
banister_ has joined #ruby
<banister_>
any americans awake here?
* hoelzro
raises his hand
Vainoharhainen has joined #ruby
wargasm has quit [Ping timeout: 246 seconds]
<banister_>
hoelzro: thanks
<banister_>
hoelzro: im trying to understand the linkedin address
<banister_>
it says
<matti>
hoelzro: Nooo....
<banister_>
2029 Stierlin Court
<banister_>
Mountain View, CA 94043
bigkevmcd has quit [Quit: outta here]
<banister_>
UNITED STATES
lggr has joined #ruby
bigkevmcd has joined #ruby
<hoelzro>
matti: ?
<matti>
hoelzro: Run! He is dangerous :)
<banister_>
hoelzro: but it doesnt say anything about san francisco, i thought linkedin was based there? in which case what is 'mountain view' ?
nari has quit [Ping timeout: 268 seconds]
<hoelzro>
Mountain View is a city/town/something in CA
<hoelzro>
very close to SF
<banister_>
hoelzro: oh, so it's not actually in SF
<banister_>
hoelzro: cos i was unsure whether i shoudl put SF for the city
<hoelzro>
I don't believe so
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
<banister_>
ah, cool
<banister_>
hoelzro: thanks :)
Shrink has quit [Read error: Connection reset by peer]
<hoelzro>
np
knirhs has joined #ruby
duracrisis has quit [Ping timeout: 256 seconds]
monkegjinni has joined #ruby
Spami has joined #ruby
<Spami>
hello
<matti>
Hi
Markvilla has joined #ruby
<Spami>
I try to load the gem 'curb' in my ruby file but I have this error: `require': cannot load such file -- curb (LoadError) Curb is not in my bundle but I have require 'ruby gems' at the beginning of my file
wargasm has joined #ruby
<Spami>
any idea ?
bluenemo has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
jenrzzz has joined #ruby
samphippen has joined #ruby
lggr has joined #ruby
xpen has joined #ruby
_mak has joined #ruby
wargasm1 has joined #ruby
<JonnieCache>
if you have loaded bundler then from then on you cannot load gems that arent in the gemfile
wargasm has quit [Ping timeout: 246 seconds]
banisterfiend has quit [Ping timeout: 255 seconds]
<JonnieCache>
you shouldnt require rubygems, just load bundler with `require "bundler/setup"` and everything is done
Juul has joined #ruby
binw has quit [Remote host closed the connection]
Dawne has joined #ruby
rippa has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
A124 has joined #ruby
wargasm has joined #ruby
Xeago has joined #ruby
lggr has joined #ruby
wargasm1 has quit [Ping timeout: 246 seconds]
<Xeago>
kwilczynski, you're crazy
fermion has joined #ruby
<Spami>
JonnieCache, Yes. I've used the bundle
<Spami>
But I'm still frustrated
frogprince_mac has joined #ruby
CodeFriar has quit [Quit: Leaving...]
wargasm1 has joined #ruby
wargasm has quit [Ping timeout: 256 seconds]
torarne has joined #ruby
ForevernadeAFK has joined #ruby
hsbt is now known as hsbt_away
lggr has quit [Ping timeout: 240 seconds]
wargasm has joined #ruby
wargasm1 has quit [Read error: Connection reset by peer]
Forevernade has quit [Ping timeout: 252 seconds]
xpen has quit [Remote host closed the connection]
lggr has joined #ruby
<torarne>
Q: What's the correct way to develop (and install) a gem that depends on HEAD of another gem (that hasn't been tagged as a version yet)? As far as I can tell the gemspec does not allow non-versioned depends. I tried using bundler, but after 'bundle install' the depend has been installed from git, but my own gem has been somehow halfway installed. Should bundle install also install my gem, or do I need to do a 'gem build foo.gemspec' as well?
x0F has quit [Disconnected by services]
x0F_ has joined #ruby
<workmad3_>
torarne: it's not something gemspec supports
x0F_ is now known as x0F
<workmad3_>
torarne: the only ways are to either build the gem yourself from head and install it, or let bundler handle that for you
<workmad3_>
torarne: but if you let bundler do it, the gem won't be installed into the normal gem repo, it will only be available via 'bundle exec' magic
frogprince_mac has quit [Quit: Leaving...]
reset has quit [Quit: Leaving...]
freeayu__ has quit [Read error: Connection reset by peer]
<torarne>
workmad3_: hmm, okey, so how do i set up installation instructions for my gem for users then? i assume they can't do gem install mygem, since the gemspec is not enough?
Mon_Ouie has joined #ruby
<torarne>
workmad3_: some variant of git clone myrepo && bundle install && gem build mygem.spec && gem install mygem.gem?
<workmad3_>
torarne: pretty much... you also won't be able to push it to rubygems until the dependencies are satisfied
<workmad3_>
torarne: which all makes sense if you think about it... the gem hasn't been released, it could never be released and probably won't be released in the current form
<torarne>
okey, that's fine
<workmad3_>
torarne: if it's not a gem you control, it's generally advised to only depend on released versions
lggr has quit [Ping timeout: 246 seconds]
<torarne>
but i need features that were patched in HEAD and haven't been released yet :/
<workmad3_>
unfortunate
<JonnieCache>
oh christ its "jimmy wales' scary face" month again
<JonnieCache>
how time flies!
<torarne>
is there a way to pull down the depend gem into vendor and ship it with my gem?
My_Hearing has joined #ruby
<torarne>
to work around the whole bundle install thingie?
<workmad3_>
torarne: not really... but what you can do is depend on a released version and conditionally monkey-patch the fixes in
Mon_Ouie has quit [Disconnected by services]
My_Hearing is now known as Mon_Ouie
Vainoharhainen has quit [Read error: Connection reset by peer]
margle has quit [Quit: Computer has gone to sleep.]
<workmad3_>
torarne: which would mean you have the patches to the gem in your code-base, check to see if they exist in the gem and if they don't then you add them in your code
<workmad3_>
torarne: it's a bit of a hack, but it allows a way around the issue that doesn't compromise the integrity of your dependencies
<torarne>
workmad3_: i see. is that supported by gemspec etc?
monkegjinni has quit [Read error: No route to host]
<workmad3_>
torarne: it isn't a gemspec feature
<torarne>
will it work for users who do gem install mygem?
<workmad3_>
torarne: it's something you'd do within your gem code
<torarne>
oh
<torarne>
hm
monkegjinni has joined #ruby
lggr has joined #ruby
freeayu has joined #ruby
fyolnish has joined #ruby
<Xeago>
any designer willing to design a website for fizzbuzz?
<torarne>
workmad3_: so if I do bundle install, and end up with "Using xcoder (0.1.12) from git://github.com/rayh/xcoder.git (at master) ", and then do gem build and gem install, will my installed gem then use xcoder from git (as installed by bundler)?
eikko has quit [Read error: Connection reset by peer]
eikko has joined #ruby
CodeFriar has joined #ruby
<torarne>
workmad3_: cause when i do bundle install it says "Fetching: xcoder-0.1.12.gem", even if i had bundler install it from git
fyolnish has quit [Ping timeout: 240 seconds]
justsee has quit [Quit: Leaving...]
lggr has quit [Ping timeout: 245 seconds]
`brendan has quit [Quit: - nbs-irc 2.39 - www.nbs-irc.net -]
haxrbyte has joined #ruby
Guedes has joined #ruby
Guedes has joined #ruby
Guedes has quit [Changing host]
rippa has quit [Ping timeout: 240 seconds]
hsbt_away is now known as hsbt
haxrbyte_ has joined #ruby
justsee has joined #ruby
justsee has quit [Changing host]
justsee has joined #ruby
lggr has joined #ruby
thomas`- has joined #ruby
awestroke has quit [Remote host closed the connection]
<matti>
Hi Xeago ;]
<Xeago>
hai :)
haxrbyte has quit [Ping timeout: 276 seconds]
<Xeago>
what about a hose?
<Xeago>
s/a/the
<matti>
Hose?
samphippen has quit [Quit: Computer has gone to sleep.]
<thomas`->
Hi everyone. I am having trouble understand the rules of OOP. To manage the files (for instance) that belong to my user class, which of the following is best (or please let me know if you have a better solution) : file = new File(user); file.insert(type, size, category); file.retreive_all(); OR file = new File(user, type, size, category); File::retrieve_all(user)
<Xeago>
File::retrieve_all(user) looks like c, besides namespaces
lggr has quit [Ping timeout: 240 seconds]
<Xeago>
why: you're passing an object instead of calling it on an object
<burgestrand>
There are no rules, only guidelines and context
<thomas`->
Xeago, i dont know actually. Is it better practive to have the files class inside the User class?
MHD has joined #ruby
<Xeago>
thomas`-: depends on your scenario
<MHD>
What is the general way to make factory methods in ruby?
freeayu has joined #ruby
<Xeago>
you can also open up User from your File related stuff and add files methods
<Xeago>
MHD: factorygirl
<shevy2>
def foo
<shevy2>
Something.new
<shevy2>
end
<MHD>
Wait
<MHD>
Oh, right
<MHD>
I want a Class factory
<shevy2>
thomas`- that is not ruby code. do you come from PHP or something? "new File" is not proper
<MHD>
for making, say HTML tags
<Xeago>
MHD: look at gems that exist
<shevy2>
thomas`- also - Foo::method() is longer to type than Foo.method()
<Xeago>
don't make your own crap, you'll bathe in it soon
<MHD>
I am not using it in production code
<MHD>
I am using it to get good at ruby
<shevy2>
MHD I think only rails uses "factory methods" :)
<MHD>
okay
<shevy2>
rails has its own specific ruby style
<shevy2>
I dont even understand the ActiveRecord source code
samphippen has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
whaley has joined #ruby
<MHD>
How do I make object creation memoize?
Hamed-R has quit [Quit: Leaving]
<shevy2>
what?
3JTAAFCE6 has joined #ruby
<shevy2>
why do you use so funny words
<shevy2>
"memoize"
<MHD>
Thing.new(:a).equal? Thing.new :a
<MHD>
I am a hardcore functional programmer
<MHD>
Thus the CS terminology
<Mon_Ouie>
You use another method than new for getting your instances
<MHD>
:/
<matti>
shevy2: I can't even pronounce this "memoize".
dju has joined #ruby
<shevy2>
matti: not even when drunk?
<MHD>
matti: memo - ize
<matti>
memooooblurg
lggr has joined #ruby
<MHD>
Like memorize
<shevy2>
what is wrong with == or === MHD?
<matti>
French-sounding words in English ;p
<JonnieCache>
memoize is not a fancy word
<shevy2>
let me change my nick...
shevy2 is now known as shevy
<MHD>
shevy2: not Common Lispy enough
<matti>
JonnieCache: I am just being silly ;p
<JonnieCache>
thats the almost first thing they teach you in cs
<shevy>
the 2 is appended when my silly ISP disconnects me, then xchat reconnects me after half a minute...
<shevy>
is memoize actually a proper english word?
<MHD>
yes
<shevy>
it reads as if someone forgot a 'r'
<matti>
I don't know anything about CS ;/
<JonnieCache>
memoization is just def foo; @foo ||= bar(); end
<Xeago>
In computing, memoization is an optimization technique used primarily to speed up computer programs by having function calls avoid repeating the calculation of results for previously processed inputs. Memoization has also been used in other contexts (and for purposes other than speed gains), such as in simple mutually recursive descent parsing in a general top-down parsing algorithm that accommodates ambiguity and left recursion in polynomial t
<Xeago>
ime and space. Although related to caching, memoization refers to a specific case of this optimization, distinguishing it from forms of caching such as buffering or page replacement. In the context of some logic programming languages, memoization is also known as tabling; see also lookup table.
<Xeago>
there ya go :)
<shevy>
I forgot to memorize memoize
<JonnieCache>
lookup tables ftw
margle has joined #ruby
<shevy>
JonnieCache, what does this mean... if @foo does not exist yet, call a method and assign that value to @foo ?
<Mon_Ouie>
def foo; @foo ||= compute_foo; end
<MHD>
Immutable graph reduction ftw
<matti>
shevy: CS rap: sympathize with all the people that memoize...
<shevy>
aha
<shevy>
MHD I am going to call you the buzzword master!
<matti>
Who Enjoiiiii is this?
<matti>
||=
<MHD>
Oh, I can buzz much worse
<matti>
Does not look like |^-^|=
<matti>
Which is a Neko-ish.
Juul has quit [Ping timeout: 240 seconds]
<shevy>
@foo |^-^|= generate_foo
<shevy>
I am going to write a language that uses smileys as operators
<MHD>
Brb, defining |^-^|= as an operator in Haskel
<matti>
shevy: And for handling nil -- |o_O|=
<shevy>
lol
<shevy>
hahaha :)
<shevy>
no wait
<shevy>
that is not good
<shevy>
look:
<shevy>
|o_O|
<shevy>
|O_o|
<shevy>
there would be two nils
<MHD>
left nil and right nil
<MHD>
the difference is subtle
KevinSjoberg has quit [Quit: Computer has gone to sleep.]
Takehiro has quit [Remote host closed the connection]
<matti>
MHD: Devil lie in the details ;p
<MHD>
I think I must find myself a prototype-based language now
timonv has quit [Remote host closed the connection]
margle has quit [Client Quit]
samphippen has quit [Quit: Computer has gone to sleep.]
timonv has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
KevinSjoberg has joined #ruby
lggr has joined #ruby
samphippen has joined #ruby
<matti>
Haha
justsee has quit [Quit: Leaving...]
<matti>
We can have \|>_<|/ to handle exceptions.
<matti>
;d
timonv has quit [Ping timeout: 264 seconds]
<matti>
Gundam style one ;p
Virunga has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 240 seconds]
<JonnieCache>
doesnt that already exist?
<thomas`->
Xeago, the only disadvantage to your User.files approach that i see is that you have to create a new instance of File class every time the user class is instantiated (rather than on demand). Is this correct?
<JonnieCache>
i think theres a brainfuck variant that uses smileys
arietis has joined #ruby
<thomas`->
That is unless I accessed it via User->files()->the_method(etc)
KevinSjoberg has quit [Quit: Computer has gone to sleep.]
chimay has quit [Quit: WeeChat 0.4.0-dev]
chimay has joined #ruby
vitoravelino is now known as vitoravelino`afk
lggr has joined #ruby
KevinSjoberg has joined #ruby
KevinSjoberg has quit [Client Quit]
<matti>
JonnieCache: Hm. There is Ook! ...
<matti>
JonnieCache: There are so many of them ;]
<whackatre>
what is the best alternative to constructor overloading?
frogprince_mac has joined #ruby
<workmad3_>
whackatre: to do what?
manizzle has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 260 seconds]
<whackatre>
for example, let's say we have a rectangle class with default constructors width, height, x, and y.
<whackatre>
but let's say we want to have another constructor that allows another rectangle to be copied
<whackatre>
like, def copy_rect(rect)
<Mon_Ouie>
The usual name for that operation is #replace
<Mon_Ouie>
(e.g. String, Hash, and Array have it with this name)
Agis__ has quit [Quit: Agis__]
<workmad3_>
man, it's been a while since I've used copy-constructors
lggr has joined #ruby
<workmad3_>
whackatre: why not just duplicate or clone the rectangle? why invoke a copy-constructor style 'thing'?
<workmad3_>
whackatre: e.g. 'new_rect = rect.dup'
josh^ has quit [Ping timeout: 246 seconds]
<whackatre>
that's what i was thinking, but i'm just so used to java's style of multiple constructors. thanks.
<workmad3_>
whackatre: even better, as long as you only want a shallow-copy, then you get .dup and .clone out-the-box with ruby ;)
jenrzzz has quit [Ping timeout: 245 seconds]
awestroke has joined #ruby
supd has joined #ruby
<Mon_Ouie>
Ruby actually has #initialize_copy, which is the variant of #initialize that gets called when you use #dup or #clone
<Mon_Ouie>
(It also has #initialize_clone and #initialize_dup if you need more specialization)
<gyre007>
we are trying to install pg gem...but it's failing when building native extensions...saying t's missing libpq library....however that library IS installed....https://gist.github.com/3858077
<gyre007>
Ive run out of ALL ideas...
<gyre007>
anyone has any ??
slainer6_ has joined #ruby
<JonnieCache>
maybe you need to tell it the path
josh^ has joined #ruby
<workmad3_>
gyre007: what do you get if you run 'which pg_config'?
gani has joined #ruby
<gyre007>
workmad3_, let me see
<gyre007>
/usr/bin/pg_config
<workmad3_>
gyre007: hmm, ok looking at the output again it does find that
lggr has quit [Ping timeout: 245 seconds]
<workmad3_>
gyre007: looking at the output, it can't find the PQconnectdb function in the library
hsbt is now known as hsbt_away
<workmad3_>
gyre007: which is worrying
<gyre007>
yeah
<gyre007>
weird
slainer68 has quit [Ping timeout: 240 seconds]
hsbt_away is now known as hsbt
josh^ has quit [Remote host closed the connection]
<workmad3_>
matti: yeah, that doesn't sound like Zed...
<shevy>
sure, he used to have a rant, but he took it off when he was too ashamed of it at a later time again
<matti>
That was not Zed.
<shevy>
!!!
<matti>
?!?!
<shevy>
who else was it... his evil twin brother??
<matti>
An impostor.
Pochacco has joined #ruby
<matti>
Shaw A Ze
<matti>
Shaw A Zed
<matti>
;]
<shevy>
oh man
<kaleido>
this would be a great time for a flash-in of speed racer with an exxagerated "unghgunnghghghngug"
<shevy>
I am going to do this too
<matti>
kaleido: Hahaha
dju has joined #ruby
<shevy>
everytime I write controversial stuff, I am going to say it was my evil twin
<matti>
shevy: Every time I write controversial stuff, I say you made me do it ;]
nitti has quit [Remote host closed the connection]
<franksch>
trying to understand bundler, gems and so on - how does the generated gem in the pkg folder get loaded?
wuzzzzaah has quit [Quit: wuzzzzaah]
no_worries has joined #ruby
<matti>
franksch: ?
dnstbr has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
carlyle has joined #ruby
<franksch>
when I clone vagrant and do a bundle exec how does it know to use pkg/vagrant<version>.gem?
the_jeebster has joined #ruby
daniel_hinojosa has joined #ruby
margle has joined #ruby
<matti>
franksch: I think it just look for *.gem and installs the first one there.
<franksch>
I mean is it a convention or is it part of bundler
<matti>
franksch: Probably rubygems.
<franksch>
I am learning about ruby and all these tools so I am not sure what is a convention and which tool is doing what
FeurFrei has joined #ruby
cakehero has joined #ruby
ZubKonst_ has joined #ruby
awarner has quit [Remote host closed the connection]
<matti>
franksch: gem / Ruby gems are what builds / assembles you a Gem file.
<JonnieCache>
zed shaw is his own evil twin
<franksch>
yes
<shevy>
franksch bundler came after gem
<matti>
franksch: Bundler is a dependency management / execution dependency mangement tool
<franksch>
and then it stores it under pkg
<franksch>
ok
<shevy>
they try to be like the magical app that solves all problems
<matti>
JonnieCache: We do.
<matti>
JonnieCache: banister has two, even ;]
<shevy>
rubygems is much simpler, every program has a .gem file
<shevy>
and all installed .gem files are stored locally
<shevy>
i.e. usually in a cache/ subdirectory
<shevy>
like /usr/lib/ruby/gems/1.9.1/cache/ for some sane linux systems
<franksch>
yes but the vagrant gem only stored under pkg not system-wide
<franksch>
so I was curious how it could still find it
<shevy>
insane linux systems like debian change this and thus confuse the poor souls who think that debian is great
<shevy>
where is the vagrant gem?
<matti>
shevy: Under the bed.
<shevy>
lol
<workmad3_>
shevy: bundler does just use rubygems, you realise? bundler basically only hooks in for dependency resolution
mohits has joined #ruby
<franksch>
hehe
lggr has joined #ruby
ZubKonst has quit [Ping timeout: 246 seconds]
<shevy>
workmad3_ bundler fails for me where gem does not
mohits has quit [Remote host closed the connection]
<workmad3_>
shevy: rubygems fails for me where bundler does not :P
vmatiyko has joined #ruby
<shevy>
bundler's fail chance is about ten times higher than gem's fail chance
<workmad3_>
shevy: I've yet to have bundler fail on me
<shevy>
it failed for me when I tried to official rails tutorial
<shevy>
*the
<workmad3_>
shevy: and I've had rubygems dependency resolution crap out on me nastily
<shevy>
must be because of a stupid gem :)
<workmad3_>
shevy: nope
whaley has quit [Remote host closed the connection]
<shevy>
which gem failed for you?
<shevy>
franksch where is vagrant-1.0.5.gem ?
<franksch>
vagrant.1.1.0.dev gem is in my pkg folder in the cloned src tree
<shevy>
ah so it is an unstable gem?
<shevy>
the latest official one seems to be 1.0.5
<workmad3_>
shevy: rack updated, which meant that rack application servers could pull in the new version (which was correct) but if that activated before rails (which couldn't use the latest version of rack) then boom
<franksch>
shevy: yes I wanted to test a patch i wrote
<workmad3_>
shevy: which only exploded because rubygems activates gems linearly rather than all at once
<shevy>
franksch well, install it first? then look at the output of "gem list"
<franksch>
and then I wanted to understand how this works
rippa has quit [Ping timeout: 248 seconds]
<franksch>
gem list only contains vagrant 1.0.5 not 1.1.0.dev
<shevy>
ok good
<workmad3_>
shevy: as with many issues that need more complexity, the issue wasn't a single source of failure though... it was a convergence of correct circumstances into a failure
<shevy>
well why does it not install 1.1.0?
<shevy>
workmad3_ gem sucks too
<shevy>
matz should ban bundler and gems
<workmad3_>
shevy: in favour of what? :P
bigmcq77 has joined #ruby
<shevy>
I dunno, he forgot to add add-on installations to ruby :(
fir_ed has quit [Read error: Connection reset by peer]
<shevy>
languages like nimrod dont have gem-like things
ttt has joined #ruby
<shevy>
so you have to download all manually
<franksch>
but when I do bundle/exec vagrant it does use the 1.1.0.dev version
<shevy>
franksch, hmmmm no idea how to resolve bundle issue. ask workmad3_ he knows :P
<workmad3_>
franksch: hmm, what was the original question sorry? was it basically 'how does bundle exec <whatever> activate the dev version rather than the installed version when I'm in the gem project folder'?
tagrudev has quit [Quit: late again]
ttt has quit [Ping timeout: 240 seconds]
<franksch>
yeah I am trying to understand ruby conventions, best practices and how these tools work
<workmad3_>
franksch: right, well in this case - bundler isn't activating the gem in the pkg/ directiory
rh1n0 has joined #ruby
<franksch>
it seems to load it from pkg, but how does it know that is that a bundler convention
rh1n0 has left #ruby [#ruby]
undersc0re97 has joined #ruby
undersc0re97 has quit [Changing host]
undersc0re97 has joined #ruby
<workmad3_>
franksch: what it's doing is setting things up to load the gems in the gemspec followed by setting things up to load the current project using the project directories
Pochacco has quit [Quit: Pochacco]
<workmad3_>
franksch: 'bundle exec' is a bundler command for basically doing that
ananthakumaran has quit [Ping timeout: 255 seconds]
<franksch>
ok but how does it know about pkg? I grepped the sources tree and there is no mention of pkg
<workmad3_>
it doesn't know about pkg
<workmad3_>
the gem in pkg is basically unused
AlbireoX has joined #ruby
<franksch>
ph
<franksch>
oh*
<franksch>
hmm
uris has joined #ruby
jeffreybaird has quit [Quit: jeffreybaird]
<workmad3_>
that's just a build artifact... when you do 'bundle exec' it's running the code in lib/ basically
<franksch>
ah
<shevy>
bundler enriches franksch's life greatly
<franksch>
I see
soulisson has joined #ruby
<shevy>
I think workmad3_ is the only person here who knows much about bundler :)
<workmad3_>
shevy: hardly :P
<franksch>
bundler is now only used to setup the gem dependencies but the actual sources are interpreted
john687 has joined #ruby
steffes has joined #ruby
<john687>
hi everyone
jeffreybaird has joined #ruby
<workmad3_>
franksch: bundler basically sets things up so that the code that your ruby runtime sees are the gems in the gemspec and the code in lib/
lggr has quit [Ping timeout: 245 seconds]
<franksch>
workmad3_: ok
AlbireoX`Laptop has joined #ruby
<franksch>
that was what I wanted to know :)
AlbireoX has quit [Read error: Connection reset by peer]
adaoraul has joined #ruby
<john687>
i just started to learn ruby and i have some questions...can anyone help me?
<franksch>
I also heard about rvm
<shevy>
john687 only if you ask questions
FeurFrei has quit [Ping timeout: 246 seconds]
Eplemosen has joined #ruby
<john687>
thats true shevy :) ok my first question is: array is an instance of class?
axl_ has joined #ruby
Uranio has quit [Quit: WeeChat 0.3.8]
<workmad3_>
john687: Array is an instance of Class, yes
<shevy>
john687 hmmmm
monkegjinni has quit [Read error: No route to host]
<workmad3_>
john687: but an array is an instance of Array
monkegjinni has joined #ruby
Uranio has joined #ruby
<burgestrand>
And Array is a class
freeayu has quit [Remote host closed the connection]
lggr has joined #ruby
jerius has quit [Quit: Computer has gone to sleep.]
<john687>
ok i ask just to get it clear to my head, second question...when self is used within the definition of an instance method, it refers to the current instance of the class?
margle has quit [Quit: Computer has gone to sleep.]
nitti has joined #ruby
mahmoudimus has joined #ruby
<burgestrand>
Not necessarily, but most often yes.
ltsstar has quit [Ping timeout: 260 seconds]
Nisstyre has joined #ruby
<awestroke>
is it possible to use a certain rbenv version for a directory and all subdirectories
<awestroke>
?
<burgestrand>
john687: self refers to self. Sometimes it will be a class, sometimes it will be an instance of a class. It is, however, always an object.
<wmoxam>
anything is possible. Is it easy or practical is another question
<awestroke>
sometimes it is the weird # object
Axsuul has joined #ruby
quest88 has joined #ruby
<matti>
Interesting.
mahmoudimus has quit [Client Quit]
sspiff has quit [Remote host closed the connection]
CJNE has quit [Ping timeout: 276 seconds]
yshh has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
<workmad3_>
wmoxam: not all things are possible... squaring the circle with a compass and straight-edge isn't possible :P
steffes has quit [Remote host closed the connection]
<john687>
self it is an object like everything in ruby right? :)
<workmad3_>
john687: it's always a reference to an object
<matti>
john687: It refernces current object-ish.
<workmad3_>
john687: it's basically the current 'context'
<wmoxam>
workmad3_: lulz
<matti>
john687: Like this in Python.
hekin has joined #ruby
<hekin>
0.0249 * 100 = 2.4899999999999998
<hekin>
tested under Ruby 1.9.3p125
<workmad3_>
hekin: yup
<hekin>
any clue how to avoid that?
<workmad3_>
hekin: welcome to floating point numbers
<hekin>
i want it to be 2.49
lggr has joined #ruby
<hekin>
:D
<workmad3_>
hekin: so would we all
<workmad3_>
hekin: unfortunately, we can't always get that wish
<hekin>
workmad3_: would Float class help?
<workmad3_>
hekin: no
<hekin>
damn it
moshee has quit [Ping timeout: 260 seconds]
<workmad3_>
hekin: BigDecimal might help
<hekin>
cool
<hekin>
thanks
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
<john687>
so to be clear when self is used in a method of a class, it refers to the method itself or to class?
<workmad3_>
hekin: assuming that the issue is that 2.49 isn't representable, rather than 0.0249 not being representable
dakine has joined #ruby
<hekin>
cool
yalue has quit [Remote host closed the connection]
<workmad3_>
hekin: if 0.0249 isn't representable then you'll hit a floating point rounding error before your BigDecimal is created
axl_ has quit [Quit: axl_]
<hekin>
yeah
<hekin>
what do you mean by "representable"?
<hekin>
workmad3_: what do you mean by "representable"?
<workmad3_>
hekin: floating point numbers are binary representations of decimals
<hekin>
workmad3_: you mean "abcde"
<hekin>
?
iamjarvo has joined #ruby
<hekin>
BigDecimal.new("abcde")
<workmad3_>
hekin: no, I mean 2.49 <-- that's a decimal representation of the number
<hekin>
workmad3_: yeah, i know of that
axl_ has joined #ruby
<hekin>
yeah
<workmad3_>
hekin: however, not all decimal numbers can be encoded in a finite number of digits in binary
dakine has quit [Client Quit]
<workmad3_>
hekin: in the same way that not all rational numbers can be represented in a finite number of digits in decimal
margle has joined #ruby
<workmad3_>
hekin: e.g. 1/3
irleif has joined #ruby
<hekin>
workmad3_: yeah, make sense, thanks a lot
beiter has quit [Quit: beiter]
<Xeago>
val = value.split(",") if value.class == String
<Xeago>
I want to be able to pass an array and a string as value
<john687>
public methods of a class can be redefined after an instance of that class is instantiated?
nitti_ has joined #ruby
<Xeago>
private methods aswell with trickeries
<workmad3_>
hekin: if you wanted to be sure, you should do 'require "bigdecimal"; val = BigDecimal(249) / BigDecimal(10000)'
<burgestrand>
john687: yes, methods can be removed and added at runtime to pretty much all objects
<burgestrand>
with a few exceptions
<hekin>
workmad3_: let me try that
<workmad3_>
hekin: that would let you start with a bigdecimal containing '0.0249'
<hekin>
yeah
<hekin>
it give me 0.0249
nitti__ has joined #ruby
quest88 has quit [Quit: quest88]
<hekin>
workmad3_: no, it gives me an object
<workmad3_>
hekin: BigDecimals are objects
<burgestrand>
(you cannot define singleton methods on symbols, or numbers)
<john687>
burgestrand: even if the class is instantiated?
<burgestrand>
john687: yes
<Xeago>
john687: yes
<workmad3_>
hekin: the same as floats and integers are objects
lggr has joined #ruby
<Xeago>
classes are objects aswell
<burgestrand>
john687: you can even add and remove methods from an instance of a class, and only that instance will be affected
<hekin>
workmad3_: yeah, everything in Ruby is object, :)
blazes816 has joined #ruby
davidcelis has joined #ruby
sirecote is now known as sirecote
nitti has quit [Ping timeout: 240 seconds]
jprovazn is now known as jprovazn_away
schaerli has joined #ruby
abstrusenick has joined #ruby
davidcelis has quit [Client Quit]
burgestrand has quit [Quit: Leaving.]
nitti_ has quit [Ping timeout: 240 seconds]
<john687>
im still confused about that! when an instance of a class is instantiated, is it possible to define again a public method in that class?
<reactormonk>
john687: sure, all dynamic
xbayrockx has quit []
Eplemosen has quit [Quit: NOPE]
lusory has quit [Ping timeout: 246 seconds]
monkegjinni has quit [Remote host closed the connection]
arturaz has joined #ruby
nitti__ has quit [Ping timeout: 260 seconds]
<JonnieCache>
john687: you can change the class and have all the previously instantiated objects change too, or you can change just one object without affecting others
<JonnieCache>
you can pretty much do what you want. its more a question of what is and isnt a good idea
TheFuzzb_ has joined #ruby
sent-hil has quit [Remote host closed the connection]
TheFuzzball has quit [Read error: Operation timed out]
irleif has quit [Quit: Computer has gone to sleep.]
TheFuzzb_ has quit [Excess Flood]
schaerli has quit [Remote host closed the connection]
<john687>
ok i think i get it now...some practice will help even more ;)
nitti has joined #ruby
ly_gs has quit [Remote host closed the connection]
xpen has joined #ruby
dakine has joined #ruby
lggr has quit [Ping timeout: 260 seconds]
kaawee has quit [Read error: Operation timed out]
anachronistic has joined #ruby
nitti_ has joined #ruby
kaawee has joined #ruby
fantazo has quit [Read error: Operation timed out]
Guedes has quit [Read error: Operation timed out]
elux has quit [Read error: Connection reset by peer]
fantazo has joined #ruby
elux has joined #ruby
nitti__ has joined #ruby
Guedes has joined #ruby
TheFuzzball has joined #ruby
apok has joined #ruby
<john687>
ok i have another question more general this time...what is "foo" that i see almost everywhere?
mengu has quit [Ping timeout: 246 seconds]
<kaleido>
an example
lggr has joined #ruby
<blazes816>
foo, bar, and less commonly, baz are common terms to use as example labels for things, when the thing doesn't matter
nitti has quit [Ping timeout: 246 seconds]
irleif has joined #ruby
<blazes816>
instead of describing a class User, I might just call it Foo, to be short
<john687>
so it has nothing to do with ruby coding?
jerius has joined #ruby
<anachronistic>
nope; part of geek humor (descends from the term 'fubar') :)
<DarkStar1>
evenining all. Am extremely new to ruby, and I've just been given the tarball of a site apparently developed in ruby. How can I find out what version it is so that I may install the same version on my server
irleif has joined #ruby
Solnse has joined #ruby
<epochwolf>
DarkStar1: um… unless there is some reference in the docs, it's going to be a little hard to determine more than 1.9 or 1.8
<epochwolf>
does the app have any jar files in it?
baroquebobcat has joined #ruby
philcrissman has quit [Remote host closed the connection]
eikko is now known as akem
lggr has quit [Ping timeout: 276 seconds]
patatras has joined #ruby
Ankhers has joined #ruby
akem is now known as akemEikko
baphled has quit [Ping timeout: 245 seconds]
lggr has joined #ruby
<epochwolf>
DarkStar1: I'm making tea and after it's brewed I'm leaving for work. If you want some help, speak up.
axl_ has quit [Quit: axl_]
lusory has joined #ruby
xpen has quit [Remote host closed the connection]
axl_ has joined #ruby
patatras has left #ruby [#ruby]
senny has quit [Remote host closed the connection]
DrShoggoth has joined #ruby
davidcelis has joined #ruby
<DarkStar1>
epochwolf: sorry I got called away
<DarkStar1>
I'm looking now
<epochwolf>
ah
uris_ has quit [Read error: Connection reset by peer]
<epochwolf>
DarkStar1: gist that for us and we might be able to guess which version you want
Diranged has joined #ruby
<Diranged>
ive got an array of server:host pairs. .. ie, foo = [ 'localhost:123', 'foobar:4123' ]… in a ruby template i want to essentailly do a foo.join(',') .. but i want to strip out the port numbers entirely (and the semicolons)..
<Diranged>
any thoughts on how to do that simply?
<epochwolf>
Diranged: regex
<DarkStar1>
epochwolf: don't know what a gist is but here is an pastebin: http://fpaste.org/OqZj/
AlbireoX has joined #ruby
<Diranged>
epochwolf: im not sure how to do that though in a ruby template.. (really this is happening in a ruby template thats parsed by puppet.. but anyways)
timonv has quit [Remote host closed the connection]
mneorr has joined #ruby
Synthead has joined #ruby
daniel_- has quit [Quit: WeeChat 0.3.9]
<Diranged>
is there a way to run a regex across the entire array of elements before i do the .join?
lggr has quit [Ping timeout: 255 seconds]
artm has quit [Quit: artm]
robotmay has quit [Remote host closed the connection]
ryanlecompte has joined #ruby
codespectator has joined #ruby
xclite has joined #ruby
busybox42 has quit [Ping timeout: 246 seconds]
timonv has joined #ruby
dju has joined #ruby
<blazes816>
Diranged: you could #map it
haxrbyte has joined #ruby
haxrbyte has quit [Remote host closed the connection]
a_a_g has joined #ruby
cj3kim has joined #ruby
<DarkStar1>
epochwolf: any joy
<epochwolf>
DarkStar1: well, it's a rails app
<Diranged>
blazes816: can you give me any example syntax?
haxrbyte has joined #ruby
lggr has joined #ruby
<epochwolf>
DarkStar1: it's also using an external repository for the source. I'm not sure you can install this.
<theRoUS>
how can i tell the yardoc command that i want LICENCE.txt to use *no* markup rather than text? without modifying the LICENCE.txt file itself?
<lenswipe>
Sou|cutter, im not on mac
<lenswipe>
harushimo, yeah did that, that's why im here :p
<harushimo>
what version of linux are you running
<epochwolf>
lenswipe: and yet the solution is strangely the same.
<harushimo>
or are you running mac os x
<harushimo>
I just found that online. It seems that should work
<lenswipe>
epochwolf, except it isnt....because i already added gems to my path
<lenswipe>
harushimo, no, debian
<lenswipe>
and see above
sepp2k has quit [Ping timeout: 246 seconds]
<Sou|cutter>
lenswipe: if your path was correct you would not have this issue
<epochwolf>
^ this
<lenswipe>
*sigh*
<harushimo>
sudo didn't work
<theRoUS>
basically, i want the effect of adding a '# @markup pre' to the top of LICENCE.txt, but imposed from a config file or the command line
xaq has quit [Read error: Connection reset by peer]
sneakyness_wk has joined #ruby
hotovson has quit [Remote host closed the connection]
hotovson has joined #ruby
macmartine has joined #ruby
chrismcg is now known as zz_chrismcg
bricker has joined #ruby
Elhu has quit [Quit: Computer has gone to sleep.]
bigoldrock has joined #ruby
hotovson has quit [Client Quit]
hotovson has joined #ruby
<bigoldrock>
easy question: How do I define an attr_accessor in one class, and then change the variable from another class? ... while keeping it with class scope ala @@ ?
peneconleche has joined #ruby
Guest42265 has quit [Ping timeout: 260 seconds]
thmzlt has quit [Remote host closed the connection]
Apocalypse has joined #ruby
nitti has quit [Remote host closed the connection]
thmzlt has joined #ruby
iamjarvo has joined #ruby
lenswipe has left #ruby ["Leaving"]
zommi has left #ruby [#ruby]
Synthead has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
mohits has quit [Ping timeout: 240 seconds]
x1337807x has joined #ruby
shevy has quit [Ping timeout: 264 seconds]
zigomir has quit [Ping timeout: 255 seconds]
<waxjar>
i don't understand the last part of your question bigoldrock
wallerdev has joined #ruby
jerius has joined #ruby
jerius has quit [Client Quit]
lvyiwang has left #ruby [#ruby]
jerius has joined #ruby
<LiquidInsect>
bigoldrock: are you looking for something like Rails's cattr_accessor?
Takehiro has joined #ruby
Takehiro has quit [Remote host closed the connection]
Takehiro has joined #ruby
<bigoldrock>
well... I want to have a variable that can change after the class is instantiated
<LiquidInsect>
on the class, or the instance?
<bigoldrock>
and have it be scoped as a class variable so other methods can use it
<LiquidInsect>
see that's where you lose us
<LiquidInsect>
other methods can use instance variables
lggr has joined #ruby
<bigoldrock>
ah ha, so automatically scoped for other methods
<LiquidInsect>
it is possible to use instance variables on a class as well if that's what you want
Guest24198 is now known as kelotr
kelotr is now known as keltor
keltor has quit [Changing host]
keltor has joined #ruby
<bigoldrock>
@iquidInsect so when other methods (where we defined attr_accessor) use :instanceVar what do they call it?
<LiquidInsect>
I'd recommend against using class variables unless you know what you're doing, they're... kind of weird.
jrist-dogwalk is now known as jrist
josh__ has quit [Read error: Connection reset by peer]
<waxjar>
attr_accessor is a convenient way of defining two methods, #variable and #variable=
ltsstar has quit [Ping timeout: 246 seconds]
josh__ has joined #ruby
<LiquidInsect>
bigoldrock: Not sure what you're asking... When you use attr_accessor :some_variable in a class definition, you're defining two instance methods on that class, some_variable, and some_variable=
<LiquidInsect>
you grok all that already?
<waxjar>
they basically just return the instance variable with the name you feed to attr_accessor, so :lol returns @lol, :foo returns @foo, etc
<LiquidInsect>
they're public methods that just set @some_variable on that instance
elaptics is now known as elaptics`away
<bigoldrock>
ah ha, thanks
stonewall has joined #ruby
josh__ has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 276 seconds]
schaerli has quit [Remote host closed the connection]
<LiquidInsect>
predicate method names are generally for methods that return a boolean, so it's a weird choice... but you should be able to do it with alias :string? :string
<shevy>
aah camping
<shevy>
I love question marks :)
<shevy>
not the ! methods though
<shevy>
app.run!
kaawee has quit [Ping timeout: 255 seconds]
<LiquidInsect>
huh. You shouldn't need the quotes to make that a valid symbol...
<shevy>
I hate that
<shevy>
or... config.parse!
mneorr has quit [Remote host closed the connection]
<shevy>
I need more beer, I feel agitated
<burgestrand>
Also, felix the fearless is supposedly doing his jump soon :)
<waxjar>
i wonder if #what?! would be possible :p
carloslopes has joined #ruby
<shevy>
felix the who?
<shevy>
waxjar hmm
stephenjudkins has joined #ruby
<LiquidInsect>
they make sense in a few situations, reject vs reject! etc
<shevy>
def wtf?!
<shevy>
does not work :(
<shevy>
syntax error, unexpected '!', expecting '\n' or ';'
<burgestrand>
shevy: he’s jumping from a balloon from record height, aiming to break the sound barrier in free fall
<shevy>
it seems the parser demands that the "?" would be the last token
<Axsuul>
How would I inherit a class that is one level higher in the module hierarchy? http://codepad.org/Tr9nECKu
<LiquidInsect>
"wicked" is right... you can do downright evil stuff
adeponte has joined #ruby
wpaulson has joined #ruby
baphled has joined #ruby
<LiquidInsect>
call a private method? sure! hide data in an instance variable on a symbol to hide it from the garbage collector? why not?
<burgestrand>
Axsuul: you’ll have to reach it from the top-level namespace, typing out the full constant path
xyzodiac has joined #ruby
<Axsuul>
burgestrand: thanks
<burgestrand>
Axsuul: even so, Extreme is defined before Base
<burgestrand>
Axsuul: so you need to define Base first
<shevy>
Axsuul I would also define the parent classes first
<shevy>
somehow the ruby parser likes that more
<burgestrand>
Axsuul: by doing that, you might not need to type out the full name :)
<shevy>
:)
yshh has quit [Remote host closed the connection]
<blazes816>
I worked on an app where the method current_user returns :false if no user is logged in. this lead to adding a large number of methods to the :false symbol ala whinynils
_cheney has joined #ruby
<Axsuul>
burgestrand: ah yes, you're right
lggr has joined #ruby
stephenjudkins has quit [Quit: stephenjudkins]
<shevy>
hehe
cj3kim has quit [Quit: This computer has gone to sleep]
<shevy>
whinynils, nice word
kaawee has joined #ruby
<shevy>
they have an epic fight against the happynils
fram has quit [Remote host closed the connection]
<shevy>
I'm gonna teach teletubby-ruby to kids
timonv has quit [Remote host closed the connection]
robotmay has joined #ruby
keymone has joined #ruby
reset has joined #ruby
<sent-hil>
In ruby source code I see a lot of `VALUE rb_cBasicObject;`
<sent-hil>
I'm not able to find VALUE keyword in C lang though, what does it do?
<solidus-river>
it has a function i would like to use from the console but i cant find out how to gain access to it
<epochwolf>
crapshoot: doesn't cap return an error code if it fails?
<solidus-river>
its in the gemfile under the space
vlad_starkov has quit [Remote host closed the connection]
<solidus-river>
Fog::Storage::AWS::Real
<crapshoot>
Unfortunately I need this to be a handler to be registered into this Capistrano configuration itself, not something to run on the outside as a shim,
macmartine has quit [Quit: Computer has gone to sleep.]
<solidus-river>
so how would i access functions within that space from the command line or elsewhere?
eikko has joined #ruby
adamkittelson has joined #ruby
lggr has joined #ruby
<crapshoot>
Well, this is awesome. I suppose the Ruby Way (TM) would be to monkey patch something into the turd.
timmow has quit [Quit: is having a nap]
jimeh2 has joined #ruby
haxrbyte_ has quit [Remote host closed the connection]
h4mz1d has joined #ruby
salman has joined #ruby
wedtm is now known as wedtm|away
philcrissman has joined #ruby
cj3kim has quit [Quit: This computer has gone to sleep]
<harushimo>
I'm using symbols like it was suggested to me. I didn't know you could do it this way but I also want to use strings to get the winning strategy
<harushimo>
like for example, m1.downcase.to_string(is that method call), where you can use symbols and strings
lggr has joined #ruby
huismon has left #ruby ["Leaving"]
awarner has joined #ruby
<harushimo>
I also want be pass strings to the hash table
<harushimo>
any suggestions
<harushimo>
i'm working on it
solidus-river has quit [Ping timeout: 260 seconds]
jrajav has joined #ruby
<canton7>
harushimo, use '#to_sym
<canton7>
also #to_s, not #to_string
lenswipe has left #ruby ["Leaving"]
<harushimo>
would I type m1.downcase.to_sym
<harushimo>
like that
<harushimo>
is that correct way
axl_ has quit [Quit: axl_]
lggr has quit [Ping timeout: 246 seconds]
<canton7>
yup
<harushimo>
I just about to test it
<harushimo>
thank you
<harushimo>
to_sym takes the symbol from the hash and return its as a string
<harushimo>
am I right
apok has joined #ruby
<canton7>
to_sym takes a string and turns it into a symbol
<harushimo>
its the opposite
<harushimo>
oh okay
<harushimo>
sorry about that
<canton7>
to_s takes something and turns it into a string
<harushimo>
ok
piotr__ has joined #ruby
<harushimo>
thank you
lggr has joined #ruby
<harushimo>
this game is coming better
piotr_ has quit [Ping timeout: 256 seconds]
<A124>
Is there a shell 'clear' alternative for pry or irb?
CJNE has joined #ruby
<ddd>
clear?
<anachronistic>
control+L on a mac
yxhuvud has quit []
rakl has joined #ruby
<A124>
anachronistic: Awesome! Thanks! Same for Linux terminal
samflores is now known as samflores|away
<anachronistic>
n/p. don't have a windows box but i'm sure there's something similar
<anachronistic>
(For those windows users listening in anyway)
<A124>
I have windows box, but work in virtual ^^
<salman>
anyone from berkeley saas edx course
<salman>
??
yxhuvud has joined #ruby
brianosborne has joined #ruby
<ddd>
for pry internally you would run the 'reset' command. the CTL-L is the terminal specifically (works on the terminal window itself)
brianosborne has left #ruby [#ruby]
<ddd>
but if you want to *specifically* reset pry, you use 'reset
<ddd>
'
<ddd>
just to delineate the difference
deadghost has quit [Ping timeout: 256 seconds]
schaerli has joined #ruby
<A124>
ddd: Nope, just the output. So I don't have to look at code when There is only progress bar. I'll find ANSI sequence for that.
<A124>
But Thanks, Good to know.
<ddd>
oh, nm, i'm wrong! because I just noticed I have mine remapped. My apologies for bad info!
<anachronistic>
reset is likely to be removed from pry, if it hasn't happened already
<ddd>
anachronistic: still there
solidus-river has joined #ruby
<solidus-river>
sorry all i dc'd
daniel_-_ has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
CJNE has quit [Ping timeout: 260 seconds]
<solidus-river>
how do i get to a namespace inside a gem i'm using to execute a function i'm confused on how to translate this rdoc into something to actually use in an instance
carlyle_ has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 246 seconds]
arietis has joined #ruby
mvangala_ has quit [Remote host closed the connection]
pettsson has joined #ruby
samuel02 has joined #ruby
lggr has joined #ruby
freakazoid0223 has joined #ruby
Russell^^ has joined #ruby
<harushimo>
I'm putting this disclaimer here: this maybe a dumb question, i'm still going to ask it for my edification. Is Ruby considered to a scripting language?
<harushimo>
I didn't think it was from what I reading
samflores has quit [Quit: Leaving...]
<harushimo>
since everything in Ruby is an object
drule has joined #ruby
chrisramon has joined #ruby
<harushimo>
I just want to ask that question
darule has quit [Ping timeout: 256 seconds]
bbttxu_ has quit [Quit: bbttxu_]
drule is now known as darule
a_a_g1 has quit [Quit: Leaving.]
seich- is now known as seich
harryheintz has joined #ruby
artm has joined #ruby
Orcris has joined #ruby
peneconleche has quit [Ping timeout: 240 seconds]
<shevy>
harushimo ruby belongs to the scripting language family
A124 has quit [Quit: reboot]
<harushimo>
I wasn't entirely sure
<shevy>
like ... ruby python perl php... I'd say lua too
<harushimo>
I know python is
<harushimo>
and perl
<harushimo>
I didn't think php fall under scripting languages
<harushimo>
that is interesting to know
<shevy>
on the other side of the spectrum are the classically compiled languages like C C++ Obj-C... I think java too (or at least until you make this .jar file?)
<shevy>
you can use .php scripts locally just as well
harryheintz has quit [Client Quit]
<rubious>
Sorry to be lame, can anyone see this?
<shevy>
you can use php to process text, like awk sed or perl do
<shevy>
rubious I can see your sentence, but not the girls shaking behind you
<harushimo>
I know php can do that like python and ruby
peneconleche has joined #ruby
<rubious>
woo
<shevy>
harushimo I think both ruby and python are better languages than php :)
<harushimo>
I know
hotovson has quit [Ping timeout: 245 seconds]
<harushimo>
I agree with you 100 %
lggr has quit [Ping timeout: 252 seconds]
<harushimo>
I know python and now, I'm learning ruby
<harushimo>
I see a lot of jobs in RAILS actually
<harushimo>
I'm learning ruby for that purpose too
<shevy>
aha
<shevy>
I never learned rails
<shevy>
but I am going to learn python
peneconleche has quit [Client Quit]
<shevy>
only 3.x though
<reactormonk>
shevy: no regexp in stdlib? blub
<harushimo>
you should take the course in coursera for learning python
<harushimo>
its good course. I'm in that too
<shevy>
reactormonk in python?
<reactormonk>
shevy: yep
<shevy>
the thing that annoys me the most about python is that transition from 2 to 3
<shevy>
and that there are build scripts out there in the wild that require version 2 and fail with version 3
hotovson has joined #ruby
<shevy>
it is making me very angry
<harushimo>
right
<reactormonk>
shevy: python2 vs. python :-)
<shevy>
ok harushimo
<shevy>
will look at this coursera thing (sounds spanish...)
starship is now known as eightydays
ryanf has joined #ruby
eightydays is now known as starship
akem has quit [Ping timeout: 240 seconds]
<harushimo>
its an english. It was started by two stanford professors
<harushimo>
udacity has course in python to build your own search engine
lggr has joined #ruby
<harushimo>
see if anyone those help you.
J2EE has joined #ruby
Takehiro has quit [Remote host closed the connection]
<harushimo>
I mean any of those courses will help you
<chrisramon>
Hi, I am trying to install nokogiri on ubuntu 12, and i keep getting this error: Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
<chrisramon>
besides already installed the dependencies from nokogiri website
<Mon_Ouie>
Object orientation doesn't prevent you from writing quick and short scripts to automatize some task
<Mon_Ouie>
Which is pretty much all that you need to call it a scripting language
<rking>
Mon_Ouie += 1
<shevy>
hmmm damn... that course takes a bit long harushimo :(
Coolhand has quit [Remote host closed the connection]
<ddd>
the fact that internally to ruby everything is an object isn't what defines it as a scripting language. thats internal implementation details. iirc, its because it isn't compile, and/or is interpreted that makes it a scripting language.
<ddd>
err s/compile/compiled/
<harushimo>
its a good course. I took it
<rking>
Mon_Ouie: Though I've heard the "scripting" definition has more to do with embedding in other languages.
<shevy>
yeah... hmm... but I dont think I have the time right now hmmmm
jarrett has joined #ruby
<harushimo>
coursera one is seven weeks. They are pretty good at it.
<jarrett>
Hello, does anyone have experience with Treetop? (Nobody in the #treetop channel)
zii has quit [Ping timeout: 246 seconds]
<shevy>
never heard of treetop
<shevy>
only of htop :)
drule has joined #ruby
<jarrett>
It's a gem for generating parsers
jarrett has quit [Client Quit]
DarkStar1 has quit [Quit: Later coppenstoppers]
indian has joined #ruby
darule has quit [Ping timeout: 256 seconds]
lggr has quit [Ping timeout: 244 seconds]
<sent-hil>
offtopic...i used parslet parser yesterday with ok success, seemed much easier than treetop
_md has joined #ruby
jenrzzz has joined #ruby
<shevy>
there he went away
Coolhand has joined #ruby
lggr has joined #ruby
mvangala has joined #ruby
evilsushi has quit [Quit: Lost terminal]
irleif has quit [Quit: Computer has gone to sleep.]
A124 has joined #ruby
bbttxu_ has joined #ruby
<sent-hil>
shevy: what did you do :)
rovalent has joined #ruby
Tearan has joined #ruby
manizzle has quit [Ping timeout: 260 seconds]
Battuu has joined #ruby
samphippen has joined #ruby
nanderoo has quit [Quit: Leaving.]
TriTodd has quit [Ping timeout: 244 seconds]
lggr has quit [Ping timeout: 276 seconds]
JonnieCache has joined #ruby
benwoody has joined #ruby
xavii has joined #ruby
AlbireoX has quit [Remote host closed the connection]
jarred has joined #ruby
<A124>
OP Question: Why we don't have pastie bot here?
<rking>
A124: As opposed to pasting a gist URL?
lggr has joined #ruby
workmad3 has joined #ruby
<A124>
rking: Pastie bot is kind of more.. comfortable and synta highlighting is nice for ruby on pastie also. Both #ruby-lang and #rubyonrails have the bot. Which seemed interesting to me.
<burgestrand>
No bot when I joined like two years ago
eikko has joined #ruby
xavii has quit [Quit: Leaving]
ixti has quit [Quit: So Long, and Thanks for All the Fish!]
Virunga has joined #ruby
thmzlt has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
<A124>
burgestrand: Interesting.
crapshoot has quit [Quit: Lost terminal]
Criztian_ has joined #ruby
MikeyV27_ has joined #ruby
<A124>
Time to make one.
<burgestrand>
>> "Hi"
<burgestrand>
A124: usually have another bot in here, not for pasties though.
<burgestrand>
Or, used to, that bot has been gone lately as well. Lasted a few months.
lggr has quit [Ping timeout: 240 seconds]
<A124>
burgestrand: Can you be a little more specific please? (for what?)
<burgestrand>
Executing ruby snippets.
<burgestrand>
>> 1 + 2
<burgestrand>
And it would respond with 3.
Criztian has quit [Ping timeout: 245 seconds]
<A124>
Ah.
thmzlt has joined #ruby
<burgestrand>
Nice idea, for some reason those bots always crash and then they go away because the maintainers get bored fixing them.
grizlo42 has quit [Ping timeout: 246 seconds]
diegoviola has joined #ruby
<burgestrand>
Anyhow, time for some gaming, ta-ta.
<A124>
burgestrand: What do you play?
xavii has joined #ruby
JonnieCache has quit [Ping timeout: 246 seconds]
<burgestrand>
A124: DotA, casually.
manizzle has joined #ruby
Takehiro has joined #ruby
vlad_starkov has quit [Ping timeout: 260 seconds]
MikeyV27 has quit [Ping timeout: 246 seconds]
<A124>
What I face now is a need of solid computer workbench. (Which is a little more for me. I'm ethusiast exhaustive, data oriented, .... user). And enabling Raspberry Pi to be a lightwight workstation nonstop online, irc, ruby.
MikeyV27_ has quit [Ping timeout: 246 seconds]
<A124>
Anyone could give any tips for Ruby on RPi?
kaawee has joined #ruby
lggr has joined #ruby
hotovson has quit [Remote host closed the connection]
jeffreybaird has quit [Read error: Connection reset by peer]
jeffreybaird has joined #ruby
Takehiro has quit [Remote host closed the connection]
jrist is now known as jrist-brb
jrist-brb has quit [Quit: o no u din't]
Chryson has joined #ruby
cburyta has quit [Remote host closed the connection]
drule is now known as darule
lggr has joined #ruby
nitti has joined #ruby
sauer_braten is now known as TheHeartCollecto
TheHeartCollecto is now known as pskosinski
morozovm has quit [Read error: Connection reset by peer]
morozovm has joined #ruby
chessteach has quit [Remote host closed the connection]
vlad_starkov has joined #ruby
vitoravelino`afk is now known as vitoravelino
vlad_sta_ has joined #ruby
nitti_ has joined #ruby
lggr has quit [Ping timeout: 256 seconds]
nitti has quit [Ping timeout: 260 seconds]
mark_locklear has quit [Remote host closed the connection]
lggr has joined #ruby
cburyta has joined #ruby
sailias has quit [Ping timeout: 244 seconds]
vlad_starkov has quit [Ping timeout: 240 seconds]
Drager has quit [Changing host]
Drager has joined #ruby
wedtm is now known as wedtm|away
dju has quit [Remote host closed the connection]
geekbri has quit [Remote host closed the connection]
jellosea has quit [Ping timeout: 252 seconds]
manizzle has quit [Ping timeout: 260 seconds]
morozovm has quit [Read error: Connection reset by peer]
morozovm has joined #ruby
jrajav has quit []
adamkittelson has quit [Remote host closed the connection]
lggr has quit [Ping timeout: 260 seconds]
wedtm|away is now known as wedtm
bigmcq77 has joined #ruby
cburyta has quit [Remote host closed the connection]
blazes816 has quit [Quit: blazes816]
robertotauille has quit [Read error: Connection reset by peer]
ewag has joined #ruby
sent-hil has joined #ruby
robertotauille has joined #ruby
lggr has joined #ruby
ltsstar has quit [Quit: ltsstar]
CJNE has joined #ruby
vmatiyko has quit [Quit: Page closed]
Eplemosen has quit [Quit: NOPE]
jrist has joined #ruby
awarner has quit [Remote host closed the connection]
cburyta has joined #ruby
sailias has joined #ruby
Juul has quit [Quit: Leaving]
CJNE has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 252 seconds]
heftig has quit [Quit: leaving]
_md has quit [Quit: Leaving...]
robertotauille has quit [Quit: Leaving...]
<ZenGuy>
I installined XDCC-Fetch with rvm and it doesn't work.. How can i completely remove it .. i tried rvmsudo gem cleanup XDCC-Fetch but it's still tehere when i run updatedb & locate
AlbireoX has quit [Remote host closed the connection]
verto is now known as verto|off
AlbireoX has joined #ruby
<ZenGuy>
help please
morozovm has quit [Quit: morozovm]
Orcris has quit [Ping timeout: 246 seconds]
lggr has joined #ruby
awestroke has quit [Remote host closed the connection]
carlyle has joined #ruby
carlyle has quit [Remote host closed the connection]
sailias has quit [Ping timeout: 260 seconds]
Takehiro has joined #ruby
atmosx has joined #ruby
deadghost has quit [Ping timeout: 245 seconds]
zenformatics1 has quit [Quit: Leaving.]
AlbireoX has quit [Ping timeout: 240 seconds]
Agis__ has quit [Quit: Agis__]
timonv has quit [Remote host closed the connection]
etehtsea has joined #ruby
asteve has quit []
heftig has joined #ruby
ken_barber has joined #ruby
<Paradox>
man
<Paradox>
if i had $120k
<Paradox>
i'd see if i could get a .rb domain name
<Paradox>
then use them for rubygems
<Paradox>
so every gem got gemname.rb
<ZenGuy>
Paradox: are you paradox from snoonet ?
<Paradox>
ZenGuy, that i am
<Paradox>
:D
<ZenGuy>
Paradox: oh
lggr has quit [Ping timeout: 256 seconds]
awestroke has joined #ruby
<Paradox>
actaully, i'm currently working on an irc services bot
<Paradox>
in ruby
wpaulson has joined #ruby
<Paradox>
heh
elux has quit [Quit: Leaving...]
v0n has joined #ruby
no_worries has quit [Remote host closed the connection]
<ZenGuy>
what fucntionality will it provide?
lggr has joined #ruby
wpaulson has quit [Client Quit]
reset has joined #ruby
Vinz| has joined #ruby
Takehiro has quit [Ping timeout: 260 seconds]
awestroke has quit [Remote host closed the connection]
<armenb>
I'm totally stuck on the "sudo -u gitlab bundle exec rake gitlab:app:status RAILS_ENV=production" step.
<armenb>
because I'm in my home directory and bundle is looking for a Gemfile, and there's no Gemfile in my home directory
mneorr has quit [Remote host closed the connection]
dakine has joined #ruby
jimeh2 has joined #ruby
nitti has quit [Remote host closed the connection]
stephenjudkins has quit [Quit: stephenjudkins]
samuel02 has quit [Ping timeout: 256 seconds]
emergion has quit [Quit: Computer has gone to sleep.]
whaley has quit [Remote host closed the connection]
lggr has joined #ruby
elaptics is now known as elaptics`away
frogprince_mac has quit [Remote host closed the connection]
elaptics`away is now known as elaptics
Morkel has quit [Quit: Morkel]
Spooner has joined #ruby
havenn has quit [Remote host closed the connection]
<nadendla>
is there an irc channel for aws ec2 ruby users
<nadendla>
?
fr0gprince_ is now known as frogprince
<matti>
nadendla: Not sure. I don't think so.
<matti>
nadendla: Why?
lggr has quit [Ping timeout: 240 seconds]
jamjam has joined #ruby
digerati_ has joined #ruby
<nadendla>
I have to mount several ebs volumes on an ec2 cluster since the max limit that we can mount on to an instance is 10 I have to shuffle by mounting and unmounting volumes depending on requirement , to do this I have to know which devices are already in use and which are not .. not sure how to do this
thmzlt has quit []
<nadendla>
btw I am using aws-sdk rubygem
GeekOnCoffee has quit [Ping timeout: 244 seconds]
stkowski has quit [Remote host closed the connection]
pskosinski has quit [Quit: A few unofficial Red Eclipse 1.3.1 (r4131) servers: http://altred.tk/toggle.rb (and no more global banning for saying that main dev is not very smart, what is truth anyway)]
<harushimo>
I can't get the raise NoSuchStrategyError works
stkowski_ has joined #ruby
stkowski_ has quit [Remote host closed the connection]
stkowski has quit [Remote host closed the connection]
skrewler has joined #ruby
nadendla has left #ruby [#ruby]
<harushimo>
any suggestions
stkowski has joined #ruby
timonv has joined #ruby
skrewler has quit [Client Quit]
moshee has quit [Ping timeout: 276 seconds]
moshee has joined #ruby
moshee has quit [Changing host]
moshee has joined #ruby
dmiller has joined #ruby
Chryson has quit [Quit: Leaving]
rakl has quit [Quit: sleeping]
<Spooner>
harushimo : Looks like it should raise that error to me. When I run it, it tells me "uninitialized constant NoSuchStrategyError" which means it is trying to raise it.
stkowski has quit [Remote host closed the connection]
<Spooner>
A124 : Yeah, give undergraduate psych students the job of doing it manually, telling them it is an important test.
h4mz1d has quit [Read error: Operation timed out]
stkowski has joined #ruby
<A124>
Spooner: Heh.
cburyta has joined #ruby
lggr has quit [Ping timeout: 255 seconds]
GoGoGarrett has quit [Remote host closed the connection]
stephenjudkins has joined #ruby
Xeago has quit [Remote host closed the connection]
<Spooner>
A124 : Google is your friend on this, but I suspect it is far from trivial - especially if it isn't just to solve one specific captcha system.
cburyta has quit [Ping timeout: 240 seconds]
emmanuelux has quit [Remote host closed the connection]
<A124>
Spooner: It's one specific. But I'd like to have to be able to solve more. But nothing fancy, as I'm not plannign to spam or automate anything that is only legal for human. I just got into trouble with "high volumes"
lggr has joined #ruby
<Spooner>
A124 : Don't worry, I wasn't going to help or hinder ;)
joshman_ has quit [Quit: Computer has gone to sleep.]
philcrissman has quit [Remote host closed the connection]
QKO has quit [Ping timeout: 260 seconds]
<A124>
Is there any way to in-block leave user to irb and then continue?
<Spooner>
A124 : You want to use pry gem and binding.pry (irb is for losers).
<A124>
Spooner: Is the same possible with irb?
bbttxu_ has quit [Quit: bbttxu_]
sent-hil has quit [Remote host closed the connection]
<A124>
And anyway, I use both.
bigmcq77 has quit [Quit: Computer has gone to sleep.]
<A124>
Spooner: irb is faster in certain situations. Also I need to find out formatting yet. I see the binding, Thank you.
hsbt is now known as hsbt_away
<Spooner>
irb is certainly a lot faster to start up. I'll give you that.
<Spooner>
armenb : Did you install Ruby for the user with rvm and then installed bundler using "sudo" so it was installed for the system, not for the user's Ruby?
lggr has joined #ruby
<armenb>
Spooner: I'm confused. installing ruby for the system implies users can see it too, right?
<armenb>
my ruby installation is in /usr/local/rvm, along with a copy of ruby buried in there somewhere.
<Spooner>
armenb : It does, but if you install Ruby for the user and install the gem for the system, then Ruby can't access it.
arielpts- has quit [Excess Flood]
<Spooner>
Question is, did you use sudo gem install or not?
nitti has joined #ruby
Jork1 has quit [Quit: Jork1]
arielpts has joined #ruby
arielpts has quit [Excess Flood]
<Spooner>
Oh right, so you have system ruby, not user (user would be in /home/me/.rvm/rubies).
arielpts has joined #ruby
arielpts has quit [Excess Flood]
skogis has joined #ruby
arielpts has joined #ruby
arielpts has quit [Excess Flood]
Foxandxss has joined #ruby
arielpts has joined #ruby
arielpts has quit [Excess Flood]
<Spooner>
armenb : Anyway, I've found that using sudo with gem if you have Ruby in ~, then Ruby won't see it.
arielpts has joined #ruby
arielpts has quit [Excess Flood]
<armenb>
I don't have any ~/.rvm or ~/.gem directory anywhere.
pettsson has quit [Ping timeout: 255 seconds]
<armenb>
(thanks for responding, I really appreciate your insight)
mikeg has joined #ruby
arielpts has joined #ruby
arielpts has quit [Excess Flood]
arielpts has joined #ruby
arielpts has quit [Excess Flood]
<ZenGuy>
i'm usign ruby 1.8.7 and i'm having trouble runnign xdcc-fetch .. the original developer seemed to abandopn the project but at some point it worked on older distroshttp://sourceforge.net/projects/xdccfetch/files/ if you can download it and try to see what the problem I'd appreciate that .. you'll need gem install fxruby which requires sudo apt-getinstall libfox
banseljaj is now known as imami|afk
arielpts has joined #ruby
arielpts has quit [Excess Flood]
nitti has quit [Ping timeout: 240 seconds]
arielpts has joined #ruby
arielpts has quit [Excess Flood]
lggr has quit [Ping timeout: 245 seconds]
havenn has joined #ruby
arielpts has joined #ruby
<armenb>
Spooner: do you happen to know the critical environment variables to have set with ruby/rvm/gems to make things work smoothly?
no_worries has quit [Remote host closed the connection]
colinbm has joined #ruby
arielpts has quit [Excess Flood]
arielpts has joined #ruby
arielpts has quit [Excess Flood]
<Spooner>
armenb : I don't sorry. Generally, the recommendation is to install Ruby for users, not the whole system. Life runs more smoothly ;)
<A124>
I'm runing all as root.
arielpts has joined #ruby
arielpts has quit [Excess Flood]
arielpts has joined #ruby
arielpts has quit [Excess Flood]
<Spooner>
A124 : Yeah, it does work that way. Just nicer to avoid rooting everything.
arielpts has joined #ruby
arielpts has quit [Excess Flood]
<A124>
And no, I'm not suicidal. Developer virtual machine.
<armenb>
A124: can you tell me your output of "env|grep GEM"?
lggr has joined #ruby
arielpts has joined #ruby
arielpts has quit [Excess Flood]
zemanel has quit [Quit: Remote hottie closed the connection]
<Paradox>
anyone know a non-eval way to parse a string, containing, say [0..30], into the ruby version of [0..30] ?
<A124>
armenb: nothing
arielpts has joined #ruby
<Paradox>
i want to take user input that lets them specify elements of an array
<Spooner>
Paradox : Depends what it contains. If it is always that format, then just use a regexp - if it is complex, then not so easy to do.
<Paradox>
and let them preform actions on them
<Paradox>
Spooner, i want basically all the things people can do with raw arrays
<Paradox>
but in a safe manner
<Paradox>
that is, [1, 3, 4], [1..3], and [1...-1]
v0n has quit [Ping timeout: 246 seconds]
<Paradox>
guess i should just regex it
macmartine has joined #ruby
<A124>
armenb: I don't use rvm unless I need more versions. And in that case I load rvm only when needed not with profile
<armenb>
by the way, what happens when you type "gem install bundler" on your system?
<armenb>
does it tell you it's already installed?
<Spooner>
You could regexp it to make sure it has nothing crazy in it and just eval it. If it is local input, then you don't have to be super-careful (unlike running source from a web input).
ffranz has quit [Quit: Leaving]
jenrzzz has joined #ruby
<Paradox>
its for an irc bot
<A124>
Nothing I guess
<A124>
Installed
ken_barber has quit [Remote host closed the connection]
<armenb>
I use rvm because I'm fruitlessly following install directions on gitlabhq.com
<A124>
Umm.. so I have bundler on the other system.
colinbm has quit [Quit: colinbm]
<armenb>
A124: ahh interesting. My system seems to keep forgetting that it installed it.
<A124>
I'm running, and always end up running Fedora Minimal for developer systems.
<Spooner>
Paradox : I'd probably whitelist, rather than blacklist, but yeah, if the user started the process then there is no reason to hack it.
<armenb>
i.e. no formal package or anything.
ffranz has joined #ruby
<armenb>
i.e. a maintenance disaster.
havenn has quit [Ping timeout: 244 seconds]
ffranz has quit [Read error: Connection reset by peer]
<Tarential>
even with packages red hat is a maintenance disaster
ken_barber has joined #ruby
<armenb>
Tarential: amen to that...
lggr has quit [Ping timeout: 276 seconds]
<A124>
Spooner: Do you remember half year ago when I was asking about scrapers and such?
imami|afk is now known as banseljaj
anachronistic has quit [Quit: anachronistic]
<A124>
armenb: Hey. Do you work on Ruby extensions?
stopbit has quit [Quit: Leaving]
cburyta has joined #ruby
CJNE has quit [Ping timeout: 255 seconds]
vlad_sta_ has quit [Remote host closed the connection]
<armenb>
A124: no, I don't. why?
skogis has quit [Ping timeout: 260 seconds]
lggr has joined #ruby
<ElderFain>
I need to gather all the children of node A, n nodes deep. so my first thought was "recursion!" but I hate recursion
<A124>
armenb: Working on one. I just need to figure out string passing / StrinIO
<ElderFain>
so then I'm thinking.. some mojo with inject?
vlad_starkov has joined #ruby
<Tarential>
you are not allowed to hate recursion
chrisramon has quit [Remote host closed the connection]
vlad_starkov has quit [Read error: Connection reset by peer]
<ZenGuy>
i'm usign ruby 1.8.7 and i'm having trouble runnign xdcc-fetch .. the original developer seemed to abandopn the project but at some point it worked on older distroshttp://sourceforge.net/projects/xdccfetch/files/ if you can download it and try to see what the problem I'd appreciate that .. you'll need gem install fxruby which requires sudo apt-getinstall libfox
<Spooner>
A124 : Nope. I don't remember last week too well :D
<ElderFain>
so if node a has 2 children, and those children have 2 children, and those children have 2 children.. i'd say "node a, 1 level deep" and I'd get back the first two children. if i said "node a, 2 levels deep" i'd get back 4 children
<ElderFain>
the first and second set of children
<matti>
ZenGuy: What is the trouble you are having?
stephenjudkins has quit [Quit: stephenjudkins]
<A124>
Spooner: Ah ok. So to put it short. I had problems .. enormous with memory. Not sure if that still applies for 1.9.3, but I guess so for the gem. So I wrote an efficient downloader myself. Just the captcha got in the way.
<ZenGuy>
ruby XDCC-Fetch.rbw
<ZenGuy>
./src/GUI/Main_Window.rb:157:in `initialize': undefined method `icon=' for #<Main_Window:0xb7564200> (NoMethodError)
<ZenGuy>
from ./src/GUI/Main_Window.rb:279:in `new'
<ZenGuy>
from ./src/GUI/Main_Window.rb:279
<ZenGuy>
from XDCC-Fetch.rbw:29:in `require'
<ZenGuy>
from XDCC-Fetch.rbw:29
<ZenGuy>
matti: thats the problem
<matti>
Um.
<Spooner>
ElderFain : You could just have an array and pass it and a level (so #add_children(array, level); array.push *children; children.each {|c| c.add_children array, level - 1 } if level > 0 end
<ZenGuy>
this is after i was advised to edit src/GUI/Packet_List.rb line 31 to "include Fox"
<Paradox>
any quick way to use delete_at and pass it an array of indices to delete at?
<Paradox>
if not i can just use each
<ElderFain>
Spooner: hmm
<ElderFain>
chewing on it
h4mz1d has joined #ruby
elaptics is now known as elaptics`away
Takehiro has joined #ruby
lggr has quit [Ping timeout: 245 seconds]
the_jeebster has quit [Quit: Leaving.]
libryder has joined #ruby
<libryder>
when authors include executables in their gem, how is that done?
rabidpraxis has quit [Remote host closed the connection]
<harushimo>
how come I can't return the winner looking like this: ["Rob", "P"]
<harushimo>
that is whole element
lggr has joined #ruby
mango_ has quit [Ping timeout: 246 seconds]
<ElderFain>
yeah, i've hated recursion since I first learned about it 15 years ago haha
<ElderFain>
so I've always avoided using it, and thankfully I don't have many problems that require it
<ElderFain>
I did recognize this was a perfect problem for recursion =p
<ElderFain>
guess I'll buckle down
vlad_starkov has quit [Ping timeout: 256 seconds]
<harushimo>
any suggestiosn
<harushimo>
I mean suggestions
<A124>
wmoxam: Could you please enlighten me on that one?
jamjam has quit [Ping timeout: 246 seconds]
daniel_- has joined #ruby
juarlex has quit [Read error: Connection reset by peer]
anachronistic has joined #ruby
<Spooner>
harushimo : You are using puts, which writes arrays out on separate lines. You want to use "p", not "puts" to get the output you want.
<salman>
any hints.. ??
<harushimo>
ok
daniel_-_ has quit [Ping timeout: 246 seconds]
lggr has quit [Ping timeout: 244 seconds]
<harushimo>
so many nuisances of ruby
<harushimo>
that I'm learning
<harushimo>
this is totally different from python
timonv has joined #ruby
lggr has joined #ruby
SegFaultAX|work has quit [Ping timeout: 245 seconds]
jenrzzz has joined #ruby
cakehero has quit [Quit: Computer has gone to sleep.]
rakl has joined #ruby
jlwestsr has quit [Ping timeout: 246 seconds]
beneggett has quit [Quit: Computer has gone to sleep.]
manizzle is now known as WeLoveCP
indian has quit [Quit: Leaving]
timonv has quit [Ping timeout: 240 seconds]
xaq has joined #ruby
nitti has joined #ruby
reuf has quit [Quit: Leaving]
nari has quit [Ping timeout: 260 seconds]
lggr has quit [Ping timeout: 240 seconds]
WeLoveCP is now known as manizzle
manizzle is now known as manizzle_
havenn has joined #ruby
daniel_hinojosa has quit [Quit: Leaving.]
nitti has quit [Ping timeout: 256 seconds]
samphippen has quit [Quit: Computer has gone to sleep.]
JonnieCache has quit [Ping timeout: 255 seconds]
lggr has joined #ruby
bambanx has joined #ruby
bambanx has left #ruby [#ruby]
sent-hil has joined #ruby
sent-hil has quit [Remote host closed the connection]
savage- has quit [Remote host closed the connection]
ryanlecompte has joined #ruby
stkowski has quit [Quit: stkowski]
rakl has quit [Quit: sleeping]
havenn has quit [Ping timeout: 264 seconds]
jlwestsr has joined #ruby
marcux has joined #ruby
lggr has quit [Ping timeout: 246 seconds]
Takehiro has joined #ruby
hsbt_away is now known as hsbt
lggr has joined #ruby
eignerch_ has joined #ruby
Michael_ has joined #ruby
slainer68 has quit [Remote host closed the connection]
<Paradox>
does anyone know of a stack style object, that i can set to have a limited size, and as new items are pushed to the top old ones fall off the bottom?