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

Feature: Output templating #10

Open
jhermann opened this issue Mar 28, 2018 · 2 comments
Open

Feature: Output templating #10

jhermann opened this issue Mar 28, 2018 · 2 comments

Comments

@jhermann
Copy link
Contributor

I'd like to get results in ReST, Markdown, etc.

  • Add -t / --template ‹name› option
  • Built-in templates for default, rst, md (default is the current output)
  • Look for custom ones in a [TEMPLATES] section in ~/.oh-my-stars/config.ini
  • Using string.Formatter should be sufficient
  • Besides variables for link, language, etc., provide ANSI sequences as c.red, a.bold, etc. (the latter empty strings in "no color" mode)

I might do a PR if I find the time, putting the idea out there anyway.

@jhermann
Copy link
Contributor Author

BTW, could you config your editor to squash trailing whitespace please, as per PEP8:

“Avoid trailing whitespace anywhere. Because it's usually invisible, it can be confusing: e.g. a backslash followed by a space and a newline does not count as a line continuation marker. Some editors don't preserve it and many projects (like CPython itself) have pre-commit hooks that reject it.”

Right now, doing PRs for this project is a pain because of all those empty lines that aren't actually empty.

@wolfg1969
Copy link
Owner

ok, thank you. I'll get rid of the trailing whitespaces.

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

2 participants