[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Erb rdoc wrong?

Belorion

2/18/2006 5:53:00 PM

Greetings.

I am trying to use Erb to process a plain-text template. Following the RDoc
documentation at
http://www.ruby-doc.org/stdlib/libdoc/erb/rdoc/classe..., I can't get
the first plain-text example to work. ruby 1.8.2 (2004-12-25)
[i686-linux]. Below[1] is the actual sample script which isn't working
(it's not finding the local variables when processing the template). Any
ideas what's going on here? Thanks.

-Matt

[1]
require "erb"

# Create template.
template = %q{
From: James Edward Gray II <james@grayproductions.net>
To: <%= to %>
Subject: Addressing Needs

<%= to[/\w+/] %>:

Just wanted to send a quick note assuring that your needs are being
addressed.

I want you to know that my team will keep working on the issues,
especially:

<%# ignore numerous minor requests -- focus on priorities %>
% priorities.each do |priority|
* <%= priority %>
% end

Thanks for your patience.

James Edward Gray II
}.gsub(/^ /, '')

message = ERB.new(template, 0, "%<>")

# Set up template data.
to = "Community Spokesman <spokesman@ruby_community.org>"
priorities = [ "Run Ruby Quiz",
"Document Modules",
"Answer Questions on Ruby Talk" ]

# Produce result.
email = message.result
puts email
12 Answers

James Gray

2/18/2006 6:10:00 PM

0

On Feb 18, 2006, at 11:53 AM, Belorion wrote:

> Any ideas what's going on here?

Hmm, has ERB stopped defaulting to a top-level binding?

> email = message.result

Change that to:

email = message.result(binding)

Can someone please patch the docs for me?

James Edward Gray II


laraine

10/24/2010 6:13:00 AM

0

On Oct 22, 8:26 pm, "M. A." <not.for....@server.com> wrote:
> "M. A." <not.for....@server.com> wrote...
>
> > I have to try Trifonov.
>
> Phew, I prefer it when Chopin sounds less faggy...
>
> M. A.

?

O

10/24/2010 4:29:00 PM

0

In article
<86f6f9ee-2a24-4a91-a2ac-60ea437fa6a9@l14g2000yqb.googlegroups.com>,
laraine <laraine6@gmail.com> wrote:

> On Oct 22, 8:26?pm, "M. A." <not.for....@server.com> wrote:
> > "M. A." <not.for....@server.com> wrote...
> >
> > > I have to try Trifonov.
> >
> > Phew, I prefer it when Chopin sounds less faggy...
> >
> > M. A.
>
> ?

I think M.A. has just gotten himself fired from NPR.

-Owen

M. A.

10/24/2010 5:35:00 PM

0

"laraine" <laraine6@gmail.com> wrote...
>
> On Oct 22, 8:26 pm, "M. A." <not.for....@server.com> wrote:
> > "M. A." <not.for....@server.com> wrote...
> > >
> > > I have to try Trifonov.
> >
> > Phew, I prefer it when Chopin sounds less faggy...
>
> ?

Laraine, let me clarify for you:

I have listened to (and watched) Trifonov's first round, and I quite
strongly dislike how he smoothes away all the edges. I dislike his
spineless and limp-wristed demeanor on stage, too, just as much as I dislike
Bozhanov's funny faces. But Bozhanov has some strong and interesting ideas,
whereas Trifonov seems to attempt to make Chopin a listening experience as
soft and inoffensive as possible.

You might argue that from all the accounts of Chopin's own soft playing and
fragile appearance, Trifonov might actually have been a worthy Chopin
Competition winner -- but still, I, for one, and based on what I have
listened to and seen in Trifonov's first round, don't like Chopin played
this way.

M. A.

pianomaven

10/24/2010 9:34:00 PM

0

On Oct 24, 1:34 pm, "M. A." <not.for....@server.com> wrote:
> "laraine" <larai...@gmail.com> wrote...
>
> > On Oct 22, 8:26 pm, "M. A." <not.for....@server.com> wrote:
> > > "M. A." <not.for....@server.com> wrote...
>
> > > > I have to try Trifonov.
>
> > > Phew, I prefer it when Chopin sounds less faggy...
>
> > ?
>
> Laraine, let me clarify for you:
>
> I have listened to (and watched) Trifonov's first round, and I quite
> strongly dislike how he smoothes away all the edges.  I dislike his
> spineless and limp-wristed demeanor on stage, too, just as much as I dislike
> Bozhanov's funny faces.  But Bozhanov has some strong and interesting ideas,
> whereas Trifonov seems to attempt to make Chopin a listening experience as
> soft and inoffensive as possible.
>
> You might argue that from all the accounts of Chopin's own soft playing and
> fragile appearance, Trifonov might actually have been a worthy Chopin
> Competition winner -- but still, I, for one, and based on what I have
> listened to and seen in Trifonov's first round, don't like Chopin played
> this way.

Fair enough.

But there is NO call whatsoever to refer to his playing as "faggy".
That's the kind of mindless comment one might expect from a 13 year
old on the school playground. It has no place here. For all you know
Trifonov is a macho stud, but likes soft Chopin.

I don't care for Chopin that way either, but lots do, you know.
Pianists have made careers making the ladies swoon with such playing.

Advice: grow up.

TD

M. A.

10/24/2010 11:03:00 PM

0

"pianomaven" <1pianomaven@gmail.com> wrote...
>
> But there is NO call whatsoever to refer to his playing as "faggy".
> That's the kind of mindless comment one might expect from a 13 year
> old on the school playground. It has no place here. [...]

I'm surprised. RMCR actually does feel like a school playground most of the
time - which includes (but certainly is not limited to) your discussions
with Arri.

M. A.

William Sommerwerck

10/24/2010 11:35:00 PM

0

> But there is NO call whatsoever to refer to his playing as "faggy".

It's a terrible choice or words, but Chopin can too-easily be interpreted in
"precious" sort of way.


pianomaven

10/25/2010 12:47:00 AM

0

On Oct 24, 7:02 pm, "M. A." <not.for....@server.com> wrote:
> "pianomaven" <1pianoma...@gmail.com> wrote...
>
> > But there is NO call whatsoever to refer to his playing as "faggy".
> > That's the kind of mindless comment one might expect from a 13 year
> > old on the school playground. It has no place here. [...]
>
> I'm surprised.  RMCR actually does feel like a school playground most of the
> time - which includes (but certainly is not limited to) your discussions
> with Arri.

Arri and I have a mutual respect: for each other's deafness.

Your comment has no justification whatsoever. Moreover you know it.

Which only makes you either a fag baiter or a self-loathing fag. Which
one it is I leave to your shrink.

TD

pianomaven

10/25/2010 12:50:00 AM

0

On Oct 24, 7:34 pm, "William Sommerwerck" <grizzledgee...@comcast.net>
wrote:
> > But there is NO call whatsoever to refer to his playing as "faggy".
>
> It's a terrible choice or words, but Chopin can too-easily be interpreted in
> "precious" sort of way.

Mannered is the usual term.

Perfumed would be another.

Salonard yet another.

TD

bassppn

10/25/2010 1:30:00 AM

0

On Oct 24, 7:02 pm, "M. A." <not.for....@server.com> wrote:
> "pianomaven" <1pianoma...@gmail.com> wrote...
>
> > But there is NO call whatsoever to refer to his playing as "faggy".
> > That's the kind of mindless comment one might expect from a 13 year
> > old on the school playground. It has no place here. [...]
>
> I'm surprised.  RMCR actually does feel like a school playground most of the
> time - which includes (but certainly is not limited to) your discussions
> with Arri.
>
> M. A.

dont know why my name was invoked in this conversation. But i do agree
with TD that using the word "faggy" is beyond stupid.
Just finished my second post at the great-pianits ng where I thorougly
trash Avdeeva... what drab, uninteresting playing. The whole
competition is a fraud if that type of playing wins top prize.

AB