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

Use a Ruby Markdown-to-roff library instead of an external dependency #10

Closed
gettalong opened this issue Aug 24, 2018 · 6 comments
Closed

Comments

@gettalong
Copy link

Hi,

I'm the author of kramdown which includes a converter for roff files - see https://kramdown.gettalong.org/converter/man.html.

If you used kramdown for converting the Markdown source, you wouldn't need an external library. This would also probably help the issues #6 and #4.

And if kramdown doesn't fit your need, there are other Ruby libraries as well, for example ronn, which do Markdown-to-roff conversion.

Just mentioning this since it might make things easier.

Cheers,
Thomas

@sinclairtarget
Copy link
Owner

Hi! Will definitely look into this. Thanks for the tip.

@sinclairtarget
Copy link
Owner

Don't think I have the free time to do this now, but labeling as "Help Wanted" in the hope that someone wants to take a crack at this.

Doesn't seem like it would be too difficult, though this might require a major version bump if it entails a change in Markdown dialect.

@leggettc18
Copy link

leggettc18 commented Aug 28, 2018

@gettalong In order for this project to work using Kramdown, any users would have to run gem install kramdown correct? That could work better for some people, but pandoc is already in the package managers for most Linux distros.

That being said, if Linux packages can be made for Kramdown (there may already be some in some distributions, not really sure atm) it would cause less dependencies (at least on my distribution of choice, installing pandoc pulled in a bunch of haskell packages as well on Solus).

@gettalong
Copy link
Author

Even if pandoc is in the package managers, users would still have to install it, won't they? I don't see much of a difference between sudo apt install pandoc and gem install kramdown. In addition, kramdown is also available through most package managers (there are at least packages for Ubuntu and Fedora).

But, as I said, it is just a suggestion and it certainly only makes sense if it makes working with um easier or better.

@leggettc18
Copy link

Well if it's in the distro's package managers the dependency can be installed automatically when one tries to install um, instead of the user having to install um from the package manager and install the converter with gem install afterwards. Then users also don't have to remember to uninstall the converter after uninstalling um if they no longer need it. That being said, its not as if creating a package for a Linux distro is difficult (Although some can get a bit picky on acceptance criteria, but that's a whole other discussion). I do think overall it would be better, since, as I said, pandoc pulls in a bunch of extra stuff as dependencies on Solus.

@sinclairtarget
Copy link
Owner

Hi everyone,

Um 4.0 now uses Kramdown to parse and convert Markdown files. I think depending on the gem is much better than depending on something as big as Pandoc.

That said, Kramdown Markdown is not the same as Pandoc Markdown. So if you have lots of Markdown um pages you may need to revise them if you really want to upgrade. See UPGRADE.md for more info.

Let me know if you run into any trouble!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants