RNB is a template designed to help vimmers create their own colorschemes without much effort.
In reality, Vim colorschemes are not that hard to write but there are several benefits to using a template such as RNB:
- you can define/modify variables once instead of messing around with potentially botched substitutions,
- you can distribute a lean colorscheme, free from unnecessary logic,
- you can distribute the source alongside the colorscheme, making it easy for your users to experiment and adapt your colorscheme to their needs,
- you can focus on the design of your colorscheme rather than its implementation,
- you can start working on new colorscheme ideas very easily.
ERB, the templating engine used here, is part of Ruby's standard library so you will need Ruby to generate your colorscheme. Neither ERB nor Ruby knowledge is required, though.
The process is divided in five steps:
- rename
colors/rnb.erb
tocolors/name_of_your_colorscheme.erb
, - start by editing your colorscheme's information,
- define your colors,
- define your highlight groups and links,
- and generate your colorscheme (refer how to generate).
Steps 2 to 5 are thoroughly described in the colorscheme template itself in an effort to make it portable: if you ever decide to distribute your colorscheme you can simply package the template with it.
you need to have ruby installed before get started:
- apt (Debian or Ubuntu):
sudo apt install ruby
- pacman (Arch Linux):
sudo pacman -S ruby
- Homebrew (macOS):
brew install ruby
- FreeBSD:
pkg install ruby
The following colorschemes are known to be built with RNB:
- Apprentice
- Dichromatic
- Bruin
- Sweet16
- Paper
- Journeyman
- Warlock
- Cyberpunk-Neon
- Tutfish
- Nisha
- Photon
- vim-J
- (your colorscheme here, send us a PR!)
README.md
template