firstdayonthejob has quit [Ping timeout: 245 seconds]
nadir has quit [Quit: Connection closed for inactivity]
FatSpitfire has quit [Read error: Connection reset by peer]
webguynow has quit [Ping timeout: 260 seconds]
webguynow has joined #ruby
bocaneri has joined #ruby
alexherbo2 has quit [Ping timeout: 265 seconds]
gusrub has joined #ruby
User458764 has joined #ruby
willardg has joined #ruby
gusrub has quit [Remote host closed the connection]
aganov has joined #ruby
gnufied has quit [Ping timeout: 245 seconds]
Derperperd has quit [Quit: Derperperd]
wugy has joined #ruby
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
ace05 has quit [Remote host closed the connection]
Pumukel has joined #ruby
dminuoso_ has joined #ruby
ziarkaen has joined #ruby
gusrub has joined #ruby
gusrub has quit [Remote host closed the connection]
hahuang65 has quit [Ping timeout: 260 seconds]
lenwood has joined #ruby
ziarkaen has quit [Ping timeout: 260 seconds]
vuoto has joined #ruby
benlieb has quit [Quit: benlieb]
TomyWork has joined #ruby
last_staff has joined #ruby
claudiuinberlin has joined #ruby
alexherbo2 has joined #ruby
hutch34 has joined #ruby
Burgestrand has joined #ruby
Madplatypus has joined #ruby
hutch34 has quit [Ping timeout: 250 seconds]
CloCkWeRX has quit [Quit: Leaving.]
sphex has quit [Read error: Connection reset by peer]
elifoster has quit [Quit: sleep]
aufi has joined #ruby
quazimodo has joined #ruby
armyriad has joined #ruby
Pupeno has joined #ruby
mark_66 has joined #ruby
dionysus69 has joined #ruby
sphex has joined #ruby
andikr has joined #ruby
palms has quit [Ping timeout: 260 seconds]
antgel has joined #ruby
minimalism has quit [Ping timeout: 250 seconds]
blaxter has joined #ruby
lacour has quit [Quit: Leaving]
aupadhye has quit [Ping timeout: 256 seconds]
marsjaninzmarsa has quit [Quit: ZNC 1.7.x-git-487-cbf5c38 - http://znc.in]
marsjaninzmarsa has joined #ruby
quazimodo has quit [Ping timeout: 250 seconds]
orangey_ is now known as orangey
VladGh has quit [Ping timeout: 256 seconds]
VladGh has joined #ruby
User458764 has joined #ruby
aupadhye has joined #ruby
Silthias1 has joined #ruby
grh has joined #ruby
Silthias2 has joined #ruby
Silthias has quit [Ping timeout: 265 seconds]
lenwood has quit [Remote host closed the connection]
lenwood has joined #ruby
jphase has quit [Remote host closed the connection]
jphase has joined #ruby
Silthias1 has quit [Ping timeout: 260 seconds]
sphex has quit [Ping timeout: 256 seconds]
jphase has quit [Remote host closed the connection]
jphase has joined #ruby
edwinvdgraaf has joined #ruby
antgel has quit [Ping timeout: 256 seconds]
foooobear has joined #ruby
sphex has joined #ruby
dar123 has quit [Read error: Connection reset by peer]
antgel has joined #ruby
djbkd has quit []
sdwrage has quit [Quit: This computer has gone to sleep]
jphase has quit [Ping timeout: 260 seconds]
harai_ has joined #ruby
Cohedrin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Cohedrin has joined #ruby
armyriad has quit [Ping timeout: 256 seconds]
armyriad has joined #ruby
lenwood has quit [Ping timeout: 250 seconds]
pawnbox has quit [Remote host closed the connection]
Guest33 has joined #ruby
Chair has joined #ruby
the_drow has joined #ruby
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
AndrewIsHere has joined #ruby
Guest33 has quit [Read error: Connection reset by peer]
Cohedrin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
spami has quit [Quit: This computer has gone to sleep]
mpr555 has joined #ruby
bturker has joined #ruby
startupality has joined #ruby
bturker has quit [Client Quit]
AndrewIsHere has quit [Ping timeout: 260 seconds]
quazimodo has joined #ruby
mikecmpbll has joined #ruby
futabachannel has quit [Read error: Connection reset by peer]
nankyokusei has joined #ruby
ericwood_ has quit [Remote host closed the connection]
edwinvdgraaf has quit [Ping timeout: 250 seconds]
ziarkaen has joined #ruby
nankyokusei has quit [Ping timeout: 260 seconds]
antgel has quit [Ping timeout: 260 seconds]
edwinvdgraaf has joined #ruby
jsrn_ has joined #ruby
shayan__ has quit [Quit: shayan__]
ishahnaz has joined #ruby
the_drow has quit [Quit: Leaving]
<gizmore>
btw.. what are we waiting for? i always wondered
Immune__ has joined #ruby
Prawnzy has quit [Remote host closed the connection]
antgel has joined #ruby
mpr555 has quit []
jphase has joined #ruby
sonne_ is now known as sonne
sonne has quit [Changing host]
sonne has joined #ruby
anisha has quit [Quit: This computer has gone to sleep]
Immune_ has quit [Ping timeout: 260 seconds]
lenwood has joined #ruby
elemnn has joined #ruby
User458764 has joined #ruby
jphase has quit [Remote host closed the connection]
Snowy has joined #ruby
jphase has joined #ruby
ishahnaz has quit []
tvw has joined #ruby
mpr555 has joined #ruby
ocbtec has joined #ruby
brent__ has quit [Quit: Connection closed for inactivity]
jphase has quit [Ping timeout: 260 seconds]
elenatanasoiu has joined #ruby
bigkevmcd has joined #ruby
Burgestrand has joined #ruby
mpr555 has quit []
salut has joined #ruby
jaequery has joined #ruby
SCHAAP137 has joined #ruby
flying has joined #ruby
jenrzzz has joined #ruby
jenrzzz has joined #ruby
gregf_ has joined #ruby
jenrzzz has quit [Changing host]
Beams has joined #ruby
dangerousdave has joined #ruby
aidalgol has joined #ruby
ishahnaz has joined #ruby
gingray has joined #ruby
fivmo has joined #ruby
willardg has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Macaveli has joined #ruby
jenrzzz has quit [Ping timeout: 256 seconds]
pawnbox has joined #ruby
pawnbox has joined #ruby
jenrzzz has joined #ruby
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
ponga has joined #ruby
minimalism has joined #ruby
willardg has joined #ruby
pawnbox has quit [Ping timeout: 276 seconds]
Burgestrand has joined #ruby
Nahra has joined #ruby
Burgestrand has quit [Client Quit]
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
AndrewIsHere has joined #ruby
senayar has joined #ruby
quazimodo has quit [Ping timeout: 252 seconds]
aswen has joined #ruby
AndrewIsHere has quit [Ping timeout: 260 seconds]
jenrzzz has quit [Ping timeout: 260 seconds]
al2o3-cr has quit [Ping timeout: 245 seconds]
willardg has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
al2o3-cr has joined #ruby
mim1k|wo1k is now known as mim1k|work
jaruga___ has joined #ruby
latpaw has quit [Remote host closed the connection]
jaguarma_ has quit [Remote host closed the connection]
jaequery has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
sylario has quit [Quit: Connection closed for inactivity]
hutch34 has joined #ruby
marr has joined #ruby
vuoto has quit [Remote host closed the connection]
willardg has joined #ruby
renderfu_ has joined #ruby
astrobunny has quit [Remote host closed the connection]
edwinvdgraaf has quit [Ping timeout: 245 seconds]
djellemah has quit [Ping timeout: 252 seconds]
hutch34 has quit [Ping timeout: 250 seconds]
willardg has quit [Ping timeout: 248 seconds]
djellemah has joined #ruby
Burgestrand has joined #ruby
renderfu_ has quit [Ping timeout: 244 seconds]
edwinvdgraaf has joined #ruby
edwinvdgraaf has quit [Read error: Connection reset by peer]
quazimodo has joined #ruby
edwinvdgraaf has joined #ruby
ferr has joined #ruby
pwnd_nsfw has joined #ruby
Robtop__ has quit [Ping timeout: 256 seconds]
joneshf-laptop has joined #ruby
pawnbox has joined #ruby
dangerousdave has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
ta_ has quit [Ping timeout: 256 seconds]
ta__ has quit [Ping timeout: 250 seconds]
dextertzu has quit [Read error: Connection reset by peer]
Pupeno has quit [Ping timeout: 260 seconds]
workmad3 has joined #ruby
ta_ has joined #ruby
User458764 has joined #ruby
troulouliou_div2 has joined #ruby
troulouliou_div2 has quit [Changing host]
troulouliou_div2 has joined #ruby
ta__ has joined #ruby
mrgrieves has quit [Ping timeout: 256 seconds]
ziarkaen has quit [Ping timeout: 245 seconds]
ziarkaen has joined #ruby
quazimodo has quit [Read error: Connection reset by peer]
lxsameer has joined #ruby
hck89 has joined #ruby
ishahnaz has quit []
gingray has quit [Ping timeout: 260 seconds]
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
edwinvdgraaf has quit [Remote host closed the connection]
edwinvdgraaf has joined #ruby
edwinvdgraaf has quit [Read error: Connection reset by peer]
edwinvdgraaf has joined #ruby
workerbeetwo has joined #ruby
xpt has quit [Ping timeout: 265 seconds]
AlexRussia has joined #ruby
Macaveli has quit [Ping timeout: 250 seconds]
skweek has quit [Ping timeout: 250 seconds]
dextertzu has joined #ruby
xall_ has quit [Ping timeout: 260 seconds]
nettoweb has joined #ruby
nankyokusei has joined #ruby
Jameser has quit [Ping timeout: 250 seconds]
edwinvdg_ has joined #ruby
nankyokusei has quit [Ping timeout: 256 seconds]
edwinvdgraaf has quit [Read error: Connection reset by peer]
Diabolik has joined #ruby
araujo has joined #ruby
araujo has quit [Changing host]
araujo has joined #ruby
araujo has quit [Max SendQ exceeded]
araujo has joined #ruby
futabachannel has joined #ruby
Prawnzy has joined #ruby
SCHAAP137 has quit [Quit: Leaving]
ldnunes has joined #ruby
mrgrieves has joined #ruby
garyolee has quit []
User458764 has joined #ruby
beawesomeinstead has quit [Ping timeout: 260 seconds]
bustiz has quit [Quit: leaving]
aidalgol has quit [Quit: zZzZzZzzzz]
Prawnzy has quit [Ping timeout: 252 seconds]
koooge has quit [Quit: Leaving...]
beawesomeinstead has joined #ruby
Pupeno has joined #ruby
Pupeno has quit [Changing host]
Pupeno has joined #ruby
koooge has joined #ruby
Macaveli has joined #ruby
c355e3b has joined #ruby
mmachenry has joined #ruby
SCHAAP137 has joined #ruby
<mmachenry>
Could someone explain to me why Ruby is interpreting this whitespace ambiguity in a way that seems to be different from what the tutorial says? http://lpaste.net/306752
jenrzzz has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Changing host]
Burgestrand has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<ciawal>
I can't access that page :/
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
ojeno has joined #ruby
ojeno has quit [Max SendQ exceeded]
Azure has joined #ruby
ojeno has joined #ruby
ojeno has quit [Max SendQ exceeded]
Algebr has joined #ruby
jenrzzz has quit [Ping timeout: 250 seconds]
ojeno has joined #ruby
harfangk has joined #ruby
ojeno has quit [Max SendQ exceeded]
<Algebr>
Can someone please do me a big favor? I'm trying to build this project https://github.com/Thibaut/devdocs but it keeps failing for one reason or another, nokogiri can't compile, etc etc. I just want to get documentation of JavaScript as one big json file, like say for Array.map, etc etc
<Algebr>
if someone could build this, run it, and put the resultant JS json API up somewhere, I'd be very grateful
ojeno has joined #ruby
ojeno has quit [Max SendQ exceeded]
nikivi has joined #ruby
ojeno has joined #ruby
ojeno has quit [Max SendQ exceeded]
startupality has quit [Quit: startupality]
AlexJakeGreen has joined #ruby
nikivi has quit [Remote host closed the connection]
<Milo_learn_ruby>
i wish to learn ruby by practice
<mmachenry>
ciawal: What happens when you try to get that page? http://lpaste.net/306752 I works for me. Odd
<ciawal>
mmachenry: I'm in a cafe and the wifi provider has blocked it for some reason (“we block pages that could be deemed offensive in a public place, intrusive or affect your security online”)
<workmad3>
Algebr: any reason to not use the hosted version they mention in the docs?
<workmad3>
Algebr: no idea if that covers what you need... but it's unlikely that someone else spinning up an instance would produce anything different :)
<ciawal>
mmachenry: perhaps because a is undefined?
<ciawal>
if you add:
<ciawal>
def a(x); p x; end
<ciawal>
at the top
<ciawal>
what happens
<dminuoso_>
Bah, Im trying to parse a pdf with pdf-reader. It seems like some spaces between words are not properly recognized and skipped (thus joining words together). I need some ideas what to do to figure out whats going on.
<dminuoso_>
(When trying to get the raw text)
<chrisseaton>
dminuoso_: there's a handful of PDF libraries - you could try some alternatives. Or there are command line tools outside Ruby for converting a PDF to plain text you could run.
<mmachenry>
ciawal: Does not change the program at all. I would have been rather scared if it did, to be honest.
hutch34 has quit [Ping timeout: 256 seconds]
Madplatypus has quit [Quit: Connection closed for inactivity]
ace05 has joined #ruby
<ciawal>
mmachenry: oh because a is defined as a variable there
<ciawal>
I mean if instead of being a variable a is a function
<mmachenry>
Still seems to think it's a binary operator.
<dminuoso_>
chrisseaton: Mmm alright. As for Ruby libraries there seems to be only pdf-reader, though pdftotext from poppler-utils gets the spaces out correctly - so there must be some speciality causing pdf-reader to misinterpret things. It could be that I cant rely on this #text method and must extract it manually.
<Algebr>
workmad3: much appreciated
xpt_webchat has joined #ruby
palms has joined #ruby
ace05 has quit [Ping timeout: 244 seconds]
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
<ciawal>
mmachenry: yeah, in this case the line 4 is invalid syntax
<ciawal>
and the line 5 is showing the ambiguity
nikivi has joined #ruby
nikivi has quit [Client Quit]
JeanCarloMachado has joined #ruby
pragmaticus has joined #ruby
vuoto has joined #ruby
rafaelcosta has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<mmachenry>
So is this tutorial worded oddly and I'm misinterpreting it?
<mmachenry>
Maybe it's just wrong?
palms has quit [Ping timeout: 260 seconds]
_sfiguser has joined #ruby
lenwood has quit [Ping timeout: 252 seconds]
nadir has joined #ruby
johnmilton has quit [Remote host closed the connection]
m_abdelfattah has joined #ruby
grh has joined #ruby
m_abdelfattah has quit [Client Quit]
<ciawal>
mmachenry: it's right
m_abdelfattah has joined #ruby
<ciawal>
note the bit in the brackets from your tutorial paste
<ciawal>
with each example
<mmachenry>
But Ruby doesn't interpret a +b as a(+b) in any case.
edwinvdg_ has quit [Remote host closed the connection]
<ciawal>
it does
<ciawal>
# a +b is interpreted as a(+b) ( Here a is a method call)
<ciawal>
if a is a method
<dminuoso_>
This pdf is super strange. When I use the default pdf-receiver, the output completely breaks iterm. CPU usage spikes at 100%, scrolling becomes impossible. Wow
<mmachenry>
So it's saying not that the parser decides "here a is a method" it's say "this parsing works only if a is a method"
al2o3-cr has quit [Ping timeout: 256 seconds]
<ciawal>
yeah the bit in the brackets is saying what `a` is in each example
<mmachenry>
I guess that makes sense. It's odd that they would use that as an example of where whitespace changes what the parse tree looks like when it's actually the prior declarations of the variables involved that change it.
biberu has joined #ruby
m_abdelfattah has quit [Ping timeout: 245 seconds]
vuoto has quit [Remote host closed the connection]
edwinvdgraaf has joined #ruby
User458764 has joined #ruby
wjimenez5271 has quit [Read error: Connection reset by peer]
iNs has joined #ruby
bkxd has quit [Ping timeout: 252 seconds]
rafaelcosta has joined #ruby
aryaching has quit [Ping timeout: 256 seconds]
ziarkaen has quit [Ping timeout: 260 seconds]
<linduxed>
if i've got some rspec code that looks like this:
<linduxed>
subject { ford }
<linduxed>
it_behaves_like 'a car'
<linduxed>
is there some way i can express that without a subject?
<linduxed>
like is there some syntax like `expect(car).to behave_like('a car')`?
<linduxed>
or would that not work because it's using expect outside of an it-block?
Guest43 has quit [Ping timeout: 260 seconds]
<linduxed>
actually i suspect that to be the case...
<linduxed>
but anyway, do you guys know of a way to avoid setting a subjecT?
<linduxed>
*subject
the_drow has joined #ruby
nankyokusei has joined #ruby
djbkd has joined #ruby
Snowy has quit [Remote host closed the connection]
Snowy has joined #ruby
tyang__ has joined #ruby
SesMan has joined #ruby
brendan- has joined #ruby
<workmad3>
linduxed: you can pass arguments to an `it_behaves_like` shared example group
nankyokusei has quit [Ping timeout: 260 seconds]
<workmad3>
linduxed: so you could have a shared example group that does something like `RSpec.shared_examples do |subject_block|; let(:car, &subject_block) ...` and then call it with `it_behaves_like 'a car', ->{ ford }`
Guest33 has joined #ruby
edwinvdgraaf has quit [Ping timeout: 260 seconds]
Snowy has quit [Ping timeout: 250 seconds]
johnmilton has joined #ruby
synthroid has joined #ruby
lenwood has joined #ruby
edwinvdgraaf has joined #ruby
User458764 has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
sagax has quit [Ping timeout: 250 seconds]
rafaelcosta has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rafaelcosta has joined #ruby
Prawnzy has joined #ruby
brendan- has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
mmachenry has quit [Quit: Leaving.]
<linduxed>
workmad3: ah, but that would require the shared example to be changed to use the block parameter, so if i can't change that, then i'll just have to use the subject, right?
Prawnzy has quit [Ping timeout: 265 seconds]
<workmad3>
linduxed: yeah
tvl has joined #ruby
tvl is now known as tobiasvl
aupadhye has quit [Ping timeout: 276 seconds]
vuoto has joined #ruby
the_drow has quit [Quit: This computer has gone to sleep]
rafaelcosta has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
rkazak has joined #ruby
shinnya has joined #ruby
rafaelcosta has joined #ruby
sparch has joined #ruby
rafaelcosta has quit [Client Quit]
WebDawg is now known as neoweb_
ziarkaen has joined #ruby
corbytacrb has joined #ruby
rafaelcosta has joined #ruby
pawnbox has quit [Remote host closed the connection]
pawnbox has joined #ruby
<linduxed>
workmad3: ok thx!
PaulCapestany has quit [Quit: .]
Derperperd has joined #ruby
pawnbox has quit [Remote host closed the connection]
vuoto has quit [Quit: Lost terminal]
pawnbox has joined #ruby
pawnbox has quit [Remote host closed the connection]
grh has quit [Ping timeout: 250 seconds]
pawnbox has joined #ruby
pawnbox has quit [Remote host closed the connection]
corbytacrb has quit [Quit: Leaving]
Derperperd has quit [Quit: Derperperd]
velocity64 has joined #ruby
velocity64 has quit [Remote host closed the connection]
djbkd has quit []
dhurba has joined #ruby
lenwood has quit [Ping timeout: 252 seconds]
dhurba is now known as nobody12321
startupality has joined #ruby
tk__ has joined #ruby
ben__ has joined #ruby
pawnbox has joined #ruby
AndrewIsHere has joined #ruby
PaulCapestany has joined #ruby
d0nn1e has quit [Ping timeout: 250 seconds]
velocity64 has joined #ruby
<CustosLimen>
hi
d0nn1e has joined #ruby
frozengeek__ has joined #ruby
scorphus has quit [Changing host]
scorphus has joined #ruby
AndrewIsHere has quit [Ping timeout: 260 seconds]
pawnbox has quit [Ping timeout: 260 seconds]
velocity64_ has joined #ruby
<linduxed>
hi o/
frozengeek__ is now known as frozengeek
grh has joined #ruby
<CustosLimen>
someone is getting asciidoctor.ruby-2.2 in $HOME/.gem/ruby/*/bin when they do gem install --user-install asciidoctor
<CustosLimen>
why is this ? and how can I get gem to not put the .ruby-2.2
lenwood has joined #ruby
rafaelcosta has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
Snowy has joined #ruby
gnufied has joined #ruby
ramortegui has joined #ruby
Algebr has left #ruby ["ERC (IRC client for Emacs 25.1.50.1)"]
hck89 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<linduxed>
i don't know the answer to your question, but maybe it has something to do with some setting for `gem`?
nfk has joined #ruby
<linduxed>
you could look into that
rafaelcosta has joined #ruby
hutch34 has joined #ruby
renderfu_ has joined #ruby
ocbtec has quit [Quit: leaving]
ben__ has quit [Read error: Connection reset by peer]
ben__ has joined #ruby
ben__ has quit [Remote host closed the connection]
ben__ has joined #ruby
hutch34 has quit [Ping timeout: 250 seconds]
cdg has joined #ruby
JesseH has quit [Remote host closed the connection]
dhurba has joined #ruby
renderfu_ has quit [Ping timeout: 260 seconds]
rafaelcosta has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
nobody12321 has quit [Ping timeout: 250 seconds]
hck89 has joined #ruby
<FatSpitfire>
ruby is a real headache for ubuntu :D
harai_ has quit [Ping timeout: 260 seconds]
roger_rabbit has quit [Ping timeout: 245 seconds]
<FatSpitfire>
here`s a quick one : do I try Drupal or continue my battle with ruby and its CMSs ?
<FatSpitfire>
anyone ?
<hanmac>
hm SAP seeems to be problems with DST ... DST might be some of such new inventions that don't work on all systems yet ... ;P
lxsameer has quit [Quit: WeeChat 1.6]
<dminuoso_>
Always what I wanted. A 1000 page pdf file specying the PDF format.
* dminuoso_
sighs
velocity64 has quit [Remote host closed the connection]
velocity64_ is now known as velocity64
andikr has quit [Remote host closed the connection]
tlaxkit has quit [Remote host closed the connection]
tlaxkit has joined #ruby
malconis has joined #ruby
gregf_ has quit [Quit: Page closed]
frozengeek has quit [Quit: frozengeek]
DLSteve has quit [Quit: All rise, the honorable DLSteve has left the channel.]
mikecmpbll has quit [Quit: inabit. zz.]
weemsledeux has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
elenatanasoiu has quit [Ping timeout: 256 seconds]
tercenya has quit [Remote host closed the connection]
tercenya has joined #ruby
Jameser has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
senayar has quit []
flying has quit []
DonDS has joined #ruby
igniting has joined #ruby
Beams has quit [Quit: .]
hutch34 has quit [Ping timeout: 260 seconds]
<DonDS>
good evening, that noob(myself) again on here
DLSteve has joined #ruby
<DonDS>
i know i could find all of it in doc if i read properly, but just a quicky
<DonDS>
i want to insert into array random number, how do i do?
rafaelcosta has joined #ruby
<havenwood>
DonDS: [] << rand(0..42)
<DonDS>
havenwood: thats almost what i want to do, but not as exactly. cheapest example: i do Array.new(10) and then 10 times rand[0..9] and each of that solution of rand should go into array
<DonDS>
for example, if rand gives back "6", 6th element of array should be ++
spami has joined #ruby
spami has joined #ruby
spami has quit [Changing host]
Synthead has quit [Quit: Synthead]
<DonDS>
i'm not a programming guy, i know my question is lame ;-/
<havenwood>
DonDS: Array.new(10) { rand 0..9 }
Macaveli has joined #ruby
<DonDS>
havenwood: that does it one time, doesn't it? i want to test rand itself, so lets say i want to do that 1000 times, english not my native language, i can't explain better
<havenwood>
DonDS: It's often easier to say the value of your expected input argument and the return value you'd like rather than describing the logic.
augcesar has joined #ruby
Macaveli has quit [Client Quit]
rafaelcosta has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<havenwood>
"it is easier for humans to understand complex data compared with complex logic"
<havenwood>
~ Eric Raymond
_sfiguser has quit [Ping timeout: 256 seconds]
rafaelcosta has joined #ruby
Ishido has joined #ruby
jaruga___ has quit [Quit: jaruga___]
<DonDS>
ok, may i tell in pseudocode: array B lenght of 10. Then 10000 times do i=rand(0..9). each time do result of rand = i > B[i]++
spami has quit [Read error: Connection reset by peer]
wesley_ has joined #ruby
chrisja has joined #ruby
wesley_ is now known as Guest97339
<DonDS>
for example if rand result is 6 and B(6) == 15 then B(6) should get 7
<DonDS>
s/should get 16
ocbtec has joined #ruby
<Guest97339>
Hello, do you know a good Ruby online training (practice with a full ruby project) ?
ziarkaen has quit [Ping timeout: 245 seconds]
troys has joined #ruby
<DonDS>
or otherwise said, i want to construct array of lenght 10 with earch elemt is initialized 0, then do 1000 times rand[0..9] and each result bin into array[result], therefore if all happens endof array would be [9,9,9,9,9,9,9,9,9,9]
rafaelcosta has quit [Ping timeout: 276 seconds]
<DonDS>
(on thelong run in infinity of time)
<DonDS>
soemeone understand my problem?
<havenwood>
DonDS: a = Array.new(10, 0); 10_000.times { a[rand a.size] += 1 }; a
hahuang65 has joined #ruby
<DonDS>
or for simple logic: do rand(1..9) -> if result = 3 Then array[3] = array[3] + 1
<DonDS>
havenwood: i'll try that tomorrow. that sounds like i want
<DonDS>
havenwood: how long do you have to practice ruby than to gat to such short and elegant answer?
gusrub has quit [Remote host closed the connection]
jbeeze has quit []
<DonDS>
that " a[rand a.size]" part is really sexy. i wouldn't have fugured out that for weeks
gusrub has joined #ruby
ziarkaen has joined #ruby
blackbombay_ has joined #ruby
Guest97339 has quit [Ping timeout: 260 seconds]
<DonDS>
i like chubby twen girls, but that is almost as sexy to me
<DonDS>
thank you, havenwood. It's great!
<DonDS>
how can you learn that kind of stuff? Anyway, thanks for the help!
armyriad has quit [Read error: Connection reset by peer]
tercenya has quit [Remote host closed the connection]
armyriad has joined #ruby
tercenya has joined #ruby
<DonDS>
{ a[rand a.size] += 1 }
polishdub has joined #ruby
<DonDS>
what a cool syntax. even i am not a programming persionality i really appreciate that
<_sfiguser>
anybody is attending some US university here ?
gingray has joined #ruby
bovis has joined #ruby
shayan_ has joined #ruby
SeepingN has joined #ruby
dextertzu has quit [Read error: Connection reset by peer]
<bovis>
When CSV.foreach loops through a file's lines, it sees blanks as nil. How can I make it see them as just an empty string? Do I have to input the empty string into the file in the first place?
whathappens has quit [Remote host closed the connection]
<machinewar>
or just nil.to_s when you process the csv
whathappens has joined #ruby
dextertzu has joined #ruby
whathappens has quit [Read error: Connection reset by peer]
whathappens has joined #ruby
<bovis>
machinewar: The foreach collects lines in a file as entire rows and, I think, saves the row temporarily as an array... I'd have to loop through the array. Maybe just insuring the input would be easier.
LeBlaaanc has joined #ruby
shayan_ has quit [Quit: shayan_]
<Papierkorb>
bovis: the_array.map(&:to_s)
<LeBlaaanc>
can I ask a question about bundler here?
<LeBlaaanc>
If this is a cli tool how can I specify to run a specific version of that dependency? I created Gemfile and my CI tools knows how to use it but I don't know how to use it locally
weemsledeux has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
funnel has joined #ruby
<machinewar>
LeBlaaanc: can you just install that version you want?
<LeBlaaanc>
Meaning can I just use the dated versin?
<LeBlaaanc>
version*
Pumukel has joined #ruby
djbkd has joined #ruby
<LeBlaaanc>
oh ya just gem install the specific version?
<machinewar>
LeBlaaanc: yep exactly
Pumukel has quit [Remote host closed the connection]
<machinewar>
gem install gem -v "x.x.x" or whatever you want
<LeBlaaanc>
ya...
<LeBlaaanc>
i see something like `bundle exec fastlane ...` is that used for this?
Pumukel has joined #ruby
<LeBlaaanc>
machinewar also, regarding gem install ...., it still seems to use the newer version as the newer one falls within that range, there's gotta be a better way to do this
jgnagy has joined #ruby
Derperperd has quit [Quit: Derperperd]
last_staff has joined #ruby
SteenJobs has joined #ruby
<machinewar>
LeBlaaanc: did you try to install a specific version?
Pumukel has quit [Remote host closed the connection]
<MrLow>
:)
Pumukel has joined #ruby
<MrLow>
thanks @havenwood
<havenwood>
MrLow: you're welcome
<dminuoso>
havenwood, tell me something. I saw that you are the actual author behind deck-of-cards.
<dminuoso>
Can you do card tricks with it too?
<dminuoso>
Like you know - making cards disappear? :S
<havenwood>
dminuoso: That's an in-app purchase upsell.
<dminuoso>
Mmm.
<dminuoso>
I could show you a magic trick with it, but I'd have to Fiddle a bit to make it work!
<dminuoso>
Could make any card disappear.. just like that..
funnel has quit [Ping timeout: 276 seconds]
machinewar has quit [Remote host closed the connection]
Rodya_ has quit [Quit: Leaving...]
peaches is now known as badpeaches
danst has quit [Ping timeout: 260 seconds]
danst has joined #ruby
shayan_ has quit [Quit: shayan_]
shayan_ has joined #ruby
Prawnzy has quit [Remote host closed the connection]
johnmilton has joined #ruby
nfk has quit [Quit: Try memory.free_dirty_pages=true in about:config]
shayan_ has quit [Client Quit]
postmodern has joined #ruby
gusrub has joined #ruby
ziarkaen has joined #ruby
shayan_ has joined #ruby
arashb has joined #ruby
ziarkaen has quit [Ping timeout: 256 seconds]
gingray has quit [Ping timeout: 244 seconds]
marxarelli is now known as marxarelli|afk
icarus has joined #ruby
ben__ has quit [Remote host closed the connection]
metalic has joined #ruby
metalic has quit [Client Quit]
Pupeno has quit [Remote host closed the connection]
ben__ has joined #ruby
djbkd has quit [Remote host closed the connection]
gusrub has quit [Remote host closed the connection]
synthroid has quit []
ben__ has quit [Remote host closed the connection]
shayan_ has quit [Quit: shayan_]
SteenJobs has quit [Read error: Connection reset by peer]
SteenJobs has joined #ruby
tdy has quit [Ping timeout: 256 seconds]
shayan_ has joined #ruby
ben__ has joined #ruby
arashb has quit [Ping timeout: 244 seconds]
dextertzu has quit [Ping timeout: 260 seconds]
funnel has joined #ruby
shayan_ has quit [Client Quit]
shayan_ has joined #ruby
bongobrown has joined #ruby
djbkd has joined #ruby
suchness has joined #ruby
whathapp_ has quit [Remote host closed the connection]
<suchness>
I am looking for something to indicate "loading" for some long running methods in rake tasks and in the console, anyone know any good ways to get a percent completion and or bar, or to add a spinner?
LeBlaaanc has joined #ruby
whathappens has joined #ruby
machinewar has joined #ruby
<cek>
how do you monkey patch an autoloading class before it loads?
<cek>
in latest ruby
hutch34 has quit [Ping timeout: 252 seconds]
xall_ has quit [Ping timeout: 260 seconds]
ramfjord_ has joined #ruby
Dimik has joined #ruby
bongobrown has quit [Remote host closed the connection]
<suchness>
The definition of monkey patching is altering a class after it loads.
<suchness>
I am going to go out on a limb and say you cant.
whathappens has quit [Ping timeout: 260 seconds]
<suchness>
Not in a sane or responsible manner.
<dminuoso>
suchness, thinking about it :D
LeBlaaanc has quit [Ping timeout: 256 seconds]
<cek>
hasnt it added callbacks when class is loaded
polyidus has joined #ruby
troys is now known as troys_
<cek>
or rather, const is defined
<suchness>
cek: Not that I am aware of.
<dminuoso>
cek, no. The closest thing that comes to mind right now is abusing set_trace_func
<suchness>
cek: Well yes, there will be a defined constant...
ramfjord has quit [Ping timeout: 260 seconds]
badpeaches is now known as flexbot
Prawnzy has joined #ruby
Prawnzy has quit [Remote host closed the connection]
<havenwood>
I'd suggest imploding RVM and installing as your deploy user. If you only need one Ruby (like you usually do in prod) consider not using a Ruby version switcher.
<DoctorMonocular>
but I failed to set up the deploy user ahead of time, and install used root mistakenly
<DoctorMonocular>
I'm all for that, but I don't know how
<havenwood>
DoctorMonocular: rvm implode --force # then turn it off and back on again
<DoctorMonocular>
run `rvm implode --force` as root?
<havenwood>
yes
<havenwood>
then restart to clear env vars
<DoctorMonocular>
buh, I'm confused -- root doesn't have rvm access, but deploy does
notes is now known as peaches
<havenwood>
See the link I pasted regarding using RVM as the root user above.
<havenwood>
It doesn't play nice with usage by root by default.
<DoctorMonocular>
yeah :/
koooge has joined #ruby
dextertzu has quit [Ping timeout: 245 seconds]
suchness has quit [Remote host closed the connection]
rcvalle has quit [Quit: rcvalle]
railssmith has joined #ruby
<DoctorMonocular>
yeah I'm stuck, I have no idea what I'm doing -- I know root is a problem, but I'm clueless here, and out of my element
<havenwood>
DoctorMonocular: What OS/distro are you on?