Re: [nesta] Redcarpet support
- From:
- Misha Reyzlin
- Date:
- 2011-12-18 @ 19:24
Hello Graham, thanks for this link, my code has got old with the recent
updates then.
I am now able to see the content and there are no warnings from Maruku.
Is there some way to see what is actually being used in console though?
I was also using typogruby library in order to enhance typography of the
content.
I am now trying this in app.rb and I get errors:
module Nesta
class FileModel
def to_html ( scope = nil )
html = convert_to_html ( @format, scope, markup )
Typogruby.improve html
end
end
end
Here's what I get in the browser:
Boot Error
Something went wrong while loading config.ru
SyntaxError: /Users/m/rubycode/mishareyzlin.com/themes/mr/app.rb:7: syntax
error, unexpected ',', expecting ')' html = convert_to_html ( @format,
scope, markup ) ^ /Users/m/rubycode/mishareyzlin.com/themes/mr/app.rb:7:
syntax error, unexpected ')', expecting '=' /Users/m/rubycode/
mishareyzlin.com/themes/mr/app.rb:171: syntax error, unexpected
keyword_do_block, expecting keyword_end pages.select do |page| ^
/Users/m/rubycode/mishareyzlin.com/themes/mr/app.rb:172: syntax error,
unexpected tSTRING_BEG, expecting keyword_end page.path.include? "notes/" ^
/Users/m/rubycode/mishareyzlin.com/themes/mr/app.rb:228: syntax error,
unexpected keyword_end, expecting $end
Thanks!
On Sun, Dec 18, 2011 at 7:24 PM, Graham Ashton <graham@effectif.com> wrote:
> On 18 Dec 2011, at 17:43, Misha Reyzlin <mrejzlin@gmail.com> wrote:
>
> > How can I make Nesta parse markdown files with Redcarpet?
>
> Have a look at this:
>
> http://nestacms.com/docs/creating-content/changing-the-markdown-processor
>
Re: [nesta] Redcarpet support
- From:
- Graham Ashton
- Date:
- 2011-12-18 @ 19:29
On 18 Dec 2011, at 19:24, Misha Reyzlin wrote:
> Here's what I get in the browser:
> Boot Error
>
> Something went wrong while loading config.ru
> SyntaxError: /Users/m/rubycode/mishareyzlin.com/themes/mr/app.rb:7:
syntax error, unexpected ',', expecting ')' html = convert_to_html (
@format, scope, markup )
Your syntax error is caused by too much whitespace. Remove the space
between "convert_to_html" and "(" and it your method should compile.
To see which processor Tilt is using you'll have to investigate Tilt a
bit. I suspect there will be a way to get it to report which engine it's
using (though if you've added RedCarpet to your Gemfile, it'll be using
RedCarpet).
I'm short on time so can't check myself, but here are the docs:
https://github.com/rtomayko/tilt
Cheers,
Graham