<nofxx>
is there some clever way to add a separator to the beginning of the join? scenario: EXTRA_LIBS.join(" -I") on a Rakefile, if it's empty I can't have a '-I' lying around...
<nofxx>
nah... gonna rewrite it better
<wallerdev>
it won't add it if the array is empty
<wallerdev>
oh
<wallerdev>
i see what yours saying
<nofxx>
wallerdev, I know but I need one prefixed
<nofxx>
heh
<wallerdev>
i would just use map { add to the beginning }.join
wimplash [wimplash!~Adium@63.131.95.235] has joined #ruby-lang
<drbrain>
compact.join
<wallerdev>
i don't think he's talking about nil entries
<erikh>
there's nothing but this to look at, just trying to work out the initial idea
dnjaramba [dnjaramba!~dnjaramba@41.72.193.86] has joined #ruby-lang
<acts_as>
This a Monit / God replacement idea?
<acts_as>
It'd be amazing if you come up with something that doesn't blow
Pip [Pip!~Pip@host-88-156-66-217.spbmts.ru] has joined #ruby-lang
Pip [Pip!~Pip@unaffiliated/pip] has joined #ruby-lang
<Guest84119>
Is there anyone here who would be able to help me with installing ruby with rbenv and ruby-build using ubuntu 11.04?
<nofxx>
Writing a script to realtime read/write from serial: Create a thread that infinite loops reading from the port, sleeps 1/100 sec. Main thread waits for input -> while line = STDIN.gets.strip . Is this the correct way? Am I missing something ?
krz [krz!~foobar@unaffiliated/krz] has joined #ruby-lang
<acts_as>
cola_zero: Yeah, llvm is a piece of shit. I uninstalled XCode and installed that, but it's still all kinds of f'd up.
<AlecTaylor>
RubyEventMachine hates me
<acts_as>
cola_zero: I suspect that because some formula in Homebrew were fubar, and the maintainers are shitheads, I compiled with plain old gcc. Now this cesspool needs to be drained.
<bnagy>
nofxx: not sure, you can't use select?
<nofxx>
bnagy, select ?
<bnagy>
I haven't done serial, but I have done some pipey stuff and sleep(x) seems ugly
<nofxx>
bnagy, yea... serial is the example, was thinking of any kind of OP like this... chat app for instance
<bnagy>
I could improve my bitmap encoder / compressor quite a bit, which is the current champ for maxvals that are small enough to build a bitstring of in memory
<bnagy>
I couldn't find a current bitvector gem :/
<bnagy>
but the sparse matrix thingy performs well overall, and wins egregiously once the maxvals get big
<bnagy>
only cause my bitstring is totally naive though
<bnagy>
anyway, boring. Gotta go play pool and drink
<manveru>
i've written a BERT loader/dumper... it's not suitable for that problem i fear
<manveru>
i mean, it's kinda like BER, but if you only need to handle 32bit ints, then why waste the type information bits?
<bnagy>
HA I could use flip flop! Like...legitimately!
toretore [toretore!~toretore@crr06-3-82-231-12-81.fbx.proxad.net] has joined #ruby-lang
<bnagy>
if I store [sequential_1s,sequential_0s,sequential_1s.....] and pack it
<bnagy>
I am so coding that tomorrow
<manveru>
:)
<manveru>
have fun
<manveru>
i still gotta make two gems today :(
Dreamer3 [Dreamer3!~Dreamer3@74-134-34-116.dhcp.insightbb.com] has joined #ruby-lang
<shevy>
manveru, what gems?
<manveru>
jsonh and pgpass
pieterm [pieterm!~pieterm@cable-212.76.229.116.static.coditel.net] has joined #ruby-lang
robotmay [robotmay!~robotmay@94.30.13.228] has joined #ruby-lang
ConstantineXVI [ConstantineXVI!~constanti@216-24-48-34.ip.win.net] has joined #ruby-lang
enikar [enikar!~gil@cl-140.mrs-01.fr.sixxs.net] has joined #ruby-lang
aGiantPanda [aGiantPanda!~xuwen@70-36-146-89.dsl.dynamic.sonic.net] has joined #ruby-lang
aGiantPanda [aGiantPanda!~xuwen@70-36-146-89.dsl.dynamic.sonic.net] has quit [#ruby-lang]
Fractality [Fractality!~bjoern@g225036023.adsl.alicedsl.de] has joined #ruby-lang
davidw [davidw!~davidw@apache/committer/davidw] has joined #ruby-lang
rolfb [rolfb!~rolfb@77.94.232.40] has joined #ruby-lang
gix [gix!~gix@e180023198.adsl.alicedsl.de] has joined #ruby-lang
S3kx [S3kx!~S1kx@ip-95-223-80-198.unitymediagroup.de] has joined #ruby-lang
Banistergalaxy [Banistergalaxy!~AndChat@222.153.223.42] has joined #ruby-lang
mksm [mksm!~ramorim@li168-21.members.linode.com] has joined #ruby-lang
pabs [pabs!~pabs@ip68-98-175-235.dc.dc.cox.net] has joined #ruby-lang
cyndis [cyndis!cyndis@lakka.kapsi.fi] has joined #ruby-lang
imajes [imajes!~imajes@is.imaj.es] has joined #ruby-lang
gentz [gentz!ilab@ancient.webfoundation.net] has joined #ruby-lang
robgough [robgough!~robgough@li184-32.members.linode.com] has joined #ruby-lang
DefV [DefV!~Jan@node-hahmcop4no4a1ruk1w.ipv6.as30961.net] has joined #ruby-lang
sinuc [sinuc!~sinuc@irssi.sinuc.boxnet.eu] has joined #ruby-lang
sinuc [sinuc!~sinuc@unaffiliated/sinuc] has joined #ruby-lang
alexeyKolosov [alexeyKolosov!~quassel@ns1.zbku.ru] has joined #ruby-lang
slaytanic [slaytanic!~slaytanic@200-55-73-253.dsl.prima.net.ar] has joined #ruby-lang
QaDeS [QaDeS!~mklaus@frbg-4d029576.pool.mediaWays.net] has joined #ruby-lang
tris [tris!tristan@2001:1868:a00a::4] has joined #ruby-lang
Wardrop [Wardrop!~tomwardro@86.46.96.58.static.exetel.com.au] has joined #ruby-lang
SpitfireWP [SpitfireWP!spitfire@wikipedia/spitfire] has joined #ruby-lang
<Wardrop>
Does anyone know of a way to print from code using ERB. The <%= %> syntax is all well and good, but sometimes, especially when using a ternary operator, having an inline print method would be very convenient. E.g. <% (self.isValid) ? put 'good' : put 'bad' %> - replace #put with any other short method name.
<Wardrop>
Backbone.js copies ERB with it's templating, but it supports a print method in addition to the <%= %> syntax, so you can do exactly as I demonstrated above.
Ttech [Ttech!ttech@botters/staff/ttech] has joined #ruby-lang
<rippa>
<%= (self.isValid) ? 'good' : 'bad' %>
furbage [furbage!~james@213.246.135.171] has joined #ruby-lang
<Wardrop>
Yeah, that was a bad example. It's better actually in more complex expression, or where multiple conditions are needed, where inserting one or many <%= %> blocks is awkward and breaks the readability of the code. The problem is breaking out of a normal <% %> code block to just to output a small amount of text, when it would have been much easier and more readable to just do something like: put colour, instead of %><%= colour %><%.
<Wardrop>
rippa: That was for you
priteshjain [priteshjain!~priteshja@115.248.175.50] has joined #ruby-lang
<rippa>
I don't think there's anything like that
furbage [furbage!~james@213.246.135.171] has joined #ruby-lang
kitallis [kitallis!~kitallis@122.172.248.47] has joined #ruby-lang
burgestrand [burgestrand!~burgestra@dhcp-188018.eduroam.chalmers.se] has joined #ruby-lang
dbussink [dbussink!~dbussink@elle.fallingsnow.net] has joined #ruby-lang
g0bl1n_ [g0bl1n_!~g0blin@a213-22-27-14.cpe.netcabo.pt] has joined #ruby-lang
g0bl1n_ [g0bl1n_!~g0blin@unaffiliated/g0bl1n] has joined #ruby-lang
<manveru>
Wardrop: usually you don't put such code into a template...
<manveru>
also backbone doesn't have templating itself, you mean underscore?
Spooner [Spooner!~Miranda@host-78-144-139-130.as13285.net] has joined #ruby-lang
Pip [Pip!~Pip@unaffiliated/pip] has joined #ruby-lang
burgestrand [burgestrand!~burgestra@dhcp-187042.eduroam.chalmers.se] has joined #ruby-lang
<shevy>
the problem with templates is that they are so ugly
runeb [runeb!~runeb@77.40.155.28] has joined #ruby-lang
burgestrand [burgestrand!~burgestra@dhcp-187042.eduroam.chalmers.se] has joined #ruby-lang
runeb [runeb!~runeb@77.40.155.28] has joined #ruby-lang
Pip [Pip!~Pip@host-191-146-66-217.spbmts.ru] has joined #ruby-lang
Pip [Pip!~Pip@unaffiliated/pip] has joined #ruby-lang
mztriz [mztriz!~mztriz@74-136-75-114.dhcp.insightbb.com] has joined #ruby-lang
retro|cz [retro|cz!~retro@106.142.broadband6.iol.cz] has joined #ruby-lang
bryanl [bryanl!~bryanl@li362-49.members.linode.com] has joined #ruby-lang
stephenp [stephenp!~stephenp@gatepost.hos.net] has joined #ruby-lang
yadav [yadav!~quassel@dsl-173-248-230-235.acanac.net] has joined #ruby-lang
rolfb [rolfb!~rolfb@77.94.232.40] has joined #ruby-lang
dous_ [dous_!~dous@cm171.sigma67.maxonline.com.sg] has joined #ruby-lang
burgestrand [burgestrand!~burgestra@dhcp-191046.eduroam.chalmers.se] has joined #ruby-lang
yfeldblum [yfeldblum!~Jay@pool-71-246-76-76.bltmmd.east.verizon.net] has joined #ruby-lang
dv310p3r [dv310p3r!~dv310p3r@host-208-68-238-122.biznesshosting.net] has joined #ruby-lang
Locke23rus_ [Locke23rus_!~quassel@128-70-13-32.broadband.corbina.ru] has joined #ruby-lang
voker57 [voker57!~voker57@128-70-25-242.broadband.corbina.ru] has joined #ruby-lang
voker57 [voker57!~voker57@kvirc/developer/Voker57] has joined #ruby-lang
szarubin [szarubin!stas@188.163.26.61] has joined #ruby-lang
krz [krz!~foobar@unaffiliated/krz] has joined #ruby-lang
tekin [tekin!~tekin@host-78-151-24-9.as13285.net] has joined #ruby-lang
diddy [diddy!diddy@41.92.156.231] has joined #ruby-lang
Defusal [Defusal!~DeFi@41-133-238-54.dsl.mweb.co.za] has joined #ruby-lang
Defusal [Defusal!~DeFi@unaffiliated/ecnerifed] has joined #ruby-lang
Indian [Indian!~Indian@unaffiliated/londonmet050] has joined #ruby-lang
Defusal_ [Defusal_!DeFi@unaffiliated/ecnerifed] has joined #ruby-lang
mark_locklear [mark_locklear!~jlocklear@ab-tech-lan-to-ab-tech-gw.ncren.net] has joined #ruby-lang
amerine [amerine!~mturner@206.205.72.226] has joined #ruby-lang
diddy [diddy!diddy@41.92.156.231] has joined #ruby-lang
bglusman [bglusman!~bglusman@c-68-80-200-61.hsd1.pa.comcast.net] has joined #ruby-lang
wmoxam [wmoxam!~wmoxam@pdpc/supporter/active/wmoxam] has joined #ruby-lang
zkl [zkl!zkl@morpheus.net] has joined #ruby-lang
slyphon [slyphon!~weechat@unaffiliated/slyphon] has joined #ruby-lang
burgestrand [burgestrand!~burgestra@host.62.65.124.23.bitcom.se] has joined #ruby-lang
gnufied [gnufied!~gnufied@122.172.224.153] has joined #ruby-lang
rshackleford [rshackleford!~mike@host154.181-14-121.telecom.net.ar] has joined #ruby-lang
rippa [rippa!~rippa@93-181-232-63.adsl.yaroslavl.ru] has joined #ruby-lang
Sailias [Sailias!~jonathan@s72-38-77-178.static.comm.cgocable.net] has joined #ruby-lang
elux_ [elux_!~peter@96.45.198.150] has joined #ruby-lang
sora_h [sora_h!~sora_h@mayfield.privs.net] has joined #ruby-lang
gianlucadv [gianlucadv!~gianlucad@st-dellaved.statistica.unimib.it] has joined #ruby-lang
ap3mantus [ap3mantus!~ap3mantus@c-98-217-179-108.hsd1.ma.comcast.net] has joined #ruby-lang
leonL [leonL!~leonl@74-115-197-34.eng.wind.ca] has joined #ruby-lang
tomzx [tomzx!~tomzx@dsl-156-68.aei.ca] has joined #ruby-lang
AlecTaylor [AlecTaylor!~alectaylo@unaffiliated/alectaylor] has joined #ruby-lang
queequeg1 [queequeg1!~chatzilla@c-71-202-152-67.hsd1.ca.comcast.net] has joined #ruby-lang
JEG2 [JEG2!~JEG2@ip72-198-103-217.ok.ok.cox.net] has joined #ruby-lang
elux [elux!~peter@96.45.198.150] has joined #ruby-lang
outoftime [outoftime!~mat@ip-160-79-101-2.autorev.intellispace.net] has joined #ruby-lang
malev [malev!~malev@190.210.138.237] has joined #ruby-lang
imajes [imajes!~imajes@is.imaj.es] has joined #ruby-lang
chris2 [chris2!~chris@vuxu.org] has joined #ruby-lang
andrewhl [andrewhl!~andrew@24-246-14-26.cable.teksavvy.com] has joined #ruby-lang
jbwiv [jbwiv!~wellsj@world.timcogso.com] has joined #ruby-lang
ap3mantus [ap3mantus!~ap3mantus@c-98-217-187-172.hsd1.ma.comcast.net] has joined #ruby-lang
vbatts [vbatts!~vbatts@hashbangbash.com] has joined #ruby-lang
jensn [jensn!~Jens@c-83-233-145-148.cust.bredband2.com] has joined #ruby-lang
Taylor [Taylor!~alectaylo@CPE-58-164-16-161.lnse5.ken.bigpond.net.au] has joined #ruby-lang
michael_mbp [michael_mbp!~Marin@31.203.10.218] has joined #ruby-lang
perryh_ [perryh_!~root@unaffiliated/perry753] has joined #ruby-lang
robbrit [robbrit!~rob@38.108.76.250] has joined #ruby-lang
indstry [indstry!~apple@c-71-238-98-243.hsd1.mi.comcast.net] has joined #ruby-lang
darkf [darkf!~darkf_dix@unaffiliated/darkf] has joined #ruby-lang
burgestrand [burgestrand!~burgestra@host.62.65.124.23.bitcom.se] has joined #ruby-lang
ttilley [ttilley!~ttilley@unaffiliated/lv] has joined #ruby-lang
slyphon [slyphon!~weechat@unaffiliated/slyphon] has joined #ruby-lang
RomyEatsDrupal [RomyEatsDrupal!~stickycak@cpe-69-203-115-155.nyc.res.rr.com] has joined #ruby-lang
tbuehlmann [tbuehlmann!~Tobias@unaffiliated/tovias] has joined #ruby-lang
heftig [heftig!~Jan@archlinux/developer/heftig] has joined #ruby-lang
enikar [enikar!~gil@cl-140.mrs-01.fr.sixxs.net] has joined #ruby-lang
Austin__ [Austin__!~austin@96.45.197.22] has joined #ruby-lang
retro|cz [retro|cz!~retro@106.142.broadband6.iol.cz] has joined #ruby-lang
suckerpunch [suckerpunch!~suckerpun@host81-148-10-179.in-addr.btopenworld.com] has joined #ruby-lang
noize_hioki [noize_hioki!~noize_hio@ai126194000253.1.tss.access-internet.ne.jp] has joined #ruby-lang
dejongge [dejongge!~jonke@pD9E0E0AE.dip0.t-ipconnect.de] has joined #ruby-lang
mfournier [mfournier!~marc@2001:4b98:dc0:51:216:3eff:feac:7652] has joined #ruby-lang
spleeze [spleeze!~Spleeze@173-15-131-114-BusName-Philadelphia.hfc.comcastbusiness.net] has joined #ruby-lang
cynosure [cynosure!~cynosure@centrumnet.hu] has joined #ruby-lang
nofxx [nofxx!~nofxx@unaffiliated/nofxx] has joined #ruby-lang
tekin_ [tekin_!~tekin@82.132.238.116] has joined #ruby-lang
leonL [leonL!~leonl@199-7-156-43.eng.wind.ca] has joined #ruby-lang
runeb [runeb!~runeb@77.40.155.28] has joined #ruby-lang
runeb [runeb!~runeb@77.40.155.28] has joined #ruby-lang
runeb [runeb!~runeb@77.40.155.28] has joined #ruby-lang
robgleeson [robgleeson!~rob@subtle/contributor/robgleeson] has joined #ruby-lang
headius [headius!~headius@71-210-154-45.mpls.qwest.net] has joined #ruby-lang
<slyphon>
injekt: ping?
<slyphon>
dammit
* slyphon
slaps slop
tekin [tekin!~tekin@82.132.239.127] has joined #ruby-lang
tekin [tekin!~tekin@82.132.237.194] has joined #ruby-lang
rippa [rippa!~rippa@93-181-232-63.adsl.yaroslavl.ru] has joined #ruby-lang
burgestrand [burgestrand!~burgestra@h-45-63.a155.priv.bahnhof.se] has joined #ruby-lang
niklasb [niklasb!~codeslay0@p5B31098D.dip0.t-ipconnect.de] has joined #ruby-lang
savage- [savage-!~savage-@209.118.197.220] has joined #ruby-lang
savage- [savage-!~savage-@209.118.197.220] has joined #ruby-lang
SuperTaz_work [SuperTaz_work!~supertaz_@38.99.52.59] has joined #ruby-lang
mztriz [mztriz!~mztriz@nkugateway.nku.edu] has joined #ruby-lang
Indian_ [Indian_!~Indian@unaffiliated/londonmet050] has joined #ruby-lang
gianlucadv [gianlucadv!~gianlucad@109.53.188.130] has joined #ruby-lang
scampbell [scampbell!~scampbell@c-98-224-240-62.hsd1.mi.comcast.net] has joined #ruby-lang
<rue>
PEEENG
<rue>
slyphon: Are you trying to use software for the wrong things again?
<slyphon>
nah
<slyphon>
i was "doing it wrong"
<slyphon>
it's on :a, :apple, 'this is an apple', true, :optional => true
<slyphon>
the 'true' is the salient bit
<slyphon>
i mean OF COURSE
mark_azevedo [mark_azevedo!~mark_azev@adsl-76-228-82-246.dsl.pltn13.sbcglobal.net] has joined #ruby-lang
<rue>
See?
<slyphon>
:)
runeb [runeb!~runeb@cm-84.215.181.150.getinternet.no] has joined #ruby-lang
solars [solars!~solars@mk089144206075.a1.net] has joined #ruby-lang
sepp2k [sepp2k!~sexy@g230249099.adsl.alicedsl.de] has joined #ruby-lang
jMCg [jMCg!~hiro@apache/committer/igalic] has joined #ruby-lang
jeremy_ross [jeremy_ross!~jeremy_ro@cpe-76-186-157-98.tx.res.rr.com] has joined #ruby-lang
<rue>
The system call, not mktemp.exe or whatever?
<imperator>
the C function, _mktemp
corsican [corsican!corsican@50-79-33-41-static.hfc.comcastbusiness.net] has joined #ruby-lang
<imperator>
_mktemp_s is no better
<imperator>
hm, how do you explicitly raise EINVAL?
* imperator
is spacing
mark_azevedo [mark_azevedo!~mark_azev@adsl-76-228-82-246.dsl.pltn13.sbcglobal.net] has joined #ruby-lang
<rue>
Errno::EINVAL?
<imperator>
can't seem to do raise Errno::EINVAL, though, unless irb is goofing me up
<apeiros_>
ruby-1.9.2:013:0>> raise Errno::EINVAL
<apeiros_>
Errno::EINVAL: Invalid argument
<apeiros_>
works here
<apeiros_>
platform specific?
<erikh>
yes
<imperator>
oh, i guess i misinterpreted that
<imperator>
i thought ruby was telling me that Errno::EINVAL itself was an invalid argument, duh
<erikh>
oh ha
<apeiros_>
g
ro_70s [ro_70s!~rob@pool-96-255-9-205.washdc.fios.verizon.net] has joined #ruby-lang
ro_70s [ro_70s!~rob@pool-96-255-9-205.washdc.fios.verizon.net] has quit [#ruby-lang]
<imperator>
there's always SystemCallError.new(22), too ;)
<erikh>
you hacker
<apeiros_>
that's a compliment, right?
<apeiros_>
like nerd & geek…
csherin [csherin!~csherin@61.17.32.83] has joined #ruby-lang
<erikh>
yes it was a compliment.
<ReinH>
so apparently that whole think about using the socratic method to convince him to forgo POSIX compliance and just use the Ruby public API for making a new tempfile name didn't have the hoped for result
<ReinH>
s/think/thing
<ReinH>
wah wah
<rue>
More like Suckrates, amirite
<erikh>
so crates
<erikh>
wyld stallyns rules
<imperator>
bill & ted
<erikh>
the only movie keanu reeves was good in
<imperator>
ReinH, it might have something to do with the fact that it's for a gem that competes with Ruby's tempfile lib :)
jredville [jredville!~james.dev@c-66-235-23-17.sea.wa.customer.broadstripe.net] has joined #ruby-lang
ricardovaleriano [ricardovaleriano!~ricardova@189-69-29-244.dsl.telesp.net.br] has joined #ruby-lang
robbrit [robbrit!~rob@38.108.76.250] has quit [#ruby-lang]
ap3mantus [ap3mantus!~ap3mantus@c-98-217-187-172.hsd1.ma.comcast.net] has joined #ruby-lang
spleeze [spleeze!~Spleeze@173-15-131-114-BusName-Philadelphia.hfc.comcastbusiness.net] has joined #ruby-lang
srbaker [srbaker!~srbaker@184.66.82.213] has joined #ruby-lang
<slyphon>
orly?
* slyphon
bangs on the side of his sarcasm-detector
<drbrain>
now I'm looking at how the files get chosen to see why rake-0.8.7 would show up twice
<slyphon>
kk
ryanf [ryanf!~rfitz@ec2-50-18-158-149.us-west-1.compute.amazonaws.com] has joined #ruby-lang
SkramX [SkramX!~SkramX@128.164.114.248] has joined #ruby-lang
csherin [csherin!~csherin@61.17.32.83] has joined #ruby-lang
<drbrain>
the mtime filtering code only looks at each gem once
<slyphon>
u/u
<drbrain>
and the gem list comes from: Dir[File.join(@dest_directory, "gems", '*.gem')]
<slyphon>
thlksadjflakjsdflskjflaj
<slyphon>
sorry
<drbrain>
… but you only have one rake
<drbrain>
… rake-0.8.7
<drbrain>
There's no way Dir[] is broken
<slyphon>
yeah, doublt it
<drbrain>
is it always rake-0.8.7 that's dup'd, or is it random stuff?
<slyphon>
lemme try again
<slyphon>
hmm
<slyphon>
that's odd
<slyphon>
i ran it a second time and i get "No new gems"
<apeiros_>
damit, I want my real keyword args. now. >:(
<drbrain>
yeah, that's to be expected
<slyphon>
ah
uniqanomaly_ [uniqanomaly_!~ua@dynamic-87-105-21-16.ssp.dialog.net.pl] has joined #ruby-lang
<slyphon>
drbrain: should i touch a bunch of stuff?
SkramX [SkramX!~SkramX@128.164.155.166] has joined #ruby-lang
* slyphon
does the "I'm not touching you" thing to drbrain
<drbrain>
it updates the index file first then copies in the .gemspec
<drbrain>
slyphon: sure, touch a bunch of .gem files
<slyphon>
drbrain: oh, weird, that might explain why we sometimes get errors where the index seems to see a gem but then when you try to install it it fails
<drbrain>
slyphon: can you file an issue with your first gist against rubygems like "rubygems should continue when a gemspec is missing" or something
<drbrain>
at least I can make it continue when a file is missing :/
<drbrain>
but update_index doesn't go through that path
retro|cz [retro|cz!~retro@ip-86-49-73-114.net.upcbroadband.cz] has joined #ruby-lang
tenderlove [tenderlove!~tenderlov@pdpc/supporter/active/tenderlove] has joined #ruby-lang
<slyphon>
i added `p marshal_name => spec_file_name` @ line 177
<apeiros_>
btw., zenspider - solved that euler with the division?
<zenspider>
apeiros_: um... which one?
<apeiros_>
I think it was the one where you had to find the division with the longest repeating pattern or somesuch
<slyphon>
holy crap the internet sucks in this place
<slyphon>
note to "coworking facility managers", make the internet not suck
<apeiros_>
problem 26, I think
<apeiros_>
"Find the value of d 1000 for which 1/d contains the longest recurring cycle in its decimal fraction part"
<slyphon>
hmm
<slyphon>
drbrain: well, from my inexpert analysis, that shouldn't be called
My_Hearing [My_Hearing!~Mon_Ouie@subtle/user/MonOuie] has joined #ruby-lang
<zenspider>
apeiros_: yeah. I finally broke down and did that one by teaching it long division... but it turns out there is a much easier way in mathematica
<apeiros_>
heh, mathematica…
<slyphon>
`gem generate_index --update -V -d .`
<zenspider>
hrm. I must have given up and done it in ruby...
srbartlett [srbartlett!~srbartlet@202.146.7.239] has joined #ruby-lang
<slyphon>
drbrain: oh oh, no it does
<drbrain>
slyphon: build_marshal_specs ?
<slyphon>
yeah, called in update_index
<slyphon>
drbrain: oh, so it *looks* like you'd need ot do that Gem::Specification.dirs in update_index...oh right, you already said that
hagabaka [hagabaka!~hagabaka@cblmdm24-53-178-92.buckeyecom.net] has joined #ruby-lang
<zenspider>
apeiros_: I think in ruby I just taught it long division and kept looking for a repeate of the remainder
<zenspider>
repeat
hagabaka [hagabaka!~hagabaka@unaffiliated/hagabaka] has joined #ruby-lang
<zenspider>
stupid fingers
<apeiros_>
zenspider: yeah, that's about what I did too
<apeiros_>
then keep the longest (normal max)
postmodern [postmodern!~postmoder@c-71-237-178-98.hsd1.or.comcast.net] has joined #ruby-lang
<zenspider>
there... just did it in mathematica: Max[Table[Length[First[First[RealDigits[1/n]]]], {n, 1000}]] // Timing # => {0.044532, 982}
wallerdev [wallerdev!~wallerdev@72.44.102.30] has joined #ruby-lang
rpowell [rpowell!~rpowell@CPE-121-217-139-191.lnse2.cht.bigpond.net.au] has joined #ruby-lang
<apeiros_>
one-liner! yay!
leonL [leonL!~leonl@199.119.232.2] has joined #ruby-lang
corsican [corsican!corsican@50-79-33-41-static.hfc.comcastbusiness.net] has joined #ruby-lang
hagabaka [hagabaka!~hagabaka@unaffiliated/hagabaka] has joined #ruby-lang
robbyoconnor [robbyoconnor!~wakawaka@guifications/user/r0bby] has joined #ruby-lang
<zenspider>
_fast_ one liner
<erikh>
mathematica: the unruby
<zenspider>
so fun to code in tho... very very powerful
<erikh>
Never tried...
benanne [benanne!~rijdier@ip-83-134-149-227.dsl.scarlet.be] has joined #ruby-lang
rpowell [rpowell!~rpowell@CPE-121-217-139-191.lnse2.cht.bigpond.net.au] has joined #ruby-lang
hagabaka [hagabaka!~hagabaka@unaffiliated/hagabaka] has joined #ruby-lang
<andrewvos>
zenspider: Should I make a sinatra-inspired web framework in it??
<zenspider>
uhhh... it has _no_ OO at all... that'd be a challenge
<andrewvos>
even better
<andrewvos>
I am of course just telling bad jokes again though.
tenderlove [tenderlove!~tenderlov@pdpc/supporter/active/tenderlove] has joined #ruby-lang
<rpowell>
hey how would I batch rename a bunch of files called [something].css.sass to [something].sass in the terminal?
<drbrain>
hint: for f in *.css.sass; do …; done
Swimming_Bird [Swimming_Bird!~textual@64.70.114.89] has joined #ruby-lang
<zenspider>
rpowell: I have a perl script for that ;)
<rpowell>
yeah
<rpowell>
I should learn Perl one of these days
<zenspider>
it could just as easily be redone in ruby tho
spyvsspy [spyvsspy!~nonenone@209.145.177.162] has joined #ruby-lang
headius [headius!~headius@71-210-154-45.mpls.qwest.net] has joined #ruby-lang
uniqanomaly [uniqanomaly!~ua@dynamic-87-105-21-16.ssp.dialog.net.pl] has joined #ruby-lang
imperator2 [imperator2!~djberg96@184-96-109-96.hlrn.qwest.net] has joined #ruby-lang
My_Hearing [My_Hearing!~Mon_Ouie@subtle/user/MonOuie] has joined #ruby-lang
nuclearsandwich [nuclearsandwich!~nuclearsa@74-93-3-244-SFBA.hfc.comcastbusiness.net] has joined #ruby-lang
Carnage\ [Carnage\!~carnage@84-75-163-211.dclient.hispeed.ch] has joined #ruby-lang
suckerpunch [suckerpunch!~suckerpun@93-97-12-107.zone5.bethere.co.uk] has joined #ruby-lang
<wwalker>
rpowell: in ruby? if not, what distro? most distros have a rename command that does what you want, but the redhat/fedora one and the debian ubuntu one have different syntax
nuclears1ndwich [nuclears1ndwich!~nuclearsa@74-93-3-244-SFBA.hfc.comcastbusiness.net] has joined #ruby-lang
<rpowell>
I'm on OS X
<wwalker>
run the one from debian (as it's perl based)
<wwalker>
you could write your own rather simply, but there are all kinds of corner cases that the distro's rename commands have already coded around.
<rpowell>
yeah
<erikh>
are you talking about 'mv' or some hipster rename command?
jensn [jensn!~Jens@c-83-233-145-148.cust.bredband2.com] has joined #ruby-lang
<wwalker>
erikh: rename, been in most distros for years
* erikh
blinks
<zenspider>
yeah. no clue
havenn [havenn!~skipper@pool-71-189-127-140.lsanca.fios.verizon.net] has joined #ruby-lang
<wwalker>
rename.c - aeb 2000-01-01 from the linux-util package.
Spooner [Spooner!~Miranda@host-78-144-139-130.as13285.net] has joined #ruby-lang
matled- [matled-!~matled@85.131.246.184] has joined #ruby-lang
<erikh>
but.. mv is pretty portable
<erikh>
anyhow
Axsuul [Axsuul!~Axsuul@75-140-75-52.dhcp.mtpk.ca.charter.com] has joined #ruby-lang