<funburn>
that's starting to seem a little circular
<Blaster>
is this a good place to ask design pattern questions?
<shevy>
Blaster I dont think many ruby guys here care much about design patterns, mostly when it works, it ought to be fine
<Blaster>
i am just wondering if its ok to use factory pattern to create a collection of objects
<Blaster>
or is there a better way
tjbiddle has quit [Ping timeout: 264 seconds]
<shevy>
I dont even know what a "factory pattern" is
<volty>
the universe is infinite and there are infinite ** infinite possible ways and paths ....
<patrikf>
Blaster: you need to give more context for this question to be answered...
<ykk`>
use the force
<shevy>
MrZYX do you often use factory patterns in your code?
elux has quit [Quit: Bye!]
<MrZYX>
I might if I've to do a bigger java project in the next semester
<MrZYX>
we'll see
<shevy>
ack
taternuts has joined #ruby
<ykk`>
a factory pattern doesn't sound pretty =(
<Blaster>
I have 2 different types of objects but I need to create a common interface between them and then order and sort them. Like a factory adapter pattern
DonRichie has quit [Ping timeout: 264 seconds]
<shevy>
ok so three classes
end_guy has quit [Ping timeout: 240 seconds]
DonRichie has joined #ruby
<Blaster>
I have Categories and Ads but I need them to both turn into Preview classes so my views can iterate over them and show previews of both categories and ads mixed together
<volty>
voluntary student of my friend here? :)
<MrZYX>
Blaster: sounds like a job for the presenter pattern actually
<Blaster>
oh really
<volty>
why don't you just implement what you need?
<MrZYX>
sure, just make two presenters with the same interface
<Blaster>
volty: Because I don't want to reinvent the wheel
<MrZYX>
ruby doesn't care about the types, it only cares about the methods being there
<volty>
Blaster: if you know the wheel you wouldn't have asked :)
<MrZYX>
so if you make two classes that provide the same methods you can just mesh them together into a collection as you like
<funburn>
voty: MrZYX: thanks a ton for those refactor tips. I think I'm going with volty's because I can understand it and it's similar to what I was working out on my own, but I'm going to study MrZYX to maybe improve my understanding of Ruby. Thanks again!
jamesaanderson has joined #ruby
<volty>
funburn: yw
<patrikf>
Blaster: so where does the need arise to use a factory?
<Blaster>
MrZYX that sounds like a good solution
<shevy>
when I read "funburn", my brain translates this into funbear ... I think I need to sleep soon...
<bnagy>
funburn: that's not a refactor, that's turning readable code into vomit
peregrine81 has joined #ruby
iliketurtles has quit [Quit: zzzzz…..]
randomautomator has quit [Ping timeout: 240 seconds]
<Blaster>
patrikf: I don't know actually, I guess I just really want to use some patterns
<funburn>
bnagy, awesome input! whatever the end result it taught me something new
<apeiros>
in ruby, even classes use the factory pattern :-p
<bnagy>
hooray for learning :/
snovak has joined #ruby
<volty>
i think that bluster read something about creating another class just for using his classes (as adapter) without changing this implementation of his 2 base classes to satisfy the interface requimentes
mrsolo has quit [Quit: This computer has gone to sleep]
<Blaster>
probably true
<volty>
kind of a proxy
<volty>
could be
<shevy>
right
<Blaster>
is it bad to hard code the creation of a new object within an object?
<shevy>
like in a big office where one guy delegates to another until at the end of the day noone knows what happened
<shevy>
Blaster when you write ruby, you do that all the time
<shevy>
x = "foo" <--- that is a new string object
<volty>
Blaster: such questions only to your priest ! :)
<funburn>
MrZYX: can you point me at some doc that explains this leading . syntax?
<patrikf>
as always, it depends on what you're trying to achieve...
<pontiki>
lol, volty
<shevy>
Blaster typically, you use a method from one class to instantiate an object from another class, like: def foobar(i = Bar.new) <--- here the default first argument will be a new instance of class Bar, if one omits the argument
mansi has quit [Ping timeout: 264 seconds]
<Blaster>
I think I am trying to make my solution much too perfect for my problem
<funburn>
it's kind of sexy
<volty>
funburn: just on separate lines // the usual dot for methods
<MrZYX>
funburn: there's nothing special to it, just chained method calls, like foo.bar.baz, except with added newlines for readability. You could also put the dot at the end of each line
<shevy>
good
snovak has quit [Ping timeout: 240 seconds]
<shevy>
Blaster you are ripe for management job
<Blaster>
why's that?
<funburn>
nice! I'm going to start using that, it's easy to read/understand
<shevy>
if it is too simple, ask management for a more complex solution
baroquebobcat has quit [Quit: baroquebobcat]
<Blaster>
shevy: how do you determine when you're overengineering a problem
cads2 has quit [Remote host closed the connection]
baroquebobcat has joined #ruby
<pontiki>
if you're asking the question, you have
<volty>
Blaster: headache
<volty>
?
<pontiki>
if you're not asking the question, you did 3 days ago
<Blaster>
ah
colonolGron has quit [Quit: Lost terminal]
<Blaster>
im always trying to make my code too perfect, it wastes so much time
<Blaster>
I just want to tackle each problem as elegantly as possible
vlad_starkov has joined #ruby
<apeiros>
there's elegance in pragmatism
<bnagy>
weight simplicity as an element of perfection
vlad_starkov has quit [Remote host closed the connection]
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<volty>
Blaster: (and the others like), exercise perfection on cook code, snippets etc // on working code, instead, always brute force
<Blaster>
it becomes harder to maintain later then
<taternuts>
Blaster: keep iterating 'til it works and your confident enough to leave it behind
<volty>
you cannot have the bottle full and your wife drunk ...
end_guy has joined #ruby
<Blaster>
complicated problems...
<volty>
it's like with a spoken language -- talent + (past) studies
<funburn>
patrikf: I like this approach too. thanks!
<pontiki>
oh wow, i'ma steal that, volty
<funburn>
i'm still mystified by this :+
<patrikf>
funburn: it's just a symbol, like :to_s or :other_symbol
<volty>
funburn: you apply sum to all the elements
<volty>
equiv. to inject { |t, el| t + el }
<patrikf>
funburn: 1 + 2, for ruby, is really like calling the method "+" on the object "1". so if the &:correct doesn't mystify you, :+ shouldn't either
<funburn>
I'm not familiar with &:correct either :(
ehc has quit [Quit: ehc]
<Blaster>
if I have a collection of objects and I want to decorate them all, do I just iterate over them and add the extra behaviors?
<fryguy>
Blaster: you could do it at class level too potentially
<Blaster>
the classes are the activerecord objects
gyre007 has joined #ruby
<funburn>
okay, I get that in an "i'm going to be puzzled in a minute" kind of way
simoz has joined #ruby
<volty>
pity you can call only methods without parameters
maletor has quit [Quit: Computer has gone to sleep.]
<funburn>
so weights.inject(:+) just sums up all the weights?
<patrikf>
yep.
<funburn>
perfect, I think I can retain this concept. thanks for taking the time to explain it out
<patrikf>
volty: really? I never needed that before.
werdnativ has quit [Ping timeout: 260 seconds]
gyre007 has quit [Remote host closed the connection]
<volty>
i did, though can't remember now where // but i'm not the right customer - quite hard to please
<volty>
@patrikf
<bnagy>
it would be great
dankest has quit [Quit: dankest]
<patrikf>
well, yeah, coming to think of it I've used blocks calling methods with arguments numerous times... it just doesn't strike me as something where the block is too tedious too write I guess.
<bnagy>
[1,17,25].map(&:to_s,16)
<bnagy>
etc
<volty>
i remember i was doing that in c++ with function templates and the like - but too much time passed by
simoz has quit [Ping timeout: 240 seconds]
<patrikf>
bnagy: true. the block version is more readable though since that's how you're used to see methods invoked
osvico has joined #ruby
simoz has joined #ruby
lkba has quit [Ping timeout: 260 seconds]
<bnagy>
the block version is always more readable
Levin_22 has quit [Quit: Levin_22]
<patrikf>
yes, but it's a bigger step from methods with arguments to another syntax than from methods without arguments. anyway, this is highly subjective
<volty>
let's say something trivial, you want to split, or match, or scan an array of lines and pass the regexp
aeontech has joined #ruby
<volty>
(instead of changing the default field separator - or something more complicated)
zorg24 has quit [Ping timeout: 264 seconds]
<volty>
lines(&:split, /aa/) is quite readable, isn't it?
_bart has quit [Remote host closed the connection]
sambao21 has quit [Quit: Computer has gone to sleep.]
mlpinit has joined #ruby
funburn has quit [Quit: funburn]
<volty>
(.map)
agjacome has quit [Ping timeout: 264 seconds]
funburn has joined #ruby
mary5030 has joined #ruby
jamesaanderson has joined #ruby
<volty>
how do I create an instance variable on a singleton (without creating a method)?
yfeldblum has joined #ruby
snovak has joined #ruby
huoxito has quit [Quit: Leaving]
mlpinit has quit [Ping timeout: 256 seconds]
<bnagy>
instance_variable_set
mrsolo has joined #ruby
<patrikf>
that sounds wrong
<patrikf>
volty: you know attr_writer, right?
byprdct has joined #ruby
Quashie has joined #ruby
sarkis has joined #ruby
<volty>
of course i know it // probably a typo (tired messing)
blackmesa has quit [Ping timeout: 240 seconds]
lkba has joined #ruby
<pontiki>
using instance_variable_set is how you create a new instance variable for an existing instance
<volty>
yap, but i cannot create it from inside a module.extended
zorg24 has joined #ruby
niklasb has quit [Read error: Operation timed out]
<apeiros>
the only way to ivars from outside an object is through a method
thesheff17 has quit [Ping timeout: 264 seconds]
<volty>
apeiros - the magician ! thx :)
snovak has quit [Ping timeout: 264 seconds]
<apeiros>
either ivar_set, instance_eval/exec or a specific method
blackmesa has joined #ruby
sarlalian has quit [Ping timeout: 256 seconds]
Davey has quit [Quit: Computer has gone to sleep.]
thesheff17 has joined #ruby
vlad_starkov has joined #ruby
clocKwize has quit [Quit: clocKwize]
ykk` has quit [Quit: ykk`]
adeponte has quit [Remote host closed the connection]
<banisterfiend>
volty what u trying to do exactly?
Lewix has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
gimpygoo has joined #ruby
<pontiki>
howso, volty ?
<volty>
banisterfiend: trying to go beyond the limits of ruby :)
DanKnox is now known as DanKnox_away
<banisterfiend>
volty can you explain what you're trying to achieve, what are your specs?
<pontiki>
thot this was just ruby sandbox tiem
rburton- has joined #ruby
<volty>
banisterfiend: let's say i have an array and i want multiple pointers that can move around
Fuzai has joined #ruby
<pontiki>
volty: still not seeing what the ns collision is?
Fuzai_ has joined #ruby
mardin has joined #ruby
ics has quit [Ping timeout: 240 seconds]
tungd has joined #ruby
reset has joined #ruby
chxane has quit [Quit: Leaving]
mlpinit has joined #ruby
ner0x has joined #ruby
Voodoofish430 has quit [Quit: Leaving.]
<volty>
pontiki: sorry, i didn't see the self.
funburn has quit [Quit: funburn]
chxane has joined #ruby
pwh has quit [Quit: pwh]
xjiujiu has joined #ruby
pwh has joined #ruby
pwh has quit [Client Quit]
jonahR has joined #ruby
Kelet has quit [Quit: Leaving]
ics has joined #ruby
ics has quit [Max SendQ exceeded]
ewnd9 has joined #ruby
ehaliewicz has joined #ruby
jonr22 has quit [Ping timeout: 260 seconds]
JumpMast3r has joined #ruby
freerobby has joined #ruby
ianclarksmith has joined #ruby
azcodex has quit [Read error: Connection reset by peer]
travisjeffery has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<volty>
trying to connect (my brain) without success, night by(e)
volty has quit [Quit: Konversation terminated!]
Teddy2steper has quit [Remote host closed the connection]
pwh has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
Suit_Of_Sables has joined #ruby
<platzhirsch>
So recognizing his self made him disappear, very philosophic
Lewix has quit [Remote host closed the connection]
<pontiki>
volty: ah, yes, the self in the module defn makes it a module_function
aeontech has quit [Quit: aeontech]
mikepack has quit [Remote host closed the connection]
sepp2k1 has quit [Read error: Connection reset by peer]
<pontiki>
you can also create regular functions that would be accessible in the class that includes the module that act upon the module_functions
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jamesaanderson has joined #ruby
<Suit_Of_Sables>
I understand how to use 'include' within a class to give it access to methods defined elsewhere without having to use inheritance but is there something similar to Java's 'implements' for ensuring that a certain class contains implementations of all methods declared in another abstract class?
ravster has quit [Quit: Leaving.]
reset has quit [Quit: Leaving...]
<existensil>
Suit_Of_Sables: you can create something similar to an Java interface using a module/class that has the methods defined but raises errors for all the methods until they are implemented by a descendent
xjiujiu has quit [Quit: No Ping reply in 180 seconds.]
randomdrake has quit [Quit: randomdrake]
xjiujiu has joined #ruby
<apeiros>
Suit_Of_Sables: "without having to use inheritance"
<apeiros>
actually, include is inheritance
<apeiros>
>> module X; end; class Y; include X; end; Y.ancestors
alexju has quit [Read error: Connection reset by peer]
freerobby1 has quit [Quit: Leaving.]
Splourian has joined #ruby
agent_white has quit [Quit: leaving]
alexju_ has quit [Read error: Connection reset by peer]
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
alexju has joined #ruby
robbyoconnor has joined #ruby
haxrbyte has joined #ruby
robbyoconnor has quit [Read error: Connection reset by peer]
quando has quit [Quit: quando]
locriani has joined #ruby
noopq has joined #ruby
randomdrake has joined #ruby
brianpWins has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
taternuts has quit []
fridim__ has joined #ruby
emanon_ has quit [Read error: Connection reset by peer]
quando has joined #ruby
emanon_ has joined #ruby
haxrbyte has quit [Remote host closed the connection]
haxrbyte has joined #ruby
jamesaanderson has joined #ruby
snovak has joined #ruby
noopq has quit [Ping timeout: 256 seconds]
snovak has quit [Ping timeout: 260 seconds]
vlad_starkov has joined #ruby
alexju has quit [Remote host closed the connection]
alexju has joined #ruby
cj3kim has joined #ruby
jarin has joined #ruby
vlad_starkov has quit [Ping timeout: 240 seconds]
brianpWins has quit [Quit: brianpWins]
tk_ has quit [Quit: ばいばい]
dagnachew has joined #ruby
polaco is now known as polaco_zZz
echevemaster has quit [Quit: Leaving]
locriani has quit [Ping timeout: 246 seconds]
brianpWins has joined #ruby
ananthakumaran has joined #ruby
T_T has joined #ruby
ykk` has quit [Ping timeout: 260 seconds]
nathanieldavid has joined #ruby
jaimef has quit [Excess Flood]
cads has joined #ruby
tjad has quit [Ping timeout: 260 seconds]
intuxicated has joined #ruby
pothibo has quit [Quit: pothibo]
razi has joined #ruby
jaimef has joined #ruby
cj3kim has quit [Remote host closed the connection]
ukd1 has quit [Remote host closed the connection]
macmartine has quit [Quit: Computer has gone to sleep.]
gamma9mu has joined #ruby
krz has joined #ruby
krz has quit [Changing host]
krz has joined #ruby
cj3kim has joined #ruby
Domon__ has quit [Remote host closed the connection]
Domon has joined #ruby
mrsolo has joined #ruby
jp- has joined #ruby
quando has quit [Quit: quando]
tjad has joined #ruby
Domon has quit [Ping timeout: 264 seconds]
randomdrake has quit [Quit: randomdrake]
JohnBat26 has joined #ruby
ewnd9 has quit [Read error: Connection reset by peer]
ewnd9_ has joined #ruby
SHyx0rmZ has quit [Quit: ネウロイを負かさなきゃならないね]
gamma9mu has quit [Remote host closed the connection]
jonahR has quit [Quit: jonahR]
jp- has quit [Quit: OK, I believe you… but my tommy gun don't]
gamma9mu has joined #ruby
i8igmac has quit [Remote host closed the connection]
gamma9mu has quit [Remote host closed the connection]
locriani has joined #ruby
gamma9mu has joined #ruby
quando has joined #ruby
highlighters has joined #ruby
locriani has quit [Ping timeout: 256 seconds]
KobraKao has quit [Quit: Saindo]
snovak has joined #ruby
locriani has joined #ruby
tomzx_mac has quit [Ping timeout: 240 seconds]
mansi has joined #ruby
snovak has quit [Ping timeout: 240 seconds]
aryaching_ has joined #ruby
locriani has quit [Remote host closed the connection]
aryaching has quit [Ping timeout: 240 seconds]
mansi has quit [Remote host closed the connection]
duggiefresh has quit [Remote host closed the connection]
mansi has joined #ruby
mclosson has quit [Quit: leaving]
aryaching has joined #ruby
pvizcay has joined #ruby
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
nathanieldavid has quit [Quit: Bye!]
fridim__ has quit [Ping timeout: 264 seconds]
gamma9mu has quit [Remote host closed the connection]
aryaching_ has quit [Ping timeout: 256 seconds]
jamesaanderson has joined #ruby
mansi has quit [Ping timeout: 264 seconds]
aryaching_ has joined #ruby
ryandeussing has joined #ruby
dagnachew has quit [Read error: Operation timed out]
Es0teric has quit [Quit: Computer has gone to sleep.]
yekta has quit [Quit: yekta]
byprdct has joined #ruby
byprdct has quit [Max SendQ exceeded]
aryaching has quit [Ping timeout: 240 seconds]
browndawg has joined #ruby
ryandeussing has quit [Ping timeout: 264 seconds]
dmiller has quit [Remote host closed the connection]
zets has quit []
DoritosMan has joined #ruby
quazimodo has joined #ruby
highlighters has quit [Quit: highlighters]
xjiujiu has joined #ruby
highlighters has joined #ruby
razi has quit [Quit: Leaving.]
xjiujiu_ has quit [Ping timeout: 264 seconds]
eka has quit [Ping timeout: 264 seconds]
xjiujiu has quit [Quit: No Ping reply in 180 seconds.]
xjiujiu has joined #ruby
highlighters has quit [Quit: highlighters]
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
quando has quit [Quit: quando]
ukd1 has joined #ruby
DoritosMan is now known as DM
noop has joined #ruby
sayan has joined #ruby
xjiujiu has quit [Quit: No Ping reply in 180 seconds.]
xjiujiu has joined #ruby
parzo has joined #ruby
quazimodo has quit [Ping timeout: 264 seconds]
ugm781 has joined #ruby
quando has joined #ruby
ugm781 has quit [Client Quit]
jamesaanderson has joined #ruby
echevemaster has joined #ruby
echevemaster has joined #ruby
cj3kim has quit [Remote host closed the connection]
Monie has joined #ruby
highlighters has joined #ruby
ukd1 has quit [Ping timeout: 240 seconds]
Monie has quit [Client Quit]
bg_ has joined #ruby
dmiller has joined #ruby
xjiujiu has quit [Quit: No Ping reply in 180 seconds.]
quando has quit [Quit: quando]
xjiujiu has joined #ruby
diegoviola has joined #ruby
<diegoviola>
hi
<diegoviola>
i have some filename string with something like "foo.svg.png", is there a regex or something i can use to remove all the extensions and just get "foo"?
<diegoviola>
please
parzo has quit [Ping timeout: 260 seconds]
<diegoviola>
i need to learn regex, i also tried google but none of the regex i found work
fgo has joined #ruby
dmiller has quit [Ping timeout: 264 seconds]
Es0teric has joined #ruby
Es0teric has quit [Remote host closed the connection]
uri781 has joined #ruby
snovak has joined #ruby
uri781 has left #ruby [#ruby]
mrsolo has quit [Quit: This computer has gone to sleep]
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
wookiehangover has quit [Ping timeout: 248 seconds]
kevind has quit [Quit: kevind]
jericon has quit [Read error: Operation timed out]
jericon has joined #ruby
alexju_ has joined #ruby
kilophoton has quit [Ping timeout: 240 seconds]
T_T has quit [Remote host closed the connection]
moeSeth_ has quit [Ping timeout: 264 seconds]
AlSquire has quit [Read error: Connection reset by peer]
<|jemc|>
\. is the escaped representation of '.' because the . is a special character in regexp
<|jemc|>
\w is the character class representing alphabet and numerical characters - one \w represents one character fitting into this group
<|jemc|>
the + dictates that you are looking for one or more of these \w characters
<diegoviola>
ty
<|jemc|>
and the $ indicates the end of the string, meaning that it won't match the pattern if it occurs in the middle (it is a zero-width assertion, essentially anchoring it to the end)
predator117 has quit [Ping timeout: 260 seconds]
ukd1 has joined #ruby
pwh has quit [Quit: pwh]
<|jemc|>
and the gsub method replaces every instance of that pattern found in the string with the following string, '' (an empty string)
predator117 has joined #ruby
<|jemc|>
that, along with the website should get you started
<|jemc|>
have fun. regular expressions are a great tool to be able to use
<diegoviola>
right, thanks
Tuxist has joined #ruby
<|jemc|>
although I should note that for this particular case, there is a builtin method to help you drop the file extension from a filename
monkegjinni has quit [Remote host closed the connection]
<MrZYX>
dsferreira: let me repeat that once more, you're not modifying the instance variable, you're modifying the object currently assigned to the instance variable
cj3kim has joined #ruby
nemesit|znc has joined #ruby
<MrZYX>
maybe describe the behaviour you need (including the real world application) and we may find a solution for you
lkba has joined #ruby
noop has quit [Ping timeout: 264 seconds]
bulkan has joined #ruby
mengu has joined #ruby
araujo has joined #ruby
carraroj has quit [Ping timeout: 246 seconds]
<dsferreira>
I'm trying to understand here the problem
vlad_starkov has joined #ruby
<dsferreira>
You're class Foo is my Array class
<bulkan>
why is rbenv telling me rbenv: ruby: command not found
<MrZYX>
exactly
ismlages has joined #ruby
<bulkan>
after I run `bundle install`
<dsferreira>
So the Bar is my Test
<MrZYX>
yes
<dsferreira>
in my case I do Test.files
osvico has joined #ruby
<dsferreira>
It would be the same has Bar.foo
<dsferreira>
ok
ananthakumaran has quit [Quit: Leaving.]
_bart has joined #ruby
DanKnox is now known as DanKnox_away
<dsferreira>
The is a Bar.instance_variable_get(:@foo) = Foo.new
<MrZYX>
to be precise you're doing Test.files.<<('some_files') and I'm doing Bar.foo.bar=(2)
Advocation has quit [Quit: Advocation]
<MrZYX>
both are in fact method calls on the object returned by .files/.foo
saskuach has quit [Quit: saskuach]
<dsferreira>
This means that an instance variable is always open to be changed outside the class environment.
<bulkan>
anyone use rbenv ?
cj3kim has quit [Ping timeout: 256 seconds]
visof has quit [Ping timeout: 256 seconds]
<dsferreira>
Which mean that ruby makes available the instance variable object methods to the public?
<MrZYX>
no, you're not changing the instance variable. You're changing the object that's assigned to the instance variable
<MrZYX>
not ruby did, you did with attr_reader :files
<MrZYX>
which is a shortcut to def files; @files; end
<dsferreira>
So what would be the solution?
drPoggs has quit [Ping timeout: 246 seconds]
<MrZYX>
I yet have to see a problem ;)
haxrbyte has quit [Remote host closed the connection]
<MrZYX>
all intended behavior so far
Olipro has quit [Ping timeout: 246 seconds]
ukd1 has joined #ruby
<dsferreira>
With attr_reader my purpose was to be able to get the value of the instance variable not allow anyone to change it
<MrZYX>
but still being able to change it inside the class?
Notte has quit [Remote host closed the connection]
<dsferreira>
How can we make the instance variable accessible to the public and close the change of that value
ukd1_ has joined #ruby
<dsferreira>
I thought it would be done with the attr_reader vs attr_writer
<MrZYX>
and we need to get terminology straight here: you're not changing the instance variable, you're changing the object inside the instance variable
<dsferreira>
Ok
<dsferreira>
Understood
<MrZYX>
attr_writer does set the instance variable
Olipro has joined #ruby
<dsferreira>
I no that. I have tried it.
<dsferreira>
I can only change the object associated to the instance_variable
<MrZYX>
it defines a method like def files=(v) @files = v; end
<dsferreira>
I no
<dsferreira>
know
drPoggs has joined #ruby
<MrZYX>
you maybe you want return frozen copies of files
<dsferreira>
This is new to me, because I never had realised that we can change the object associated to an instance variable outside the class scope.
<MrZYX>
still not sure why that would be super useful
<MrZYX>
you're not changing the association, you're modifying the object
<dsferreira>
What implications come from that
ukd1_ has quit [Remote host closed the connection]
<dsferreira>
yes change the object associated
ukd1 has quit [Ping timeout: 264 seconds]
dmiller has joined #ruby
<dsferreira>
While coding I always thought the instance variables values would not change unless you would explicitly set them
vlad_starkov has quit [Ping timeout: 264 seconds]
<dsferreira>
Is there any security implication associated to this?
Banistergalaxy has joined #ruby
<dsferreira>
For instance. You set an instance variable as an array or string which is common
<MrZYX>
the security implication is the same as everywhere in ruby: if the attacker can run code or call arbitrary methods you lost
dangerousdave has joined #ruby
Xeago_ has joined #ruby
<MrZYX>
always filter user input that goes into stuff like .send through a whitelist, never eval user input
vlad_starkov has joined #ruby
<dsferreira>
So I have this program to load files contents to a database
<dsferreira>
I want to receive as an argument the files directory.
<dsferreira>
This will be the only user interface for the time being.
dmiller has quit [Ping timeout: 240 seconds]
AndChat| has quit [Ping timeout: 264 seconds]
<dsferreira>
So in that regard I'm not concerned
<dsferreira>
I'm think more when you develop a gem and want to make it available to the public
Banistergalaxy has quit [Read error: Connection reset by peer]
<MrZYX>
DBImporter.new(Dir["./ARGV[0]/**/*"]) no problem in doing something like that
<dsferreira>
In that case the API is important so that the gem users are assured that nothing wrong will happen. No security halls.
visof has joined #ruby
<dsferreira>
Yes. Once again that is not my concern at the moment
<MrZYX>
well, write proper docs, if the user does want to break your gem, he'll find a way
dAnjou_ is now known as dAnjou
<dsferreira>
I'm just trying to realise what are the implications of this new reality for me.
blackmesa has joined #ruby
<MrZYX>
he can always do class Test; attr_writer :files; end, a ruby class can always be reopened
azcodex has joined #ruby
<MrZYX>
all foots that he'll shoot will be his own anyway
<dsferreira>
If you really want to close your instance variable object status. Which mean hide all it's methods from public. What would you do?
<dsferreira>
attr_reader is out of question.
ferdev has joined #ruby
<MrZYX>
define no single getter
<dsferreira>
So it should be something like object.inspect?
fgo has joined #ruby
<dsferreira>
def show_files
<dsferreira>
@files.inspect end
vlad_sta_ has joined #ruby
<dsferreira>
That would resolve the problem right?
vlad_starkov has quit [Read error: Connection reset by peer]
<MrZYX>
depends on how useful that would be to the caller
<dsferreira>
Or even: def files; @files.inspect; end
<MrZYX>
and I still can just do instance_variable_get or instance_variable_set
<dsferreira>
That is true
<MrZYX>
you can freeze an object, then nobody can modify it anymore
<MrZYX>
except if you #unfreeze it ;)
<dsferreira>
Yes. I see.
<MrZYX>
so ruby doesn't provide any mean to enforce anything
<dsferreira>
Good to remember.
<dsferreira>
The developer as all the tools in his hands
<MrZYX>
you rather say: that's the intended path, if you leave it, fine, but you're on your own, guarantees void
<dsferreira>
The user is a different situation.
<dsferreira>
But the user side is just the ARGV[0]
<MrZYX>
or gets or DB input or a tcplistener, but yeah
<MrZYX>
ruby will never evaluate any kind of user input on its own
<MrZYX>
you have to tell him that
bluenemo has joined #ruby
bluenemo has joined #ruby
chairabanta has joined #ruby
<MrZYX>
most of the time that would happen through the families of send and eval
<dsferreira>
I get it. Thanks
visof has quit [Ping timeout: 260 seconds]
_bart has quit [Remote host closed the connection]
okinomo has joined #ruby
ferdev has quit [Quit: ferdev]
Xeago_ has quit [Remote host closed the connection]
Domon has quit [Read error: Connection reset by peer]
DrCode has quit [Ping timeout: 240 seconds]
Domon has joined #ruby
azcodex has quit [Quit: azcodex]
Domon has quit [Remote host closed the connection]
cody-- has joined #ruby
pushpak has joined #ruby
JesseH has joined #ruby
TripleDES has joined #ruby
jefflyne3 has joined #ruby
okinomo has quit [Read error: No route to host]
TripleDES has quit [Read error: Connection reset by peer]
_bart has joined #ruby
goganchic has joined #ruby
saskuach has joined #ruby
mansi has joined #ruby
TripleDES has joined #ruby
pjb1 has joined #ruby
vlad_sta_ has quit [Remote host closed the connection]
okinomo has joined #ruby
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
mansi has quit [Ping timeout: 246 seconds]
relix has joined #ruby
goshakkk has joined #ruby
Domon has joined #ruby
Domon has quit [Remote host closed the connection]
Domon has joined #ruby
sambao21 has joined #ruby
DrCode has joined #ruby
yosafbridge has quit [Ping timeout: 264 seconds]
Notte has joined #ruby
Domon has quit [Remote host closed the connection]
yosafbridge has joined #ruby
atno has quit [Ping timeout: 240 seconds]
rcosta has quit [Remote host closed the connection]
_bart has quit [Ping timeout: 264 seconds]
saskuach has quit [Quit: saskuach]
dodosan has joined #ruby
VTLob has joined #ruby
dangerousdave has quit [Quit: Leaving...]
dodosan has quit [Ping timeout: 256 seconds]
gg0_ has joined #ruby
Fuzai has quit [Remote host closed the connection]
saskuach has joined #ruby
snovak has joined #ruby
jibi has quit [Quit: .]
cody-- has quit [Quit: derp]
bulkan has left #ruby [#ruby]
yacks has quit [Ping timeout: 256 seconds]
cj3kim has joined #ruby
snovak has quit [Ping timeout: 246 seconds]
Xeago_ has joined #ruby
Tuxist has joined #ruby
coderhs has quit [Ping timeout: 264 seconds]
cj3kim has quit [Ping timeout: 240 seconds]
agjacome has joined #ruby
hamakn has quit [Remote host closed the connection]
schaerli has quit [Remote host closed the connection]
pothibo has joined #ruby
vlad_starkov has joined #ruby
dodosan has joined #ruby
Clooth has quit [Client Quit]
Xeago_ has joined #ruby
intuxicated has quit [Ping timeout: 260 seconds]
Advocation has quit [Quit: Advocation]
dodosan has quit [Ping timeout: 259 seconds]
goganchic has quit []
Aryasam has joined #ruby
atno has quit [Ping timeout: 260 seconds]
cody-- has joined #ruby
okinomo has quit [Ping timeout: 260 seconds]
apeiros has quit [Remote host closed the connection]
waxjar has joined #ruby
jonkri has quit [Quit: jonkri]
soya has joined #ruby
platzhirsch1 has joined #ruby
okinomo has joined #ruby
yekta has joined #ruby
jp- has joined #ruby
zarubin has joined #ruby
kaspergrubbe has quit [Remote host closed the connection]
duggiefresh has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
atno has joined #ruby
vlad_starkov has joined #ruby
platzhirsch1 has left #ruby [#ruby]
duggiefresh has quit [Remote host closed the connection]
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
kaspergrubbe has joined #ruby
platzhirsch has joined #ruby
<platzhirsch>
How is it going down here? :)
mansi has joined #ruby
Aryasam has quit [Ping timeout: 264 seconds]
intuxicated has joined #ruby
kaspergrubbe has quit [Remote host closed the connection]
Notte has quit [Remote host closed the connection]
mansi has quit [Ping timeout: 264 seconds]
randomdrake has joined #ruby
kaspergrubbe has joined #ruby
sambao21 has joined #ruby
atno has quit [Ping timeout: 264 seconds]
randomdrake has quit [Ping timeout: 256 seconds]
saskuach has quit [Quit: saskuach]
mary5030 has joined #ruby
sambao21 has quit [Remote host closed the connection]
sambao21 has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
sambao21 has quit [Client Quit]
saskuach has joined #ruby
vlad_starkov has joined #ruby
DanKnox_away is now known as DanKnox
Xeago_ has quit [Read error: Connection reset by peer]
Advocation has joined #ruby
DrCode has quit [Ping timeout: 240 seconds]
Xeago_ has joined #ruby
hogeo has joined #ruby
Banistergalaxy has joined #ruby
Xeago_ has quit [Read error: Connection reset by peer]
Xeago_ has joined #ruby
Cyrus has quit [Read error: Operation timed out]
Xeago_ has quit [Read error: Connection reset by peer]
rcosta has joined #ruby
snovak has joined #ruby
DrCode has joined #ruby
Xeago_ has joined #ruby
mary5030 has quit [Remote host closed the connection]
mary5030 has joined #ruby
saskuach has quit [Ping timeout: 260 seconds]
vlad_starkov has quit [Ping timeout: 264 seconds]
polaco_zZz is now known as polaco
sevenseacat has joined #ruby
d45h has joined #ruby
saskuach has joined #ruby
saskuach has quit [Client Quit]
rcosta has quit [Remote host closed the connection]
Advocation has quit [Quit: Advocation]
snovak has quit [Ping timeout: 245 seconds]
vlad_starkov has joined #ruby
vlad_starkov has quit [Remote host closed the connection]
saskuach has joined #ruby
vlad_starkov has joined #ruby
intuxicated has quit [Ping timeout: 246 seconds]
dash_ has quit [Ping timeout: 256 seconds]
DanKnox is now known as DanKnox_away
vlad_starkov has quit [Ping timeout: 264 seconds]
yekta has quit [Quit: yekta]
mary5030 has quit [Remote host closed the connection]
starfox21 has quit [Quit: starfox21]
relix has joined #ruby
zorg24 has quit [Ping timeout: 260 seconds]
ananthakumaran has joined #ruby
<linduxed>
hey guys, yesterday i was in a discussion with a co-worker and we started talking about a piece of code which we had extracted into a class
mengu has joined #ruby
<linduxed>
the thing is that the main method which would be used was more like a function
maroloccio has joined #ruby
<linduxed>
you provided two arguments and got back a result
<linduxed>
no side effects
colonolGron has quit [Ping timeout: 260 seconds]
<linduxed>
so the question was, why should we instantiate that class? why work with an object when we could just provide a class method?
mfridh has quit [Ping timeout: 240 seconds]
colonolGron has joined #ruby
duggiefresh has joined #ruby
<linduxed>
i still voted for going the instance method route, but since the implementation was fairly easy and we would only ever have one instance of it
ryandeussing has joined #ruby
<linduxed>
it just felt like BananaSearcher.find(green_banana) was kind of the same as BananaSearcher.new(green_banana).find
Guest1214 has joined #ruby
okinomo_ has joined #ruby
<platzhirsch>
linduxed: well, I know this situation you have described
okinomo has quit [Ping timeout: 260 seconds]
saskuach has quit [Quit: saskuach]
<platzhirsch>
but what about module methods?
emergion has quit [Quit: Computer has gone to sleep.]
<platzhirsch>
module BananaSeacher; def self.find(green_banana); ... ; end; end
mansi has joined #ruby
duggiefresh has quit [Remote host closed the connection]
<Guest1214>
hi
mfridh has joined #ruby
starfox21 has joined #ruby
fflush has joined #ruby
Guest1214 has quit [Client Quit]
<fflush>
bonjour
Xeago_ has quit [Remote host closed the connection]
<linduxed>
platzhirsch: yeah that could be an idea, but this wouldn't be something what would have been reused
<linduxed>
so i think a class makes more sense
<platzhirsch>
how come?
<platzhirsch>
How come the class is more likely to be reused?
<platzhirsch>
Because it's probably going to get a state?
schaerli has joined #ruby
sayan has quit [Ping timeout: 240 seconds]
<linduxed>
no i'm saying that in both cases it probably won't be reused
kreantos has joined #ruby
<platzhirsch>
ah
<linduxed>
so i figured it fits a bit better to extract into a class
<shevy>
that is the kind of discussion that just should not be happen really
<platzhirsch>
shevy: why?
<shevy>
because it only exists as there is a functional difference between modules and classes
kreantos has quit [Read error: Connection reset by peer]
funburn has joined #ruby
<shevy>
when do you guys use module methods and when do you guys use class methods?
kreantos has joined #ruby
vlad_starkov has joined #ruby
fgo has joined #ruby
<platzhirsch>
So modules are are nice if you want to mixin behavior (imo). But I also tend to use modules to namespace certain static methods
funburn has quit [Client Quit]
cj3kim has joined #ruby
kreantos_ has joined #ruby
vlad_starkov has quit [Read error: No route to host]
<platzhirsch>
and class methods if I happen to have a class anyway and I want to put a functionality into it because it is a) not based on an object's state b) can or should be used by other instances
vlad_starkov has joined #ruby
rcosta has joined #ruby
<Banistergalaxy>
Linduxed instances are better if you need to store state
<Banistergalaxy>
And threads or whatever could be used
<platzhirsch>
shevy: or what do you mean?
colonolGron has quit [Quit: Lost terminal]
duggiefresh has joined #ruby
cina has joined #ruby
Xeago has quit [Remote host closed the connection]
emergion has joined #ruby
Xeago has joined #ruby
kreantos has quit [Ping timeout: 240 seconds]
cj3kim has quit [Ping timeout: 246 seconds]
agjacome has joined #ruby
cads has quit [Ping timeout: 264 seconds]
agjacome has quit [Client Quit]
kindjal has joined #ruby
jefflyne3 has joined #ruby
lupine has left #ruby [#ruby]
blaxter_ has quit [Quit: foo]
Ripp__ has joined #ruby
freerobby has joined #ruby
sambao21 has joined #ruby
fgo has quit [Remote host closed the connection]
lupine has joined #ruby
freerobby has quit [Client Quit]
emergion has quit [Quit: Computer has gone to sleep.]
<linduxed>
Banistergalaxy: yes i know that
<linduxed>
Banistergalaxy: but this is specifically a case where I pretty much won't store state
zorg24 has joined #ruby
sysop2 has quit [Ping timeout: 245 seconds]
<linduxed>
it's a special case
freerobby has joined #ruby
freerobby has quit [Client Quit]
<Banistergalaxy>
If they're pure functions, who cares ;)
jerius has joined #ruby
Xeago has quit [Ping timeout: 246 seconds]
vlad_sta_ has joined #ruby
freerobby has joined #ruby
blackmesa has quit [Ping timeout: 240 seconds]
vlad_starkov has quit [Ping timeout: 256 seconds]
<platzhirsch>
who cares, hah.. the Ruby case
robbyoconnor has joined #ruby
jbpros has joined #ruby
freerobby has quit [Quit: Leaving.]
randomdrake has joined #ruby
vlad_starkov has joined #ruby
<Banistergalaxy>
Idiot
freerobby has joined #ruby
soya has quit [Quit: WeeChat 0.4.1]
krz has joined #ruby
<platzhirsch>
:|
Ripp__ has quit []
<platzhirsch>
Banistergalaxy: I just wanted to express that I found this idiomatic as Ruby advertises itself with many ways to do the same thing
<Banistergalaxy>
Weak
<shevy>
platzhirsch there is not much choice we get right now due to the way how ruby was designed
<shevy>
platzhirsch that something is really odd is the fact that the predominant way to handle inheritance (by subclassing) is at odds with what many other people like to use (include-functionality through modules, even to the point where you dont have to subclass at all)
vlad_sta_ has quit [Ping timeout: 256 seconds]
<shevy>
platzhirsch you wrote that you use modules to namespace other methods. but you could use a class as well as namespace container
<platzhirsch>
shevy: so you would say that's legitimate as well?
randomdrake has quit [Ping timeout: 264 seconds]
<platzhirsch>
it just felt a bit wrong, but then again I only know design from Java, C#, Python,..
<shevy>
platzhirsch well, ruby allows it. I myself absolutely hate that
jbpros has quit [Ping timeout: 256 seconds]
<shevy>
as apeiros once wrote when I asked him why he used class as namespace, he said he got more features that way (because he can call .new on his main namespace, which he could not if he would use a module instead)
<shevy>
class Foo; class Bar
<shevy>
vs
<shevy>
module Foo; class Bar
rcosta has quit [Ping timeout: 246 seconds]
<platzhirsch>
well there is a point in extending the namespace to something with a state in a later phase of development...
rcosta has joined #ruby
timonv has joined #ruby
dodosan has joined #ruby
DoritosMan has joined #ruby
bluenemo has quit [Ping timeout: 264 seconds]
apeiros has joined #ruby
_maes_ has joined #ruby
<shevy>
those questions often puzzled me
kreantos_ has quit [Ping timeout: 260 seconds]
<shevy>
like "when do I have to use @@foo variables"
<platzhirsch>
shevy: never :D
<shevy>
yeah but did anyone say that before?
dodosan has quit [Ping timeout: 256 seconds]
<shevy>
I think I saw them first in the pickaxe book
snovak has joined #ruby
okinomo_ has quit [Ping timeout: 264 seconds]
<shevy>
it would be nice to have a table listing the efficiency and usefulness of programming language features
<shevy>
instance-variables: very, very useful
<shevy>
class-variables: almost utterly useless
<shevy>
global-variables: limited use case, but ugly
quoin has quit [Remote host closed the connection]
<platzhirsch>
shevy: it's very unbalanced that one can make such judgment, with whom I all agree, about language features
<proc{|x|x^2}>
while this is a valid nick, ->{|x|x^2} is not :(
proc{|x|x^2} is now known as apeiros
tungd has quit [Quit: leaving]
KobraKao has quit [Client Quit]
tungd has joined #ruby
jbpros has quit [Quit: jbpros]
Xeago has joined #ruby
adambeynon has joined #ruby
rcosta has joined #ruby
zmike123 has joined #ruby
saskuach has quit [Quit: saskuach]
azcodex has quit [Quit: azcodex]
aryaching has joined #ruby
tungd has quit [Client Quit]
sevenseacat has quit [Quit: Leaving.]
tungd has joined #ruby
karakhul has joined #ruby
jefflyne3 has quit [Ping timeout: 246 seconds]
rcosta_ has quit [Ping timeout: 240 seconds]
bluOxigen has joined #ruby
T_T has joined #ruby
workmad3 has joined #ruby
Xeago has quit [Ping timeout: 264 seconds]
<shevy>
proc{|x|x^2}.call
saskuach has joined #ruby
<platzhirsch>
so, what's the result?
atno has joined #ruby
Lewix has joined #ruby
<platzhirsch>
I bet 100$ on it does not matter, what do I get?
cina has quit [Remote host closed the connection]
<apeiros>
the result would probabl be an exception
<apeiros>
since nil^2 doesn't work well
dmiller has joined #ruby
cina has joined #ruby
T_T has quit [Remote host closed the connection]
fgo has joined #ruby
Lewix has quit [Remote host closed the connection]
Lewix has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
randomdrake has joined #ruby
dmiller has quit [Ping timeout: 256 seconds]
fgo has quit [Ping timeout: 260 seconds]
T_T has joined #ruby
Clooth has joined #ruby
nx000bsd has quit [Read error: Connection reset by peer]
nx000bsd has joined #ruby
fridim__ has joined #ruby
Lewix has quit [Remote host closed the connection]
<Suit_Of_Sables>
ls
forced_request has joined #ruby
<Suit_Of_Sables>
ewps, notta shell >.<
LeafMan has joined #ruby
<LeafMan>
Hey, how can I declare private functions in Python
DrCode has quit [Ping timeout: 240 seconds]
randomdrake has quit [Ping timeout: 246 seconds]
<apeiros>
LeafMan: wrong channel
<LeafMan>
apeiros: ,,|,,
dhruvasagar has joined #ruby
kreantos has quit [Ping timeout: 240 seconds]
LeafMan was kicked from #ruby by apeiros [yeah, no, that kind of behavior is not accepted here]
<canton7>
and you don't, iirc? You prepend them with '_' and hope no-one sees them
sambao21 has joined #ruby
JumpMast3r has quit [Quit: JumpMast3r]
<canton7>
damn
<canton7>
bit harsh....
<apeiros>
the ban? it'll be removed in 5~10min
<canton7>
why bad at all?
<canton7>
*ban
<apeiros>
because idiots tend to come back and spout nonsense.
Lewix has joined #ruby
<apeiros>
and 5-10min is usually enough for them to come to their senses.
<canton7>
he's a guy who got the wrong channel
<apeiros>
canton7: um
<apeiros>
17:23 LeafMan: apeiros: ,,|,,
cina has quit [Ping timeout: 264 seconds]
browndawg has quit [Ping timeout: 264 seconds]
<apeiros>
figure what that means :-p
<shevy>
is that an ascii middle finger?
<apeiros>
yes
<canton7>
fair, I haven't seen that one before
<shevy>
In all my years of IRC I never had that idea yet :D
<apeiros>
it's not "getting the wrong channel" which got him kicked ;-)
<shevy>
hehehehe
<platzhirsch>
good thing it has two commas on each side and not just one
<apeiros>
if that had been all, then yes, kicking would have been waaay out of bounds
<shevy>
platzhirsch how about that ~,|,~
Lewix has quit [Remote host closed the connection]
katsrc has quit [Remote host closed the connection]
Lewix has joined #ruby
<platzhirsch>
shevy: oh...
saskuach has quit [Quit: saskuach]
<shevy>
hmm.. I can't draw in reallife... and I can't draw in ascii either
dodosan has joined #ruby
<apeiros>
canton7: just trust in me making sane decisions :-p
<apeiros>
wrt kicking/banning
Guest63395 has quit [Ping timeout: 240 seconds]
Lewix has quit [Remote host closed the connection]
<canton7>
haha, agreed it's reasonable. I hadn't seen that particular ascii before, and so was surprised, hence my questions
aryaching has quit []
Lewix has joined #ruby
<apeiros>
sure, sure. I was kidding anyway. it's a good idea to watch the watchers.
<canton7>
anyway, cue rant about pythoners being rude bastards? ;)
<apeiros>
dunno, don't know too many pythonistas
carraroj has joined #ruby
<platzhirsch>
I will go back to Python programming when preparing for coding interview questions... sigh
<canton7>
hmm, neither. the best one I know picked it up because I was insisting that ruby > python... same with git/hg
dodosan has quit [Ping timeout: 240 seconds]
vlad_starkov has quit [Read error: Operation timed out]
DrCode has joined #ruby
kreantos has joined #ruby
chairabanta has joined #ruby
kobain has joined #ruby
kobain has quit []
<veronica>
how can i tunnel via an http proxy
|jemc| has joined #ruby
kobain has joined #ruby
browndawg has joined #ruby
kilophoton has joined #ruby
duggiefresh has quit [Read error: Connection reset by peer]
duggiefr_ has joined #ruby
<canton7>
veronica, how many languages are you trying to do this in?
<shevy>
chinese
<canton7>
##php and #ruby so far.. not seen him in ##csharp
<shevy>
hehe
<veronica>
php ruby i triedd commandline linux
<veronica>
i'll soon hit cpp
aryaching has joined #ruby
<shevy>
now try GUI linux!
<shevy>
cpp has good tunnels
<veronica>
this is SOOO easy that i don't know how anyone cant answer this tto me.
dhruvasagar has quit [Ping timeout: 264 seconds]
<apeiros>
if it's so easy, why do you need an answer at all then?
Lewix has quit [Remote host closed the connection]
<apeiros>
if you don't know the answer, how do you know it is soooo easy?
Lewix has joined #ruby
<canton7>
the problem is that it's a very open question. people tend not to like to get stuck into those sorts of questions unless they have a lot of time available, right now
<apeiros>
veronica: you tunnel through an http proxy by setting your http proxy option
sergicles has left #ruby [#ruby]
kreantos has quit [Ping timeout: 260 seconds]
jbpros has joined #ruby
rcosta has quit [Read error: Connection reset by peer]
Lewix has quit [Remote host closed the connection]
jbpros has quit [Client Quit]
rcosta has joined #ruby
Lewix has joined #ruby
cody-- has quit [Quit: derp]
carraroj has quit [Ping timeout: 261 seconds]
zmike123 has quit [Quit: ~]
Lewix has quit [Remote host closed the connection]
grzywacz has joined #ruby
Lewix has joined #ruby
noop has joined #ruby
wallerdev has joined #ruby
LeafMan has joined #ruby
DoritosMan has quit [Quit: MacBook has gone to sleep]
Yakko has joined #ruby
Lewix has quit [Remote host closed the connection]
<LeafMan>
Sorry, I think I stated the question in the wrong channel? ⨀_Ꙩ
Lewix has joined #ruby
noop is now known as noopq
vlad_starkov has joined #ruby
Guest63395 has joined #ruby
kvirani has joined #ruby
vlad_starkov has quit [Read error: Connection reset by peer]
vlad_starkov has joined #ruby
Lewix has quit [Remote host closed the connection]
Lewix has joined #ruby
rcosta_ has joined #ruby
vlad_sta_ has joined #ruby
Lewix has quit [Remote host closed the connection]
rcosta has quit [Ping timeout: 264 seconds]
Lewix has joined #ruby
tjj has joined #ruby
<tjj>
I'm a total ruby newbie, and I'm trying to install the package at https://github.com/mingjin/vagrant-ovf. When I try to run "gem install vagrant-ovf" like the docs say, gem gives the error "Could not find a valid gem 'vagrant-ovf' in any repository". What am I doing wrong?
vlad_st__ has joined #ruby
Lewix has quit [Remote host closed the connection]
<LeafMan>
tjj: ಠ︵ಠ凸
coderhs has quit [Ping timeout: 260 seconds]
<tjj>
eh?
* LeafMan
purs gasoline over apeiros and puts him to the fire
LeafMan was kicked from #ruby by apeiros [LeafMan]
<C0deMaver1ck>
wat just happened
<apeiros>
he's probably some troll
dhruvasagar has joined #ruby
<apeiros>
tjj: I think you can safely ignore what LeafMan said.
vlad_starkov has quit [Ping timeout: 256 seconds]
ewnd9_ has quit [Remote host closed the connection]
ewnd9 has joined #ruby
randomdrake has joined #ruby
Es0teric has joined #ruby
nazty has quit [Read error: No route to host]
karakhul has quit [Remote host closed the connection]
okinomo has joined #ruby
dhruvasagar has quit [Read error: Connection reset by peer]
vlad_sta_ has quit [Ping timeout: 264 seconds]
kreantos has joined #ruby
<MrZYX>
tjj: there's no such gem on rubygems.org so poke the maintainer about that
ehc has joined #ruby
<tjj>
MrZYX: OK, thanks...after reading more it looks like the package doesn't do what I wanted anyways
byprdct has joined #ruby
<canton7>
tjj, for future, if the gem isn't on rubygems, you'd have to clone that repo, gem build <file>.gemspec, gem install <file>.gem
tomzx_mac has joined #ruby
fgo has joined #ruby
Guest63395 has quit [Remote host closed the connection]
vlad_st__ has quit [Read error: Connection reset by peer]
saskuach has joined #ruby
closer has quit [Ping timeout: 252 seconds]
vlad_starkov has joined #ruby
okinomo has quit [Ping timeout: 264 seconds]
dodosan has joined #ruby
Guest63395 has joined #ruby
carraroj has joined #ruby
adeponte has joined #ruby
dodosan has quit [Read error: Connection reset by peer]
closer has joined #ruby
starfox21 has quit [Ping timeout: 260 seconds]
dodosan has joined #ruby
cina has joined #ruby
defrag has quit [Ping timeout: 245 seconds]
mengu has quit [Quit: Leaving]
vlad_starkov has quit [Read error: Connection reset by peer]
Lewix has joined #ruby
vlad_starkov has joined #ruby
cj3kim has joined #ruby
adeponte has quit [Remote host closed the connection]
saskuach has quit [Quit: saskuach]
Lewix has quit [Remote host closed the connection]
Lewix has joined #ruby
Lewix has quit [Read error: Connection reset by peer]
Lewix has joined #ruby
_Minos_ has joined #ruby
quoin has joined #ruby
starfox21 has joined #ruby
Lewix has quit [Remote host closed the connection]
Notte has quit [Remote host closed the connection]
ferdev has quit [Quit: ferdev]
rcosta has joined #ruby
virtualize has joined #ruby
jamesaanderson has joined #ruby
tylersmith has joined #ruby
<brunoro>
kraljev2: if they don't have any data dependencies you could fork processes to acheive parallelism
<brunoro>
if your `work` functions aren't data dependent, I mean
<kraljev2>
sadly, they are
rcosta_ has quit [Ping timeout: 260 seconds]
Advocation has joined #ruby
<brunoro>
well, then you _shouldn't_ be running it in parallel
Lewix has joined #ruby
mrsolo has quit [Quit: This computer has gone to sleep]
timonv has joined #ruby
<kraljev2>
those are websocket callsž
pjb1 has quit [Quit: pjb1]
<kraljev2>
I am trying to achieve that
arca0 has quit [Remote host closed the connection]
<MrZYX>
did you try to use a mutex yet?
aryaching has quit [Ping timeout: 257 seconds]
<kraljev2>
Thread::Mutex ?
cj3kim has joined #ruby
rcosta has quit [Remote host closed the connection]
saskuach has quit [Remote host closed the connection]
<MrZYX>
it's in the toplevel namespace for me
quando has quit [Quit: quando]
schaerli has joined #ruby
<MrZYX>
But I'm pretty sure there's only one
<kraljev2>
yep, but it doesn't interfere with EM
saskuach has joined #ruby
Spami has joined #ruby
<|jemc|>
Thread.exclusive { some_code }
<|jemc|>
will ensure that no threads interrupt some_code
Lewix has quit [Remote host closed the connection]
saskuach has quit [Client Quit]
blackmesa has quit [Ping timeout: 240 seconds]
<kraljev2>
And what about if I have a board game, 4 people present
<kraljev2>
and just people in front of the same board cannot run calls in parallel?
Lewix has joined #ruby
<kraljev2>
poeple from different boards should.
saskuach has joined #ruby
<MrZYX>
do you need to save the call?
fgo has quit [Remote host closed the connection]
rcosta has joined #ruby
<|jemc|>
a board-local mutex is what I would probably use
oliver_ has quit [Read error: Connection reset by peer]
sambao21 has quit [Quit: Computer has gone to sleep.]
Lewix has quit [Remote host closed the connection]
oliver_ has joined #ruby
Lewix has joined #ruby
aryaching has joined #ruby
<|jemc|>
just remember that if your mutex'd code calls itself at any point, you should be using a reentrant lock instead
mrsolo has joined #ruby
<|jemc|>
Monitor instead of Mutex
cj3kim has quit [Ping timeout: 256 seconds]
saskuach has quit [Remote host closed the connection]
saskuach has joined #ruby
<kraljev2>
but if i don't use EM specific functions for let's say network calls
<kraljev2>
then EM won't paralelize the calls anyway?
<kraljev2>
because all calls are blocking?
Advocation has quit [Quit: Advocation]
Lewix has quit [Remote host closed the connection]
Ripp__ has joined #ruby
<|jemc|>
well, I can't say because I don't use EM. sorry to butt in
byprdct has quit [Ping timeout: 240 seconds]
<kraljev2>
I wouldn't either, If faye websocket wouldn't force me
saskuach has quit [Remote host closed the connection]
axl_ has joined #ruby
aryaching has quit [Read error: Connection reset by peer]
<|jemc|>
I'm working on a different async library at the moment
aryaching has joined #ruby
<kraljev2>
cool :)
<|jemc|>
but of no use to you in this conversation, unfortunately
<|jemc|>
like I said, sorry to butt in where my knowledge isn't directly relevant
devoldmx3 has joined #ruby
schaerli has quit [Ping timeout: 264 seconds]
kreantos has joined #ruby
saskuach has joined #ruby
endash has joined #ruby
Lewix has joined #ruby
adeponte has joined #ruby
cj3kim has joined #ruby
Breadcrumbs has joined #ruby
devoldmx has quit [Ping timeout: 264 seconds]
Lewix has quit [Remote host closed the connection]
Lewix has joined #ruby
Macaveli has joined #ruby
Lewix has quit [Remote host closed the connection]
brianpWins has quit [Quit: brianpWins]
rcosta_ has joined #ruby
jefflyne3 has joined #ruby
adeponte has quit [Ping timeout: 260 seconds]
platzhirsch has left #ruby [#ruby]
apeiros has joined #ruby
Xeago has quit [Read error: Connection reset by peer]
Xeago has joined #ruby
vlad_starkov has joined #ruby
rcosta has quit [Ping timeout: 259 seconds]
Xeago has quit [Read error: Connection reset by peer]
Xeago has joined #ruby
<AntelopeSalad>
how would i go about asserting that a meta title's content attribute is not empty?
Xeago_ has joined #ruby
Xeago has quit [Read error: Connection reset by peer]
nowthatsamatt has quit [Quit: nowthatsamatt]
EIA has joined #ruby
Macaveli has quit [Quit: Computer has gone to sleep.]
Yakko has quit [Remote host closed the connection]
Trudko_ has joined #ruby
<Trudko_>
guys is this good way how to deal with nil values when using select over array ? @players.select { |player| if player.team.nil? then false else player.rebricky_team.id == team.to_i end }
kaspergrubbe has quit [Remote host closed the connection]
<pontiki>
one of my favourite kinds of food :) yummm
mstrbutlertron has joined #ruby
zorg24 has joined #ruby
azcodex has joined #ruby
ferdev has quit [Quit: ferdev]
EIAC has quit [Remote host closed the connection]
Lewix has joined #ruby
tesuji has quit [Remote host closed the connection]
EIAC has joined #ruby
ehc has quit [Quit: ehc]
tesuji has joined #ruby
sambao21 has quit [Quit: Computer has gone to sleep.]
<shevy>
r0bglees0n where are you now?
rcosta has quit [Remote host closed the connection]
EIAC has quit [Remote host closed the connection]
wallerdev has quit [Quit: wallerdev]
Nisstyre-laptop has joined #ruby
matchaw has quit [Remote host closed the connection]
azcodex has quit [Quit: azcodex]
Nisstyre-laptop is now known as nisstyre
azcodex has joined #ruby
kraljev2 has left #ruby [#ruby]
sayan has joined #ruby
intuxicated has quit [Quit: Leaving]
JumpMast3r has joined #ruby
<banisterfiend>
shevy he's a fellow european
noop has joined #ruby
dodosan has joined #ruby
kaspergr_ has quit [Ping timeout: 256 seconds]
kaspergrubbe has joined #ruby
<platzhirsch>
Europe does not have an identify :P
noopq has quit [Ping timeout: 260 seconds]
rcosta has joined #ruby
kpshek has joined #ruby
EIAC has joined #ruby
matchaw has joined #ruby
<banisterfiend>
platzhirsch no, they're all just silly and backwards and speak dying languages
<banisterfiend>
(i live there too :P)
dodosan has quit [Ping timeout: 246 seconds]
<platzhirsch>
Well, identifying as a European citizen for instance as opposed to identifying with the own country ^^
dankest has joined #ruby
nomenkun has quit [Read error: Connection reset by peer]
EIAC has quit [Remote host closed the connection]
Catbuntu has quit [Read error: Connection reset by peer]
nomenkun has joined #ruby
<shevy>
platzhirsch right because it does not make much sense or difference
<waxjar>
i only identify myself as european towards americans, really.
<shevy>
either one belongs to (xyz) nation, or one is a world citizen
<platzhirsch>
Although I feel like feeling very comfortable when traveling between EU countries and just need to show my identifcation and not my passport
EIAC has joined #ruby
decoponyo has joined #ruby
Dave has joined #ruby
dangerousdave has quit [Read error: Connection reset by peer]
Advocation has joined #ruby
rcosta has quit [Ping timeout: 264 seconds]
Dave is now known as Guest17668
<waxjar>
ive been mistaken for a german too many times. apparantly a lot of people think that's what dutch means :P
decoponio has quit [Ping timeout: 260 seconds]
<waxjar>
or they think i said i live in "neverland" and am just joking :/
colonolGron has joined #ruby
<banisterfiend>
waxjar which city are you from in netherlands?
<waxjar>
leiden
Clooth has quit [Quit: Leaving...]
<banisterfiend>
waxjar haha, me too
<banisterfiend>
waxjar i live opposite the law school around steenschuur
quoin has joined #ruby
nomenkun has quit [Ping timeout: 264 seconds]
<banisterfiend>
waxjar i know another rubyist/pryist who lives just down hooigracht by the albert heijn
<waxjar>
haha, awesome
<banisterfiend>
waxjar do u go to einsteins?
<banisterfiend>
(the pub)
EIAC has quit [Remote host closed the connection]
<waxjar>
rarely, someone i know tended bar there though
<platzhirsch>
Leiden? Does it also mean suffering in Dutch?
cina has joined #ruby
<waxjar>
i usually go to bad habits, at the end of the haarlemmerstraat
<waxjar>
yes, it does platzhirsch. it also means "to lead"
<gr33n7007h>
pontiki, Thanks looks very interesting gonna have a browse
EIAC has joined #ruby
<Banistergalaxy>
Waxjar never heard of that, bar or club?
<gr33n7007h>
jeez i didn't even know there were that many
<waxjar>
it's a sports café originally i believe, looks like an english pub from the inside.
goshakkk has joined #ruby
randomdrake has quit [Quit: randomdrake]
havenwood has joined #ruby
Mephisto4 has quit [Ping timeout: 240 seconds]
<Banistergalaxy>
Waxjar near the kebab place?
<waxjar>
haha, yeah.
allsystemsarego has quit [Quit: Leaving]
<waxjar>
i think there are three gyros places and a kebab place within 20 mtrs
<Banistergalaxy>
Are you Dutch or another expat?
<waxjar>
i'm dutch
<Banistergalaxy>
Meneeer
<Banistergalaxy>
Funny language ;)
<platzhirsch>
hungry...
<waxjar>
haha, it must sound pretty wacky for non-native speakers
DanKnox_away is now known as DanKnox
browndawg has left #ruby [#ruby]
<banisterfiend>
waxjar it's pretty throaty
jefflyne3 has joined #ruby
<platzhirsch>
Why are there two banisters?
cina has quit [Quit: leaving]
<apeiros>
meiosis
<waxjar>
hehe. have you heard people from the hague speak banisterfiend?
Al_ has joined #ruby
jamesaanderson has quit [Ping timeout: 256 seconds]
<apeiros>
or was it mitosis?
<banisterfiend>
waxjar yes, but i honestly can't tell the difference :)
<waxjar>
haha, oh well. they're even throatier!
TheFuzzball has quit [Read error: Connection reset by peer]
<banisterfiend>
waxjar weird, they're only 15 mins away by train :)
RDash[AW] is now known as RDash
<banisterfiend>
waxjar hague is nasty, only reason i go there is to get KFC :D
<waxjar>
lol
<banisterfiend>
there's no kfc in leiden, right?
<waxjar>
nope :(
agent_white has joined #ruby
jamesaanderson has joined #ruby
snovak has joined #ruby
<banisterfiend>
waxjar i do love leiden though, very pretty city
<waxjar>
opposite the kfc is a place that sells really nice french fries, but belgian style. bram ladache it's called i think. i used to get my chicken at kfc and fries at bram ladache
dangerousdave has joined #ruby
<waxjar>
yea, it's like a miniature, less-crazy amsterdam
haxrbyte has joined #ruby
mary5030 has quit [Remote host closed the connection]
<banisterfiend>
waxjar which is your favourite 'coffeeshop' in leiden? :)
snovak has quit [Read error: Operation timed out]
<waxjar>
bebop
TheFuzzball has joined #ruby
<waxjar>
never really tried others out tbh
<banisterfiend>
me too :)
Al_ has quit [Quit: Al_]
<banisterfiend>
the one further down the same street bebop is on, is weird
voodoofish has joined #ruby
<waxjar>
haha, yeah
<banisterfiend>
i mean down that narrow alley there's another one
platzhirsch has left #ruby [#ruby]
platzhirsch has joined #ruby
<waxjar>
leidse plein
Emmanuel_Chanel has quit [Ping timeout: 240 seconds]
<banisterfiend>
ah
<banisterfiend>
scary place
<waxjar>
you can play chess there though, that's kinda nice
<platzhirsch>
Sorry to interrupt, but why are there two Ruby channels? #ruby and #ruby-lang ?
Al_ has joined #ruby
haxrbyte has quit [Remote host closed the connection]
haxrbyte has joined #ruby
<shevy>
platzhirsch historic reasons
<platzhirsch>
shevy: that sounds like: "Well boy, you know, back then 2005 when there was the civil war..."
<shevy>
yes
<shevy>
back in 2000 or so
Al_ has quit [Client Quit]
dgfdgf has quit []
<shevy>
I think the original owner of #ruby disappeared for a long while
starfox21 has quit [Quit: starfox21]
`MArceLL` has joined #ruby
<platzhirsch>
shevy: in #ruby-lang someone told me it's the official one and the more cooler ;)
robustus has quit [Ping timeout: 245 seconds]
cody-- has joined #ruby
schaerli has quit [Remote host closed the connection]
<banisterfiend>
#ruby-lang can be more of a bore
<banisterfiend>
#ruby is a little more relaxed and the people less full of themselves
colonolGron has quit [Ping timeout: 246 seconds]
<apeiros>
in the case of banisterfiend, they're usually full of something else :-p
kpshek has joined #ruby
<banisterfiend>
pizza
<apeiros>
does that come with weed too?
robustus has joined #ruby
<shevy>
platzhirsch yeah #ruby-lang is the "official" one, whatever that means. I think it only means that whoever has access to ruby homepage, wrote it that way... :P
<banisterfiend>
usually comes a few hours after :)
<platzhirsch>
shevy: well, I suggest we raid #ruby-lang
<shevy>
platzhirsch it's defended well by egospider and other villains
<platzhirsch>
villains, hah
<Morrolan>
shevy: The current owner of #ruby seems to have disappeared, too.
dagnachew has joined #ruby
<shevy>
Morrolan he is probably a pythonista now!
<shevy>
or, I think, he actually was here on #ruby a few months ago
<Morrolan>
Well, I'll be damned, he's on right now.
iliketurtles has joined #ruby
<platzhirsch>
Moving from Ruby to Python? I don't understand... I am starting to freeze
<Morrolan>
I remember /ns infoing him a few weeks ago, and the "last sign in" date was quite a bit ago. :)
rrichardsr3 has joined #ruby
<banisterfiend>
he's a perl programmer iirc
dv__ has joined #ruby
Emmanuel_Chanel has joined #ruby
dv_ has quit [Ping timeout: 264 seconds]
iliketur_ has joined #ruby
lfox has joined #ruby
Clooth has joined #ruby
iliketurtles has quit [Ping timeout: 264 seconds]
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
dagnachew has quit [Read error: Connection reset by peer]
dagnachew has joined #ruby
bricker`LA has joined #ruby
ehaliewicz has joined #ruby
corpuscle has quit [Quit: WeeChat 0.4.1]
<shevy>
platzhirsch well there are more folks using python out there
echevemaster has quit [Quit: Leaving]
lfox has quit [Quit: ZZZzzz…]
haxrbyte has quit [Read error: Connection reset by peer]
platzhirsch has quit [Ping timeout: 256 seconds]
ggordan has quit [Remote host closed the connection]
rcosta has joined #ruby
colonolGron has joined #ruby
kpshek has quit []
prometheanfire has quit [Ping timeout: 245 seconds]
Advocation has quit [Quit: Advocation]
matchaw has quit [Ping timeout: 264 seconds]
simoz has joined #ruby
matchaw has joined #ruby
prometheanfire has joined #ruby
prometheanfire is now known as Guest17973
echevemaster has joined #ruby
iliketur_ has quit [Quit: zzzzz…..]
jbpros has joined #ruby
<Xeago_>
does anyone have know of a weather api that is fairly decent?
iliketurtles has joined #ruby
ananthakumaran has quit [Quit: Leaving.]
matchaw has quit [Ping timeout: 240 seconds]
<r0bglees0n>
Xeago_: i heard the sky is a pretty good indicator
coderhs has quit [Ping timeout: 256 seconds]
quoin has joined #ruby
zerun0 has joined #ruby
schaerli has joined #ruby
matchaw has joined #ruby
platzhirsch has joined #ruby
Emmanuel_Chanel has quit [Ping timeout: 256 seconds]
<hanmac>
Xeago_: use your window ;D
dagnachew has quit [Read error: Connection reset by peer]
quoin has quit [Ping timeout: 263 seconds]
schaerli has quit [Ping timeout: 260 seconds]
sparq_ has joined #ruby
pwh has quit [Quit: pwh]
mansi has joined #ruby
Targen has joined #ruby
Lewix has quit [Remote host closed the connection]
noop has quit [Ping timeout: 256 seconds]
rippa has quit [Read error: Connection reset by peer]
tclark has joined #ruby
cj3kim has joined #ruby
nnmkut has joined #ruby
coderhs has joined #ruby
zeromodulus has joined #ruby
matchaw has quit [Ping timeout: 240 seconds]
matchaw has joined #ruby
oliver_ has quit [Remote host closed the connection]
havenwood has quit [Remote host closed the connection]
oliver_ has joined #ruby
nnmkut has quit [Remote host closed the connection]
d45h has quit [Ping timeout: 260 seconds]
joesavage has joined #ruby
ehc has joined #ruby
snovak has joined #ruby
optimusprimem has joined #ruby
optimusprimem has joined #ruby
<joesavage>
I've been looking through some of the Ruby Time documentation, but I can't seem to find a way to get the time into today in milliseconds.. any advice? (e.g. at 9am, it should be 9 hours = 32400000ms)
mansi has quit [Remote host closed the connection]
matchaw has quit [Ping timeout: 264 seconds]
mansi has joined #ruby
matchaw has joined #ruby
machuga|away is now known as machuga
chairabanta|away has quit [Quit: Leaving...]
dash_ has joined #ruby
snovak has quit [Ping timeout: 240 seconds]
Emmanuel_Chanel has joined #ruby
Scorchin has joined #ruby
mansi has quit [Ping timeout: 246 seconds]
fixnum has quit [Quit: Leaving]
cj3kim has quit [Remote host closed the connection]
skaflem has quit [Quit: Leaving]
ntus1017 has quit [Remote host closed the connection]
ars23 has joined #ruby
RDash is now known as RDash[AW]
ars23 has quit [Client Quit]
optimusprimem has quit [Quit: Saindo]
ars23 has joined #ruby
optimusprimem has joined #ruby
pjb1 has quit [Quit: pjb1]
cj3kim has joined #ruby
nisstyre has quit [Quit: Leaving]
cj3kim has quit [Remote host closed the connection]
<Kelet>
joesavage, I'm not sure if there's a method but of course you can do something like:
relix has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
funburn has joined #ruby
dangerousdave has quit [Read error: Operation timed out]
anshin has joined #ruby
TheMoonMaster has quit [Remote host closed the connection]
taternuts has joined #ruby
Xeago_ has quit [Read error: Connection reset by peer]
dhruvasagar has quit [Ping timeout: 264 seconds]
<shevy>
---
dassouki has joined #ruby
Xeago has joined #ruby
<atmosx>
what?
max_dev has joined #ruby
yekta has joined #ruby
<shevy>
hehe
<shevy>
I am bored :(
ssvo has joined #ruby
anshin has quit [Quit: leaving]
anshin has joined #ruby
DanKnox is now known as DanKnox_away
anshin has left #ruby [#ruby]
FDj has quit [Read error: No route to host]
simoz has joined #ruby
brunoro has quit [Ping timeout: 260 seconds]
sambao21 has joined #ruby
dassouki has quit [Ping timeout: 264 seconds]
<volty>
what is the right design pattern for graphs ?
BillCriswell has joined #ruby
tclark has quit [Remote host closed the connection]
freerobby has joined #ruby
FDj has joined #ruby
quoin has joined #ruby
ssvo has quit [Ping timeout: 256 seconds]
DanKnox_away is now known as DanKnox
yekta has quit [Quit: yekta]
zachrab has quit [Remote host closed the connection]
<atmosx>
shevy: what do youdo know? study?
Xaitec has quit [Remote host closed the connection]
<shevy>
atmosx dunno... I delegated to become a jack of all trades right now ... but mostly in the overall sense I am still focused on biological information of any kind
quoin has quit [Ping timeout: 240 seconds]
<atmosx>
so you're studying?
<shevy>
atmosx yeah in a way
sayd_ has quit [Quit: Goodbye]
<shevy>
atmosx right now I am trying to rush through all sorts of exams in different universities
sayd has joined #ruby
jamesaanderson has joined #ruby
TDJACR has joined #ruby
<shevy>
atmosx the current hat I am wearing is an ECTS whore :P but I also try to do useful stuff... like try to improve BioRuby (I find it so hard to use... I dunno...)
eka has quit [Quit: Computer has gone to sleep.]
<atmosx>
I see
<atmosx>
nice
kilophoton has quit [Ping timeout: 264 seconds]
lmwood has quit [Read error: Connection reset by peer]
mercwithamouth has joined #ruby
sambao21 has quit [Ping timeout: 260 seconds]
simoz has quit [Ping timeout: 260 seconds]
thesheff17 has quit [Quit: Leaving]
joesavage has quit [Quit: joesavage]
cody-- has joined #ruby
gimpygoo has joined #ruby
patrikf has left #ruby [#ruby]
Xeago has quit [Remote host closed the connection]
cads has quit [Ping timeout: 264 seconds]
quoin has joined #ruby
emergion has joined #ruby
tesuji has quit [Remote host closed the connection]
snovak has joined #ruby
predator217 has joined #ruby
<shevy>
atmosx it is almost as if there is a lack of scientific projects in ruby
predator117 has quit [Read error: Operation timed out]
<shevy>
I am guilty of that as well... I hate rdoc layout
sayd has left #ruby ["WeeChat 0.4.1"]
<|jemc|>
layout or color scheme?
bluenemo_ has joined #ruby
bluenemo_ has quit [Changing host]
bluenemo_ has joined #ruby
snovak has quit [Ping timeout: 256 seconds]
<|jemc|>
I don't mind the layout, but vomit green and gray on white is not my idea of easy on the eyes. silly darkfish
<volty>
you can change the colors
<shevy>
|jemc| you need to write in a specific layout, the comments... header tags
bluenemo has quit [Ping timeout: 264 seconds]
cody-- has quit [Quit: derp]
aryaching has quit [Ping timeout: 256 seconds]
jonahR has quit [Quit: jonahR]
<|jemc|>
ah, yes that too
<|jemc|>
one thing I miss from python is docstrings
<apeiros>
|jemc|: just use pry. it provides a way to access the docs and source of methods/classes
<|jemc|>
well, I usually use ri
bluenemo_ has quit [Read error: Connection reset by peer]
<|jemc|>
but that's good to know
<apeiros>
I assumed your problem was that you had to switch between irb & ri
<apeiros>
(or whatever other tool you could have used to access the docs)
mansi has joined #ruby
<|jemc|>
well, I guess it's more about the aesthetic in the source file
<|jemc|>
the docstrings appeal to me a little more I suppose
<apeiros>
oh well, then I just disagree :D
<apeiros>
I find docstrings ugly beyond reason
<|jemc|>
ha
<apeiros>
also having them inside the method collides with code comments
devoldmx has joined #ruby
<volty>
yes, they are awful
jamesaanderson has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
MrZYX is now known as MrZYX|off
<|jemc|>
well, obviously I don't miss them enough to go back to python
funburn has quit [Quit: funburn]
iliketurtles has quit [Quit: zzzzz…..]
<apeiros>
what I do miss in ruby is that doc comments end up in the parse tree and that code is generally available as objects from ruby itself
devoldmx3 has quit [Ping timeout: 240 seconds]
jamesaanderson has joined #ruby
mansi has quit [Ping timeout: 256 seconds]
<apeiros>
I'd be fine if it only does that with a flag present
<volty>
would be nice to have an editor that hides/shows the rdoc stuff
<apeiros>
would be nice to have an editor like eiffel uses - switch between single method, docs only, code only
<shevy>
hehehe
jamesaanderson has quit [Client Quit]
<apeiros>
I wonder whether one could amend sublime to do that
<shevy>
someone likes eiffel ;)
iliketurtles has joined #ruby
iliketurtles has quit [Max SendQ exceeded]
<|jemc|>
is there a way to have barebones docs in the source code, but have a more detailed, verbose file that has detailed doc comments, which get 'interleaved' by rdoc?
iliketurtles has joined #ruby
<|jemc|>
I suppose maybe you could just open up the classes and modules again?
<|jemc|>
hm
<apeiros>
that might work.
<|jemc|>
but that wouldn't work for methods, because you'd overwrite them
<|jemc|>
and it may not even work for objects
<apeiros>
well, don't put it in lib
jamesaanderson has joined #ruby
jamesaanderson has quit [Client Quit]
<apeiros>
rdoc doesn't care whether it's actually requirable or not
<|jemc|>
hm
<|jemc|>
sounds worth playing with
<apeiros>
just don't forget to tell rdoc where to look ;-)