podman has quit [Quit: Connection closed for inactivity]
<Papierkorb>
currently tinkering with my irc bot. I want to give rules for specific URLs to look up, and i want the rule for "youtube.com" also to match "www.youtube.com". Cheating is not allowed, as services like deviantart give each user a subdomain on their own ;)
keen__________13 has quit [Read error: Connection reset by peer]
jlast has joined #ruby
<Papierkorb>
There's a short-cut for single character strings? oh man
jlast has quit [Read error: Connection reset by peer]
jlast_ has joined #ruby
swgillespie has quit [Remote host closed the connection]
Zamyatin has joined #ruby
<eam>
it doesn't concat at parse time though, which is a bummer
<eam>
>> ?? ??
<ruboto>
eam # => /tmp/execpad-151bd5a1e066/source-151bd5a1e066:2: warning: invalid character syntax; use ?\n ...check link for more (https://eval.in/393766)
<havenwood>
MagePsycho_: sudo bash -s stable <- note the sudo
<MagePsycho_>
ruboto, thanks noted
<pontiki>
i would really like to see what the problem was trying to install it without sudo
<Aeyrix>
MagePsycho_: kek
<Aeyrix>
ruboto is a bot
<MagePsycho_>
havenwood, yeah
olistik has joined #ruby
<Aeyrix>
> sudo bash
<Aeyrix>
;_;
<havenwood>
MagePsycho_: Why did you do a system install? Any reason?
<MagePsycho_>
new to ruby.. so did as per the tutorial from net
Xeago has joined #ruby
djbkd has quit [Remote host closed the connection]
<pontiki>
[20150707|0100.27] < MagePsycho_> using sudo bash.. as only bash was giving write permission error
<havenwood>
MagePsycho_: It's not recommended to install RVM with sudo or as root.
<Aeyrix>
MagePsycho_: Yeah, I'm just astounded that after all this time it's still the suggested way
<pontiki>
that was the reason i saw for using sudo bash
jsaak has quit [Ping timeout: 264 seconds]
<havenwood>
pontiki: Likely a previous system install's env vars.
arturaz has joined #ruby
hotpancakes has quit [Ping timeout: 255 seconds]
<havenwood>
MagePsycho_: implode your system install and start a completely new terminal session.
<pontiki>
havenwood: you must have more psychic power than i do
<baweaver>
Well bed for me, 'night all.
sharpmachine has quit [Ping timeout: 244 seconds]
<Aeyrix>
ciao
<havenwood>
pontiki: Just seen the problem before.
pengin has joined #ruby
baweaver has quit [Remote host closed the connection]
<pontiki>
havenwood: i'm unfamiliar with ubuntu installations that render the user's homedir inaccessible
konsolebox has joined #ruby
yardenbar has joined #ruby
<havenwood>
pontiki: Person installs RVM with sudo, decides that was a bad idea and either implodes and doesn't start a new shell session or doesn't implode, either way leaving the env vars in place that will cause a regular RVM installation to fail due to root locations.
olistik has quit [Ping timeout: 248 seconds]
<havenwood>
pontiki: Lingering sudo install screws up non-sudo install. That's all.
<MagePsycho_>
but while installing mechanize: ERROR: Error installing mechanize:
<MagePsycho_>
mime-types requires Ruby version >= 1.9.2.
thalassa has quit [Ping timeout: 256 seconds]
<havenwood>
MagePsycho_: Are you using sudo?
<MagePsycho_>
havenwood, yeah for now just for testing sudo gem install mechanize
<Aeyrix>
sudo ruby and ruby are not the same.
<havenwood>
MagePsycho_: When you do you drop the RVM env. If you want to use sudo with RVM (you most certainly don't here) you can use rvmsudo to not drop the env.
<MagePsycho_>
quickly i need to test one mechanize script for web scraping so
krz has joined #ruby
<MagePsycho_>
havenwood, OK i want to uninstall all the ruby rvm
<MagePsycho_>
havenwood, how to uninstall all
<havenwood>
MagePsycho_: Either start over with RVM and follow their installation instructions or implode it go as suggested.
<havenwood>
MagePsycho_: rvm implode
thiagovsk has quit [Quit: Connection closed for inactivity]
<pontiki>
probably have to use sudo rvm implode now...
<havenwood>
;)
<MagePsycho_>
Could not remove '/usr/share/rvm/', please try removing it manually.
<MagePsycho_>
--> :)
<havenwood>
pontiki: You mean `rvmsudo rvm implode`, as we discussed. :P
bruno- has quit [Ping timeout: 246 seconds]
pengin has quit [Remote host closed the connection]
<MagePsycho_>
rvm implode --> sudo rvm implode?
<Aeyrix>
rvmsudo
<pontiki>
what does --> mean?
<MagePsycho_>
sudo rvm implode OR rvmsudo implode
<jesterfraud>
sudo should come with a built in quiz to make sure you understand what you're doing, I know I'd fail it :P
<MagePsycho_>
which one to use
<Aeyrix>
jesterfraud: i agree
<Aeyrix>
MagePsycho_: Use the latter.
<havenwood>
MagePsycho_: rvmsudo rvm implode
<Aeyrix>
rvmsudo implode
<Aeyrix>
ya what havenwood said
<Aeyrix>
i forgot the middle bit
lee-jon has joined #ruby
jsaak has joined #ruby
<MagePsycho_>
havenwood, yeha it worked
<MagePsycho_>
now what? sudo gem insall mechanize OR ...
<sevenseacat>
ubuntu does not come with any ruby preinstalled
<Aeyrix>
sudo apt-get purge rubygems
<sevenseacat>
why did you sudo apt-get install rubygems
<Aeyrix>
sudo apt-get purge ruby rubygems
<Aeyrix>
do the second one
<Aeyrix>
then
<sevenseacat>
that would have installed a whole host of crap
<Aeyrix>
follow Ryan's guide
<Aeyrix>
then
<Aeyrix>
you're good
<Aeyrix>
you can do what you want
<MagePsycho_>
sudo apt-get install build-essential --> it has sudo ;)
<Aeyrix>
Yes, because it explicitly is mentioned.
<Aeyrix>
It's also required to install the gnu C compiler.
d0lph1n98 has quit [Quit: leaving]
acke has joined #ruby
acke has quit [Read error: Connection reset by peer]
acke has joined #ruby
<MagePsycho_>
so far so good.. installing ruby using ruby-install
<Radar>
\o/
<havenwood>
the crisp, cool breeze
fabrice31 has joined #ruby
workmad3 has joined #ruby
lee-jon has left #ruby [#ruby]
towski_ has joined #ruby
Xeago has quit [Read error: Connection reset by peer]
workmad3 has quit [Ping timeout: 244 seconds]
Musashi007 has quit [Quit: Musashi007]
<MagePsycho_>
but in my mac OSx it was working fine.. i used brew command
<MagePsycho_>
just to note :)
<sevenseacat>
we wouldnt typically recommend that on osx either.
hotpancakes has joined #ruby
lxsameer has quit [Ping timeout: 240 seconds]
Ox0dea has quit [Read error: Connection reset by peer]
<MagePsycho_>
i use mac osx at home and ubuntu at work
<MagePsycho_>
i love mac :)
<MagePsycho_>
anyway
<MagePsycho_>
>>> Successfully installed ruby 2.2.0 into /home/rajendra/.rubies/ruby-2.2.0
<ruboto>
MagePsycho_ # => /tmp/execpad-cc7154d0c89c/source-cc7154d0c89c:2: syntax error, unexpected '>' ...check link for more (https://eval.in/393917)
<sevenseacat>
hooray.
<MagePsycho_>
but ruby --version says the old
<sevenseacat>
err, what old?
<MagePsycho_>
sorry i am too fast.. need to follow other steps as well
hotpancakes has quit [Ping timeout: 250 seconds]
<Aeyrix>
MagePsycho_: Mac's p great.
<Aeyrix>
`brew install ruby` works for Mac though. ;)
Scroff has joined #ruby
<sevenseacat>
Aeyrix: why bother if you just want ruby? it comes pre-installed on osx
<Aeyrix>
sevenseacat: Older version.
<sevenseacat>
for real use we'd still recommend a ruby version manager
jlast has joined #ruby
jlast has quit [Remote host closed the connection]
<Aeyrix>
For real use I wouldn't be using OS X in production. :P
<sevenseacat>
who said anything about production?
<pontiki>
my everyday use of ruby on my mac is production
<sevenseacat>
MagePsycho_ got all the help they needed, now they just want to sit and poke fun
<neanias>
MagePsycho_: haskell script
<flughafen>
python > ruby > writing binary by hand > php
<sevenseacat>
joke's on them
<MagePsycho_>
sevenseacat, LOL.. i appreciate you help buddy
<MagePsycho_>
your* so many typos
<ddv>
buddy :p
<sevenseacat>
MagePsycho_: pretty sure the rest of us are laughing at you, not with you.
<adaedra>
Or you know, you could just stop trying to compare languages.
<MagePsycho_>
so flughafen agrees python > ruby
<neanias>
All languages are good for certain purposes
<adaedra>
^
<MagePsycho_>
neanias, thats the truth
<adaedra>
If only we had a FAQ where this was already explained.
<sevenseacat>
I'm not sure when I would ever reach for php over another language
<neanias>
I've never touched PHP
<neanias>
And I don't intend to
<neanias>
Because I don't want to
<adaedra>
A virgin :>
<neanias>
Steady
<sevenseacat>
I did it for quite a few years
arup_r has joined #ruby
<sevenseacat>
wrote more than my fair share of monstrosities
tjbiddle has quit [Quit: tjbiddle]
renderful has quit [Ping timeout: 255 seconds]
<MagePsycho_>
I am in the process of automating some thing.. and using shell script.. but since it's not so easy for web scraping.. heard about ruby's mechanize.. so thought giving a try
<MagePsycho_>
mechanize is simply the best for web scraping
<neanias>
Nokogiri
<sevenseacat>
I think mechanize uses nokogiri under the hood
<neanias>
Take out the middle man then
lee-jon has joined #ruby
<neanias>
Oh, hey
<neanias>
lee-jon
<nofxx>
ruby > python any day, any case
<ddv>
nofxx: any arguments?
<yorickpeterse>
__python__
<lee-jon>
neanias ?
<adaedra>
LOLCODE > *
<neanias>
It's Will from Cake
<nofxx>
ddv, alphabetical or my personal rank?
Ox0dea has joined #ruby
<ddv>
oh sorry I read it wrong
<Ox0dea>
adaedra: Do you know LOLCODE?
andikr has quit [Remote host closed the connection]
<adaedra>
OHAI
<nofxx>
mechanize is good if you need to interact (forms, buttons..).. iirc if you can run inside phantojs
<nofxx>
to crawl there's polipus
<adaedra>
Ox0dea: from name
<nofxx>
*you can even run inside phantom
<Ox0dea>
adaedra: Ah, okay. You should totally learn it. :)
arooni-mobile has quit [Ping timeout: 248 seconds]
<adaedra>
KTHXBYE
* flughafen
likes phantomjs
<adaedra>
uuuuuuuuuugh phantomjs
jenrzzz has quit [Ping timeout: 240 seconds]
<neanias>
I might learn some more haskell
mistermocha has joined #ruby
<flughafen>
adaedra: i take it you love phantomjs
lee-jon has left #ruby [#ruby]
ArchRogem has joined #ruby
workmad3 has joined #ruby
<adaedra>
flughafen: s/ve/athe/
* sevenseacat
goes to learn more elixir
<sevenseacat>
actually the book I'm reading uses clojure
havenwood has quit [Ping timeout: 276 seconds]
davedev24_ has joined #ruby
mistermocha has quit [Read error: Connection reset by peer]
davedev2_ has joined #ruby
<MagePsycho_>
sevenseacat, yeah nokogri is there by default in mechanize
MrQuux has joined #ruby
nofxx has quit [Ping timeout: 244 seconds]
davedev2_ has quit [Read error: Connection reset by peer]
<yorickpeterse>
phantomjs isn't too bad
mistermocha has joined #ruby
jeanlinux has joined #ruby
davedev2_ has joined #ruby
<shevy>
sevenseacat you are addicted to that elixir!
<sevenseacat>
its what keeps me looking so fresh and young.
kislak has joined #ruby
workmad3 has quit [Ping timeout: 252 seconds]
oo_ has quit [Remote host closed the connection]
<MrQuux>
Hi. I have a SOAP interface that returns an error in the form of: "de.foo.bar.SomeJavaClass: 1234: Page is dirty". I intend to match for /de\.foo\.bar\.SomeJavaClass: \d+/ and create a custom error class, where I offer an accessor for the error code, and an accessor for the actual error string ("page is dirty")
<MrQuux>
Would this be acceptable design wise?
<ddv>
ew soap
<ddv>
the java world surely likes old legacy soap stuff apis
davedev24_ has quit [Ping timeout: 248 seconds]
arturaz has quit [Remote host closed the connection]
arturaz has joined #ruby
<ddv>
MrQuux: also I have no idea what the problem is
eGGsha has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<MrQuux>
ddv: The idea of an error class that provides its own logic how to obtain error related data
PotatoCrisps has quit [Remote host closed the connection]
thalassa has joined #ruby
<bnagy>
I would reflexively do that with error subclasses
Musashi007 has joined #ruby
jlast has joined #ruby
jenrzzz has joined #ruby
<bnagy>
because it makes the rescues look prettier when people use your code
sigurding has joined #ruby
solocshaw has joined #ruby
jlast has quit [Remote host closed the connection]
krz has quit [Read error: Connection reset by peer]
oo_ has joined #ruby
eGGsha has joined #ruby
ndrei has quit [Ping timeout: 256 seconds]
jaimessi has quit [Read error: Connection reset by peer]
bronson has joined #ruby
jaimessi has joined #ruby
<adaedra>
There are gems for that
_joes_ has joined #ruby
<MagePsycho_>
adaedra, which gems you use
<adaedra>
I used yell
M-Technic has quit [Ping timeout: 244 seconds]
gambl0re has quit [Ping timeout: 256 seconds]
DLSteve has joined #ruby
Igorshp has quit [Remote host closed the connection]
krz has joined #ruby
ndrei has joined #ruby
bronson has quit [Ping timeout: 264 seconds]
jeanlinux has quit [Remote host closed the connection]
magical-imouto is now known as pyon
<shevy>
le french 'ell
konsolebox has joined #ruby
pyon is now known as magical-imouto
denver has joined #ruby
stamina has joined #ruby
willhumphreys has quit [Ping timeout: 246 seconds]
eightyeights has joined #ruby
icosa has joined #ruby
olistik has joined #ruby
_joes_ has quit [Ping timeout: 256 seconds]
_joes_ has joined #ruby
Nick_joes has joined #ruby
<_mh_>
morning. Trying to get an extconf.rb to run flex and bison, then to compile the results. (current extconf.rb: https://gist.github.com/mbbh/d11c164283bc160d43a5) Someone got any pointers for me? ( a working example would suffice )
fabrice31_ has quit [Remote host closed the connection]
magical-imouto is now known as pyon
_joes_ has quit [Ping timeout: 256 seconds]
mistermocha has joined #ruby
sharpmachine has joined #ruby
oo_ has quit [Remote host closed the connection]
konsolebox has quit [Read error: Connection reset by peer]
Alina-malina has quit [Read error: Connection reset by peer]
<MagePsycho_>
-bash: /usr/share/ruby-rvm/scripts/initialize: No such file or directory
<tobacco_joe01>
why should there be a penalty?
<neanias>
shevy: sounds about right
astrobun_ has joined #ruby
khebbie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<MagePsycho_>
whenver i do cd /path/ -> gives me the above error
jlast has joined #ruby
mistermo_ has joined #ruby
<shevy>
possibly depends on what kind of penalty. Maybe it is super slow
<Ox0dea>
No, it just doesn't look right.
<shevy>
YES
<shevy>
FINALLY :)
<Ox0dea>
-> {} and proc do end, but no mixing.
<shevy>
I shall immortalize the Oracle's statement
jlast has quit [Remote host closed the connection]
<Ox0dea>
To be clear, I have no problem with stabby lambdas.
<shevy>
It just doesn't look right.
mistermocha has quit [Ping timeout: 248 seconds]
<shevy>
I actually use {} usually
<shevy>
I liked it as visual separator
<shevy>
def bla
<shevy>
lala.each {
<shevy>
}
<shevy>
end
<Ox0dea>
Eh, I just use Weirich's rule.
<ytti>
shevy, you monster
<shevy>
ytti haha
Igorshp has joined #ruby
<shevy>
well it does not work for DSLs
chinmay_dd has quit [Ping timeout: 248 seconds]
<shevy>
in sinatra I use the do/end
sdothum has joined #ruby
<ytti>
big thing with do/end is that you need ruby specific intelligence in vim, to get '%' working
<shevy>
or just use emacs!
jenrzzz has quit [Ping timeout: 276 seconds]
<adaedra>
lolno
<apeiros>
Ox0dea: {} vs. do/end?
<apeiros>
if so: jim weirich's rule++
<neanias>
Ox0dea, what's Weirich's rule?
<neanias>
ytti: vim-ruby obvs
senayar has quit [Remote host closed the connection]
oo_ has quit [Remote host closed the connection]
senayar has joined #ruby
<Ox0dea>
apeiros: I kvetch specifically at the combination of -> and do/end, but otherwise yeah, Weirich's rule is best rule.
nettoweb has joined #ruby
k3asd` has joined #ruby
<apeiros>
but with ->, you always want the return value, therefore -> is always {} according to JW's rule :)
oo_ has joined #ruby
<Ox0dea>
No, that needn't be so.
<apeiros>
I don't know what kvetching is, though :D
<apeiros>
I'm quite curious for a case where you don't want the return value of -> ^^
oo_ has quit [Remote host closed the connection]
oo_ has joined #ruby
<apeiros>
(if you .call it -> return value, if you assign it to a variable -> return value, if you pass it to a method -> return value…)
<Ox0dea>
Not if you're passing it to a method simply for the side effects it'll have.
<Ox0dea>
Which is admittedly quite unorthodox.
lokulin has joined #ruby
<apeiros>
that's still using its return value
ndrei has quit [Ping timeout: 255 seconds]
<apeiros>
the return value of -> is the Proc instance you get
j_mcnally has joined #ruby
lkba_ has joined #ruby
<apeiros>
and passing that object is using it :)
<apeiros>
->{} doesn't have any immediate side effect. you have to invoke it. one way or another.
<Ox0dea>
I learned "kvetch" from Guy Steele's "Growing a Language" talk, in which he limited himself to words of one syllable or those he'd previously defined (using words of one syllable).
<Ox0dea>
It's basically "blech".
Zai00 has quit [Quit: Zai00]
<apeiros>
man, fuck those SAN SSL cert vendors
<apeiros>
"we sell you a SAN, but please pay up for each domain you want to add to the cert…"
konsolebox has joined #ruby
lxsameer has quit [Ping timeout: 246 seconds]
<shevy>
now this is how to make apeiros angry!
<Ox0dea>
Let's Encrypt should be interesting.
konsolebox has quit [Read error: Connection reset by peer]
<apeiros>
are they operational already?
<shevy>
SSL the world - and pay for it :)
<Ox0dea>
apeiros: Coming September.
j_mcnally has quit [Client Quit]
lkba has quit [Ping timeout: 252 seconds]
khebbie has joined #ruby
<apeiros>
fuck them. does a CNAME to an SSL certified domain name work?
<Ox0dea>
It seems that would be the crux of the operation, no?
<ljarvis>
undefined method `flap_map' for #<Array
<ljarvis>
I do this way too often
<apeiros>
flap_flap
<apeiros>
you played too much
mathie has quit [Quit: Quitting...]
mathie has joined #ruby
wpp has joined #ruby
duncannz has quit [Remote host closed the connection]
Rickmasta has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<shevy>
why won't it get in?
<agent_white>
JUST PUSH IT. PUSH IT GOOD.
<adaedra>
lewd
phutchins has joined #ruby
konsolebox has joined #ruby
blackmes1 has quit [Ping timeout: 244 seconds]
<Ox0dea>
shevy: I do think the code should be "correct" and that methods should return what they say they do, but how often does it really matter that $1-9 are always in there, or that $10+ will never be?
Igorshp has quit [Remote host closed the connection]
quazimodo has quit [Ping timeout: 255 seconds]
<adaedra>
(O)x(0)dea
<Ox0dea>
It still bugs me that $1-9 are artificially added to the result, if only because I can't hit upon the logic that made nobu do it.
<shevy>
ah I see
<shevy>
well the logic is simple!
<shevy>
$9 is two chars
<shevy>
$10 is three chars!!!!
veekram has quit [Ping timeout: 250 seconds]
<Ox0dea>
It's still a perfectly valid global variable, of course.
eGGsha has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<ddv>
rofl I have been seeing the same discussion for weeks
crazydiamond has joined #ruby
<Ox0dea>
In my defense, `ps aux` has 11 columns.
solocsha1 has joined #ruby
sgambino has joined #ruby
<neanias>
MagePsycho_: http://githut.info if you look at Q3/14, it's Python > Ruby > PHP
sgambino has quit [Client Quit]
meph has quit [Remote host closed the connection]
bronson has quit [Ping timeout: 256 seconds]
AxonetBE has joined #ruby
<AxonetBE>
I do an import of some information through csv and in my mysql database the text is : https://gist.github.com/bigbentobox/bd87b4cd22093dc54e26 You see some starts and I want to make this a html list (ul->li). I thought to use markdown -> html but as it is on the same line it is not working. What other solutions are there?
blackmes1 has joined #ruby
solocsha1 has quit [Ping timeout: 255 seconds]
willhumphreys has joined #ruby
<Ox0dea>
AxonetBE: Will your list elements ever contain asterisks?
<AxonetBE>
AxonetBE: No
Nick_joes_ has joined #ruby
<AxonetBE>
Ox0dea: No
<Ox0dea>
AxonetBE: Then a regular expression could do.
eGGsha has joined #ruby
<Ox0dea>
AxonetBE: Something along the lines of gsub(/\* ([^*]+)/, '<li>\1</li>')
<AxonetBE>
Ox0dea: I also thought about it but how to know from where to where to surround li and ul
<Ox0dea>
AxonetBE: Are the lists always going to be introduced with a colon?
Nick_joes_ has quit [Read error: Connection reset by peer]
Nick_joes_ has joined #ruby
<AxonetBE>
not sure
Igorshp has joined #ruby
Nick_joes has quit [Ping timeout: 240 seconds]
<AxonetBE>
Ox0dea: better maybe to do first the gsub(/\* ([^*]+)/, '<li>\1</li>') part and after find the first <li> and the last </li> and surround it by ul
oo_ has quit [Remote host closed the connection]
platzhirsch has left #ruby [#ruby]
veekram has joined #ruby
codecop has joined #ruby
<Ox0dea>
>> 'here comes a list * foo * bar * baz'.gsub(/\* ([^*]+)/, '<li>\1</li>').sub(/(<.*>)/, '<ul>\1</ul>')
<ruboto>
Ox0dea # => "here comes a list <ul><li>foo </li><li>bar </li><li>baz</li></ul>" (https://eval.in/394100)
<Ox0dea>
AxonetBE: ^ That would indeed do the trick, but it looks a little gnarly.
<MagePsycho_>
neanias, yeah ruby is dong good, thats why i am in #ruby channel :)
c355E3B has joined #ruby
<neanias>
Fair
<Ox0dea>
-1 for choosing Ruby because of its popularity and not on its merits as a language.
<adaedra>
-1 for getting a -1 from Ox0dea
jesterfraud has joined #ruby
codecop has quit [Remote host closed the connection]
sharpmachine has joined #ruby
tkuchiki has quit [Remote host closed the connection]
<neanias>
+1 for something
<heftig>
+√˗1 for dong
<neanias>
+i for dong?
<shevy>
ding dong ding dong!
<Ox0dea>
Shame.
<AxonetBE>
Ox0dea: problem with my text https://eval.in/394103 don't see from where it comes
cek has joined #ruby
<heftig>
don't support the oppression of the number line!
<heftig>
wake up, realpe!
<cek>
Hi. Need json formatter with color (html) for our support dept.
<jhass>
cek: highlight.js
rodfersou has joined #ruby
sharpmachine has quit [Ping timeout: 264 seconds]
bruno- has quit [Ping timeout: 264 seconds]
Scroff has quit [Ping timeout: 246 seconds]
<Ox0dea>
AxonetBE: You'll need to put the "m" flag (multi-line) on your regular expressions.
<superrorc>
shevy: ow . that is i need! thanks a lot!
mutuma has joined #ruby
<shevy>
yeah rubular is awesome for finding regexes
<superrorc>
yea! and for what need 2d fiels?
t3k has joined #ruby
mutuma has quit [Client Quit]
<superrorc>
like / reg ex / / here ?
zacstewart has joined #ruby
<shevy>
hmm where do you see that
astrobun_ has quit [Remote host closed the connection]
platzhirsch has joined #ruby
<yorickpeterse>
Does Sinatra have a way to customize what regular expressions it generates for named parameters in paths? e.g. "/:id" results in basically /\/([^/?#]+)/ but I want it to use a different pattern (e.g. /\/(\d+)/)
<shevy>
I only see / foo /
sa233sad has quit [Quit: leaving]
<ljarvis>
yorickpeterse: I think you can use named captures?
hoofed has joined #ruby
<yorickpeterse>
ljarvis: Yes, so here's the problem:
<yorickpeterse>
I can't use regular expressions as paths because we use the paths in our documentation
<ljarvis>
yes that does seem like a problem
<yorickpeterse>
and "/:id" reads way better than /\d(?<id>\d+)/
<yorickpeterse>
errr
<yorickpeterse>
that should be /\/(?<id>\d+)/
<yorickpeterse>
We use the paths so people actually know where to send their stuff to
michael_mbp has quit [Excess Flood]
millerti has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Scroff has joined #ruby
_ixti_ has joined #ruby
khebbie has joined #ruby
<yorickpeterse>
hrmpf, looking at the code I'll have to hack this in
Zai00 has joined #ruby
ixti has quit [Ping timeout: 265 seconds]
zeeraw has joined #ruby
mandarinkin has joined #ruby
michael_mbp has joined #ruby
balazs has joined #ruby
zeeraw has quit [Client Quit]
zeeraw has joined #ruby
last_staff has quit [Remote host closed the connection]
<yorickpeterse>
and thanks to Ruby for actually exposing Regex named captures in a Regexp instance
<[k->
noice :3
varunwachaspati has quit [Ping timeout: 255 seconds]
<yorickpeterse>
From the rdoc:
<[k->
there aren't any - tho
<yorickpeterse>
If there are no named captures, an empty hash is returned.
<[k->
how does that work
<yorickpeterse>
/(.)(.)/.named_captures
<yorickpeterse>
somebody had a giggle there I Think
<[k->
ahh different base
<[k->
((.).(.).(.)) is legit haskell
<Ox0dea>
.().().().().() is legit Ruby.
<[k->
that is nothing special
<Ox0dea>
You're right.
<[k->
:>
varunwachaspati has joined #ruby
<yorickpeterse>
Ox0dea: it's not
<Ox0dea>
yorickpeterse: It is.
<yorickpeterse>
>> .().().().().()
<ruboto>
yorickpeterse # => /tmp/execpad-17b24de75791/source-17b24de75791:2: syntax error, unexpected '.' ...check link for more (https://eval.in/394153)
RegulationD has joined #ruby
<yorickpeterse>
it's not
<Ox0dea>
yorickpeterse: I didn't mean by itself.
<yorickpeterse>
suuuuuure
<Ox0dea>
You'd obviously need to call it on a lambda that returned a lambda that returned a lambda...
<[k->
>> class A def .call; self end end; A.new.().().().().().().()
<ruboto>
[k- # => /tmp/execpad-2d3980cd969a/source-2d3980cd969a:2: syntax error, unexpected keyword_def, expecting '<' ...check link for more (https://eval.in/394154)
<Ox0dea>
The language's original aesthetic, insofar as it could be said to have such a thing, has certainly become unorthodox, but I suppose that's for the better; a language is its ecosystem, after all.
but3k4 has joined #ruby
y0da has quit [Read error: Connection reset by peer]
<yorickpeterse>
yay I wrote a regex to parse/find/replace regexes
<yorickpeterse>
Hm, it would be nice if you could do something like X.gsub(/%r(.)|$1/, '')/
<yorickpeterse>
errr
<yorickpeterse>
X.gsub(/%r(.)|$1/, '')
<yorickpeterse>
which would replace "%r{" and "}" with ''
<yorickpeterse>
or "%r(" and ")"
<[k->
but that would break pita
<[k->
pola
<[k->
err what was the acronym?
<Ox0dea>
It was "surprise" long before "astonishment", I think.
jhwhite has joined #ruby
<Burgestrand>
yorickpeterse: and it would automatically figure out that the closing brace of ( or { is ) or }? :O
fabrice31 has quit [Remote host closed the connection]
<yorickpeterse>
Yes
<yorickpeterse>
magic
<Ox0dea>
require 'dwim'; DWIM.dwim
<Burgestrand>
Magic is scary
tmi has quit [Ping timeout: 256 seconds]
hotpancakes has joined #ruby
paulcsmith has joined #ruby
iwishiwerearobot has joined #ruby
<Burgestrand>
I just found this http://installrails.com/ — it's nice to have a how-to install guide. Are there any more similar to this somewhere else?
<fenjamin>
hi, is there a better place to talk about json?
mistermocha has joined #ruby
<[k->
is this a bad place? :(
<jhass>
fenjamin: what's there much to talk about? it's just a serialization format
<Ox0dea>
What's the best cerealization format?
<Ox0dea>
libcheerios?
<adaedra>
.
Bitcrusher01 has joined #ruby
christiandsg has quit [Ping timeout: 265 seconds]
<[k->
.
dangerousdave has joined #ruby
stantonnet has quit [Remote host closed the connection]
<shevy>
yum, cereals
avril14th has joined #ruby
<Ox0dea>
-1 for not being able to count higher than two.
<[k->
were we counting?
<Bitcrusher01>
Hi guys, I'm a Ruby user and have a question that Google can't seem to answer for me
fgo has quit [Quit: WeeChat 1.1.1]
zz_Outlastsheep is now known as Outlastsheep
<Ox0dea>
Bitcrusher01: Try one more time.
<fenjamin>
i want activity to update across servers
<jhass>
Bitcrusher01: sup girl?
<jhass>
fenjamin: trying to make a record in being vague?
sharpmachine has joined #ruby
<[k->
Ox0dea you are too impatient, he could be typing out his question!
<[k->
that's how irc works
<Ox0dea>
[k-: No, I meant that Google can be finicky that way.
<[k->
we split it over many lines
charliesome has joined #ruby
<Ox0dea>
Sometimes you just need to ask it again.
<Bitcrusher01>
How do I use a variable to access a hash key? What works for me is: config[:network_interfaces]
<fenjamin>
i can think of this for myself but i would a but of clarity
<[k->
you are ambiguous then!
<shevy>
Bitcrusher01 that is a symbol though
mary5030 has joined #ruby
<shevy>
if you really need it a var: var = :network_interfaces; config[var]
<fenjamin>
when a transaction occurs, i would like the charts to update on all servers
willhumphreys has quit [Ping timeout: 246 seconds]
mary5030 has quit [Remote host closed the connection]
<Ox0dea>
fenjamin: And you think this is a task for JSON?
jpfuentes2 has joined #ruby
nettoweb has joined #ruby
<Bitcrusher01>
but the subkey of that has is a variable, and I've tried various combinations to access it: config[:network_interfaces]["#{name}"], config[:network_interfaces][:name] and other variations, with no luck
mary5030 has joined #ruby
paulcsmith has quit [Quit: Be back later ...]
malconis has joined #ruby
<Bitcrusher01>
shevy: i've tried using config[:network_interfaces][name.to_s] on it as well
<[k->
no, no, its a task for ajax! /s
<Ox0dea>
Could be, though.
<adaedra>
.to_s will give you a string, you want a symbol, Bitcrusher01
symbol has quit [Ping timeout: 256 seconds]
<Ox0dea>
Depends on what her Hash actually looks like.
<[k->
Bitcrusher01, symbols and strings are not the same
<adaedra>
you need to use .to_sym to obtain a symbol
<Ox0dea>
Bitcrusher01: Are you able to post the Hash you're trying to key into?
<jhass>
Bitcrusher01: where does name come from and what does it contain
<fenjamin>
i'll do some more homework and come back when the weather's better
<[k->
we know she uses symbols as keys!
ESpiney has joined #ruby
<fenjamin>
you guys going to be around?
<Ox0dea>
?guys
<ruboto>
we're not all guys - while you probably don't meant to be exclusive, not everybody feels that way. Maybe consider using "folks", "y'all" or "everyone" instead?
<[k->
not me
zacstewart has quit [Remote host closed the connection]
<Bitcrusher01>
name is the result of a each loop, that has an array of all network interfaces (eth0, eth1, wlan0, etc)
sharpmachine has quit [Ping timeout: 252 seconds]
NeverDie has joined #ruby
<yorickpeterse>
We were all planning on leaving this channel at 17:00
willhumphreys has joined #ruby
failshell has joined #ruby
<Ox0dea>
yorickpeterse: UGT?
<[k->
yes, and its personal time!
<jhass>
yorickpeterse: please, use space time. don't assume we're all from earth
<fenjamin>
i'll be back a little after that - give you time to leave:-)
<Burgestrand>
Sangrias at my place.
leonardoajim has joined #ruby
<jhass>
?code Bitcrusher01
<ruboto>
Bitcrusher01, We can't help you without your code, please post it to https://gist.github.com
<yorickpeterse>
jhass: pretty sure none of us in here are in the ISS
dangerousdave has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
sideshowcoder has joined #ruby
<[k->
I knew that!
tvw has quit [Ping timeout: 252 seconds]
zacstewart has joined #ruby
JoshL has joined #ruby
tmtwd has quit [Remote host closed the connection]
RegulationD has quit [Ping timeout: 248 seconds]
di3soft has joined #ruby
dangerousdave has joined #ruby
di3soft has quit [Remote host closed the connection]
di3soft has joined #ruby
<shevy>
hmm when do I use .force_encoding and when do I use .encode
tmtwd has joined #ruby
<Bitcrusher01>
Ox0dea: I've tried puts config[:network_interfaces][name.to_sym], but it does not work
<Burgestrand>
shevy: source.force_encoding(target) is used when the source is already in the target encoding, but ruby doesn't know it yet.
<shevy>
aha
hinbody has joined #ruby
<[k->
are you not using UTF-8? Monster!
<shevy>
very strange
<Burgestrand>
shevy: source.encode(target) is used when the source is in some encoding, and you want ruby to change the data to turn it into the target encoding.
mistermocha has quit [Read error: Connection reset by peer]
<shevy>
[k- actually I do have to use UTF-8 as well now :(
<Ox0dea>
Bitcrusher01: Does config[:network_interfaces][:eth0] work?
di3soft has quit [Client Quit]
<[k->
Bitcrusher01, replace Hash#[] with Hash#fetch
<shevy>
[k- ruby-gnome uses it internally and yaml require it as well
<[k->
shevy of course they do!
<[k->
you monster!
devdazed has joined #ruby
tvw has joined #ruby
<Bitcrusher01>
Ox0dea: yes it does
<Burgestrand>
Bitcrusher01: I believe it'll be easier to help you if you post an example that can be run that is failing for you. Try to keep it short.
<Bitcrusher01>
[k-: I don't know you mean by that
<shevy>
Burgestrand when you handle encoding-related issues, do you ever find yourself to have to do: force_encoding() and also encode() at the same time, or in the same program?
<Burgestrand>
Bitcrusher01: as in, not just the hash, but an actual runnable example.
<Burgestrand>
shevy: yes, for example if data is coming from somewhere and the encoding associated with that string is wrong.
charliesome has quit [Quit: zzz]
<shevy>
ah ok
pullphinger15 has joined #ruby
<[k->
I mean to replace all the object[name.to_sym] with object.fetch(name.to_sym)
<Burgestrand>
shevy: consider for example, you have data coming in from some websocket gem, in encoding BINARY. You *know* that the data coming in is ALWAYS in Latin-1, but you want it in UTF-8.
eGGsha has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
mistermocha has joined #ruby
Channel6 has joined #ruby
Igorshp has joined #ruby
whippythellama has joined #ruby
sngeth has joined #ruby
<Burgestrand>
shevy: in which case you would do: websocket.read.force_encoding("ISO-8859-1").encode("UTF-8")
<Bitcrusher01>
Burgestrand: i currently relies heavy on server_spec and other libs - I'll try to make it independent of it...
<Ox0dea>
Bitcrusher01: Debug print the value of `name` and ensure it doesn't contain any leading or trailing spaces.
theery has joined #ruby
<shevy>
ok!
pullphinger15 has quit [Client Quit]
ledestin has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Burgestrand>
shevy: I guess another name for #force_encoding could have been #encoding= :)
Guest54365 has quit [Changing host]
Guest54365 has joined #ruby
<shevy>
[k- do your chinese symbols work in UTF-8?
Guest54365 is now known as starship
* [k-
withdraws
<[k->
yes they do
<shevy>
:)
jvrmaia has quit [Ping timeout: 264 seconds]
duggiefresh has joined #ruby
icebourg has joined #ruby
duggiefresh is now known as Guest80357
decoponyo has joined #ruby
Guest80357 has quit [Remote host closed the connection]
pullphinger has quit [Client Quit]
icebourg has quit [Client Quit]
pullphinger has joined #ruby
anisha has joined #ruby
denver has quit [Read error: Connection reset by peer]
varunwachaspati has quit [Ping timeout: 240 seconds]
pandaant has joined #ruby
bruno- has quit [Ping timeout: 246 seconds]
decoponio has quit [Ping timeout: 264 seconds]
theery has quit [Remote host closed the connection]
joonty has joined #ruby
rbennacer has joined #ruby
tvw has quit [Ping timeout: 252 seconds]
hotpancakes has joined #ruby
quazimodo has joined #ruby
eGGsha has joined #ruby
darkf_ has joined #ruby
charliesome has joined #ruby
yeticry has quit [Ping timeout: 250 seconds]
Scroff has quit [Remote host closed the connection]
<Bitcrusher01>
Ox0dea: sorry, was just called away
mistermocha has quit [Ping timeout: 256 seconds]
jpfuentes2 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
khebbie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<Bitcrusher01>
Ox0dea: it's not a problem when I have string - it's a problem when I have a variable containing a string, I want to convert to a symbol
<ruboto>
Ox0dea # => /tmp/execpad-0a16c09770ba/source-0a16c09770ba:2: [BUG] Segmentation fault at 0x0565f2 ...check link for more (https://eval.in/394323)
<Ox0dea>
Well, that didn't go well.
dopie has joined #ruby
inoic has joined #ruby
yeticry has quit [Ping timeout: 255 seconds]
<neanias>
kek
eggoez has joined #ruby
<Ox0dea>
[k-: I thought maybe the class-changing trick from the other day would work to turn numbers into the Symbol at that address.
christiandsg has joined #ruby
senayar has quit [Remote host closed the connection]
<[k->
ah
yeticry has joined #ruby
balazs has joined #ruby
<Ox0dea>
Symbols really do get "internalized"; they don't behave like normal objects at all.
senayar has joined #ruby
JDiPierro has quit [Remote host closed the connection]
<Ox0dea>
Internally, pretty much every object's "root" is an RBasic construct containing flags and the object's class, but not Symbols.
<Ox0dea>
That's not turning a String into a Symbol, though.
<inoic>
just wondering if the convention in Ruby for `a < 1000` is `a < 1_000` — is 1_000 preferred? I'm doing the full stack track at Bloc.io and that's how they write 1000, 2000, etc.
hinbody has joined #ruby
<[k->
wellllllllll
<Ox0dea>
inoic: Doesn't strike me as very idiomatic.
<inoic>
Yeah me neither, I mean 1000 is certainly more readable.
Bitcrusher01 has quit [Ping timeout: 246 seconds]
<Burgestrand>
inoic: for larger numbers I do it, but 1000 is a bit too low.
<Ox0dea>
> Add underscores to large numeric literals to improve their readability.
<Ox0dea>
That's all the style guide's got to say on it.
bmurt has quit [Ping timeout: 276 seconds]
<inoic>
Burgestrand: I guess they're just trying to introduce a convention and use 1000 as an example.
<ruboto>
[k- # => [[#<IOError: stream closed>, #<NoMemoryError: failed to allocate memory>, #<SystemStackError: stack ...check link for more (https://eval.in/394377)
<shevy>
if we have a file called foo.rb and one module is in it called module Bar; end, how would you let ruby know that this is the main namespace/constant of that file?
<Burgestrand>
Could it be the random seed?
<[k->
require "foo"; Bar
<shevy>
[k- but you know the name!
<Burgestrand>
shevy: what do you mean by main?
<shevy>
I have a module here which has lots of array constants
Azulinho has joined #ruby
* yorickpeterse
just realized it's Burgestrand and not Burgerstand
<shevy>
so for me it works fine; but it should also support loading custom .rb files
<neanias>
yorickpeterse: he's beachy
<shevy>
yorickpeterse yeah I get hungry when I read his nick
<Burgestrand>
yorickpeterse: it's a common mistake :)
<shevy>
also mozzarella makes me hungry and pizzaops
<[k->
ahh a problem I have tackled before
<shevy>
burgers?
<agent_white>
[k-: Pizza problem?!
<Burgestrand>
I'd like to open a burgerstand once. It'd be called Burgestrands Burgerstand
Nick_joes_ has joined #ruby
<shevy>
haha
<[k->
the constants
<pizzaops>
Why have I been summoned?
<pizzaops>
* adaedra
noms pizzaops
<jhass>
shevy: ruby has no concept of filename to constant mapping
<[k->
so u have polynomial/ten.hs it would expect Polynomial.Ten
Outlastsheep is now known as zz_Outlastsheep
<adaedra>
huehue
<yorickpeterse>
but what about continuous integration and deployments of the pizza?
<shevy>
[k- ok I guess that can be the same as in ruby... so people should write foo.rb and have module Foo or class Foo, rather than module Bar inside
<yorickpeterse>
also I hope those pizzas come with tests
<shevy>
how do you test a pizza?
<[k->
but the compiler expects it to be like that
<[k->
if it is not, it errors
<yorickpeterse>
shevy: pizzaspec
<pizzaops>
Those are not as punny so who cares.
<pizzaops>
PunOps
<adaedra>
shevy: you never tested a pizza? D:
<shevy>
[k- hmm... so it is more strict than in ruby
eGGsha has joined #ruby
<[k->
yes, it is compiled afterall
<shevy>
adaedra hawaii pizza... I am undecided whether I can eat it or not
icflournoy has quit [Ping timeout: 244 seconds]
Nick_joes has quit [Ping timeout: 244 seconds]
<[k->
and statically typed
<pizzaops>
Hawaiian pizza is the work of Satan.
<[k->
?ot
<ruboto>
this seems to be off-topic. Please move your discussion to #ruby-offtopic, to keep this channel free for Ruby related problems. Thanks!
<shevy>
here is the pizza expert :)
<shevy>
[k- it's his nick!!!
* agent_white
coughs
<[k->
^
sharpmachine has joined #ruby
<shevy>
bad pizza for agent_white
<yorickpeterse>
Pizza hawaii isn't that bad
<yorickpeterse>
if you're a monster
Kully3xf has joined #ruby
<agent_white>
I make pizza for a living. I accept your PM's as I provide pizza-consulting.
<adaedra>
:|
christiandsg has quit [Remote host closed the connection]
<shevy>
really agent_white?
DLSteve has joined #ruby
solocsha1 has joined #ruby
<agent_white>
shevy: Hm. No the pizza consulting is a lie.
<pizzaops>
PIZZA IS NEVER OFF TOPIC. Ok, I'm done derailing now. Sorry [k-
<adaedra>
agent_white: pics or it didn't happened.
<agent_white>
But yes, I do roll pizza for a job.
<shevy>
cool
christiandsg has joined #ruby
<yorickpeterse>
Do the pizzas also come with built-in error reporting?
<agent_white>
shevy: No it's awful.
<yorickpeterse>
and Slack integration?
<agent_white>
But that's ok.
<shevy>
pizza rolling AND ruby coding
icflournoy has joined #ruby
<agent_white>
Hm. I roll pizza so I can learn ruby. :)
<adaedra>
pizzaops: you can derail #ruby-offtopic. Or at least you can try.
<[k->
pizzas activate the taste buds in your mouth
intinig has quit [Remote host closed the connection]
<neanias>
Damn
<neanias>
Now I want me some pizza
<[k->
it will raise an error if it is disgusting
<adaedra>
erf
<neanias>
>> raise "Pizza isn't good enough"
<ruboto>
neanias # => Pizza isn't good enough (RuntimeError) ...check link for more (https://eval.in/394397)
arturaz has quit [Ping timeout: 240 seconds]
<shevy>
[k- can we describe a living system in ruby?
<[k->
neanias, fail pls
<pizzaops>
Yeah but we can't just test in production. That's like saying the website won't load if we have an error in our syntax. Technically true?
ta has quit [Remote host closed the connection]
<neanias>
[k-: I do what I want
<shevy>
I guess you can fail and exit or fail and continue
<shevy>
like erlang!
<shevy>
they accepted that things are not perfect
DLSteve has quit [Client Quit]
<[k->
>> fail "I am better"
<ruboto>
[k- # => I am better (RuntimeError) ...check link for more (https://eval.in/394402)
<agent_white>
[k-: My first ever switch statement in ruby checked pizza toppings. If you gave it mushrooms it said "ICK"!
<agent_white>
So yes, this is possible.
mistermocha has quit [Read error: Connection reset by peer]
<sevenseacat>
smart switch statement. i hate mushrooms.
<shevy>
cats just don't like mushrooms
<agent_white>
sevenseacat: \o
<neanias>
Can't stand mushrooms either
intinig has joined #ruby
<slash_nick>
shevy: must be composed of cells (can do); has different levels of organization (tissues, organs, etc); uses energy; responds to its environment (responds to stimulus); grows; reproduces; traits change in adapting to environment...
<ruboto>
Ox0dea # => "{\"address\":\"0x42173fa8\", \"type\":\"BIGNUM\", \"class\":\"0x42171014\", \"frozen\":true, \"mems ...check link for more (https://eval.in/394404)
<shevy>
slash_nick ok but there is cell-cell(s) communication too
<Ox0dea>
Burgestrand: I had hoped that would be more insightful.
RobertBirnie has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jpfuentes2 has joined #ruby
pullphinger has quit []
<Ox0dea>
yorickpeterse: I think perhaps you've mistaken the magical butterfly key for the actual Any key at the top left.
<yorickpeterse>
I'm sure as hell not going to replace my current topre keys with that
<yorickpeterse>
Ox0dea: oh lol
<yorickpeterse>
I completely missed that
sharpmachine has joined #ruby
<yorickpeterse>
sweet, everybody is leaving the office
casadei has quit [Remote host closed the connection]
<yorickpeterse>
that means the last donuts are mine
ZoanthusR has joined #ruby
varunwachaspati has joined #ruby
<neanias>
yorickpeterse: lucky you
towski_ has joined #ruby
<neanias>
With the doughnuts
a346 has joined #ruby
Xeago has joined #ruby
Ilyas has joined #ruby
<yorickpeterse>
2 people left, heart pounding
<yorickpeterse>
*heavy breathing*
<[k->
just grab them all
<yorickpeterse>
then people will complain I ate them all
<neanias>
Hoard them
yardenbar has quit [Quit: Leaving]
momomomomo has quit [Quit: momomomomo]
platzhirsch has quit [Read error: Connection reset by peer]
quimrstorres has joined #ruby
Sehryn has joined #ruby
pleiosaur has quit [Remote host closed the connection]
pleiosaur has joined #ruby
Igorshp has quit [Read error: Connection reset by peer]
rehat has joined #ruby
<[k->
you were planning to eat them all anyway
Igorshp has joined #ruby
momomomomo has joined #ruby
wallerdev has joined #ruby
gagrio has quit [Ping timeout: 276 seconds]
platzhirsch has joined #ruby
Scroff has quit [Remote host closed the connection]
j_mcnally has joined #ruby
<yorickpeterse>
Yes but if everybody leaves I can just pretend I didn't do it
<[k->
might as well
<yorickpeterse>
I can just blame it on gnomes
<[k->
but you are the last one!
theery has joined #ruby
<yorickpeterse>
Yessss, they're leaving
<yorickpeterse>
hey did you just call me a gnome?
<agent_white>
"I wish they made a cinnamon roll incense because I don't always have time to make a pan. Perhaps I'd rather light a stick and then have my roommates wake up with false hopes."
Agoldfish has joined #ruby
<[k->
say you are feeling giddy and need sugar to boost your blood sugar
k3asd` has quit [Ping timeout: 252 seconds]
Xeago has quit [Remote host closed the connection]
<adaedra>
yorickpeterse: the place you work in seems interesting.
<[k->
do you wish to be addressed as a gnome
Meow-J has quit [Quit: Connection closed for inactivity]
<shevy>
pick gnome or troll
zendrix has joined #ruby
avril14th has joined #ruby
<shevy>
or a gnoll!
<adaedra>
he prefers to be addressed as a kde, I'm sure.
* adaedra
flees
<[k->
kde?
CloCkWeRX has quit [Quit: Leaving.]
<slash_nick>
shevy: gromeroll?
InternetFriend has joined #ruby
Igorshp_ has joined #ruby
<yorickpeterse>
I'm actually an xfce user
<adaedra>
oooh
Igorshp has quit [Read error: Connection reset by peer]
<Senjai>
Design patterns is literally an encyclopedia of patterns
<Senjai>
with examples
<symbol>
Oh spiffy
Xeago has quit [Remote host closed the connection]
<Senjai>
Just get all of them really
<Senjai>
Also Refactoring by Martin Fowler is great too
<symbol>
I have the workbook
<symbol>
It was over my head when I first read it
hahuang65 has joined #ruby
shinnya has joined #ruby
towski_ has quit [Remote host closed the connection]
<symbol>
Senjai: Thanks for redirecting my money ;)
willhumphreys has joined #ruby
pyrotecnix has quit [Quit: WeeChat 0.4.2]
dcunliffe has joined #ruby
<Senjai>
symbol: Feel free to send some my way, I won't complain :P
varunwachaspati has quit [Ping timeout: 276 seconds]
mistermocha has quit [Read error: Connection reset by peer]
zendrix has quit [Remote host closed the connection]
dcunliffe has quit [Client Quit]
<[k->
shevy, quite okay. but I'm a critic of interfaces :>
finisherr has quit [Quit: finisherr]
mistermocha has joined #ruby
<shevy>
yeah, I am just glad it runs without erroring for now
<[k->
who reads books :/
<[k->
who even has time
<[k->
I has no time
<Aria>
People who commute by train.
<Aria>
And people who like to learn the durable parts of our craft.
<[k->
I commute by bus and I read Haskell :o
<shevy>
Aria is a trainee! someone who travels by train
<[k->
learn by conferences!
<symbol>
I generally wake up early to get 1-2 hours of tech reading done.
<[k->
I only watched the railsconf2014 half way
<[k->
symbol:
c_nick has joined #ruby
zendrix has joined #ruby
hotpancakes has joined #ruby
finisherr has joined #ruby
hotpanca_ has joined #ruby
hotpancakes has quit [Remote host closed the connection]
<symbol>
Heh...you asked who even has time.
JoshL has quit [Read error: No route to host]
spider-mario has joined #ruby
JoshL has joined #ruby
Xeago has joined #ruby
prettiestPony11 has joined #ruby
Zai00 has quit [Quit: Zai00]
mistermocha has quit [Ping timeout: 248 seconds]
anisha has quit [Ping timeout: 256 seconds]
Gadgetoid has joined #ruby
Jackneill has joined #ruby
jonathanwallace has quit [Quit: Leaving.]
paulcsmith has joined #ruby
veekram has quit [Quit: Lost terminal]
chipotle has joined #ruby
<[k->
you have time, I has school :(
<shevy>
you'll become smarter every day because of school!
t3k has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<shevy>
and then you'll be a millionaire
<[k->
poor shevy missing out :c
<[k->
has you been schooled
rcvalle has joined #ruby
<chipotle>
good afternoon
willhumphreys has quit [Ping timeout: 264 seconds]
<[k->
your answer: very yes/yes/no/absolute no
bronson has joined #ruby
gamename has joined #ruby
<c_nick>
Hi my application is using active records for database connectivity to get database table entries the function uses where method passing each and every column name with last one an object of database
RegulationD has quit [Remote host closed the connection]
varunwachaspati has joined #ruby
<c_nick>
I don't know how to get db entries with query having like
sarkyniin has quit [Ping timeout: 265 seconds]
jonathanwallace has joined #ruby
<shevy>
[k- sure but I was very lazy
Xeago has quit [Remote host closed the connection]
<[k->
your reply does not match the tailored responses
JDiPierro has joined #ruby
<[k->
pls try again
lee-jon has quit [Quit: lee-jon]
yfeldblum has joined #ruby
<shevy>
I was extremely lazy
dopie has quit [Quit: This computer has gone to sleep]
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<[k->
your responses cannot be recognised, pls give a number instead (yes 1 - 4 no)
rbennacer has quit [Remote host closed the connection]
j_mcnally has joined #ruby
InternetFriend has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Soda has joined #ruby
Igorshp_ has quit [Remote host closed the connection]
rodfersou is now known as rodfersou|lunch
* [k-
boops shevy
<shevy>
In fact I was so lazy that the metric system has no way of measuring that kind of laziness
<shevy>
just like the dudedudeman here
wallerdev_ has joined #ruby
<dudedudeman>
hey now!
solocshaw has joined #ruby
<dudedudeman>
i can measure stuff
djbkd has joined #ruby
<[k->
c_nick have you finished your question? we are still waiting
<dudedudeman>
might take some time though. gotta work it in to my schedule
Spami has joined #ruby
<[k->
but you can't measure how much time it would take
varunwachaspati has quit [Ping timeout: 264 seconds]
Kn|t3 has joined #ruby
kotk_ has joined #ruby
woodennails has joined #ruby
Kn|t3 has left #ruby [#ruby]
kotk has quit [Ping timeout: 246 seconds]
Igorshp has joined #ruby
Kricir has joined #ruby
solocshaw has quit [Ping timeout: 255 seconds]
InternetFriend has joined #ruby
GitGud has quit [Ping timeout: 246 seconds]
bluOxigen has quit [Ping timeout: 250 seconds]
sarkyniin has joined #ruby
chthon has quit [Ping timeout: 244 seconds]
varunwachaspati has joined #ruby
niemcu has joined #ruby
Antiarc has joined #ruby
Igorshp has quit [Remote host closed the connection]
j_mcnally has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
hotpanca_ has quit [Remote host closed the connection]
Synthead has joined #ruby
Scroff has quit [Remote host closed the connection]
konsolebox has quit [Quit: Leaving]
RobertBirnie has joined #ruby
failshell has joined #ruby
arooni-mobile has joined #ruby
Contigi has joined #ruby
JDiPierro has quit [Remote host closed the connection]
havenwood has quit [Ping timeout: 250 seconds]
failshell has quit [Remote host closed the connection]
intinig has quit [Remote host closed the connection]
<c_nick>
[k- yes
failshell has joined #ruby
sdothum has quit [Quit: ZNC - 1.6.0 - http://znc.in]
bmurt has joined #ruby
parabolize has joined #ruby
<[k->
but your sentence isn't complete
dangerousdave has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
dumdedum has quit [Ping timeout: 250 seconds]
psy_ has quit [Read error: Connection reset by peer]
bruno- has quit [Quit: Lost terminal]
MatrixBridge has quit [Ping timeout: 256 seconds]
<Senjai>
I forget
<Senjai>
what's faster, set#include? or array#include?
<[k->
set
<jhass>
Senjai: what's faster, Array#include? or Hash#has_key?
<Senjai>
As well as for all set related operations, like unions etc
<[k->
has_key?
kotk has joined #ruby
<Senjai>
jhass: I would imagine the latter.
bruno- has joined #ruby
<Senjai>
I was just double checking
<[k->
the latter is definitely faster
<jhass>
exactly, O(n) for array, O(1) for hash key lookup
<jhass>
and Set is just a wrapper around a hash without values
<[k->
^
<eam>
but not has_value? :)
havenwood has joined #ruby
<[k->
sets are collection of values
<[k->
so no.
<[k->
well not exactly :)
kotk_ has quit [Ping timeout: 252 seconds]
platzhirsch has left #ruby [#ruby]
hotpancakes has joined #ruby
psy_ has joined #ruby
MatrixBridge has joined #ruby
astrobun_ has joined #ruby
peter_paule has joined #ruby
zeeraw has quit [Quit: My iMac has gone to sleep. ZZZzzz…]
thiagovsk has quit [Quit: Connection closed for inactivity]
jcdesimp has quit [Remote host closed the connection]
eggoez has quit [Ping timeout: 248 seconds]
werelivinginthef has quit [Read error: Connection reset by peer]
hotpancakes has quit [Ping timeout: 265 seconds]
werelivinginthef has joined #ruby
hotpancakes has joined #ruby
freerobby has quit [Quit: Leaving.]
kinduff has joined #ruby
astrobun_ has quit [Ping timeout: 240 seconds]
Timba-as has quit [Quit: Be back later ...]
JDiPierro has joined #ruby
<cout>
jhass: Hash#has_key? isn't _quite_ O(1) due to the cost of the computation of the hash, so the answer to the question of whether Array#include? or Hash#has_key? is faster depends partly on the hash function, but yeah, saying Hash#has_key? is faster is a good rule of thumb
icebourg has quit []
peter_paule has quit [Ping timeout: 264 seconds]
helpa has quit [Remote host closed the connection]
helpa has joined #ruby
griffindy has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<jhass>
if your hash function is really really bad and throws everything into the same bucket it's O(n) too, but then you fucked up
JDiPierro has quit [Remote host closed the connection]
<canton7>
a very very very rough rule of thumb is that arrays are cheaper for fewer than around 10ish elements
<eam>
cout: it's exactly O(1) because it doesn't change based on the size of the dataset
JDiPierro has joined #ruby
<canton7>
3 elements? array's probably quicker. 300 elements? go with a hash
<eam>
a hash lookup has the same cost whether there are 1 or 1 million elements
<jhass>
but what's said with O(n) vs O(1) is that for the hash the bigger it gets, the lookup time stays roughly constant, while for an array it grows liner with size
<hanmac>
shevy: Color, Point, Rect and Size now has #hash methods and eql? is an alias for == for them, and i already add them into the specs
<jhass>
*linear
theery has quit []
<cout>
eam: you're ignoring the cost of the hash function when you say that. The cost could be thought of as O(m) for string keys where m is your string length.
dangerousdave has joined #ruby
<eam>
cout: the entire definition of big-O notation is that it ignores those things
<eam>
that's what the symbol means
JDiPierro has quit [Remote host closed the connection]
joneshf-laptop has joined #ruby
<eam>
it tracks the change in computation cost as a function of data size
eggoez has joined #ruby
<eam>
there are plenty of O(1) algorithms which are slower than O(n) or slower than O(n^2)
<eam>
the formula describes the rate of change - not the efficiency
herbst has joined #ruby
<Senjai>
Uhm
<jidar>
for specific datasets
<eam>
jidar: yes
<Senjai>
I need a flat_map, that also somewhat behaves like an inject
ndogz has joined #ruby
<Senjai>
thing.flat_map{...}.inject(&:|) is what I'm seeing now
<herbst>
hi, any ideas how i could stop to_json to make things like "-2165370312541948811" out of sha3 hashes?
<Senjai>
and I dont like it
<cout>
eam: I don't believe that is correct; the string length is an observation of the data size.
<eam>
jidar: of course we could concoct an algorithm that's O(1) and never finishes :)
<Antiarc>
cout: The hash key computation time may be O(n), but n for the purpose of hash lookups is the number of entries in the hash, not the size of the hash key
Sebastia1Thorn is now known as SebastianThorn
<Senjai>
jhass: ty
<eam>
cout: sure, generally if you want to look at a second dimension you'd say something like O(m*n)
<eam>
however in this case Hash is still faster - because both forms must iterate the string length of the source which is O(n)
<jidar>
when reduced
woodennails has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<eam>
however Array must *also* iterate all of the other strings, and Hash does not
<Senjai>
jhass: aye, I follow
helpa-bot has joined #ruby
AlphaAtom has joined #ruby
helpa has quit [Remote host closed the connection]
<eam>
so we would say comparing two strings is O(n). Hashing a string into a lookup value is O(n). Applying the lookup value to find the Hash value is O(1). Searching an Array for a matching string is O(n) in terms of elements of the array and O(m*n) in terms of elements * string length
helpa-bot has quit [Remote host closed the connection]
t_ has joined #ruby
helpa has joined #ruby
jhwhite has quit [Ping timeout: 250 seconds]
<eam>
compare/hash have the same big-o
<cout>
eam: I would agree, but while the array element comparison and the hash function are computationally equivalent in terms of big-O, linear search through the array has the advantage that it can abort the comparison early if the strings don't match on the first or second character, whereas hash _has_ to iterate over the entire string to compute the hash value
dangerousdave has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<eam>
you're talking about a radix search?
railsraider has joined #ruby
<eam>
Array doesn't work like that
<cout>
eam: no, just a regular linear search
<eam>
Array does the same or more work even in the best case
<Antiarc>
Just use benchmark/ips for your use case and measure it :P
<eam>
Array must fully iterate the string length at least once
<eam>
correct?
<eam>
Hash also iterates the string length exactly once
<Antiarc>
Not necessarily, string comparison uses length checks and memcmp
<cout>
mean: e.g. let's say your searching for "foo" in the array [ 'abc'*10000, 'def'*10000, 'ghi'*1000, 'foo' ]
yardenbar has joined #ruby
<cout>
s/mean/eam/
<eam>
cout: hash(foo) has the same cost as comparing to "foo"
<eam>
same big-o
<cout>
eam: agreed
<eam>
so it's not an advantage
howdoi has quit [Quit: Connection closed for inactivity]
<cout>
eam: but in the case of array you can abort the comparison on the first character so you don't have to iterate over the entire string
<Mon_Ouie>
The hash table implementation will only hash the key you're trying to lookup then compare it with all the elements that are in the matching buckets. Those string comparisons can be exited early just as when you perform a linear search.
<eam>
in fact, cmp has to iterate both of them :)
<eam>
cout: no you must iterate the full string at least once
<eam>
cout: you said " cout> eam: agreed" to < eam> cout: hash(foo) has the same cost as comparing to "foo"
failshell has quit []
<cout>
same big-O cost
<eam>
comparing the full string "foo" is what you do in the final element
mdarby has joined #ruby
<eam>
correct?
arooni-mobile has quit [Ping timeout: 248 seconds]
<eam>
you traverse your entire input
axl__ has quit [Ping timeout: 245 seconds]
<cout>
sure, but the 1st 3 elements in the array are 30K long strings
<eam>
so what?
<cout>
oic, I got it backward
<eam>
hash wouldn't traverse those either
<eam>
hash(foo) is o(n) and "foo
mistermocha has joined #ruby
<eam>
"foo" == "foo" is O(n) actually O(2n) if you want to count constants
<cout>
(I've been dealing with a similar real-life problem recently, but the issue was insertion cost into the hash not lookup, which is why I stated the problem backward)
<eam>
ah yeah
howdoicomputer has joined #ruby
<[k->
all the smarts talking o.o
<Antiarc>
"f" == "foo" is O(1) though :)
<eam>
it's sometimes counter-intuitive how these things interact
<Antiarc>
(because length checks are just an integer comparison)
<eam>
Antiarc: :)
<Mon_Ouie>
I mean, "foo" == "foo" is also O(1) because you're comparing a constant with a constant which takes constant time overall…
<eam>
yeah n can be 1 :)
peter_paule has joined #ruby
<Antiarc>
Those will be separate string instances, so I don't think it'll be constant time in that case
dellavg has joined #ruby
<Antiarc>
a = b = "foo"; a == b would be constant time though
<eam>
in theory ruby could optimize a constant expression like that
<Antiarc>
In practice it doesn't :P
<eam>
sure :)
reset has joined #ruby
<eam>
now, if you attack the hashing mechanism you can make Hash lookups O(n)
<Kully3xf>
best way to sleep threads?
<Mon_Ouie>
It doesn't matter that it doesn't with regards to that comparison being O(1). It takes constant time because the size of the string is a constant, it doesn't matter if you iterate over the string or not.
j_mcnally has joined #ruby
<Kully3xf>
my threads are launching to quickly and AWS is giving me a resource limit (too much data being sent throgh
jeanlinux has quit [Remote host closed the connection]
<eam>
Mon_Ouie: well, we are saying n WRT elements and m WRT string size
<eam>
"foo" is just an example
<cout>
eam: class MyString < String; def hash; sleep(2**32); super; end; end # still O(1), right? :)
<eam>
cout: it is :)
towski_ has joined #ruby
<Antiarc>
Kully3xf: Kernel#sleep should do it. But if threads are launching too quickly maybe you should be using a thread pool?
<eam>
cout: or even just sleep()
<eam>
O(1) can be slower than O(2^n)
<Kully3xf>
i'm not sure what a thread pool is - I'll check it out
<Antiarc>
It's just a resource pool where you create X threads and then check one out when you want to use it, check it back in when you're done with it
<havenwood>
Kully3xf: You want to rate-limit the requests? Or are you spawning too many Threads?
<cout>
eam: yeah but then I have to modify YARV to solve the halting problem
<Antiarc>
That way you don't have to continually pay the thread creation overhead cost
<Antiarc>
And you aren't going to run into FD limits
RegulationD has joined #ruby
lkba has joined #ruby
__butch__ has joined #ruby
<Kully3xf>
i'm spawning only 10 threads, but AWS doesn't like the amount of data being sent so fast, I need to slow down how fast the threads are sending the data
[k- has quit [Quit: AndroidIrc Disconnecting]
relix has joined #ruby
davedev2_ has quit [Ping timeout: 276 seconds]
<Kully3xf>
I am using a thread pool
<Antiarc>
I rather doubt that the problem is "the amount of data"; AWS will happily accept throughput up to network link saturation if you can handle it
<Kully3xf>
The maximum request rate permitted by the Amazon EC2 APIs has been exceeded for your account. For best results, use an increasing or variable sleep interval between requests.
<Antiarc>
Oh, request limits. Okay, so you need to throttle your requests.
<shevy>
hanmac \o/
<Kully3xf>
I'll check that out @havenwood
c_nick has quit [Ping timeout: 240 seconds]
<eam>
Antiarc: that ain't true
<Antiarc>
Which bit?
tvw has quit [Remote host closed the connection]
zz_Outlastsheep is now known as Outlastsheep
<eam>
lots of aws services have per-connection throughput limits. You can do 100 parallel s3 uploads and get lots more throughput than one
<miah>
aws is all about request limits, but also making sure you memoize results so that you dont perform lookups without reason
<Senjai>
Today I realized how much I suck at writing recursive functions
SCHAAP137 has joined #ruby
<Antiarc>
I was thinking EC2 stuff - I figured Kully3xf was hitting actual resource limits, in the ulimit sense
<eam>
ah
<havenwood>
Senjai: Did you realize it recursively?
<Kully3xf>
I'm sending a knife ec2 server create request with ruby in multiple threads.
<Kully3xf>
throttle queue is exactly what i'm looking for I think
<Antiarc>
Senjai: To understand how much you suck at recursion, you must first understand how much you suck at recursion
<Senjai>
Antiarc: hahahaahaha
<miah>
depending on your account, your limits are likely going to be default, so make sure you memoize =) but if you are a customer giving aws tens of thousands of dollars per month you can have some limits increased
<Kully3xf>
so my error handler I guess is incompetent
<Kully3xf>
lol
finisherr has joined #ruby
a346 has quit [Quit: a346]
djbkd has quit [Read error: Connection reset by peer]
shadoi has joined #ruby
djbkd has joined #ruby
<Kully3xf>
right now i'm just ignoring them and not letting the thread die - so if I just wait long enough will the thread retry?
<jhass>
no
j_mcnally has quit [Ping timeout: 265 seconds]
rodfersou|lunch is now known as rodfersou
<Antiarc>
you're just shelling out to a command there; it's not likely to raise an exception. You'll need to look for exceptional text in the body of the command response, or check the return code of the command
pdoherty has quit [Remote host closed the connection]
Voker57|2 has quit [Remote host closed the connection]
<dudedudeman>
what type of service are you actually writing a GUI for?
<shevy>
everything! write all the things
bhuvanaurora has joined #ruby
bhuvan_aurora has joined #ruby
<woodennails>
Hello guys, Im moving to a new job as a junior developer and im going to be primarily using Ruby, not necessarily Rails but definitely Ruby. They are aware i know zero Ruby and are willing to train me up on it but is there any recommeded guides or tutorials that I can practice before at so that I dont look a total noob :)
<shevy>
right now just an exam-trainer, but I also have to port code I wrote many years ago, which was for all sorts of things, most of them incomplete; like you know mc (midnight commander?) - that thing could be in ruby-gnome too I thought once
<dudedudeman>
woodennails: woo! congrats on the new job(i'm searching for one myself)
<shevy>
dudedudeman are you on linux?
kadoppe has joined #ruby
<dudedudeman>
are you a book person? video person? courses, lectures, etc?
<dudedudeman>
shevy: yes. linux all the things
<dudedudeman>
at least at work i am
baweaver has quit [Remote host closed the connection]
jackjackdripper has quit [Quit: Leaving.]
<shevy>
woodennails have you used another programming language before?
<shevy>
dudedudeman ok excellent
<olas>
how would you have a ruby script respond to external commands? for example, we have 'counter' daemon that runs and we want to run say 'counter --current-count' to get what it's currently on?
<woodennails>
shevy im a javascript developer in my current role :)
<dudedudeman>
oh lawd. shevy, he said it
<jhass>
olas: via IPC, drb might the easiest for that purpose
last_staff has joined #ruby
<shevy>
dudedudeman let's try to see if you can install two small gems on your system, I found these to be quite important for ruby-gnome; first, pkg-config: "gem install pkg-config", which I hope should work without a problem.
nofxx has joined #ruby
nofxx has quit [Changing host]
nofxx has joined #ruby
<dudedudeman>
done
xtsee has quit []
<dudedudeman>
at least, it installed
Scroff has quit [Remote host closed the connection]
<shevy>
\o/ woooot
tobacco_joe has joined #ruby
<dudedudeman>
1.1.6
<shevy>
yeah that is the latest. let me look at the other one... this one has to do with cairo... ruby bindings to cairo... a moment
bruno- has quit [Ping timeout: 264 seconds]
<craysiii>
woodennails codecademy was good for an intro course
<woodennails>
Yeh i've been working through that
<dudedudeman>
woodennails: codecademy would be a good, easy place to start. free, too. from there you can pick up the pickaxe book, and so many other good books
<woodennails>
Ive gotten hold of Chris Pine Learn to Program
<shevy>
ok it should be "gem install cairo" but! it may require some cairo .h file, via this check here: "checking for cairo version (>= 1.2.0)... yes" not sure if your current system has it dudedudeman
<Senjai>
woodennails: Pickaxe book for the win man
<craysiii>
i did codecademy, and right now im running through the full-stack web course through bloc.io. hoping i can get a ruby job in 9 months or so
<shevy>
woodennails knowing javascript is good, you should not have a big problem with ruby. Chris Pine is pretty simple, perhaps boring, but after you read it, you should be able to answer questions such as "what is a block in ruby?"
<Senjai>
craysiii: Back in the day
mdarby has quit [Ping timeout: 250 seconds]
<woodennails>
So Pragmatic Ruby is recommended then?
<shevy>
pickaxe has a great reference with examples in the last 400 pages ( :P ) or so
<dudedudeman>
i get a failure on that one, shevy
<shevy>
dudedudeman ah dang ok
<dudedudeman>
woodennails: yes! it's a good'en
<craysiii>
i actually went to school for CS but then dropped out because of the calculus requirement. so far it seems easy (especially because i am already well versed in MVC from django)
ndogz has quit [Quit: Leaving...]
<olas>
jhass: hmm it seems like drb is limited to ruby 1.9.3
<Senjai>
craysiii: the math is handy
howdoicomputer has quit [Ping timeout: 256 seconds]
<jhass>
olas: where did you read that? oO
nettoweb has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
jackjackdripper has joined #ruby
<shevy>
craysiii you also don't like math?
<craysiii>
yes it is, i did this when i was younger
dagda1 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<shevy>
but I think you may lack some header or perhaps a library too... hmm
leonardoajim has joined #ruby
dcunliffe has joined #ruby
dcunliffe is now known as Pyrotecnix
leonardoajim has quit [Read error: Connection reset by peer]
blackmes1 has joined #ruby
leonardoajim has joined #ruby
<shevy>
my system confuses me
<dudedudeman>
no... definitely don't have that
workmad3 has quit [Ping timeout: 250 seconds]
<olas>
jhass, Senjai: my god i was trying to gem install when it was part of the stdlib
<shevy>
I am using some script to install .gem files ... via a system 'gem install --ignore-dependencies '
tjohnson has joined #ruby
axsuul has quit [Ping timeout: 240 seconds]
<shevy>
dudedudeman ok good, that is also usually what I have when I try to install ruby-gnome bindings on a fresh install
<craysiii>
what OS you guys running?
solocshaw has joined #ruby
dblessing has quit [Ping timeout: 252 seconds]
<jhass>
?guys
<ruboto>
we're not all guys - while you probably don't meant to be exclusive, not everybody feels that way. Maybe consider using "folks", "y'all" or "everyone" instead?
<eam>
is your operating system running?
<shevy>
craysiii linux here but mostly I compile from source
GBrawl has joined #ruby
<eam>
better go catch it
quimrstorres has joined #ruby
<craysiii>
sorry i dont mean to offend
mhib has joined #ruby
<jhass>
anyway, arch here
eggoez has joined #ruby
<shevy>
dudedudeman ok... let's try the old way... I am sure there are better ones, but this one I know... we grab good old setup.rb ... let me find the latest version...
<jhass>
and #ruby-offtopic if anybody feels like fighting over the best ;)
lavros has quit [Quit: leaving]
axsuul has joined #ruby
denver has quit [Remote host closed the connection]
<atomical>
?girls
<ruboto>
I don't know anything about girls
kinduff has quit [Quit: leaving]
<shevy>
2% girls here but they are hiding
dagda1 has joined #ruby
<craysiii>
7% of statistics are made up on the spot
tno has joined #ruby
solocshaw has quit [Ping timeout: 255 seconds]
<shevy>
ok dudedudeman this is the setup.rb from 2005, I just copy pasted it -> https://goo.gl/07U1Go, you can save it as "setup.rb" in the same directory as you are in of cairo*; you could also use the original source if you want to, which you could obtain from here: http://i.loveruby.net/en/projects/setup/ or you could also use a somewhat more recent updated variant (but by another author) at: https://github.com/r
<shevy>
ubyworks/setup
<woodennails>
What editors do you guys use?
<shevy>
woodennails bluefish 1.1.7 still \o/ though if I were to start from scratch today, I would probably opt for something such as sublime
GriffinHeart has joined #ruby
<woodennails>
im trying to get into Vim, people i know swear by it but i just find it takes longer
jayrmotta has quit [Quit: This computer has gone to sleep]
<shevy>
dudedudeman once you have setup.rb (sorry for the extra steps... I don't know of a simpler way), run this please: "ruby setup.rb config"
eggoez has quit [Ping timeout: 246 seconds]
<shevy>
woodennails vim has nice keybindings
<shevy>
I did not like the extension syntax much
<dudedudeman>
shevy: this be crazy
bronson has joined #ruby
<shevy>
yea :(
juanca__ has joined #ruby
<woodennails>
I've never bought a programming book before, i've just used online resources.. you reckon it may be better to use a paperback rather than epub/pdf?
solocshaw has joined #ruby
<shevy>
dunno. I do have some .pdf files from paper books, but I prefer good old books in general
<craysiii>
theres pros and cons to each. I like a physical book so i can flip to pages
juanca_ has quit [Ping timeout: 265 seconds]
Igorshp has joined #ruby
<shevy>
woodennails for programming I started to keep local reference things/notes
<shevy>
like tricks, hints, examples, tests
<shevy>
for science-related stuff, I definitely prefer books
<woodennails>
There any online tutorials for Ruby you guys can recommend
<dudedudeman>
definitely the codecademy stuff, for free
bronson has quit [Remote host closed the connection]
<dudedudeman>
the oden project has a bunch of good ruby resources if you're looking for web related development
jayrmotta has joined #ruby
<woodennails>
Yeah i'm going through that at minute.. codeschool?
bronson has joined #ruby
<dudedudeman>
codeschool is awesome, but doesn't have too many courses for pure ruby
GriffinHeart has quit [Ping timeout: 256 seconds]
<dudedudeman>
lots of rails, lots of javascript, lots of stuff for things htat compliment ruby/rails, like sql/bootstrap/etc
arescorpio has joined #ruby
<shevy>
woodennails ultimately one of the best ways to learn is to sit down and simply do all the basic stuff, by yourself... how to create directories... how to create symlinks... how to copy, delete, remove... how to group code into modules/class
bruno- has joined #ruby
<woodennails>
yeah ive been doing Javascript for the past year at work, im still a junior developer... and just accepted a job where i'll be primarily doing ruby
Kricir has quit [Remote host closed the connection]
railsraider has quit [Quit: railsraider]
<eam>
the best way to learn is to assert your ideas as true and wait for people to correct you
SuMo_D has joined #ruby
momomomomo has joined #ruby
DEac- has joined #ruby
_blizzy_ has joined #ruby
<shevy>
oh
eggoez has joined #ruby
hotpancakes has quit [Remote host closed the connection]
sarkyniin has quit [Quit: Quit]
<shevy>
I let my old friend, the ruby parser, correct me
<woodennails>
im just struggling on what to create between now and hten
<woodennails>
then*
* eam
waits
sarkyniin has joined #ruby
wallerdev_ has quit [Quit: wallerdev_]
<shevy>
18th october 2014: <eam> well that's super dumb; <eam> I'm disappointed in perl
<shevy>
\o/
mistermocha has joined #ruby
sharpmachine has quit [Remote host closed the connection]
<craysiii>
i always like to write a brainf*ck emulator / interpreter in whatever language
momomomomo has quit [Client Quit]
<craysiii>
good first execise
<eam>
shevy: what was that about anyway I forgot
<shevy>
sadly I did not store the ruby-parser = devilish reference
<shevy>
eam not entirely sure... the rest of the quote is: <eam> oh holy cow; <eam> you're right, that's insane (looks like you disable it with binmode); <eam> $^I disables it, looks like
<shevy>
I really could not tell you what $^I means in the first place
JoshL has quit []
<eam>
oh, it was the i/o layer translating \n inside write()
<eam>
which is why you should always use syswrite
<Ox0dea>
craysiii: What is a "brainfuck emulator"?
axsuul has quit [Ping timeout: 250 seconds]
hmnhf has quit [Ping timeout: 276 seconds]
<shevy>
reminds me of puts "foo\n" versus puts "foo" now... where the one without \n is slower
<shevy>
hmm or perhaps "more expensive"
<eam>
shevy: both
<Ox0dea>
shevy: They aren't the same.
<eam>
Ox0dea: they're the same output
<craysiii>
more of an interpreter. but if you don't know what brainf*ck is, it's an esoteric programming language
<eam>
but letting puts add the \n is much slower
digifiv5e is now known as daynaskully
<ytti>
puts "foo\n" likely is thread safe
<ytti>
puts "foo" definitely is not
<eam>
ytti: well, what's threadsafe?
<ytti>
perhaps that is wrong word
<eam>
you mean in terms of interleaved writes?
<ytti>
i mean puts "foo" is "foo" and "\n" done separately
<eam>
yeah
sshuff has joined #ruby
<ytti>
and if two threads are writing to same output
<Ox0dea>
craysiii: Right, I'd just never heard the term "emulator" used in the context of brainfuck is why I asked.
<shevy>
cool
<ytti>
it might be that output is unexpected
_blizzy_ has quit [Read error: Connection reset by peer]
<ytti>
i tink "foo\n" would produce expected output
<eam>
puts should use writev() or have a writev() ruby i/o layer equiv
<craysiii>
i shouldn't have used the term
sharpmachine has joined #ruby
<shevy>
ruby has so much thread stuff... threads ... fiber... mutex... probably something else that I forgot
icflournoy has quit [Ping timeout: 244 seconds]
railsraider has joined #ruby
poguez_ has joined #ruby
<eam>
callcc
ayonkhan has joined #ruby
icflournoy has joined #ruby
sarkyniin has quit [Remote host closed the connection]
sharpmachine has quit [Remote host closed the connection]
_blizzy_ has joined #ruby
sharpmachine has joined #ruby
<Ox0dea>
So, for Kernel.puts, "foo" and "foo\n" are the same, but "foo\n" and "foo\n\n" are not. Why isn't it just defined as print + newline?
<eam>
perlism
phutchins has quit [Ping timeout: 264 seconds]
<eam>
DWIM
KnownSyntax has quit [Remote host closed the connection]
KnownSyntax has joined #ruby
Sthebig_ has joined #ruby
Sthebig_ has joined #ruby
<Ox0dea>
It seems TNWIM hasn't caught on.
sarkyniin has joined #ruby
ayonkhan has quit [Read error: Connection reset by peer]
AlphaAtom has quit [Read error: Connection reset by peer]
hotpancakes has joined #ruby
lele has quit [Ping timeout: 250 seconds]
Sthebig_ is now known as Sthebig
AlphaAtom has joined #ruby
<shevy>
nobody else knows what that is, you fossil coders you!
Muhannad has joined #ruby
<shevy>
born in the 1960s
<shevy>
I have an idea... let's bring larry wall to #ruby :)
f3lp has quit [Ping timeout: 252 seconds]
blue_deref has joined #ruby
<Ox0dea>
shevy: You're supposed to have read The Jargon File by now. :P
<Ox0dea>
On Larry, I think Black Perl provides some interesting insight into his psyche.
Drakevr has quit [Ping timeout: 276 seconds]
howdoicomputer has joined #ruby
mjuszczak has joined #ruby
Zai00 has joined #ruby
<mjuszczak>
In Ubuntu, what is the proper way to repoint /usr/bin/ruby to something else? Or to tell apt to never install ruby1.9 packages even if something depends on it? I installed ruby2.1 into /opt and repointed /usr/bin/ruby to it (seems there's no way to do it with alternatives like other operating systems though I could be mistaken), but any time the ruby1.9 package gets updated or installed it repoints symlinks.
hahuang65 has quit [Ping timeout: 276 seconds]
<Ox0dea>
mjuszczak: Please use a Ruby version manager.
<bougyman>
mjuszczak: on the debuntus, you use update-alternatives to manage those links.
CustosLimen has joined #ruby
hotpancakes has quit [Ping timeout: 264 seconds]
<bougyman>
but Ox0dea's idea is much better.
ayonkhan has joined #ruby
bronson has quit [Remote host closed the connection]
last_staff has quit [Ping timeout: 255 seconds]
lele has joined #ruby
<bougyman>
use system ruby only for essential stuff (chef/puppet/system stuff)
<shevy>
mjuszczak sounds pretty annoying - debian tells you to not use any alternatives :)
<bougyman>
debian provides the most complete alternatives system available
tobacco_joe has quit []
<bougyman>
so no, it doesn't tell you not to use alternatives.
juanca_ has joined #ruby
juanca__ has quit [Ping timeout: 265 seconds]
<shevy>
what business of it is it to modify a symlink made by the USER of the system?
<bougyman>
it won't, if you use update-alternatives --install
<bougyman>
from then on it's part of the alternatives system.
bruno- has quit [Read error: Connection reset by peer]
bruno- has joined #ruby
mjuszczak has quit []
SpeakerToMeat has joined #ruby
<SpeakerToMeat>
Hello. I'll try my hand here too
<Ox0dea>
shevy: The system must assume the user does not know what it's doing, and vice versa. This may be the only truly insoluble conflict facing our respective species.
SuMo_D has quit [Quit: Off into this... Real world place...]
<SpeakerToMeat>
I'm trying to modify an xml document with Nokogiri. I'm doing this: http://pastebin.com/f26ehTjc to try and add a namespace to the root element, but this causing the insertion of a <root> element instead... what am I doing wrong?
woodennails has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
t_ has quit [Ping timeout: 276 seconds]
solars has joined #ruby
khebbie has joined #ruby
stoodfarback has joined #ruby
bashusr has quit [Ping timeout: 256 seconds]
hoofed_ has quit [Read error: Connection reset by peer]
hotpancakes has quit [Ping timeout: 248 seconds]
bruno- has quit [Read error: Connection reset by peer]
bruno- has joined #ruby
Limix has joined #ruby
arup_r has joined #ruby
bashusr has joined #ruby
bashusr has quit [Changing host]
bashusr has joined #ruby
__butch__ has joined #ruby
mistermocha has quit [Ping timeout: 265 seconds]
axsuul has joined #ruby
quimrstorres has quit [Remote host closed the connection]
nettoweb has quit [Read error: Connection reset by peer]
Kruppe has quit [Ping timeout: 248 seconds]
nettoweb has joined #ruby
cpruitt has quit [Read error: Connection reset by peer]
baweaver has joined #ruby
jenrzzz has joined #ruby
cpruitt has joined #ruby
railsraider has quit [Quit: railsraider]
khebbie has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
Kruppe has joined #ruby
apt-get_ has joined #ruby
lkba has joined #ruby
sarkyniin has quit [Ping timeout: 265 seconds]
tvw has quit [Remote host closed the connection]
hotpanca_ has joined #ruby
Muhannad has quit [Read error: Connection reset by peer]
sargas has joined #ruby
<SpeakerToMeat>
I turned it to this: https://gist.github.com/Lars/8418797358c13d46befe but it fails to find the namespace if I try to use it bellow.. Even if I do this: xml.namespace_definitions.find{|ns|ns.prefix=="dsig"}
lkba_ has quit [Ping timeout: 240 seconds]
apt-get_ has quit [Quit: Quit]
sarkyniin has joined #ruby
intinig has joined #ruby
ringarin has joined #ruby
lxsameer has joined #ruby
lxsameer has joined #ruby
multi_io has quit [Ping timeout: 256 seconds]
Helheim has joined #ruby
jcdesimp has quit [Remote host closed the connection]
iwishiwerearobot has joined #ruby
hahuang65 has joined #ruby
axsuul has quit [Ping timeout: 264 seconds]
<AlphaAtom>
Is there a different channel for rails or is here okay?
sdothum has joined #ruby
multi_io has joined #ruby
bruno- has quit [Read error: Connection reset by peer]
<pipework>
#RubyOnRails
<AlphaAtom>
thanks
failshell has joined #ruby
sshuff has quit [Quit: Leaving]
roolo has joined #ruby
varunwachaspati has quit [Quit: Leaving]
woodennails has joined #ruby
davedev24_ has quit [Ping timeout: 248 seconds]
sargas has quit [Quit: This computer has gone to sleep]
freerobby has joined #ruby
jcdesimp has joined #ruby
zendrix has joined #ruby
woodennails has quit [Client Quit]
iwishiwerearobot has quit [Ping timeout: 264 seconds]
symbol has joined #ruby
ausec has joined #ruby
ringarin has quit [Ping timeout: 244 seconds]
davedev24_ has joined #ruby
jhwhite has quit [Ping timeout: 244 seconds]
dblessing has joined #ruby
wlknsn has joined #ruby
wlknsn has left #ruby [#ruby]
jcdesimp has quit [Remote host closed the connection]
<ausec>
hey all, i want to modify this: http://pastebin.com/nXwhCkr0 to loop over a certain number of lines at a time
<symbol>
Senjai: That gang of four book is written with C examples...would a rubyist still find it valuable?
<Senjai>
symbol: Yes, it's all just code
<Senjai>
It's not all C either
zendrix has quit [Remote host closed the connection]
<symbol>
Gotcha - I should stop being afraid of X
<symbol>
*C
<Senjai>
symbol: You'll get to a point where code is all just code.
<symbol>
Cool, thanks!
icebourg has quit []
<Senjai>
Reading anything is a lot easier than writing anything though :P
<Senjai>
symbol: You might want to brush up a bit on pointers and references, if anything though.
<Senjai>
If you're not familiar with memory and how memory works
<Senjai>
that's the only gotcha
<symbol>
I know a bit about memory. While I know it's better to write code...writing bad practices won't improve my code quality.
fmcgeough has quit [Quit: fmcgeough]
<symbol>
But I suppose that's why my workplace does peer reviews.
zendrix has joined #ruby
<Senjai>
:)
<Senjai>
We have mandatory code review on every commit on gerrit, and every pr on github
_blizzy_ has quit [Ping timeout: 240 seconds]
<Senjai>
It's how you get better
hotpanca_ has quit [Remote host closed the connection]
<symbol>
I love them but sometimes I fear people aren't being harsh enough.
Carnage\ has quit []
sargas has quit [Quit: Leaving]
<slash_nick>
symbol: post non-sensitive stuff here... these guys will tear your code apart ;)
<slash_nick>
(while building you up)
_ht has quit [Quit: Konversation terminated!]
<slash_nick>
s/guys/people/
axsuul has quit [Read error: No route to host]
axsuul has joined #ruby
wldcordeiro_ has joined #ruby
<symbol>
Good call!
<symbol>
I did that once in #javascript and left weeping (in a great way)
<daxroc>
Anyone know offhand if restclient does any session caching - seeing a strange 403 issue directly after authenticating but next auth works fine looks like to token is invalid.
crdpink has joined #ruby
<Kully3xf>
does this solution to my earlier problem work/earlier problem - need to pause thread creation because they are launching to many api calls simoultaniously triggering a hard cutoff from the API receiver. My solution is to put a sleep(rand(5)) in before the API call
<Kully3xf>
that should cause each thread to sleep a random amount of seconds (negligible in the over creation time)
crdpink2 has quit [Ping timeout: 248 seconds]
<Kully3xf>
thus freeing up the api calls per second
bubbys has quit [Ping timeout: 276 seconds]
<Kully3xf>
or even better, sleep(i) where i is the number of the thread in creation, that way there's no way it randomly creates all 2 second sleeps
djbkd has joined #ruby
InternetFriend has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
jxpx777 has quit [Quit: Leaving...]
MasterPiece has quit [Quit: Leaving]
bubbys has joined #ruby
<slash_nick>
Kully3xf: why not run them serially? sounds like you're doing a lot of work to make this run *less* concurrently... serially is less concurrent.
jxpx777 has joined #ruby
<Kully3xf>
serially takes too long. Each api call takes 30-60 minutes to complete and we need to do 5-100 of them at a time
GitGud has joined #ruby
<Kully3xf>
100 times 30 minutes is too long
simplyaubs has joined #ruby
Igorshp has quit [Remote host closed the connection]
<slash_nick>
Mon_Ouie: wouldn't that require a second iteration over the array?
ruby-lang044 has quit [Ping timeout: 246 seconds]
<Mon_Ouie>
That's what map + compact does too
<slash_nick>
Mon_Ouie: I guess I never thought about how/where all the nils go lol
<Mon_Ouie>
Also it's not obvious that two iterations vs. one iteration that does twice as much is better
<Kully3xf>
@bricker it's a chef exec knife ec2 server create
rbennacer has quit [Remote host closed the connection]
last_staff has joined #ruby
davedev__ has joined #ruby
hanmac has quit [Ping timeout: 256 seconds]
Musashi007 has joined #ruby
howdoicomputer has quit [Quit: WeeChat 1.2]
solars has quit [Ping timeout: 250 seconds]
<Kully3xf>
it creates a server with chef - but the thread can't complete until the server has been created - the instances are quite large 16 core in some cases and they can take quite some time to launch and register with chef, download and configure new files/settings etc
jenrzzz has quit [Ping timeout: 252 seconds]
<slash_nick>
Mon_Ouie: in that case, I'd think the select/map would be quicker... iterate over all elements, then iterate over only the remaining........ map/compact would have to iterate over all elements both times
jfarmer has joined #ruby
bronson has quit [Ping timeout: 248 seconds]
hotpancakes has quit [Ping timeout: 265 seconds]
redteam has joined #ruby
davedev24_ has quit [Ping timeout: 248 seconds]
momomomomo has quit [Ping timeout: 246 seconds]
<Mon_Ouie>
Yes, but on the other hand the inner loop of #compact does not have to execute any Ruby code in MRI, while the select version has to switch to a block. Which one is faster probably depends on how many of the entries need to be filtered out.
<jfarmer>
The first thing that happens to establish a secure connection is the client connects to the server and the server presents the client a digital certificate.
msnyon has quit [Ping timeout: 244 seconds]
<n3vtelen>
jfarmer: I know that :D
<jfarmer>
Ok.
j_mcnally has quit [Ping timeout: 248 seconds]
j_mcnally has joined #ruby
<jfarmer>
The error means that your client can't verify the server's certificate.
juanca_ has quit [Ping timeout: 264 seconds]
workmad3 has joined #ruby
zendrix has quit [Remote host closed the connection]
<jfarmer>
This could be for a few reasons: (1) the certificate is actually invalid/expired/etc., (2) the certificate isn't signed by a certificate authority that your computer trusts
dellavg has quit [Ping timeout: 264 seconds]
<jfarmer>
And the always-present (3) neither of those because there's something I didn't think of
zendrix has joined #ruby
Sehryn has quit [Ping timeout: 244 seconds]
hotpancakes has quit [Remote host closed the connection]
monod has quit [Remote host closed the connection]
EagleDelta has quit [Ping timeout: 264 seconds]
xxneolithicxx has quit [Ping timeout: 255 seconds]
krz has quit [Quit: WeeChat 1.0.1]
rodfersou has quit [Quit: leaving]
juanca__ has quit [Ping timeout: 252 seconds]
iamse7en has joined #ruby
krz has joined #ruby
zendrix has quit [Ping timeout: 256 seconds]
krz has quit [Client Quit]
<jfarmer>
n3vtelen And if you look at that page of Google results I linked, the posts consistently point to (2) being the problem.
msnyon has joined #ruby
but3k4 has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
astrobun_ has joined #ruby
Yiota has quit [Quit: My MacBook Pro has gone to sleep. ZZZzzz…]
<jfarmer>
Some operating systems / Ruby installations don't come with all the root certificates you'd expect, causing OpenSSL to report that the certificate isn't valid / shouldn't be trusted.
GBrawl has joined #ruby
mistermocha has quit [Read error: Connection reset by peer]
Yiota has joined #ruby
zendrix has joined #ruby
Yiota has quit [Read error: Connection reset by peer]
jcdesimp has joined #ruby
GBrawl has quit [Client Quit]
<n3vtelen>
jfarmer: yes, that's ok on linux
<jfarmer>
What operating system are you using?
<n3vtelen>
jfarmer: windows
krz has joined #ruby
mistermocha has joined #ruby
<jfarmer>
I would google "ruby windows openssl certificate verify failed"
meph has joined #ruby
<jfarmer>
I'd wager there's a ton of info on the best way to correct it.
Yiota has joined #ruby
ESpiney has quit [Read error: Connection reset by peer]
krz has quit [Client Quit]
ferret_guy has joined #ruby
<jfarmer>
Just don't ever set verify_mode to VERIFY_NONE, which folks often suggest.
krz has joined #ruby
astrobun_ has quit [Ping timeout: 248 seconds]
<jfarmer>
The solution is to get the right certificates on your machine, not to disable all SSL certificate verification. :D
prettiestPony11 has joined #ruby
<jfarmer>
"My smoke alarm won't stop going off! What do I do?" "Just remove the batteries, that'll solve it."
<prettiestPony11>
trying to `rvm install 2.2.2` and getting `Version 2.2.2 is to confusing to select ruby interpreter.`
krz has quit [Client Quit]
crdpink2 has joined #ruby
hotpancakes has joined #ruby
crdpink has quit [Ping timeout: 248 seconds]
ldnunes has quit [Quit: Leaving]
krz has joined #ruby
<jfarmer>
I haven't used rvm in ages, but it seems like it's saying that 2.2.2 is ambiguous
<jfarmer>
There's a way to list out the known versions you can install with rvm.
<prettiestPony11>
jfarmer: is rvm not widely used anymore?
<jfarmer>
I'd guess something like rvm versions, rvm list, or the like, but rvm --help will say for sure.
<Senjai>
prettiestPony11: chruby is recommended
vickleton has joined #ruby
<jfarmer>
I don't have a sense of how widely used it is — I'm pretty sure it's still widely used — but lots of folks moved to rbenv and, more recently, to chruby
<Senjai>
rvm is mostly useful for servers, and things that need gemsets, which a development system doesnt
<prettiestPony11>
interesting. ok thanks!
<jfarmer>
But don't worry about that right now. It's tangential to your issue.
<jfarmer>
2.2.2 is ambiguous, likely
<Senjai>
I really miss function overloading
agent_white has quit [Quit: bbl]
<shevy>
we have a pony!
<jfarmer>
e.g., JRuby might have a version 2.2.2 and MRI might have a version 2.2.2
<jfarmer>
So rvm is like, "I don't know which you mean."
slumos has left #ruby [#ruby]
<headius>
our 2.2.2 means compat with and same stdlib as MRI 2.2.2
<jfarmer>
It'd be more useful if the error printed out all the possible matches and included example commands to install them.
<headius>
our = jruby
<adaedra>
shevy: you can't call people ponies like that, it's mean
<headius>
we have a separate version number for jruby itself
<zenspider>
set up cpp and we even get *cough*fake/bad*cough* macros!
Guest46454 is now known as vale_tudo
<Senjai>
:(
<baweaver>
L(et) O(ver) L(ambda)
casadei_ has joined #ruby
<wallerdev_>
i never found the appeal of multiline comments haha
FernandoBasso has joined #ruby
<wallerdev_>
i prefer // or # on every line
bruno- has joined #ruby
<Senjai>
wallerdev_: It used to bother me before I knew how to vim and comment blocks that way
<zenspider>
baweaver: I've been trying to take a whack at that... it's really hard to get into common lisp when you love scheme
<wallerdev_>
ah yeah i guess if you're using notepad or something and have to type in each that would suck
<baweaver>
Fair point
chouhoulis has joined #ruby
<baweaver>
Also a dense book
<zenspider>
the macros are so... gross.
<zenspider>
scheme's macro system is ... hard... but so damn pretty
<baweaver>
Clojure at least got that somewhat decently
Scroff has joined #ruby
<Senjai>
It has been forever since I've usedd scheme
<zenspider>
we're working through the entire little schemer series in our study group. just finishing the reasoned schemer. it's amazing what you can do with lambdas + hygenic macros
<baweaver>
Might have tried to write a photoshop variant in scheme once when I was bored.
<baweaver>
Peano / Church numerals abound
hahuang65 has quit [Ping timeout: 265 seconds]
<ferret_guy>
I am using passenger with apache and when I load the page I configured it shows the directory as opposed to the ruby app
<Senjai>
zenspider: Which study group is this
<Senjai>
have you tried that MIT book
<zenspider>
SeaRbSg == Seattle.rb Study Group
<zenspider>
"that MIT book" is beyond vague
mandarinkin has quit [Quit: Leaving]
<zenspider>
they have their own press, ya know...
<Radar>
ferret_guy: screenshot plz
sharpmachine has joined #ruby
<baweaver>
SICP is probably what
<Senjai>
zenspider: I've been meaning to come down to seattle sometime for one of the ruby meetups
<Senjai>
I'm not exactly far away
<baweaver>
Structure and Interpretation of Computer Programs
<baweaver>
if I got that right
<Senjai>
baweaver: Yeah
<Senjai>
that's the one
<baweaver>
I'll be up there in July at least.
<baweaver>
What time does that normally happen at anyways?
<Senjai>
baweaver: Maybe we could coordinate ;)
* baweaver
goes to meetups to find it
<baweaver>
I live in the San Francisco area
<baweaver>
just up there for vacation.
<baweaver>
figured I'd drop by.
Scroff has quit [Ping timeout: 276 seconds]
<Senjai>
I live in Victoria BC, Can
<Senjai>
Literally a clipper ride away
<Radar>
Literally.
<Radar>
:D
<Senjai>
Literally
<Senjai>
:P
platzhirsch has quit [Remote host closed the connection]
phutchins has quit [Read error: Connection reset by peer]
<Senjai>
You should join us Radar, I'm sure its not that far for you either /s
<Radar>
Senjai: 14hrs by plane
<Senjai>
ik :P, if you ask me: worth it
<Radar>
TIL: Senjai is paying for my flight to Seattle
<baweaver>
Heh, if I really wanted to I could sign up to give a talk for July too :D
<baweaver>
Clairvoyant should have enough to it by then to be fun
<zenspider>
yeah. we did SICP a few years back.
k3asd` has quit [Ping timeout: 256 seconds]
dented42 has joined #ruby
<Senjai>
I still havent got through it
<Radar>
Flights are only $1462.
k3asd`_ has quit [Ping timeout: 244 seconds]
<zenspider>
Senjai: you should come! we've had canadian members before. miles used to show up fairly regularly
<zenspider>
there's a seaplane that goes up to BC and back
<Senjai>
Yeah
<Senjai>
It's super fast
<zenspider>
has to have incredible views of the san juans
<Senjai>
could go there and back in a day ez
al2o3-cr has quit [Ping timeout: 248 seconds]
<Senjai>
zenspider: I have to get my passport renewed, then i'll come down for sure
<Senjai>
possibly not july, or maybe late july
<zenspider>
miles is in frasier valley. it's even further (but no ferry to deal with)
<Senjai>
I dont think I want to drive
bronson has joined #ruby
<zenspider>
not with that horrid ferry system.
<Senjai>
It is pretty bad
<baweaver>
zenspider: They already have a talk for this month?
axsuul_ has quit [Ping timeout: 246 seconds]
<zenspider>
tonight, yeah
<baweaver>
The 28th
<Senjai>
baweaver: You're going on the 28th?
<zenspider>
we only do talks / foods / booze on the first tuesday of the month
<baweaver>
there is still a meeting then right? Or did I get that wrong?
ohaibbq has joined #ruby
<baweaver>
ah
<zenspider>
julia will be speaking tonight about kubernetes (sp?)
<zenspider>
we meet every tuesday
<baweaver>
I get there at the last week of the month.
<zenspider>
then you can have the best espresso you've ever had
<zenspider>
(or beer, but I can't vouch for that)
<baweaver>
There are a few snooty baristas around here that'd likely disagree :P
<zenspider>
they're wrong
phutchins has joined #ruby
<zenspider>
blue bottle is the closest I've seen SF get, but it's still only 90% or so
<zenspider>
there was a teeny stand near github that was good... still not as good
<zenspider>
but really, in SF they seem to focus on the "snooty" part, and not the coffee part
<baweaver>
I'm down by Southpark
<zenspider>
they've got that down pat
<baweaver>
sounds par for course.
<Senjai>
I could see if I could come by on the 28th, passport permitting
al2o3-cr has joined #ruby
axsuul has joined #ruby
axsuul has quit [Excess Flood]
<zenspider>
southpark was close to github iirc, so I think it is near you
<baweaver>
2nd and Harrison is where we're at.
quazimodo has joined #ruby
jhwhite has joined #ruby
<zenspider>
(github may have moved since I was last in the office)
iwishiwerearobot has joined #ruby
<zenspider>
(I don't track)
axsuul has joined #ruby
jesterfraud has joined #ruby
<baweaver>
Right by Twilio, Atlassian, and Ubisoft
axsuul has quit [Excess Flood]
<zenspider>
*shrug*
<baweaver>
There are so many I lose track honestly.
iamninja has joined #ruby
bronson has quit [Ping timeout: 264 seconds]
<zenspider>
from the github office, it was .... west 1-2 blocks, then down an alley ... north?
nertzy has quit [Quit: This computer has gone to sleep]
<zenspider>
who knows. may not exist anymore. it was tastyish, but not worth the wait :)
<zenspider>
must check on beef...
dseitz has joined #ruby
<zenspider>
man... this reverse sear is gonna take forever. :/
<zenspider>
I guess its only been 20 minutes
<Senjai>
mmm
momomomomo has joined #ruby
sharpmachine has quit [Read error: Connection reset by peer]
chouhoulis has quit [Remote host closed the connection]
iwishiwerearobot has quit [Ping timeout: 252 seconds]
casadei_ has quit [Remote host closed the connection]
jhwhite has quit [Ping timeout: 264 seconds]
chouhoulis has joined #ruby
dede has quit [Quit: Connection closed for inactivity]
<ruboto>
pastebin.com loads slowly for most, has ads which are distracting and has terrible formatting.
jfarmer has joined #ruby
<ferret_guy>
ruboto TIL
<Radar>
ferret_guy: Your apache config is pointing to the application dir, rather than the public dir inside the application dir.
<Radar>
ferret_guy: change your config + restart apache
<Radar>
HEY PRESTO it's fixed
Igorshp_ has quit [Remote host closed the connection]
jeramyRR has joined #ruby
<ferret_guy>
@Radar AppRppt?
<ferret_guy>
@Radar AppRoot?*?
<Radar>
ferret_guy: Show me the whole VirtualHost config please (in a Gist)
mistermocha has joined #ruby
<Senjai>
I will also take a small sidebar and suggest nginx instead
<zenspider>
baweaver: if you have good coffee suggestions for SF, I'd love them. I always feel looked down upon (and yet, still get worse coffee) when I try to get coffee down there
mistermocha has quit [Read error: Connection reset by peer]
<ferret_guy>
@Radar :/ no go
<Radar>
ferret_guy: What happens now?
<shevy>
well zenspider that's scary... I read the intro part... lemme find it ...
<Radar>
ferret_guy: Did you restart your apache server?
<ferret_guy>
@Radar Yep, Same thing
scripore has quit [Quit: This computer has gone to sleep]
<shevy>
"...they can afford to move so fucking slow, man, they'll wait years and years. Give you a whole life, just so you'll have more to lose when they come and take it away. Patient like a spider. Zen spiders."
mistermocha has joined #ruby
<shevy>
it scared me sufficiently much so that I instantly stopped to read right there!
<Radar>
ferret_guy: oh rly
<Radar>
ferret_guy: Still showing a directory listing of app? Not public?
hahuang65 has joined #ruby
devdazed has joined #ruby
<ferret_guy>
Radar: hmm good point let me clear my cache
iamse7en has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
<zenspider>
shevy: heh
jhack has joined #ruby
rcvalle has quit [Quit: rcvalle]
nofxx has joined #ruby
yfeldblum has quit [Remote host closed the connection]
<jhack>
Hey is anyone doing or has experience with software dev Bootcamps?
<zenspider>
28 more degrees... huge jump in just 10 minutes.
<Senjai>
jhack: Not fantastic as measured from people we get applying from them
nateberkopec has quit [Quit: Leaving...]
<zenspider>
jhack: some. just ask your q's
AlphaAtom has quit [Quit: My Mac has gone to sleep. ZZZzzz…]
yizr_ has quit [Ping timeout: 246 seconds]
<Radar>
ferret_guy: I have no idea then.
<Radar>
ferret_guy: It all checks out to me.
<ferret_guy>
@Radar stopped reloaded to verifyd it was stopped started and still at the same directory
<jhack>
I've been planning on applying to flatiron
<zenspider>
ferret_guy: perms?
<jhack>
Don't know how to determine if I'm ready
<zenspider>
or... verify you're not caching the old result?
<jhack>
And I wanna get some more reviews on dev bootcamp in nyc
<ferret_guy>
@zenspide all 777 for good mesure
prettiestPony11 has joined #ruby
<zenspider>
that might not be allowed.
<zenspider>
turn off write
yfeldblum has joined #ruby
<zenspider>
depends on what you're trying to do... apache is a pita with this shit
<zenspider>
"it's wrong" "what's wrong?" "it"
<zenspider>
always feels like that
<baweaver>
s/with this shit// - ftfy
<zenspider>
s/is a/is especially a/
<ferret_guy>
@zenspider the access logs are showing the files are allowed, and obviously i can browse them
<zenspider>
kk. ignore me then
nerium has joined #ruby
scripore has joined #ruby
<nerium>
Is there any lib for downloading a partial file using Ruby?
<ferret_guy>
the passenger IRC irc dead :/ gotta wait at least a couple hours for help
<Senjai>
ferret_guy: I know this isn't a solution to your issue, have you considered using nginx instead?
<Senjai>
If you have the flexibility to do so
<ferret_guy>
@Senjai kinda locked in
Sehryn has joined #ruby
<Senjai>
That's mega unfortunate
<ferret_guy>
yep :(
<bricker>
ferret_guy: what's the problemz
<zenspider>
jhack: only you can say whether you're ready.
<ferret_guy>
I am using passenger with apache and when I load the page I configured it shows the directory as opposed to the ruby app
<jhack>
@zen
<zenspider>
if you're willing to go nose down and really work for it, you can get a lot of value out of the structure that a bootcamp can provide. if not... well... don't waste your money until you are ready