<UserInNeed_>
I'm holding the PickAxe in my hand right now
<UserInNeed_>
I was just assuming that there was a way to do it with celluloid
FooMunki has quit [Ping timeout: 240 seconds]
<UserInNeed_>
i guess not
Gnut has quit [Ping timeout: 240 seconds]
<rietta>
A lot of stuff is not threadsafe. I have no direct experience with Celluoid myself. And classic MRI still has the global thread lock to the best of my knowledge.
ocbtec has quit [Quit: leaving]
<UserInNeed_>
ok, i'll try just using mri threads
<UserInNeed_>
Celluloid uses real threads thugh, so if one thread deadlocks, then the rest don't freeze
<rietta>
Hope that works. I still don’t know how to write a test for a multi-threaded race condition like there is with the uniqueness validation in some Rails apps.
marr has quit [Ping timeout: 240 seconds]
<rietta>
It’s nearly impossible to coax the Ruby process to run concurrently.
<rietta>
Because of the GIL
finisherr has quit [Quit: finisherr]
aupadhye has joined #ruby
ysz has quit [Quit: This computer has gone to sleep]
<UserInNeed_>
gil?
<havenwood>
rietta: The GVL actually releases the lock for IO.
<toretore>
UserInNeed_: as usual with concurrency, you'll have to figure out how to define your problem more precisely before you can have a solution for it
<rietta>
The global interpreter lock - Python and Ruby both use the pattern as do other interpreted languages
<toretore>
UserInNeed_: "async puts" sounds like you want some sort of async sink where you write log or other data
<toretore>
which is then queued to be written
baweaver has joined #ruby
intrigueD has quit [Remote host closed the connection]
DLSteve has joined #ruby
<UserInNeed_>
no, i want to diplay irc messages while still being able to type
<UserInNeed_>
i'm writing an irc client
<toretore>
same thing
<toretore>
this is why you must identify the primitives to actually get a good solution
<UserInNeed_>
another question
<UserInNeed_>
how can i use curses to get a typing thing to display at the botton of the secreen
<UserInNeed_>
text input box*
<havenwood>
UserInNeed_: Just for the heck of it here's a little Celluloid::IO example you could play with, for what it's worth: require 'celluloid/io'; class MostlyIdle; include Celluloid::IO; def puts *stuff; super *stuff end end; mostly_idle = MostlyIdle.new; mostly_idle.async.puts "the 'why' is a little harder"
chadhs has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<hfp>
havenwood: Indeed, I didn't think about checking the page. Never happened to me before, I was confused... I updated my bundle and it's fine now.
rcvalle has quit [Quit: rcvalle]
chadhs has joined #ruby
<havenwood>
hfp: yeah, yanking causes chaos - hence the RubyGems folk aren't fond o fit
aupadhye has quit [Ping timeout: 252 seconds]
<havenwood>
There was a gem... and it
<havenwood>
it's gone.
DmitryBochkarev has joined #ruby
DonOtreply has quit [Quit: DonOtreply]
<UserInNeed_>
here's what i have right now: loop do { while s.gets.chomp { puts; } s.puts gets.chomp; }
<UserInNeed_>
doesn't the thing gets stored in $_ ?
symm- has quit [Ping timeout: 264 seconds]
s00pcan_ has quit [Ping timeout: 245 seconds]
exadeci has joined #ruby
<UserInNeed_>
also, why is ruby so perlish
<UserInNeed_>
like
<UserInNeed_>
$_ is weird
<eam>
if only ruby had an implicit loop iterator
mondok has quit [Ping timeout: 240 seconds]
graphettion has joined #ruby
<ropeney>
UserInNeed_: Because they make 1 liners in the terminal quick and easy to write, using them in your program is your choice
<UserInNeed_>
ok
<UserInNeed_>
but, like, can you just say
<UserInNeed_>
puts while gets for a simple cat program?
<eam>
UserInNeed_: s.each_line { |l| puts l }
chadhs has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Mojo_Nixon has joined #ruby
karmatr0n has quit [Read error: No route to host]
karmatr0n has joined #ruby
chadhs has joined #ruby
chadhs has quit [Client Quit]
chadhs has joined #ruby
aupadhye has joined #ruby
chadhs has quit [Client Quit]
mfb2 has quit [Remote host closed the connection]
chadhs has joined #ruby
chadhs has quit [Client Quit]
dopamean_ has joined #ruby
dcunit3d has quit [Ping timeout: 264 seconds]
newbie has quit [Ping timeout: 245 seconds]
<UserInNeed_>
loop do
<UserInNeed_>
while s.gets.chomp
<UserInNeed_>
puts
<UserInNeed_>
end
<UserInNeed_>
s.puts gets.chomp
<UserInNeed_>
end
jtdowney_ is now known as jtdowney
jtdowney has quit [Changing host]
jtdowney has joined #ruby
DrCode has joined #ruby
andrew has joined #ruby
despai has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
andrew_ has joined #ruby
<Mon_Ouie>
puts $_ while gets
azure32 has quit [Ping timeout: 276 seconds]
<UserInNeed_>
ok
<Mon_Ouie>
$_ is not an implicit argument in Ruby
andrew has quit [Ping timeout: 252 seconds]
TomPeed has joined #ruby
shadoi has quit [Quit: Leaving.]
mfb2 has joined #ruby
tvw has quit [Ping timeout: 245 seconds]
KnownSyntax has quit [Ping timeout: 240 seconds]
paultreny has quit [Quit: ¯\_(ツ)_/¯]
techietrash has quit [Quit: Bye! <(^_^<)]
houhoulis has joined #ruby
techietrash has joined #ruby
KnownSyntax has joined #ruby
paultreny has joined #ruby
paultreny is now known as Guest7350
KnownSyntax has quit [Remote host closed the connection]
stannard has quit [Remote host closed the connection]
askhat has quit [Read error: Connection reset by peer]
bratchley has quit [Remote host closed the connection]
askhat has joined #ruby
KnownSyntax has joined #ruby
feudality has quit [Ping timeout: 245 seconds]
Jonah11_ has joined #ruby
KnownSyntax has quit [Changing host]
KnownSyntax has joined #ruby
andrew_ has quit [Remote host closed the connection]
djbkd has quit [Remote host closed the connection]
lessless has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
karmatr0n has quit [Ping timeout: 252 seconds]
andrew has joined #ruby
davedev24 has quit [Remote host closed the connection]
griffindy has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
karmatr0n has joined #ruby
Lucky_ABA has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
benlieb has joined #ruby
hawkweed has joined #ruby
zacstewart has joined #ruby
malconis has joined #ruby
chadhs has joined #ruby
sneakerhax has quit [Quit: Leaving]
hawkweed has quit [Ping timeout: 240 seconds]
Jardayn has quit [Quit: Leaving]
DmitryBochkarev has quit [Quit: This computer has gone to sleep]
cornfeedhobo has joined #ruby
<cornfeedhobo>
is it not possible to remove something from rubygems.com?
<cornfeedhobo>
is it possible to remove something from rubygems.com?** i don't see any options for it ...
zeroDivisible has quit [Quit: WeeChat 1.3]
mikecmpbll has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
LoneHerm_ has quit [Remote host closed the connection]
slackR has quit [Ping timeout: 240 seconds]
slackR has joined #ruby
sonne has quit [Ping timeout: 240 seconds]
freerobby has quit [Quit: Leaving.]
skweek has quit [Ping timeout: 245 seconds]
janno has quit [Ping timeout: 240 seconds]
banister has quit [Ping timeout: 240 seconds]
janno has joined #ruby
mib_mib has joined #ruby
<mib_mib>
hi - rails question - How would i see the 'generated sql' for a query that is a 'count', i.e. MyModel.where(some: 'thing').to_sql works, but not MyModel.where(some: 'thing').count.to_sql doesnt (since its evaluuated)
<mib_mib>
if anyone knows the 'arel' library...
howdoi has joined #ruby
sonne has joined #ruby
sankaber has joined #ruby
<na_g>
mib_mib: you will probably have better luck asking in #RubyOnRails
lessless has joined #ruby
elifoster has quit [Ping timeout: 260 seconds]
rbennacer has quit [Remote host closed the connection]
bahar has quit [Changing host]
bahar has joined #ruby
arescorpio has joined #ruby
code2Learn has joined #ruby
psy_ has joined #ruby
kknight has quit [Read error: Connection reset by peer]
baweaver has joined #ruby
mib_mib has quit [Ping timeout: 252 seconds]
DmitryBochkarev has joined #ruby
ensyde has joined #ruby
baweaver has quit [Ping timeout: 240 seconds]
djbkd has joined #ruby
code2Learn has quit [Remote host closed the connection]
sociologic has quit [Ping timeout: 240 seconds]
coyo has joined #ruby
cornfeedhobo has left #ruby ["when i leave, come together like butt cheeks"]
wald0 has joined #ruby
nodejunkie has joined #ruby
ESpiney has quit [Ping timeout: 245 seconds]
speakingcode has joined #ruby
IrishGringo has quit [Ping timeout: 240 seconds]
speakingcode has joined #ruby
kp666 has quit [Remote host closed the connection]
celly has quit [Remote host closed the connection]
stardiviner has joined #ruby
UtkarshRay has quit [Remote host closed the connection]
bronson_ has quit [Remote host closed the connection]
benlieb has joined #ruby
Bloomer has joined #ruby
kies^ has quit [Ping timeout: 240 seconds]
claw has quit [Ping timeout: 272 seconds]
SOLDIERz has joined #ruby
Xeago has joined #ruby
<flughafen>
morning
<Radar>
good morning flughafen
<flughafen>
good morning Radar
norc has quit [Ping timeout: 252 seconds]
fedexo_ has joined #ruby
<flughafen>
how are you guys/gals doing
yoongkang has joined #ruby
fedexo__ has joined #ruby
solars has joined #ruby
TomyLobo has joined #ruby
fedexo has quit [Ping timeout: 260 seconds]
claw has joined #ruby
<Radar>
Doing well :) Reviewing the chapters of Multitenancy with Rails currently. At the end of Chapter 3 and looking to add more content to it to cover some things that I missed.
<flughafen>
awesome
greg has quit [Ping timeout: 250 seconds]
houhoulis has quit [Remote host closed the connection]
yoongkang has quit [Ping timeout: 250 seconds]
kknight has joined #ruby
lurch_ has joined #ruby
scepticulous has joined #ruby
celly has joined #ruby
atmosx has joined #ruby
themsay has joined #ruby
JohnBat26 has joined #ruby
DonOtreply has joined #ruby
oncall-pokemon has quit [Quit: Connection closed for inactivity]
themsay2 has quit [Ping timeout: 245 seconds]
lxsameer has joined #ruby
LoneHerm_ has joined #ruby
JohnBat26 has quit [Client Quit]
x77686d has quit [Quit: x77686d]
bahar has quit [Ping timeout: 256 seconds]
celly has quit [Ping timeout: 248 seconds]
DonOtreply has quit [Client Quit]
infra-red has joined #ruby
plonk has quit [Remote host closed the connection]
JohnBat26 has joined #ruby
moeabdol1 has joined #ruby
remyg has quit [Ping timeout: 252 seconds]
kknight has left #ruby ["Leaving"]
stannard has joined #ruby
moeabdol has quit [Ping timeout: 245 seconds]
remyg has joined #ruby
konsolebox has joined #ruby
sandstrom has quit [Quit: My computer has gone to sleep.]
plonk has joined #ruby
plonk has joined #ruby
stannard has quit [Ping timeout: 240 seconds]
ur5us has joined #ruby
johnzorn has quit [Ping timeout: 250 seconds]
Ishido has joined #ruby
aryaching has quit [Read error: Connection reset by peer]
plonk has quit [Client Quit]
kknight has joined #ruby
TomyLobo has quit [Ping timeout: 264 seconds]
zacstewart has joined #ruby
konsolebox has quit [Ping timeout: 240 seconds]
konsolebox has joined #ruby
konsolebox has quit [Client Quit]
mondok has joined #ruby
weemsledeux has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Bugboy1028 has quit [Ping timeout: 250 seconds]
azure32 has quit [Ping timeout: 245 seconds]
bougyman has quit [Ping timeout: 240 seconds]
azure32 has joined #ruby
Cyrus has quit [Ping timeout: 256 seconds]
zacstewart has quit [Ping timeout: 250 seconds]
bougyman has joined #ruby
triangles2 has quit [Read error: Connection reset by peer]
firstdayonthejob has joined #ruby
erbse has left #ruby [#ruby]
the_drow has quit [Quit: This computer has gone to sleep]
palaeophile has quit [Ping timeout: 240 seconds]
vdamewood has joined #ruby
Bugboy1028 has joined #ruby
<shevy>
ready for take-off flughafen?
DoubleMalt has joined #ruby
dseitz has quit [Remote host closed the connection]
<flughafen>
ask Radar if he sees anything
<Radar>
I am back in Australia (in Brisbane currently). I won't see anything.
LoneHerm_ has quit [Remote host closed the connection]
Dragooon has joined #ruby
duncannz has joined #ruby
LoneHermit has joined #ruby
chouhoul_ has quit [Remote host closed the connection]
BTRE has quit [Quit: Leaving]
ferr has quit [Ping timeout: 240 seconds]
aganov has joined #ruby
dseitz has joined #ruby
BTRE has joined #ruby
Burgestrand has joined #ruby
karapetyan has joined #ruby
Burgestrand has quit [Client Quit]
azure32 has quit [Ping timeout: 240 seconds]
ta has joined #ruby
sandstrom has joined #ruby
azure32 has joined #ruby
last_staff has quit [Quit: last_staff]
pawnbox has quit [Remote host closed the connection]
bronson_ has joined #ruby
Xeago has quit [Remote host closed the connection]
parallelogrammat has joined #ruby
codecop has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
baweaver has quit [Remote host closed the connection]
bronson_ has quit [Ping timeout: 256 seconds]
askhat has joined #ruby
dionysus69 has joined #ruby
Xeago has joined #ruby
Mon_Ouie has quit [Ping timeout: 252 seconds]
diegoviola has joined #ruby
askhat has quit [Client Quit]
sandstrom has joined #ruby
Cyrus has joined #ruby
fedexo__ has quit [Ping timeout: 240 seconds]
Cyrus is now known as Guest98055
fedexo_ has quit [Ping timeout: 260 seconds]
william3 has joined #ruby
SCHAAP137 has joined #ruby
karapetyan has quit [Remote host closed the connection]
aufi has joined #ruby
remyg has quit [Ping timeout: 252 seconds]
Silox| has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
william3 has quit [Ping timeout: 245 seconds]
mondok has quit [Ping timeout: 256 seconds]
Xeago has quit [Remote host closed the connection]
yoongkang has joined #ruby
sandstrom has joined #ruby
jxs_ has joined #ruby
TomyWork has joined #ruby
parallelogrammat has quit [Ping timeout: 240 seconds]
alexherbo2 has joined #ruby
Spami has joined #ruby
seitensei has joined #ruby
karapetyan has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
seitensei has quit [Ping timeout: 272 seconds]
sandstrom has joined #ruby
sepp2k has joined #ruby
solocshaw has quit [Ping timeout: 245 seconds]
tvw has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
Ruby_Rocks_007 has quit [Quit: Ruby_Rocks_007]
darkxploit has quit [Ping timeout: 256 seconds]
supralocal has joined #ruby
kenndel has joined #ruby
devbug_ has joined #ruby
zacstewart has joined #ruby
sandstrom has joined #ruby
devbug has quit [Ping timeout: 240 seconds]
RegulationD has joined #ruby
coyo has quit []
pranny has joined #ruby
zacstewart has quit [Ping timeout: 250 seconds]
mlehrer has joined #ruby
mlehrer_ has joined #ruby
firstdayonthejob has quit [Ping timeout: 240 seconds]
supralocal has quit [Ping timeout: 240 seconds]
Xeago has joined #ruby
supergeek has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
RegulationD has quit [Ping timeout: 256 seconds]
the_drow has joined #ruby
bahar has joined #ruby
devbug_ has quit [Read error: Connection reset by peer]
supergeek has quit [Client Quit]
mark4 has joined #ruby
darkxploit has joined #ruby
sandstrom has joined #ruby
chouhoulis has joined #ruby
Xeago has quit [Ping timeout: 245 seconds]
nunchuck has quit [Ping timeout: 245 seconds]
atmosx has quit [Quit: Lost in trance]
diegoviola has quit [Quit: WeeChat 1.4]
pawnbox has joined #ruby
einarj has joined #ruby
chouhoulis has quit [Ping timeout: 250 seconds]
mauricio has joined #ruby
sandstrom has quit [Ping timeout: 260 seconds]
mdw has joined #ruby
sandstrom has joined #ruby
lipoqil has joined #ruby
ur5us has quit [Remote host closed the connection]
ferr has joined #ruby
Sembei has quit [Quit: WeeChat 1.5-dev]
benlieb has quit [Quit: benlieb]
baweaver has joined #ruby
arlek has joined #ruby
<EdwardIII>
hmm i'm currently deciding whether to build my app multitenancy or just deploy a different instance for each client
sandstrom has quit [Read error: Connection reset by peer]
<EdwardIII>
probably won't exceed around 10 clients so i'm guessing it's probably not worth the extra complexity
phatypus has joined #ruby
ready2 has quit [Ping timeout: 245 seconds]
pawnbox_ has joined #ruby
pandaant has joined #ruby
pawnbox has quit [Ping timeout: 245 seconds]
baweaver has quit [Ping timeout: 260 seconds]
sandstrom has joined #ruby
ur5us has joined #ruby
<adaedra>
Hello
karapetyan has quit [Remote host closed the connection]
patrist has joined #ruby
karapetyan has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
lubekpl has joined #ruby
sandstrom has joined #ruby
<lipoqil>
adaedra: It's you?
azure32 has quit [Ping timeout: 264 seconds]
sandstrom has quit [Read error: Connection reset by peer]
lubekpl_ has joined #ruby
lubekpl_ has quit [Client Quit]
celly has joined #ruby
sftrabbit has joined #ruby
sandstrom has joined #ruby
ready2 has joined #ruby
lubekpl has quit [Quit: WeeChat 1.3]
lubekpl has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
celly has quit [Ping timeout: 260 seconds]
binaryplease has joined #ruby
blaxter has joined #ruby
benlieb has joined #ruby
<adaedra>
?
UtkarshRay has quit [Remote host closed the connection]
anisha has joined #ruby
pawnbox_ has quit [Ping timeout: 240 seconds]
atmosx has joined #ruby
sftrabbit has left #ruby [#ruby]
william3 has joined #ruby
sandstrom has joined #ruby
moeabdol1 has quit [Ping timeout: 240 seconds]
moeabdol2 has joined #ruby
karapetyan has quit [Remote host closed the connection]
KnownSyntax has quit [Ping timeout: 240 seconds]
srenatus has joined #ruby
pranny has quit [Remote host closed the connection]
<EdwardIII>
Radar: have you made many mult-tenancy apps in the past?
anisha has quit [Quit: Leaving]
pandaant has quit [Remote host closed the connection]
zacstewart has quit [Ping timeout: 264 seconds]
poguez_ has quit [Quit: Connection closed for inactivity]
pandaant has joined #ruby
karapetyan has joined #ruby
Gnut has joined #ruby
anisha has joined #ruby
quaristice has joined #ruby
quaristice has quit [Client Quit]
floror has quit [Quit: floror]
karapetyan has quit [Ping timeout: 250 seconds]
chouhoulis has joined #ruby
sandstrom has joined #ruby
tvw has quit [Read error: Connection reset by peer]
benlieb has quit [Quit: benlieb]
dionysus69 has quit [Ping timeout: 250 seconds]
Cohedrin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
wethu has joined #ruby
blaxter has joined #ruby
chouhoulis has quit [Ping timeout: 252 seconds]
duncannz has quit [Remote host closed the connection]
rdark has joined #ruby
rdark has quit [Client Quit]
rdark has joined #ruby
spex has joined #ruby
spex is now known as urtokk
Abrin has quit [Ping timeout: 264 seconds]
dlitvak has joined #ruby
moeabdol2 has quit [Ping timeout: 240 seconds]
sandstrom has quit [Read error: Connection reset by peer]
pawnbox has joined #ruby
william3 has quit [Remote host closed the connection]
dlitvak has quit [Ping timeout: 245 seconds]
norc has joined #ruby
<norc>
>> p a if a = 1
<ruby[bot]>
norc: # => /tmp/execpad-bb7fbfccfb81/source-bb7fbfccfb81:2: warning: found = in conditional, should be == ...check link for more (https://eval.in/515549)
<norc>
Why does this require parens around the conditional?
<apeiros>
hm? it does not?
themsay has quit [Quit: AtomicIRC: The nuclear option.]
iMessage has joined #ruby
<apeiros>
it warns you that you have an assignment, which likely should be a comparison
<apeiros>
oh, interesting, it's not just a warning
<apeiros>
I think I see now what you meant. weird.
toretore has quit [Ping timeout: 264 seconds]
blackmesa has joined #ruby
<norc>
Oh I should know better.
<apeiros>
but a paren doesn't help, a remains undefined.
<apeiros>
this is odd.
pranny has quit [Remote host closed the connection]
<paul98>
ddv: this is ubuntu and i did the apt-get install ruby-full as well
joonty has joined #ruby
<ddv>
paul98: you need to do sudo apt-get install build-essential
<norc>
apeiros: No the parens do help
<norc>
That is the bizarre thing.
<norc>
>> p a if (a = 1)
<ruby[bot]>
norc: # => /tmp/execpad-25efcc80ceb5/source-25efcc80ceb5:2: warning: found = in conditional, should be == ...check link for more (https://eval.in/515554)
Domaldel has joined #ruby
<norc>
But I think I know where to look
anisha has quit [Quit: Leaving]
urtokk has quit [Quit: WeeChat 1.4]
<norc>
apeiros: Ok this is really strange. On my pry shell that actually works.
<apeiros>
norc: in what way did it help?
s00pcan has quit [Ping timeout: 248 seconds]
<apeiros>
norc: on the second line? :)
urtokk has joined #ruby
<norc>
Oh.
krobzaur has quit [Ping timeout: 240 seconds]
evidex has joined #ruby
<apeiros>
I run it with ruby -e because of that
<norc>
apeiros: No it makes perfect sense now.
<apeiros>
not to me :-/ I mean I can understand how it probably happens, but that doesn't fit with how it should work IMO
<norc>
It is this monstrous lvar cache hack in the parser.
<norc>
Im willing to bet that this will work fine on jruby
kknight has quit [Quit: Leaving]
yardenbar has joined #ruby
<apeiros>
i.e. IMO that behavior is a bug
<norc>
Not sure whether its even fixable considering how the lvar cache works and that we have a LR parser.
chipotle_ has quit [Quit: cheerio]
pranny has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
Mon_Ouie has joined #ruby
FooMunki has joined #ruby
LoneHermit has quit [Remote host closed the connection]
<apeiros>
dunno. in my language I read the full lexical scope before executing. lvars are stored in an array. the name association is stored elsewhere and only for eval and a local_variable_get equivalent
karapetyan has joined #ruby
moeabdol has joined #ruby
<apeiros>
i.e. a code block has full knowledge of all lvars in it before it starts to execute
patrist has quit [Ping timeout: 250 seconds]
<apeiros>
it's probably not the fastest way to work with it, but faster than referring to them by name
<norc>
apeiros: The issue is how Ruby implements shadowing lvars with conflicting method names.
<norc>
So the order in which things are found is rather important.
<apeiros>
ah true. you can all a method before an assignment in the same lexical scope.
<apeiros>
luckily I don't have that ambiguity
<apeiros>
actually s/luckily/by design/
sandstrom has joined #ruby
<paul98>
ddv: cheers it still fails but i've other stuff to be worrying about will pick up on it later! thanks for the pointers
<norc>
def a; 1; end; puts a if a = 2
<norc>
apeiros: what would you expect this to return?
moeabdol1 has joined #ruby
<norc>
(Honest question)
paul98 has quit [Quit: leaving]
karapetyan has quit [Ping timeout: 240 seconds]
<apeiros>
with the current way ruby works, I'd expect it to print 2
<apeiros>
given that the `if a = 2` is necessarily executed before `puts a`
<norc>
Hehe, if lvar resolution and shadowing was done at execution stage in the VM that would certainly be possible.
ElFerna has joined #ruby
moeabdol has quit [Ping timeout: 250 seconds]
<norc>
But that would probably change lexical scope semantics wrt blocks/procs, no?
<apeiros>
it can be done when the AST is built
seitensei has joined #ruby
Zai00 has joined #ruby
mdw has quit [Quit: Sleeping Zzzzz]
<apeiros>
personally I'd favor if the existence of an lvar would always shadow, even before assignment
<apeiros>
that'd probably be unexpected at first, but make things much more clear than the current way where an unexecuted branch can shadow a method
LoneHerm_ has joined #ruby
Zai00 has quit [Client Quit]
<apeiros>
(see `ruby -e 'def a; 1; end; if false then a = 2; end; puts a'`)
shredding has joined #ruby
Silox| has quit [Quit: Connection closed for inactivity]
marr has joined #ruby
ur5us has quit [Remote host closed the connection]
rsc___ has joined #ruby
seitensei has quit [Ping timeout: 256 seconds]
stardiviner has joined #ruby
turner_ has joined #ruby
<norc>
apeiros: If you resolve var/method at runtime, it would necessitate lvar either always or never shadowing.
<norc>
I think.
sandstrom has quit [Read error: Connection reset by peer]
<EdwardIII>
hrm where do i know apeiros from
PedramT has joined #ruby
aryaching has joined #ruby
adgtl has quit [Read error: Connection reset by peer]
tvw has joined #ruby
adgtl has joined #ruby
pawnbox_ has joined #ruby
ponga has joined #ruby
PedramT has quit [Ping timeout: 248 seconds]
<norc>
apeiros: The more I think about it though, the modifier_ keywords are just rather silly for exactly this reason.
Zai00 has joined #ruby
pawnbox has quit [Ping timeout: 240 seconds]
aryaching has quit [Ping timeout: 260 seconds]
turner_ has quit [Ping timeout: 245 seconds]
<norc>
Hah. I just looked at parse.y more closely and found some interesting things
<norc>
Mon_Ouie: Interesting, I followed this down the rabbit whole and made some interesting discoveries how and when the catch entries for catch/retry come into existence.
dlitvak has joined #ruby
roshanavand has joined #ruby
chouhoulis has quit [Ping timeout: 256 seconds]
kibogol has joined #ruby
existensil has quit [Ping timeout: 245 seconds]
<kibogol>
How does one install gems to the system /usr/local directory heirarchy?
tesuji has joined #ruby
bronson_ has joined #ruby
iMessage has quit [Ping timeout: 252 seconds]
<Mon_Ouie>
By default, gem installs to GEM_HOME; you can pass an install directory with -i.
existensil has joined #ruby
baweaver has joined #ruby
dlitvak has quit [Ping timeout: 252 seconds]
ferr has joined #ruby
dlitvak has joined #ruby
bronson_ has quit [Ping timeout: 256 seconds]
krzkrz has quit [Ping timeout: 248 seconds]
PedramT has joined #ruby
Gnut has quit [Ping timeout: 248 seconds]
vondruch_ has joined #ruby
vondruch has quit [Ping timeout: 250 seconds]
blackmesa has quit [Ping timeout: 272 seconds]
baweaver has quit [Ping timeout: 250 seconds]
Mon_Ouie has quit [Ping timeout: 272 seconds]
PedramT has quit [Ping timeout: 250 seconds]
ocbtec has joined #ruby
dlitvak_ has joined #ruby
greg has quit [Quit: Leaving]
s00pcan has joined #ruby
dlitvak has quit [Ping timeout: 240 seconds]
kerunaru has joined #ruby
mdw has quit [Quit: Sleeping Zzzzz]
kerunaru has quit [Client Quit]
PedramT has joined #ruby
pranny has quit [Remote host closed the connection]
saneax_AFK is now known as saneax
TheWhip has quit [Remote host closed the connection]
pranny has joined #ruby
celly has joined #ruby
dextertzu has joined #ruby
karapetyan has joined #ruby
PedramT has quit [Ping timeout: 250 seconds]
xapak has joined #ruby
s00pcan_ has joined #ruby
celly has quit [Ping timeout: 240 seconds]
DoubleMalt has quit [Remote host closed the connection]
Mon_Ouie has joined #ruby
karapetyan has quit [Ping timeout: 260 seconds]
PedramT has joined #ruby
peitera has quit [Quit: acy]
mikecmpbll has joined #ruby
stannard has joined #ruby
peitera has joined #ruby
joonty has quit [Ping timeout: 260 seconds]
symm- has joined #ruby
PedramT has quit [Ping timeout: 240 seconds]
y2mq37 has joined #ruby
turner_ has joined #ruby
krzkrz has joined #ruby
stannard has quit [Ping timeout: 240 seconds]
<apeiros>
norc: with current ruby: no. I'd want it to work, though (and in my language it would)
<xapak>
apeiros, what do you suggest? A variable, add results there, and simply set the variable to the end?
<xapak>
Hmm... let me check that.
<apeiros>
>> [1,2,3].map { |e| "now it is relevant #{e}" }
<ruby[bot]>
apeiros: # => ["now it is relevant 1", "now it is relevant 2", "now it is relevant 3"] (https://eval.in/515655)
<apeiros>
each is for side-effects. map is for return value.
TheWhip has quit [Remote host closed the connection]
aryaching has quit [Ping timeout: 252 seconds]
bweston92 has quit [Remote host closed the connection]
PedramT has quit [Ping timeout: 250 seconds]
aryaching_ has joined #ruby
Skelz0r has quit [Ping timeout: 256 seconds]
<xapak>
In my own gist, if I change it to maps, I get the “puts” behaviour of duplicated results. If I run the Dir.glob outside, it works as intended.
TheWhip has joined #ruby
<kibogol>
setting environment variable GEM_HOME did not function as claimed. It put the executables under ~/.gem in spite of that.
<xapak>
apeiros, do you see perhaps why?
<apeiros>
xapak: update the gist
rsc___ has joined #ruby
lxsameer has quit [Quit: Leaving]
<sts>
hello folks. When I develop some code on a machine, where the same class is installed system wide, how can I exclude the system wide path for running it from my home directory?
<apeiros>
xapak: also, pretty please use .rb as filesuffix.
Kruppe has quit [Ping timeout: 256 seconds]
chipotle has joined #ruby
<apeiros>
sts: $LOAD_PATH governs how base require works. Dont' remember which variable controls gem's require, though.
lxsameer has joined #ruby
CloCkWeRX has quit [Quit: Leaving.]
zacstewart has joined #ruby
<sts>
apeiros: can i remove a path from LOAD_PATH?
<unsymbol>
EdwardIII: not sure i understand the question, could you say a little more about what you're trying to do?
rkoller has joined #ruby
<EdwardIII>
unsymbol: getting a big fat bunch of params that i need to add a few things to, then pass on to an api
<EdwardIII>
if i use **opts i don't get the validation that all params are present and correct (which i want)
sandstrom has quit [Read error: Connection reset by peer]
Zai00 has joined #ruby
danielpk has joined #ruby
yoongkang has quit [Remote host closed the connection]
trinaldi has joined #ruby
aryaching has quit [Read error: Connection reset by peer]
<apeiros>
EdwardIII: it'd be ugly and you'd still have to either use something like binding_of_caller or pass in the method name + binding
<EdwardIII>
ok then
<apeiros>
method(__method__).params gets you the info, and Binding#local_variable_get the data
<kibogol>
Bingo, --user-install is in /etc/gemrc ! Was in...
saneax is now known as saneax_AFK
<apeiros>
I think I've even written such an abomination once. just to test how ugly it'd be :)
<EdwardIII>
hehe maybe i should just pass it on
<EdwardIII>
ultimately it's going to a soap api, i think savon or the endpoint will complain if something it expects is missing
pranny has quit [Remote host closed the connection]
dlitvak_ has quit [Read error: Connection reset by peer]
dlitvak has joined #ruby
<apeiros>
if you have a sane xsd, it should
pranny has joined #ruby
<apeiros>
personally I'm a fan of early failure instead of delayed. but sometimes that's just not worth the effort.
TomyWork has quit [Remote host closed the connection]
blackmesa has joined #ruby
aryaching has joined #ruby
<shevy>
fail early, fail often
<shevy>
- PHP !!!
xapak has left #ruby [#ruby]
pranny has quit [Remote host closed the connection]
pihpah has joined #ruby
<pihpah>
I got this following error while running berks init . Unable to activate berkshelf-api-client-2.0.0, because httpclient-2.7.1 conflicts with httpclient (~> 2.6.0)
Shaboum has joined #ruby
<pihpah>
gem list tells I have two version of httpclient installed
<pihpah>
httpclient (2.7.1, 2.6.0.1)
<apeiros>
sounds like something required httpclient without specifying a version, which activated the newest
<shevy>
yeah it dislikes 2.7.1
<apeiros>
and then something else tried to activate a specific version (~ 2.6.0) which failed because 2.7.1 was already required (activation happens with a gem before the actual require, require does it automatically)
<apeiros>
shevy: stop making me look like I'd like php! :<
<pihpah>
berks init . is he exact command I ryun
<pihpah>
the*
<shevy>
I just thought fit it would fit to php :D
blackmesa has quit [Ping timeout: 264 seconds]
ElFerna has quit [Ping timeout: 276 seconds]
<pihpah>
apeiros: so, what should I do?
<shevy>
pihpah are you able to use only one httpclient version?
<apeiros>
file a bugreport with berks?
<apeiros>
uninstall 2.7.1?
sandstrom has joined #ruby
<apeiros>
run it with a Gemfile? I don't know.
eGGsha has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<pihpah>
apeiros: uninstall is the solution I guess
<apeiros>
install a newer version of berks?
sandstrom has quit [Read error: Connection reset by peer]
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
skakri has joined #ruby
stevemackinnon has quit [Remote host closed the connection]
aryaching has quit [Read error: Connection reset by peer]
turner_ has quit [Ping timeout: 272 seconds]
jottr has joined #ruby
<apeiros>
seems I've not gisted that params code. wouldn't be surprised, iirc it was ugly as hell :D
geoffyoungs has joined #ruby
aryaching has joined #ruby
sgambino has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
TheWhip has quit []
sandstrom has joined #ruby
<gregf_>
i just tried what apeiros said and it does work ;)
<gregf_>
shevy: that is such ugly code. PHP code can be written so much much more better :/
<shevy>
gregf_ :D
<EdwardIII>
shevy: other than this code being disgusting, why did you bring it up though heh? because of 'fail early, fail often'?
Azure has quit [Ping timeout: 240 seconds]
Azure|dc has joined #ruby
<shevy>
EdwardIII just compare bioperl and biopython to biophp
aryaching_ has quit [Ping timeout: 264 seconds]
aryaching has joined #ruby
<shevy>
then build a castle out of sand
<ddv>
you can make shit in every language
mottel has joined #ruby
<EdwardIII>
it'd be nice for there to be a conclusive answer to this so we didn't always have to discuss it heh
dlitvak_ has joined #ruby
<EdwardIII>
some metric that shows PHP is not as good as the alternatives
krzkrz has joined #ruby
<shevy>
we can use inferior languages to build awesome things
<EdwardIII>
in code complete mcconnell has a table that says if you use vb your project will take longer
<EdwardIII>
(iirc)
mfb2 has quit [Ping timeout: 240 seconds]
IrishGringo has joined #ruby
stannard has quit [Ping timeout: 245 seconds]
<shevy>
there are always some absolute numbers, like amount of code versus amount of features, ease of readability, maintainability, how much the language itself supports, how big its ecosystem is
<mottel>
I am creating stats for a ticket support system and I am a bit confused. I want to show the number of the tickets that are open and the waiting time for the customer was more than 24 hours. Then the tickets that have a waiting time more than 48 hours and then for 72 hours. I feel that what I did is wrong. Could you please check this (https://gist.github.com/anonymous/b029a6e87571fca3a5b8)
vondruch_ has quit [Ping timeout: 252 seconds]
dlitvak_ has quit [Remote host closed the connection]
dlitvak_ has joined #ruby
linduxed has joined #ruby
karapetyan has joined #ruby
dlitvak has quit [Read error: Connection reset by peer]
ferr has quit [Ping timeout: 250 seconds]
<ddv>
mottel: #RubyOnRails, also use scopes, don't do that in your view and maybe replace erb with something better like haml or slim
wethu has quit [Quit: This computer has gone to sleep]
RegulationD has joined #ruby
zacstewart has joined #ruby
adgtl has quit [Remote host closed the connection]
pawnbox has quit [Remote host closed the connection]
<mottel>
ddv: Thank you for your help. As I am learning, why should I not be using erb? are there any pitfalls or do others offer more features?
vondruch has joined #ruby
<EdwardIII>
i just started using erb, new to rails
<ddv>
mottel: lets discuss this in #RubyOnRails
millerti has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sts has left #ruby [#ruby]
bahar has quit [Changing host]
bahar has joined #ruby
aryaching has quit [Ping timeout: 245 seconds]
RegulationD has quit [Ping timeout: 250 seconds]
zacstewart has quit [Ping timeout: 245 seconds]
NoIdea__ has joined #ruby
<NoIdea__>
Hey.
Azure|dc is now known as Azure
<NoIdea__>
I'm beginning in Ruby (but I do not need help :D), I'm just here to ask you, is that needed or better too learn C to work (I'm still a student)?
dlitvak has joined #ruby
dlitvak_ has quit [Ping timeout: 248 seconds]
dionysus69 has joined #ruby
ohaibbq has joined #ruby
rodfersou has joined #ruby
chouhoulis has joined #ruby
aryaching has joined #ruby
linduxed has quit [Ping timeout: 256 seconds]
stardiviner has quit [Ping timeout: 256 seconds]
sandstrom has joined #ruby
nfk has joined #ruby
pawnbox has joined #ruby
sgambino has joined #ruby
NoIdea__ has quit [Quit: Page closed]
lipochromogen has joined #ruby
mottel has left #ruby [#ruby]
blackmesa has quit [Ping timeout: 240 seconds]
william3 has quit [Remote host closed the connection]
roshanavand has quit [Remote host closed the connection]
linduxed has joined #ruby
roshanavand has joined #ruby
gaspaio has joined #ruby
<gaspaio>
hey all. Newbie question: I have a huge variable declared in a ruby file. How do I load that variable info some other ruby file ?
IrishGringo has quit [Remote host closed the connection]
jxs_ has quit [Ping timeout: 245 seconds]
JDiPierro has joined #ruby
askhat has joined #ruby
<shevy>
gaspaio make it a constant
sandstrom has quit [Read error: Connection reset by peer]
zacstewart has joined #ruby
arup_r has joined #ruby
<arup_r>
If I do `rvm list known` .. it is not showing the 2.3. What should i do ?
lipochromogen has quit [Ping timeout: 240 seconds]
<EdwardIII>
ah neat, found one on hashtie
<gaspaio>
shevy: thanks a lot, that works.
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<shevy>
\o/
askhat has quit [Read error: Connection reset by peer]
askhat has joined #ruby
jxs_ has joined #ruby
jxs_ has quit [Max SendQ exceeded]
jxs_ has joined #ruby
zacstewart has quit [Ping timeout: 272 seconds]
<arup_r>
nvm, i got it ..
chouhoulis has joined #ruby
millerti has joined #ruby
sandstrom has joined #ruby
sankaber has joined #ruby
pawnbox_ has joined #ruby
pawnbox has quit [Ping timeout: 245 seconds]
<shevy>
hmmm what are the advantages of having the toplevel namespace a class or a module? Reason I ask is... I have a class right now as a toplevel namespace in one project while 98% of my other projects use a module toplevel ... so now I am tempted to turn that class into a module, but I can not remember why I picked a class back then.... (some years ago)
sleaved has joined #ruby
chouhoulis has quit [Ping timeout: 245 seconds]
stannard has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
<havenwood>
shevy: Are you creating instances of the Class?
stannard has quit [Ping timeout: 245 seconds]
<havenwood>
shevy: That's what classes are for!
rbennacer has quit [Remote host closed the connection]
blackmesa has joined #ruby
<shevy>
havenwood I don't know!
<shevy>
but yeah
<shevy>
I think so
<shevy>
but then I lose the possibility to include it! :(
ElFerna has joined #ruby
f3ttX] has joined #ruby
bluOxigen has joined #ruby
arup_r has left #ruby [#ruby]
yoongkang has quit [Remote host closed the connection]
pdoherty has quit [Ping timeout: 250 seconds]
bluOxigen_ has quit [Ping timeout: 250 seconds]
blackmesa has quit [Ping timeout: 250 seconds]
gbert has joined #ruby
cdg has joined #ruby
skweek has quit [Ping timeout: 248 seconds]
chipotle has quit [Quit: cheerio]
sandstrom has joined #ruby
failshell has joined #ruby
bruce_lee has joined #ruby
bruce_lee has quit [Changing host]
bruce_lee has joined #ruby
UtkarshRay has joined #ruby
pihpah has joined #ruby
treehug88 has joined #ruby
<pihpah>
`berks install` issues Could not parse `/home/pihpah/github/cookbooks/metadata.rb': undefined method `source' for #<Ridley::Chef::Cookbook::Metadata:0x000000028d37c0>
dcunit3d has quit [Ping timeout: 240 seconds]
<pihpah>
why
PedramT has joined #ruby
PedramT has quit [Remote host closed the connection]
PedramT has joined #ruby
danielpk has quit [Quit: danielpk]
sandstrom has quit [Read error: Connection reset by peer]
mostlybadfly has quit [Quit: Connection closed for inactivity]
<havenwood>
solars: crontab -l
<havenwood>
pihpah: You might try the #berkshelf channel if you haven't already.
roshanav_ has joined #ruby
roshanavand has quit [Read error: Connection reset by peer]
tjohnson has joined #ruby
chouhoulis has joined #ruby
darkf has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
astrobunny has quit [Read error: Connection timed out]
astrobunny has joined #ruby
loz has joined #ruby
<pihpah>
I'll give a shot but serisouly, wtf. My day is ruined. It's kind of one installs git, then spends the whole day trying to figure out why `git init .` command does not work. Did that command ever fail you? You doubt that.
<pihpah>
Seems like the Ruby community is driven by half-assed programmers.
rdar has quit [Quit: Leaving]
<solars>
havenwood, I meant in ruby, of course :) but found it already, thanks
<yorickpeterse>
pihpah: because one library is a representation of an entire community right?
<havenwood>
pihpah: I don't know what you're going on about. Go gripe to Chef or Berkshelf.
chouhoulis has quit [Ping timeout: 248 seconds]
<havenwood>
pihpah: PS - `git init .` has nothing to do with Ruby.
<DefV>
Linus is kind of a half-assed programmer :-/
blandflakes has joined #ruby
sleaved has quit [Ping timeout: 260 seconds]
<platzhirsch>
philtr: sorry to hear you have to work with Chef
rbennacer has quit [Remote host closed the connection]
TomPeed has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sandstrom has joined #ruby
baweaver has joined #ruby
momomomomo has joined #ruby
<ddv>
so we have another clueless sysadmin who doesn't know how to program but has to use orchestration tools that in reality do require programming experience
rbennacer has joined #ruby
subsimious has joined #ruby
<platzhirsch>
hah
TomPeed has joined #ruby
momomomomo has quit [Client Quit]
<shevy>
pihpah some projects are good, others are not so good. it is better to use the good projects and ignore the bad ones
blackmesa has joined #ruby
Channel6 has quit [Quit: Leaving]
DoubleMalt has quit [Ping timeout: 264 seconds]
Burgestrand has joined #ruby
<platzhirsch>
what the snake said
Burgestrand has quit [Client Quit]
<apeiros>
pihpah: you're frustrated, I understand that. but throwing stuff like "Seems like the Ruby community is driven by half-assed programmers." is neither productive nor otherwise a good idea, especially in a channel of the ruby community.
ElFerna has quit [Ping timeout: 245 seconds]
<apeiros>
(leaving the whole "single datapoint extrapolation" stupidity aside)
<shevy>
"Install redis (on OSX with homebrew use) brew install redis"
evidex has joined #ruby
<shevy>
that's a quite OSX centric installation guide right? does gem not work on OSX or why not generalize this via "gem install redis"?
<apeiros>
yupp, that's osx centric.
<apeiros>
it's an external dependency
<havenwood>
shevy: They're trying to show installing the Redis package.
<yorickpeterse>
shevy: They're probably referring to the Redis server, not the Gem
<apeiros>
the gem won't work anywhere else either if you don't have redis installed.
<apeiros>
and as yorickpeterse says, redis ain't a gem :)
karapetyan has quit [Remote host closed the connection]
sandstrom has quit [Read error: Connection reset by peer]
blackmesa has quit [Ping timeout: 245 seconds]
karapetyan has joined #ruby
yoongkang has quit [Ping timeout: 240 seconds]
dopamean_ has quit [Ping timeout: 260 seconds]
<dajobat>
Just out of interest, what's the general consensus with respect to brackets around conditionals in if statements?
<dajobat>
Should they always be there/ only be there if there are multiple conditions/ never be there?
<apeiros>
dajobat: preferably never
<apeiros>
having to put some there is IMO an indicator that you should probably break a large conditions apart.
diegoviola has joined #ruby
greg has quit [Quit: Leaving]
lxsameer has quit [Quit: Leaving]
x77686d has joined #ruby
aganov has quit [Remote host closed the connection]
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
B1n4r10 has joined #ruby
solars has quit [Ping timeout: 248 seconds]
sdothum has joined #ruby
karapetyan has quit [Ping timeout: 240 seconds]
sankaber has quit [Remote host closed the connection]
sankaber has joined #ruby
DoubleMalt has joined #ruby
<dajobat>
cool, seems reasonable
<dajobat>
apeiros: Cheers.
PedramT has quit []
arthropododo has joined #ruby
karapetyan has joined #ruby
ta has quit [Remote host closed the connection]
ohaibbq has joined #ruby
konsolebox has joined #ruby
mondok has joined #ruby
pdoherty has joined #ruby
<EdwardIII>
hrm i'm using savon which uses gyoku, it says you can pass in convert_request_keys_to: :camelcase, but it doesn't seem to do anything
<EdwardIII>
trying to diagnose it now but it's a little tricky heh
sandstrom has joined #ruby
Conflict has quit [Read error: Connection reset by peer]
Conflict has joined #ruby
sgambino has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Sucks has joined #ruby
despai has joined #ruby
despai has quit [Client Quit]
IrishGringo has quit [Ping timeout: 252 seconds]
jgt4 has joined #ruby
danielpk has joined #ruby
Ishido has quit [Remote host closed the connection]
vbatts|work has left #ruby ["found the other side of the rainbow"]
danielpk has quit [Client Quit]
howdoi has quit [Quit: Connection closed for inactivity]
s2013 has joined #ruby
Ishido has joined #ruby
sandstrom has quit [Read error: Connection reset by peer]
sandstrom has joined #ruby
freerobby has quit [Quit: Leaving.]
sandstrom has quit [Read error: Connection reset by peer]
davedev24 has joined #ruby
freerobby has joined #ruby
minimalism has quit [Quit: minimalism]
aufi has joined #ruby
infra-red has quit [Remote host closed the connection]
colli5ion has joined #ruby
SenpaiSilver has joined #ruby
damonkelley has joined #ruby
SenpaiSilver has quit [Max SendQ exceeded]
minimalism has joined #ruby
SenpaiSilver has joined #ruby
idefine has joined #ruby
DmitryBochkarev has joined #ruby
chipotle has joined #ruby
duckpuppy has quit [Ping timeout: 245 seconds]
troulouliou_div2 has quit [Remote host closed the connection]
askhat has quit [Read error: Connection reset by peer]
askhat has joined #ruby
mfb2 has joined #ruby
IrishGringo has joined #ruby
mfb2 has quit [Remote host closed the connection]
sgambino has joined #ruby
KnownSyntax has joined #ruby
LoneHermit has joined #ruby
dopamean_ has joined #ruby
kegster has joined #ruby
<EdwardIII>
hrm trying to step through the whole request cycle is taking a looong time with byebug, is there a way i can say 'just break if you hit anything in this file'? or even better, 'if the ruby filename matches glob *gyu*'?
seitensei has joined #ruby
<EdwardIII>
hrm i see i can break on class:method, i'll give that a spin
<shevy>
yorickpeterse ah I see
idefine has quit [Remote host closed the connection]
chouhoulis has joined #ruby
idefine has joined #ruby
haylon has joined #ruby
Rickmasta has joined #ruby
kies^ has joined #ruby
Pumukel has joined #ruby
the_drow has quit [Quit: This computer has gone to sleep]
eGGsha has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
codecop has quit [Remote host closed the connection]
eGGsha has joined #ruby
chouhoulis has quit [Ping timeout: 260 seconds]
idefine has quit [Remote host closed the connection]
floatingpoint has joined #ruby
kedare has quit [Quit: WeeChat 1.0.1]
lubekpl has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
kedare has joined #ruby
rbennacer has quit [Remote host closed the connection]
marxarelli has joined #ruby
idefine has joined #ruby
marxarelli is now known as Guest22587
Guest22587 has quit [Client Quit]
SenpaiSilver_ has joined #ruby
podman has joined #ruby
plonk has joined #ruby
plonk has joined #ruby
poguez_ has joined #ruby
SenpaiSilver_ has quit [Max SendQ exceeded]
marxarel_ has joined #ruby
idefine has quit [Remote host closed the connection]
SenpaiSilver_ has joined #ruby
cschneid_ has joined #ruby
bronson_ has joined #ruby
jas02 has quit [Quit: jas02]
SenpaiSilver has quit [Ping timeout: 276 seconds]
SenpaiSilver_ has quit [Max SendQ exceeded]
marxarel_ is now known as marxarelli
SenpaiSilver_ has joined #ruby
subsimious has quit [Ping timeout: 272 seconds]
ElFerna has joined #ruby
d10n-work has joined #ruby
karapetyan has quit [Remote host closed the connection]
diegoviola has quit [Quit: WeeChat 1.4]
griffindy has joined #ruby
LoneHermit has quit [Remote host closed the connection]
blackmesa has joined #ruby
Bloomer has quit []
bronson_ has quit [Ping timeout: 256 seconds]
TheHodge has quit [Quit: Connection closed for inactivity]
whippythellama has joined #ruby
aufi has quit [Ping timeout: 245 seconds]
decoponio has joined #ruby
baweaver has joined #ruby
Gnut has joined #ruby
urtokk has quit [Quit: WeeChat 1.4]
DoubleMalt has quit [Read error: Connection reset by peer]
DmitryBochkarev has quit [Quit: This computer has gone to sleep]
<EdwardIII>
do you guys actually use something like byebug for all your debugging? or do you hook it into vim, use an ide or whatever?
neohunter has joined #ruby
blackmesa has quit [Ping timeout: 256 seconds]
Smcdrc has joined #ruby
DmitryBochkarev has joined #ruby
<centrx>
EdwardIII, I don't use anything special for debugging
sgambino has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
adgtl has joined #ruby
ElFerna has quit [Ping timeout: 256 seconds]
RegulationD has joined #ruby
baweaver has quit [Remote host closed the connection]
sgambino has joined #ruby
<EdwardIII>
some good stuff in that article whether you use puts or a proper debugger
zast has joined #ruby
mark4 has quit [Quit: Leaving.]
<adaedra>
I personally use pry + pry-byebug
Spami has quit [Quit: Leaving]
sneakerhax has quit [Ping timeout: 245 seconds]
polishdub has joined #ruby
dopamean_ has quit [Quit: leaving]
glovemaking has joined #ruby
idefine has joined #ruby
LoneHerm_ has joined #ruby
rkazak has joined #ruby
scepticulous has quit [Ping timeout: 240 seconds]
astrobunny has quit [Read error: Connection reset by peer]
chipotle has quit [Quit: cheerio]
<EdwardIII>
i love actual debuggers
<EdwardIII>
like just then, once i figured out how to use byebug properly i could dip into the guts of savon and find that i just needed to ensure i used symbols for my keys or it wouldn't bother to camelise them
DoubleMalt has joined #ruby
rkazak has quit [Ping timeout: 240 seconds]
jackjackdripper has joined #ruby
finisherr has joined #ruby
<shevy>
EdwardIII I don't need much debugging for my own code, sometimes I make use of pp though
zacstewa_ has joined #ruby
SCHAAP137 has quit [Remote host closed the connection]
jackjackdripper has quit [Client Quit]
zacstewart has quit [Read error: Connection reset by peer]
last_staff1 has joined #ruby
LoneHerm_ has quit [Remote host closed the connection]
<Smcdrc>
I love awesomeprint gem. It is usually one of the first gems I install
Abrin has joined #ruby
ElFerna has joined #ruby
last_staff has quit [Ping timeout: 256 seconds]
last_staff1 is now known as last_staff
glovemaking has quit [Ping timeout: 272 seconds]
Guest7350 has quit [Changing host]
Guest7350 has joined #ruby
Guest7350 is now known as paultreny
evidex has quit [Remote host closed the connection]
TomyWork has quit [Ping timeout: 248 seconds]
ElFerna has quit [Read error: Connection reset by peer]
ElFerna has joined #ruby
askhat has quit [Read error: Connection reset by peer]
Mojo_Nixon has joined #ruby
askhat has joined #ruby
yos7ph has joined #ruby
Mojo_Nixon has quit [Client Quit]
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Ruby_Rocks_007 has joined #ruby
rsalazar has joined #ruby
Lucky_ABA has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
rsalazar has left #ruby [#ruby]
hamed_r has joined #ruby
JDiPierro has quit [Remote host closed the connection]
finisherr has quit [Quit: finisherr]
idefine has quit [Remote host closed the connection]
f4cl3y has joined #ruby
alexis has joined #ruby
huyderman has quit [Read error: Connection reset by peer]
<alexis>
Hi everyone.
<alexis>
I'm trying to install a specific gem and have issues with it, after some search I'm not more advanced, so I figured I would ask.
UtkarshRay has quit [Quit: Leaving]
<alexis>
When trying to install the gem named "curb", I have some failures.
<alexis>
I've been successful at installing the same gem as packaged for debian
<alexis>
I would need to find a way to link the gem that I installed with debian to my "bundle".
<alexis>
OR to fix the dependencies (I guess) in order for the gem to compile
<alexis>
Anyone got ideas about that?
<alexis>
Thanks for your time.
einarj has quit [Remote host closed the connection]
zacstewa_ has quit [Read error: Connection reset by peer]
zacstewart has joined #ruby
dmitch has joined #ruby
chouhoulis has joined #ruby
<shevy>
you can put what you tried into a pastie
<shevy>
(remote one)
TomyLobo has joined #ruby
<shevy>
Fetching: curb-0.9.1.gem (100%)
<shevy>
Building native extensions. This could take a while...
<shevy>
seems as if you must compile it so you may need some headers
chipotle has joined #ruby
<alexis>
yeah, I think I installed them.
<alexis>
here is the output of the "bundle install" command
<alexis>
Here I use the default versions provided with debian 8.
<alexis>
That is ruby 2.1.5p273 (2014-11-13)
tesuji has quit [Ping timeout: 240 seconds]
Pumukel has quit [Ping timeout: 260 seconds]
<alexis>
and libcurl4 7.38.0-4
msisk has joined #ruby
ElFerna has quit [Read error: Connection reset by peer]
william3 has quit [Remote host closed the connection]
<shevy>
yeah for some reason it does not want to continue to compile it for you
ElFerna has joined #ruby
<alexis>
Does anyone know a way to include an already installed gem to a bundle?
Lucky_ABA has joined #ruby
[Butch] has joined #ruby
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
yos7ph has quit [Quit: Leaving]
<chrisarcand>
alexis: 'Adding to a bundle' is just bundler adding it to its lock file. The gem can already be installed with whatever path you have set.
<chrisarcand>
ie if you installed the gem and add it to your bundle, you'll notice Bundler outputs 'Using 'the_gem' (version)' instead of Installing...
wtiger has joined #ruby
<wtiger>
Hi!
<wtiger>
what are some good os ruby projects for a beginner to contribute to?
william3 has joined #ruby
<wtiger>
*os = open source
rbennacer has joined #ruby
astrobunny has joined #ruby
<alexis>
chrisarcand: I installed it with apt, so I suppose it's not in the PATH bundle is looking for?
<alexis>
chrisarcand: how can I tell bundle to look at the correct location?
Bloomer has quit [Read error: No route to host]
SOLDIERz has quit [Ping timeout: 250 seconds]
Bloomer_ has joined #ruby
tomchapi_ has joined #ruby
amclain has joined #ruby
davedev2_ has joined #ruby
yardenbar has quit [Ping timeout: 276 seconds]
karapetyan has joined #ruby
davedev24 has quit [Ping timeout: 240 seconds]
william3 has quit [Ping timeout: 250 seconds]
tomcha___ has quit [Ping timeout: 250 seconds]
adgtl has quit [Remote host closed the connection]
yoongkang has joined #ruby
gaspaio has quit [Ping timeout: 272 seconds]
wtiger has quit [Quit: WeeChat 1.4]
<chrisarcand>
alexis: I'm not the most familiar with how bundler/rubygems pathing works, especially with ruby via apt, but you'll want to look at `gem environment`, `which ruby`, `which gem` etc and make sure all looks correct.
Pumukel has joined #ruby
mdw has quit [Quit: Sleeping Zzzzz]
gambl0re has joined #ruby
ensyde has joined #ruby
duckpuppy has joined #ruby
davedev24 has joined #ruby
Pumukel has quit [Client Quit]
desiccate has joined #ruby
hahuang61 has quit [Ping timeout: 240 seconds]
yoongkang has quit [Ping timeout: 248 seconds]
x77686d has quit [Quit: x77686d]
askhat_ has joined #ruby
ElFerna has quit [Ping timeout: 264 seconds]
karapetyan has quit [Ping timeout: 248 seconds]
krobzaur has quit [Quit: WeeChat 1.2]
davedev2_ has quit [Ping timeout: 252 seconds]
idefine has quit [Remote host closed the connection]
askhat_ has quit [Max SendQ exceeded]
idefine has joined #ruby
DmitryBochkarev has quit [Quit: This computer has gone to sleep]
askhat has quit [Ping timeout: 240 seconds]
idefine has quit [Remote host closed the connection]
askhat has joined #ruby
kedare has quit [Remote host closed the connection]
ensyde has quit [Ping timeout: 240 seconds]
JDiPierro has joined #ruby
azure32 has joined #ruby
rbennacer has quit [Remote host closed the connection]
DoubleMalt has quit [Remote host closed the connection]
joonty has quit [Ping timeout: 248 seconds]
ElFerna has joined #ruby
desiccate has quit [Ping timeout: 245 seconds]
kfpratt has joined #ruby
y2mq37 has quit [Ping timeout: 240 seconds]
crime has joined #ruby
<crime>
the zen of python is just jihadism, making everybody do something one specific way
arthropododo has quit [Remote host closed the connection]
JDiPierro has quit [Ping timeout: 240 seconds]
<azure32>
thats one way to put a very negative spin on something
<centrx>
python is murder
joonty has joined #ruby
desiccate has joined #ruby
<eam>
ideological cleansing
<crime>
I mean, jihadism isnt necessarily explicitly negative, depends on who's talking. I'm just saying that it's nice to do things your own way
<eam>
crime: you'd like perl
<crime>
If we were a bunch of jihadists, that'd be just swell
<azure32>
lol
<eam>
Coders Going Their Own Way
<crime>
perl is ok, I think perl-ers have already killed perl6 tho
<crime>
which is a shame
<azure32>
this is the first thing I see when I log on in the morning
<azure32>
XD
<crime>
good morning
<eam>
good morning everyone
<azure32>
good morning!
<crime>
i just dropped by to talk ruby and commit crimes
<crime>
ya know, the usu'
Bloomer_ has quit [Read error: Connection reset by peer]
<azure32>
typical day at the office, dontcha know
<EdwardIII>
i kinda like python's exception love
<EdwardIII>
makes it easier to avoid accidents
Bloomer has joined #ruby
<azure32>
^python has its uses
<eam>
I like that python is ref counted
gizmore has joined #ruby
<crime>
ya know, on the other side of the jihadist coin, there is potential for an argument that TIMTOWTDI is basically just hedonism, right? no moral baseline for implementation
<crime>
what language would a buddhist write? probably asm or C?
rbennacer has joined #ruby
<eam>
lisp
tvw has quit [Remote host closed the connection]
<eam>
purity of form
devbug has joined #ruby
<EdwardIII>
something with no state seems a bit more zen
<gizmore>
crime: intercal
tildes has joined #ruby
<azure32>
they want a higher state of being, not lower
<crime>
i love lisp but hate emacs
<crime>
yeah, no state for sure
tvw has joined #ruby
rakm has joined #ruby
genpaku_ is now known as genpaku
<crime>
i was sort of thinking erlang. let it crash resonates with personal mindfulness, right?
idefine_ has joined #ruby
msisk has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
idefine_ has quit [Remote host closed the connection]
genpaku is now known as genpaku_
mlehrer has quit [Quit: Leaving]
mlehrer_ has quit [Quit: Leaving]
adgtl has joined #ruby
genpaku_ is now known as genpaku
KensoDev has joined #ruby
dionysus69 has quit [Ping timeout: 260 seconds]
tomchapin has quit [Quit: Connection closed for inactivity]
joonty has quit [Ping timeout: 272 seconds]
tildes has quit [Ping timeout: 245 seconds]
david____ has joined #ruby
zacstewart has quit [Ping timeout: 248 seconds]
karapetyan has joined #ruby
nodejunkie has quit [Ping timeout: 252 seconds]
zacstewart has joined #ruby
sneakerhax has joined #ruby
diego2 has joined #ruby
elifoster has joined #ruby
kknight has joined #ruby
karapetyan has quit [Remote host closed the connection]
diego3 has joined #ruby
diego3 has quit [Changing host]
diego3 has joined #ruby
jxs_ has quit [Remote host closed the connection]
diegoviola has quit [Ping timeout: 240 seconds]
diego3 is now known as diegoviola
adgtl has quit [Remote host closed the connection]
colli5ion has quit []
f3ttX] has quit [Remote host closed the connection]
GinoManWorks has joined #ruby
last_staff has quit [Quit: last_staff]
diego2 has quit [Ping timeout: 240 seconds]
adgtl has joined #ruby
infra-red has joined #ruby
stannard_ has joined #ruby
jorrin has joined #ruby
stannard has quit [Ping timeout: 256 seconds]
ElFerna has quit [Ping timeout: 272 seconds]
pandaant has quit [Remote host closed the connection]
LoneHermit has joined #ruby
fedexo has joined #ruby
Smcdrc has quit []
fedexo_ has joined #ruby
PD028300 has joined #ruby
despai has joined #ruby
mdw has joined #ruby
haylon has quit [Ping timeout: 250 seconds]
mdw has quit [Client Quit]
ElFerna has joined #ruby
despai has quit [Client Quit]
LoneHermit has quit [Ping timeout: 240 seconds]
ohaibbq has quit [Remote host closed the connection]
baweaver has joined #ruby
chouhoulis has joined #ruby
JDiPierro has joined #ruby
lubekpl has joined #ruby
dmolina has quit [Ping timeout: 272 seconds]
Sucks has quit [Quit: No Ping reply in 180 seconds.]
zacstewa1t has joined #ruby
zacstewart has quit []
gisli has joined #ruby
gisli has left #ruby ["WeeChat 1.2"]
pdoherty has quit [Ping timeout: 260 seconds]
mauricio has quit [Remote host closed the connection]
Sucks has joined #ruby
fedexo has quit [Ping timeout: 250 seconds]
elifoster has quit [Ping timeout: 250 seconds]
selfadhesivefilm has joined #ruby
baweaver has quit [Ping timeout: 250 seconds]
fedexo_ has quit [Ping timeout: 260 seconds]
zacstewa1t is now known as zacstewart
chouhoulis has quit [Ping timeout: 276 seconds]
lubekpl has quit [Ping timeout: 272 seconds]
bb010g has quit [Quit: Connection closed for inactivity]
SCHAAP137 has joined #ruby
ElFerna has quit [Ping timeout: 264 seconds]
the_drow has joined #ruby
infra-re_ has joined #ruby
Xiti` has joined #ruby
flughafen_ has joined #ruby
tildes has joined #ruby
tw1sted_ is now known as tw1sted
tw1sted has quit [Changing host]
tw1sted has joined #ruby
mondok has quit [Ping timeout: 250 seconds]
frem has joined #ruby
infra-red has quit [Ping timeout: 260 seconds]
acidrainfall has joined #ruby
Eiam has quit [Quit: ╯°□°)╯︵ǝpouǝǝɹɟ]
askhat has quit [Remote host closed the connection]
Wolland has joined #ruby
askhat has joined #ruby
Xiti has quit [Ping timeout: 240 seconds]
baweaver has joined #ruby
<acidrainfall>
How can I check if a variable is empty?
<acidrainfall>
Anything I append to the array (.defined? .any? etc) complains about NilClass.
<acidrainfall>
I want to say "If you're going to complain about NilClass, just skip it."
<eam>
.nil?
<acidrainfall>
:/
<eam>
>> nil.nil?
<acidrainfall>
yay
<acidrainfall>
thanks.
<eam>
where's the bot :(
<acidrainfall>
I ate it.
<eam>
well drat
<acidrainfall>
ah perfect thank you so much
<acidrainfall>
I don't know why that was so hard to find, I was probably asking the wrong question
speakingcode has quit [Ping timeout: 264 seconds]
<crime>
.empty?
<crime>
oh a variable
<eam>
crime: .empty? will be true for [], but raise for nil
<crime>
yup
B1n4r10 has quit [Ping timeout: 240 seconds]
speakingcode has joined #ruby
<acidrainfall>
yeah I tried .empty.
<acidrainfall>
.nil is what I needed
<acidrainfall>
I'm defining arrays at the top and will offer a selection as part of this script, but my syntax checker complains that I have variables I'm not using anywhere else in the script.
dlitvak_ has quit [Remote host closed the connection]
jmdade has joined #ruby
<acidrainfall>
If there are 4 host groups and the selection only allows for one, there will always be 3 variables that exist with data but aren't used. That's not a problem is it?
<eam>
acidrainfall: nil is also false, so you can use it directly in a conditional
pihpah has quit [Ping timeout: 245 seconds]
<acidrainfall>
Oh really?
<acidrainfall>
I didn't know if that worked in ruby or not
Ilyes512 has joined #ruby
<eam>
if whatever; not_nil; else either_nil_or_false; end
dlitvak has joined #ruby
bluOxigen has quit [Ping timeout: 240 seconds]
evidex has joined #ruby
benlieb has joined #ruby
krobzaur has joined #ruby
bluOxigen has joined #ruby
fedexo has joined #ruby
fedexo_ has joined #ruby
Wolland has quit []
flughafen_ has quit [Ping timeout: 252 seconds]
mostlybadfly has joined #ruby
camillo has joined #ruby
dangeranger has joined #ruby
kies^ has quit [Ping timeout: 245 seconds]
stannard_ has quit [Ping timeout: 240 seconds]
dlitvak has quit [Ping timeout: 240 seconds]
Mon_Ouie has joined #ruby
kirillzh has joined #ruby
sol_ has quit [Ping timeout: 240 seconds]
camillo is now known as sol_
valera has quit [Ping timeout: 260 seconds]
hamed_r has quit [Quit: Leaving]
astrofog has joined #ruby
intrigueD has joined #ruby
bronson_ has joined #ruby
yqfvwal has joined #ruby
dfockler has joined #ruby
stannard has joined #ruby
idefine has joined #ruby
infra-red has joined #ruby
ohaibbq has joined #ruby
<yqfvwal>
Hi! Is there syntactic sugar to manipulate a variable, with a default value before being used?
Ruby_Rocks_007 has quit [Quit: Ruby_Rocks_007]
infra-red has quit [Remote host closed the connection]
<crime>
like var = var || 5?
infra-red has joined #ruby
<crime>
because that'd be var ||= 5
infra-re_ has quit [Ping timeout: 245 seconds]
fedexo_ has quit [Ping timeout: 240 seconds]
<alexis>
Thanks all. See ya
alexis has left #ruby ["WeeChat 1.0.1"]
fedexo has quit [Ping timeout: 250 seconds]
dmitch has joined #ruby
<yqfvwal>
crime, I want to set var to zero if not defined otherwise increment it by one
kknight has quit [Read error: Connection reset by peer]
<baweaver>
that sounds like a programming construct
<crime>
if var.nil? var=0; var+=1
<baweaver>
something conditional
Devalo has joined #ruby
idefine has quit [Remote host closed the connection]
<yqfvwal>
yes, I know, but I thought there was some other possibility than using conditionals, but thanks
floror has joined #ruby
arlek has joined #ruby
<crime>
but it IS a conditional, since you have a condition that you are checking for
Blaguvest has joined #ruby
<baweaver>
v = v ? v + 1 : 0
kirillzh has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<baweaver>
still an if branch though
<baweaver>
ternary, but semantics
william3 has joined #ruby
<yqfvwal>
baweaver, thanks, did not think about
kies^ has joined #ruby
hahuang61 has joined #ruby
<yqfvwal>
baweaver, ARGF.each { a = a ? a + 1 : 0 } does not work
<yqfvwal>
puts a, Name error
infra-red has quit [Ping timeout: 256 seconds]
<crime>
are they strings?
idefine has joined #ruby
<baweaver>
what's the actual error?
<baweaver>
because that each isn't going to work
<apeiros>
yqfvwal: you only set a inside the block
krobzaur has quit [Quit: WeeChat 1.2]
<apeiros>
it won't exist outside
kirillzh has joined #ruby
krobzaur has joined #ruby
<yqfvwal>
apeiros, ah ok, how do I make it global?
<baweaver>
that too
<apeiros>
also it'll be overridden on each iteration anyways
<baweaver>
never global
codecop has joined #ruby
adgtl has quit [Remote host closed the connection]
<yqfvwal>
hmm, ok, seems the best way to initialize a to zero before using each on argf
<crime>
map!
<baweaver>
no
<apeiros>
yqfvwal: .each_with_index { |line, a| …
<baweaver>
yqfvwal: what's the entire code?
<baweaver>
!gist
<baweaver>
?gist
<ruby[bot]>
https://gist.github.com - Multiple files, syntax highlighting, even automatically with matching filenames, can be edited
arlek has quit [Ping timeout: 256 seconds]
<crime>
yeah paste your code somewhere
Zai00 has quit [Quit: Zai00]
<baweaver>
don't use ! methods
<apeiros>
yqfvwal: but for your approach - why didn't you set `a` outside the loop instead of testing on every single iteration whether it exists?
<crime>
i cant wait to see whatever this is
<baweaver>
there are exceptions but more of a headache in most cases.
<baweaver>
without the entire context most of this advice is probably bad.
<yqfvwal>
It was just some experimenting. I wanted to increment a variable, everytime an enter is pressed, and write it on stdout
<dajobat>
Cheerio all
william3 has quit [Ping timeout: 250 seconds]
dajobat has quit [Quit: Leaving]
<yqfvwal>
a = 0;ARGF.each {a += 1};puts a # this is all I want to do
<marxarelli>
yqfvwal: ARGF.each.reduce(0) { |a| a + 1 } would probably work well for you
<baweaver>
a = 0; loop do gets && a +=1 end
ElFerna has joined #ruby
<baweaver>
marxarelli: won't work
<baweaver>
reduce takes two arguments to the block
x77686d has joined #ruby
<baweaver>
that'll just treat it as one array
<marxarelli>
blocks don't have strict arity
infra-red has joined #ruby
<baweaver>
try it
newbie22 has joined #ruby
<marxarelli>
i did :)
moeabdol1 has quit [Read error: Connection reset by peer]
<marxarelli>
|*a| would expand the block arguments to an array, but not |a|
<newbie22>
Hello everyone
fedexo has joined #ruby
fedexo_ has joined #ruby
<marxarelli>
blocks don't enforce their arity. i.e. (proc {}).call(1, 2, 3, ...) executes fine
zast has quit [Remote host closed the connection]
<marxarelli>
lambdas do, however
<marxarelli>
i.e. (lambda {}).call(1, 2, 3) raises ArgumentError
newbie22 has quit [Client Quit]
benlieb has quit [Quit: benlieb]
william3 has joined #ruby
krobzaur has quit [Quit: WeeChat 1.2]
krobzaur has joined #ruby
karapetyan has joined #ruby
adgtl has joined #ruby
oncall-pokemon has joined #ruby
djbkd has joined #ruby
pdoherty has joined #ruby
flughafen_ has joined #ruby
infra-re_ has joined #ruby
idefine has quit [Remote host closed the connection]
idefine has joined #ruby
kknight has joined #ruby
benlieb has joined #ruby
karapetyan has quit [Ping timeout: 245 seconds]
infra-red has quit [Ping timeout: 248 seconds]
dionysus69 has joined #ruby
despai has joined #ruby
idefine has quit [Ping timeout: 245 seconds]
roshanav_ has quit [Remote host closed the connection]
<Devalo>
Hello. I have a file with lines of text, and I want to delete a specific line. (todo-app). Gisted method: http://tinyurl.com/j3eljw9. So what I'm trying to do is create a temporary file, read my "db-file" with lines of text, and push all lines of text except the one with the specific index. I call the method with Todo.new.delete(ARGV[1]). What happens is the whole file gets erased instead of the particular line, and "012" gets stored i
<Devalo>
n the file. I feel like I'm close, but I'm not sure how to solve this. Any pointers?
<baweaver>
not common I don't pass the iterator with it :)
Lucky_ABA has quit [Read error: Connection reset by peer]
chouhoulis has quit [Ping timeout: 276 seconds]
Ruby_Rocks_007 has joined #ruby
william3 has quit [Remote host closed the connection]
<Devalo>
apeiros and crime: Thanks. That's perfect. I've been staring at this for too long.. lol. Thank you so much for your help.
desiccate has quit [Ping timeout: 256 seconds]
<apeiros>
Devalo: IMO readlines + delete_at is still easier ;-p
<crime>
Devalo: <3
baweaver has quit [Remote host closed the connection]
jackjackdripper has joined #ruby
jackjackdripper has quit [Client Quit]
jackjackdripper has joined #ruby
mdw has joined #ruby
askhat has quit [Read error: Connection reset by peer]
jackjackdripper has quit [Client Quit]
askhat has joined #ruby
jackjackdripper has joined #ruby
darkxploit has joined #ruby
firstdayonthejob has joined #ruby
yoongkang has joined #ruby
voteless has joined #ruby
jackjackdripper1 has joined #ruby
jackjackdripper1 has quit [Client Quit]
jackjackdripper1 has joined #ruby
f4cl3y has quit [Ping timeout: 245 seconds]
kibogol has left #ruby [#ruby]
seitensei has quit [Remote host closed the connection]
roshanavand has joined #ruby
Ruby_Rocks_007 has quit [Quit: Ruby_Rocks_007]
sankaber has quit [Ping timeout: 240 seconds]
jackjackdripper has quit [Ping timeout: 272 seconds]
sankaber has joined #ruby
yoongkang has quit [Ping timeout: 250 seconds]
s2013 has joined #ruby
roshanav_ has joined #ruby
Jet4Fire has joined #ruby
dlitvak has joined #ruby
Felix444 has joined #ruby
dmolina has joined #ruby
Ruby_Rocks_007 has joined #ruby
sankaber has quit [Ping timeout: 250 seconds]
rdark has quit [Ping timeout: 250 seconds]
diego2 has joined #ruby
Coldblackice has joined #ruby
evidex has quit [Ping timeout: 245 seconds]
Dave321 has joined #ruby
diegoviola is now known as Guest90189
diego2 is now known as diegoviola
RegulationD has quit [Remote host closed the connection]
<Dave321>
In Ruby 1.8.7, is it possible to get the backtrace of a thread if you have an instance of the thread object?
dangeranger has joined #ruby
roshanavand has quit [Ping timeout: 250 seconds]
Guest90189 has quit [Ping timeout: 250 seconds]
humding3r has quit [Ping timeout: 240 seconds]
evidex has joined #ruby
<dangeranger>
.
Zai00 has joined #ruby
humd1ng3r has joined #ruby
<eam>
Dave321: you could raise it
ocbtec has quit [Quit: leaving]
s00pcan_ has quit [Ping timeout: 252 seconds]
s00pcan has quit [Ping timeout: 264 seconds]
Eiam has joined #ruby
circ-user-6hGio has joined #ruby
william3 has joined #ruby
baweaver has joined #ruby
mfb2 has joined #ruby
jackjackdripper1 has quit [Quit: Leaving.]
<Dave321>
eam: true, but I don't want execution to halt on my thread, I want to figure out what's going on in the thread
rsc___ has quit [Quit: rsc___]
sepp2k has quit [Quit: Leaving.]
__butch__ has joined #ruby
rsc___ has joined #ruby
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Bloomer has quit [Remote host closed the connection]
__butch__ has quit [Client Quit]
cdg has quit [Remote host closed the connection]
s2013 has joined #ruby
symbol has joined #ruby
j0n3 has joined #ruby
__butch__ has joined #ruby
__butch__ has quit [Client Quit]
ohaibbq has quit [Quit: Leaving...]
__butch__ has joined #ruby
failshell has joined #ruby
Xeago has joined #ruby
ur5us has joined #ruby
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
solars has joined #ruby
david____ has quit [Quit: david____]
selfadhe_ has joined #ruby
<apeiros>
Dave321: an object does not have a backtrace
LoneHermit has joined #ruby
__butch__ has quit [Quit: Leaving.]
rsc___ has quit [Quit: rsc___]
krzkrz has quit [Read error: Connection reset by peer]
<Dave321>
apeiros: the thread instance has a backtrace in newer versions of Ruby, but the method doesn't exist in 1.8.7. I was checking if there was an alternate way to get this information
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
selfadhesivefilm has quit [Ping timeout: 276 seconds]
wald0_ has joined #ruby
voteless has quit [Ping timeout: 245 seconds]
<apeiros>
you could try to use set_trace_func and eval "Thread.current" via the binding
david___ has joined #ruby
<apeiros>
actually it'd be plain Thread.current. and only work if the callback is invoked in that thread
jgt4 has quit [Ping timeout: 272 seconds]
david___ has left #ruby [#ruby]
astrofog has quit [Quit: Quite]
LoneHermit has quit [Ping timeout: 250 seconds]
wald0 has quit [Ping timeout: 240 seconds]
PedramT has joined #ruby
adgtl has quit [Remote host closed the connection]
blaxter has quit [Ping timeout: 276 seconds]
Xeago has quit [Remote host closed the connection]
jottr has quit [Ping timeout: 248 seconds]
s2013 has joined #ruby
fedexo_ has quit [Ping timeout: 250 seconds]
fedexo has quit [Ping timeout: 250 seconds]
diego1 has joined #ruby
babblebre has joined #ruby
diego1 has quit [Changing host]
diego1 has joined #ruby
karapetyan has joined #ruby
s00pcan has joined #ruby
diegoviola has quit [Ping timeout: 276 seconds]
diego1 is now known as diegoviola
kirun has joined #ruby
blackmesa has joined #ruby
pawnbox_ has quit [Remote host closed the connection]
pawnbox has joined #ruby
pawnbox has quit [Remote host closed the connection]
<acidrainfall>
I know ruby isn't a scripting language per se, which is hard for me
hahuang61 has quit [Read error: Connection reset by peer]
<acidrainfall>
But I'm trying to learn it by applying my present needs
hahuang61 has joined #ruby
bronson_ has quit []
<acidrainfall>
So I'm writing a script that kicks off a cluster restart for elasticsearch. I took an existing script that was written for ES 1.x and updated it for 2.x, added a bunch of validation it didn't have, and now I'm adding in some arrays of hostnames and want to offer a selection.
<acidrainfall>
So script would run, say "Which cluster?", and you'd get 1, 2, 3 (for example), and once you've selected which one you want, the script will restart that cluster.
devFrederick has quit [Ping timeout: 240 seconds]
chris2 has joined #ruby
<pushcx>
Sounds like a great use for Ruby.
<acidrainfall>
It's going really well so far.
urbanmonk has joined #ruby
<acidrainfall>
The script itself works really well, but without a cluster selection option.
baweaver has quit [Remote host closed the connection]
<acidrainfall>
How would you do it? I want something like `answer = gets; cluster = ##{answer} ?
<pushcx>
Sounds like you want to check ARGV or use `gets`
<acidrainfall>
or something like that?
<acidrainfall>
gets is perfectly fine
infra-re_ has quit [Ping timeout: 276 seconds]
<acidrainfall>
It's how to assign the array properly
<pushcx>
cluster = gets.chomp.to_i
<crime>
^
PedramT_ has quit []
<acidrainfall>
Well
pdoherty has quit [Ping timeout: 248 seconds]
<acidrainfall>
hold on let me get you a code example
pdoherty has joined #ruby
<hightower3>
Hey, I have a Ruby source file with documentation in comments, using notation like @param, @result, @override etc. Which markup library/language is that?
celly has quit [Remote host closed the connection]
msisk has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
yoongkang has joined #ruby
<acidrainfall>
So, there are 3 arrays, and I want a numeric answer to result in the variable `cluster` getting the value of one of the 3 arrays, based on user selection.
<acidrainfall>
Am I making sense? :(
<acidrainfall>
This is harder to describe than I figured.
<hightower3>
adaedra, that's right, thanks
idefine has quit [Ping timeout: 245 seconds]
<crime>
acidrainfall: when you say 'the value of one of the 3 arrays' do you mean a single element from one of the arrays or one of the arrays as a whole?
<acidrainfall>
crime: the entire array.
<acidrainfall>
OH
<acidrainfall>
You know what, I got it.
<acidrainfall>
Does ruby have `case` ?
<crime>
yes
<acidrainfall>
that's what I need.
<crime>
case some_condition
<adaedra>
?cheatseat
<ruby[bot]>
adaedra: I don't know anything about cheatseat
idefine has joined #ruby
<adaedra>
?cheatset
<ruby[bot]>
adaedra: I don't know anything about cheatset
<acidrainfall>
I was looking for a stupid one-liner when there probably wasn't one.
<acidrainfall>
cheatseat? hah
<adaedra>
grah, how do you write that
<acidrainfall>
cheatsheet?
<acidrainfall>
?cheatsheet
<ruby[bot]>
acidrainfall: I don't know anything about cheatsheet
<adaedra>
duh
<acidrainfall>
:(
<crime>
?skynet_plans
<adaedra>
ah, we don't have that?
<ruby[bot]>
crime: I don't know anything about skynet_plans
<crime>
hmmm
<acidrainfall>
Suuuuure you don't.
<adaedra>
liar, ruby[bot].
robbyoconnor has quit [Ping timeout: 248 seconds]
<acidrainfall>
beep boop.
<crime>
?three_laws
<ruby[bot]>
crime: I don't know anything about three_laws
<crime>
!!
<crime>
dangerous
Ruby_Rocks_007 has joined #ruby
ziyadb has quit [Quit: Connection closed for inactivity]
<BraddPitt>
something more robust than Thor or similar, like a full on framework aimed at making tutorials/running against a test suite
freerobby has quit [Quit: Leaving.]
<Ox0dea>
BraddPitt: Extract the relevant code from the Koans?
<crime>
acidrainfall: all you gotta do is have an array list_of_clusters or whatever, with each element in that array being one of your lists of cluster occupants, than you can just say something like list_of_clusters[answer.to_i - 1]
<acidrainfall>
crime: That would work too, good point.
<acidrainfall>
Thank you.
<crime>
of course
<acidrainfall>
I'll see which one comes out cleaner
<crime>
I like to do things in one line, but yeah, whatever is best to u
<BraddPitt>
Ox0dea I meant a framework for building my own
<BraddPitt>
if that makes sense
yqfvwal has quit [Quit: Leaving]
<crime>
BraddPitt: you could use Highline for CLI, whatever you want for testing, and build your thing
<BraddPitt>
thanks crime, looks like I'll build my own
<crime>
it'll come out great :)
mostlybadfly has quit [Quit: Connection closed for inactivity]
circ-user-6hGio has quit [Ping timeout: 246 seconds]
SCHAAP137 has quit [Ping timeout: 264 seconds]
shadoi has joined #ruby
yqfvwal has joined #ruby
baweaver has joined #ruby
<BraddPitt>
followup, does anyone know of something similar that uses (n)curses?
s2013 has joined #ruby
<BraddPitt>
or is that asking for a whole world of trouble?
<crime>
a gem, or an application?
<BraddPitt>
gem
<crime>
dispel is a gem that is supposed to cure curses, mostly complete but not maintained much any more
Shaboum has quit [Quit: WeeChat 1.4]
<BraddPitt>
hm
<BraddPitt>
ok
<crime>
ruco text editor is built with it
<BraddPitt>
i'll forego it for now
chris2 has quit [Ping timeout: 245 seconds]
idefine has quit [Remote host closed the connection]
<acidrainfall>
At the `else`, how can I force it to go do a gets again?
idefine has joined #ruby
<acidrainfall>
If they don't put in 1, 2, or 3, I want it to say 'Nope, select again.''
<crime>
acidrainfall: put cluster_select
<crime>
where else is
idefine has quit [Remote host closed the connection]
<crime>
it can call itself
<acidrainfall>
would that break the `elasticsearch_cluster = cluster_select()` ?
<crime>
and at the beginning it should check to see if the string is one of the ones you want
<acidrainfall>
That was my first though.
<acidrainfall>
thought.
synthroid has joined #ruby
<claw>
hey guys ? "<foo:attr name="size" value="1929927113" />" how to get the value of value with nokogiri
Rickmasta has joined #ruby
<crime>
no, that just aliases elasticsearch_cluster to your method here, it can still call itself
arlek has quit [Ping timeout: 256 seconds]
<acidrainfall>
cool
<acidrainfall>
`def cluster_select` is a method?
<crime>
yes
<acidrainfall>
well, cluster_select()?
<acidrainfall>
I was wondering what the right term for this was.
karapetyan has joined #ruby
LoneHerm_ has joined #ruby
idefine_ has joined #ruby
<crime>
what i was getting at before though is that if you write it this way, when you want to add more clusters, they're hardcoded into this in a sense, whereas if you had an array of them, all you'd have to do is add to that array and pick an index
Xeago has quit [Remote host closed the connection]
<acidrainfall>
hm
<acidrainfall>
okay
<crime>
like if you had a list_of_clusters array, that array could be thousands of objects long
<crime>
and you would still only need a couple lines of code to do it
marxarelli|afk is now known as marxarelli
<crime>
but doing it this way, if you had a thousand objects to check for, that's basically a thousand or more lines you have to go write
<claw>
got it : x.xpath('newznab:attr[@name="size"]').attr('value').text
SCHAAP137 has joined #ruby
JStoker has joined #ruby
EvilJStoker has joined #ruby
william3 has quit [Remote host closed the connection]
<crime>
acidrainfall: to clarify though, I'd still have your other lists, apollo, engine, enginestg, etc. put those lists in your list_of_clusters by name, so you would know which sub array is which. so list_of_clusters[apollo, engine, enginestg]
<acidrainfall>
line 1 in the paste is line 3 in the script
segfalt__ has joined #ruby
polishdub has quit [Quit: Leaving]
tomchapin has quit [Ping timeout: 248 seconds]
<BraddPitt>
shevy /w 3
<BraddPitt>
oops, sorry
al2o3-cr has quit [Ping timeout: 264 seconds]
DoubleMalt has joined #ruby
nfk has quit [Quit: Try memory.free_dirty_pages=true in about:config]
segfalt__ has quit [Quit: WeeChat 1.3]
TinkerTyper has joined #ruby
<shevy>
acidrainfall is this method not known?
idefine has joined #ruby
<acidrainfall>
the method seems fine
<acidrainfall>
I figured it out.
johnnyt has joined #ruby
<acidrainfall>
It didn't have a definition for list_of_clusters because I wasn't passing it in.
<acidrainfall>
Things I have to get used to - scopes are very strict in ruby
<yqfvwal>
Why is def def = 42 not an error?
<Mon_Ouie>
It is though
<Mon_Ouie>
>> def def = 42
<ruby[bot]>
Mon_Ouie: # => /tmp/execpad-23654122b336/source-23654122b336:2: syntax error, unexpected '=', expecting ';' or '\n' ...check link for more (https://eval.in/515926)
xapak has joined #ruby
<yqfvwal>
Mon_Ouie, ok that is weird, in irb it does not say anything
mondok has joined #ruby
<pushcx>
yqfvwal: in irb it's waiting for the 'end' to throw the error
idefine has quit [Remote host closed the connection]
<Mon_Ouie>
IRB uses a simpler tokenizer to know if the input is terminated, you probably to enter 'end' once or twice for it to detect it
<Mon_Ouie>
probably need to*
<yqfvwal>
Mon_Ouie, ah I see, thanks
<xapak>
Is there any relatively reliable implementation of a pragmatic “Dir[path].empty?”? So far I’m simply listing entries and not counting the “.” and “..”, but I’m not sure if that’s the proper way. :(
idefine has joined #ruby
eGGsha has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<acidrainfall>
Awwwwwwwwwwwwwwwwwwww yeah
<acidrainfall>
This is getting FUN
<acidrainfall>
I just used an until loop
idefine has quit [Remote host closed the connection]
eGGsha has joined #ruby
TinkerTyper has quit [Max SendQ exceeded]
<yqfvwal>
In the book "Well-Grounded Rubyist" it is written that one could potentially name a method def. How would one achieve that?
<acidrainfall>
lol
<acidrainfall>
"it is written that"
<acidrainfall>
you make it sound like a religious text
<Ox0dea>
xapak: You could use Dir.rmdir and exceptions as control flow. :P
<yqfvwal>
acidrainfall, I am sorry, english is not my native language. How would I word that better?
<yqfvwal>
Ox0dea, cool thanks
x77686d has quit [Quit: x77686d]
<shevy>
xapak I think . and .. may be dropped in future releases of ruby, there is some discussion on the bug tracker
<acidrainfall>
yqfvwal: Oh, there was nothing wrong with it. I just found it amusing.
<Ox0dea>
yqfvwal: In general, you can name a method whatever you like; it's calling it that becomes tricky if you've given it a name that conflicts with a keyword or the like.
<acidrainfall>
yqfvwal: Your question was very well worded.
<xapak>
shevy, yeah, there should be a pragmatic approach, or another method: real_empty?, so purists don’t start hating change on entries?
celly has quit [Ping timeout: 260 seconds]
<shevy>
hehe
<Ox0dea>
They won't be dropped; there's discussion of an option to ignore them.
finisherr has joined #ruby
<xapak>
Much, much better. :D
<Ox0dea>
floatingpoint: Ruby spells it `elsif`.
jmdade has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
circ-user-6hGio has quit [Ping timeout: 246 seconds]
nofxx has quit [Ping timeout: 240 seconds]
<floatingpoint>
so you're telling me i have to fork ruby to get the correct syntax?
<Ox0dea>
Wat.
<floatingpoint>
elseif isn't even a word
luvenfu has joined #ruby
<shevy>
floatingpoint stop
<Ox0dea>
Alternatively, keep going.
nofxx has joined #ruby
nofxx has quit [Changing host]
nofxx has joined #ruby
<shevy>
nah adaedra already got his eyes on him
idefine has quit [Remote host closed the connection]
<shevy>
<floatingpoint> bash is, quite possibly, the worst
<shevy>
<adaedra> do you have anything interesting to discuss or are you here just for the troll?
last_staff has joined #ruby
<shevy>
it'll be 50 more lines before a ban ... do you really wanna go through that Ox0dea :(
circ-user-6hGio has joined #ruby
<shevy>
what was the dude with the beard again...
pokui has quit [Ping timeout: 252 seconds]
dcunit3d has joined #ruby
sepp2k has quit [Read error: Connection reset by peer]
idefine has joined #ruby
skweek has joined #ruby
ramortegui has quit [Quit: Ex-Chat]
roddutra has joined #ruby
AlexJakeGreen has quit [Quit: This computer has gone to sleep]
tvw has quit [Ping timeout: 245 seconds]
rattatmatt has joined #ruby
roddutra has quit [Read error: Connection reset by peer]
roddutra has joined #ruby
luvenfu has left #ruby [#ruby]
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby
djbkd has quit [Remote host closed the connection]
djbkd has joined #ruby
hahuang61 has quit [Ping timeout: 240 seconds]
selfadhe_ has quit [Remote host closed the connection]
jgpawletko has joined #ruby
TomPeed has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
djbkd has quit [Remote host closed the connection]
haylon has left #ruby ["WeeChat 1.3"]
djbkd has joined #ruby
idefine has quit [Remote host closed the connection]
al2o3-cr has joined #ruby
djbkd has quit [Read error: Connection reset by peer]
askhat has quit [Read error: Connection reset by peer]
Ruby_Rocks_007 has quit [Ping timeout: 264 seconds]
decoponio has quit [Quit: Leaving...]
idefine has joined #ruby
askhat has joined #ruby
djbkd has joined #ruby
Ruby_Rocks_007 has joined #ruby
x77686d has joined #ruby
djbkd has quit [Remote host closed the connection]
s2013 has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<acidrainfall>
hah
<acidrainfall>
I thought `else if` does work?
jgpawletko has quit [Client Quit]
xapak has left #ruby [#ruby]
<adaedra>
if you use else if, you have to close twice, I guess.
azure32 has quit [Ping timeout: 240 seconds]
<acidrainfall>
Odd.
<acidrainfall>
elsif doesn't bother me anyway
<adaedra>
Not at all.
<acidrainfall>
oh I see
<acidrainfall>
you're right it's not odd
<adaedra>
else keeps the first if "open", and your second if opens a new one.
<acidrainfall>
it's else { if (thing) { } }
<acidrainfall>
yeah that makes sense.
peterevjan has joined #ruby
azure32 has joined #ruby
<adaedra>
C++ "else if" is in fact application of the optional {} on 1-statements clauses on if/else
ss_much has quit [Quit: Connection closed for inactivity]
duckpuppy has quit [Ping timeout: 260 seconds]
mwlang has joined #ruby
chouhoulis has joined #ruby
skweek has quit [Ping timeout: 252 seconds]
<acidrainfall>
In English that means...? :(
<shevy>
lol
<shevy>
you must have written that with a french accent adaedra :)
<adaedra>
`if (a) {} else if (b) {}` is the same as `if (a) {} else { if (b) {} }`
<Ox0dea>
acidrainfall: There's really no such thing as "else if" in language where it's spelled that way.
dopie has joined #ruby
<Ox0dea>
*languages
<Ox0dea>
It's just an `else` with an `if` attached.
<shevy>
ok acidrainfall now I also don't know what that means
<adaedra>
shevy: I dônt sée whàt yoú mæn.
yoongkang has joined #ruby
zenlot1 has joined #ruby
dopie has quit [Client Quit]
skweek has joined #ruby
dopie has joined #ruby
<shevy>
the () caught me off-guard, like a sneaky lisp attack
mwlang has quit [Client Quit]
zenlot has quit [Ping timeout: 272 seconds]
pawnbox has joined #ruby
KillerFox has joined #ruby
<Ox0dea>
adaedra: `else if` is never the right call in Ruby.
Xeago has quit [Remote host closed the connection]
mwlang has joined #ruby
<adaedra>
Ox0dea: I know. I was just explaining C++ way of doing it, as someone mentioned it earlier.
chouhoulis has quit [Ping timeout: 256 seconds]
<Ox0dea>
Right, but "the C++ way" can't be grafted onto Ruby.
<shevy>
matz does not like C++
bhaak has quit [Ping timeout: 250 seconds]
<Ox0dea>
You could make an `else if` syntactically valid, but you'd be in for a surprise if you tried to use another one right after.
<adaedra>
right.
bhaak has joined #ruby
<havenwood>
shevy: "And after two years of C++ programming, it still surprised me."
ElFerna has quit [Ping timeout: 272 seconds]
<shevy>
my own code surprises me still too!
<adaedra>
tbf, after so many years, Ruby still surprises me.
<shevy>
hah!
<adaedra>
sometimes thanks to Ox0dea.
<havenwood>
shevy: It fails the principle of least Matz surprise.
<adaedra>
:D
<shevy>
Ox0dea's code is deliberately scary
[Butch] has quit [Quit: I'm out . . .]
<shevy>
it's like you are in university and you learn all about the fancy stuff. then you go to work and notice that work is totally different from what you learned
pawnbox has quit [Ping timeout: 260 seconds]
lipoqil has quit [Quit: Connection closed for inactivity]
<adaedra>
Seems you can totally use a language without mastering every aspect of it.
<acidrainfall>
adaedra: I see that you've excluded the circumflex
<adaedra>
acidrainfall: it's the hardest one to type on my keyboard.
circ-user-6hGio has quit [Remote host closed the connection]
<acidrainfall>
Ox0dea: adaedra: shevy: So if (condition) { action } else { if (condition) { action } } is the expanded else if logic
<acidrainfall>
adaedra: aren't they phasing the circumflex out?
<adaedra>
no
<acidrainfall>
I saw something about that, a few french/belgian friends of mine were freaking out about it
idefine has quit [Remote host closed the connection]
<adaedra>
it's a 25 years old reform which concern only o and i letters iirc, and only if not making the sense of the word change. Furthermore, old spellings are still valid.
<acidrainfall>
interesting
<acidrainfall>
The actual construction of French is so much more controlled and complicated.
<acidrainfall>
English is very laissez faire.
hahuang61 has joined #ruby
benlieb has quit [Quit: benlieb]
mickey_mouse has quit [Ping timeout: 245 seconds]
krobzaur_ has quit [Ping timeout: 264 seconds]
<adaedra>
If you are interested in the discussion, I invite you to continue in #ruby-offtopic
idefine has joined #ruby
<acidrainfall>
Naw I'm done. :)
<acidrainfall>
Thanks for the help with my Ruby issues, my script is working splendidly.
rbennacer has quit [Remote host closed the connection]
<shevy>
<adaedra> Seems you can totally use a language without mastering every aspect of it.
<adaedra>
correction then: it's u and i.
<shevy>
adaedra yeah!
rbennacer has joined #ruby
roddutra has quit []
<shevy>
I use a mini-ruby subset of ruby
idefine has quit [Remote host closed the connection]
symbol has joined #ruby
<shevy>
-> is BANNED
<shevy>
lonely operator is BANNED
djbkd has joined #ruby
<adaedra>
You mean, you're using ruby 1.8 ?
<shevy>
I would if I could!
<shevy>
but it is a fossil version now :(
* adaedra
shrugs
<shevy>
I'd like to try 1.0 but it does not compile for me