/ipython-style-gruvbox

🎨 An opinionated terminal colorscheme for IPython using gruvbox colors.

Primary LanguagePythonISC LicenseISC

IPython Style Gruvbox

GitHub Actions test status Coveralls code coverage License Python versions Latest release Any color you like

An opinionated terminal colorscheme for IPython using gruvbox colors.

IPython Style Gruvbox

Installation

The ipython-style-gruvbox package is not currently published to PyPI because of its highly opinionated, personal nature. If, however, you still wish to install this package, the following steps should work to install the latest release.

repo='https://github.com/reillysiemens/ipython-style-gruvbox'

# Find the latest release.
latest=$(git ls-remote --tags --refs $repo | # Fetch remote tags.
                 sort -t '/' -k 3 -V |       # Sort them by version.
                 tail -n 1 |                 # Take the latest one.
                 awk -F / '{print $3}')      # Return only the tag.

# Craft the URL for the release asset.
version=$(echo $latest | tr -d 'v')  # Remove the leading v.
wheel="ipython_style_gruvbox-${version}-py3-none-any.whl"
release="${repo}/releases/download/${latest}/${wheel}"

# Install the release.
pip install $release

Usage

The style installs itself as a Pygments plugin, so after installation you should only need to launch IPython with the gruvbox style

ipython --TerminalInteractiveShell.highlighting_style=gruvbox

or add it to your IPython config.

config = get_config()
config.TerminalInteractiveShell.highlighting_style = "gruvbox"

Note: This will only affect your syntax highlighting. If you're looking to create a prompt that looks exactly like the one in the image above this example prompt might help.