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

feat: add support for themes #21

Merged
merged 2 commits into from
Sep 29, 2022
Merged

feat: add support for themes #21

merged 2 commits into from
Sep 29, 2022

Conversation

noahgorstein
Copy link
Owner

@noahgorstein noahgorstein commented Sep 28, 2022

This PR adds the following:

  • a command line flag (-t/--theme) allowing a user to specify a theme. Themes currently supported are dracula, nord, monokai, monokailight, autumn and default.

Demo of using nord theme:

image

  • The ability for a user to specify a configuration file for jqp. If a configuration option is specified in both the configuration file and via a command line flag, the command line flag takes precedence. By default, jqp will attempt to search for a configuration file named .jqp.yaml in a user's home directory. A path to the configuration file can also be provided via the --config flag.
    • The only really useful thing right now is to put a theme in the config file but this should be helpful later if and when we introduce more configuration options.
  • Fixes a bug where the syntax highlighting (being done by Chroma) was highlighting by default for terminals with 16 color ANSI support. We now detect what kind of color support the user's terminal has and highlight based on that.

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.

1 participant