Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Needs to support Markdown READMEs for Sinatra 1.4.0 #97

Closed
rkh opened this issue Feb 25, 2013 · 18 comments
Closed

Needs to support Markdown READMEs for Sinatra 1.4.0 #97

rkh opened this issue Feb 25, 2013 · 18 comments

Comments

@rkh
Copy link
Member

rkh commented Feb 25, 2013

No description provided.

@duckinator
Copy link

Can you elaborate a bit? I'm not sure what exactly you're asking for here.

If you elaborate a bit and I know enough to do it, I'll take it. :)

@rkh
Copy link
Member Author

rkh commented Feb 25, 2013

intro-.html files are currently generated from README..rdoc files from the sinatra/sinatra repo. Howerver, in master, the upcoming Sinatra 1.4.0 release, most of these are now *.md files.

@rkh
Copy link
Member Author

rkh commented Feb 25, 2013

The (not that nice) code is in Rakefile.

@duckinator
Copy link

Ah, gotcha. I'll start poking around tomorrow after I get some sleep! If you've got any tidbits that you think would be of help, just dump them here and I'll read them before getting started in the morning.

@kgrz
Copy link
Member

kgrz commented Feb 25, 2013

First one would be to remove the rdoc_to_html generation and add-in a markdown to html parser like maruku.

@rkh
Copy link
Member Author

rkh commented Feb 25, 2013

If we remove it, we need to convert all the outstanding rdoc files to markdown, too.

@kgrz
Copy link
Member

kgrz commented Feb 25, 2013

That is true. I forgot there are still some Readmes pending.

@burningTyger
Copy link
Member

rdoc 4 parses markdown and rdoc just fine.

@duckinator
Copy link

@rkh I was actually really looking forward to working on this, but I'm gonna have to back out. Short version is "family issues." Github's not the place to discuss it further than that. Sorry I didn't get back to you quicker this morning about that.

@kgrz
Copy link
Member

kgrz commented Feb 26, 2013

I've been fiddling with the Rakefile. Trying out the various Markdown parsers to get proper code-block parsing but failing miserably. Will update soon.

@burningTyger The Rdoc 4 Markdown parser doesn't support fenced codeblocks I think :/ Having trouble "requiring" the right file while using it but wasn't lucky in my attempts.

@rkh
Copy link
Member Author

rkh commented Feb 26, 2013

I think you can use redcarpet plus some option to get it working.

@kgrz
Copy link
Member

kgrz commented Feb 26, 2013

Tried that. The parsing happens well but the table of contents is being
generated after the first header block. Will check other options in a
while. Dinner time :)

On Tuesday, February 26, 2013, Konstantin Haase wrote:

I think you can use redcarpet plus some option to get it working.


Reply to this email directly or view it on GitHubhttps://github.com//issues/97#issuecomment-14115317
.

Kashyap KMBC

@rkh
Copy link
Member Author

rkh commented Feb 26, 2013

I also added a ToC to the README.md, not sure if we wanna reuse that or remove that.

@kgrz
Copy link
Member

kgrz commented Feb 26, 2013

Oh! I think that needs to be removed (especially if Redcarpet is to be
used) since the html IDs that get generated are messing with the ToC IDs
generated in the README body. I'll try some options and see if anything
works.

On Tue, Feb 26, 2013 at 7:40 PM, Konstantin Haase
notifications@github.comwrote:

I also added a ToC to the README.md, not sure if we wanna reuse that or
remove that.


Reply to this email directly or view it on GitHubhttps://github.com//issues/97#issuecomment-14115960
.

Kashyap KMBC

@kgrz
Copy link
Member

kgrz commented Feb 26, 2013

This works with the current snapshot of the Sinatra repo: kgrz@1b77777 (except the inline ToC which can be enabled if needed)

This is a hack at best. This checks for each of the languages where the READMEs are still in RDoc and, depending on the list, parse the README either using the RDoc parser or the Redcarpet markdown parser. This will break if the main Sinatra repo gets updated with a new README. However, I think this can server the purpose if this is what holding back the 1.4.0 release.

@rkh The ToC gets generated twice in the english README section. Either this should be removed entirely from the README or a <div> can be added surrounding the ToC and can be hidden via JS.

@rkh
Copy link
Member Author

rkh commented Mar 7, 2013

All Markdown now!

@rkh
Copy link
Member Author

rkh commented Mar 10, 2013

See #100

@rkh rkh closed this as completed Mar 10, 2013
@rkh
Copy link
Member Author

rkh commented Mar 10, 2013

@kgrz I gave you commit access.

@rkh rkh mentioned this issue Mar 10, 2013
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants