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

Add support for README.txt and README files #911

Merged
merged 1 commit into from
Sep 20, 2022

Conversation

Atreyagaurav
Copy link
Contributor

Since we added support for readme.md I thought it'd be easy enough to do readme.txt and just plain readme.

I was thinking of adding support for readme.org like in GitHub but didn't find any libraries that can convert it easily.

Also, if I rename "README.md" from miniserve to .txt, it only shows a fraction of the file contents, I can't debug it...

@Atreyagaurav
Copy link
Contributor Author

Additional points:

It's trivial to add support for README.html, we can just insert the file contents to readme div, should I? I don't know if people use htmls as readme. But it might help if people want some advanced formatting or to convert unsupported formats to html (which preserves more info then converting to markdown).

@svenstaro
Copy link
Owner

Hm I'm not sure about README.html as it might open us up to some weird and unforeseen JavaScript injection attacks in conjunction with uploads. Let's keep it to known formats.

@svenstaro svenstaro merged commit 7a808e6 into svenstaro:master Sep 20, 2022
@svenstaro
Copy link
Owner

Implementation looks very good and I appreciate the easily expandable test. :)

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

Successfully merging this pull request may close these issues.

2 participants