Skip to content

Latest commit

 

History

30 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Althemer

A CLI and interactive TUI to switch between Alacritty themes.

demo

Crates.io Rust License

Features

  • Interactive TUI - Visually browse and select themes with live color preview
  • Dark/Light tabs - Filter themes by category with tabbed navigation
  • Fuzzy search - Type to filter themes in real-time with fuzzy matching
  • List themes - View all available themes in your themes directory
  • Check current - See which theme is currently active
  • Quick switch - Switch to any theme by name from the CLI
  • Download themes - Fetch theme collections directly from GitHub
  • Configurable - Set your themes directory, preview preferences, and more

Performance

Tool Language Execution Time
ats TypeScript ~618ms
althemer Rust ~13ms

Installation

Cargo

cargo install althemer

Cargo Binstall

cargo binstall althemer

Pre-built binaries

Download the latest release binary for your platform from the Releases page.

From source (requires rust)

git clone https://github.com/xdagiz/althemer
cd althemer
cargo install --locked --path .

Requirements

  • Alacritty
  • A themes directory with .toml alacritty theme files

Usage

Interactive mode (TUI)

Launch the interactive theme picker:

althemer

Global CLI flags

althemer -t /path/to/themes             # Custom themes directory
althemer -c /path/to/config             # Custom config file location
althemer -a /path/to/alacritty.toml     # Custom alacritty config file

List all themes and quick switch

althemer list

list demo

Check current theme

althemer current

Switch to a theme by name

althemer switch <theme-name>

Download themes from GitHub

# download from the default github repo [alacritty/alacritty-theme]
althemer download
# download from a specific repo
althemer download https://github.com/user/repo # or just user/repo
# use -b to specify the branch
althemer download https://github.com/user/repo -b develop
# -f will overwrite existing themes
althemer download -f

Configuration

Althemer looks for themes in:

  1. --themes / -t CLI argument
  2. themes_dir in config file (default: the themes directory next to the alacritty config)

And for the alacritty config file in:

  1. --alacritty-config / -a CLI argument
  2. ALTHEMER_ALACRITTY_CONFIG environment variable
  3. alacritty_config in config file
  4. ~/.config/alacritty/alacritty.toml (on macOS: ~/Library/Application Support/alacritty/alacritty.toml)

Config file

Passing --config / -c skips the search. If that file is missing or broken, althemer stops with an error.

Without the flag, althemer checks in order:

  1. $XDG_CONFIG_HOME/althemer/config.json (if XDG_CONFIG_HOME is set to an absolute path)
  2. ~/.config/althemer/config.json
  3. <platform config dir>/althemer/config.json (on macOS: ~/Library/Application Support/althemer/config.json)

Althemer reads the first path that exists, so a macOS install under Application Support keeps working. With no config on disk, althemer writes a new one to the first spot in the list.

{
  "themes_dir": "/home/xdagiz/.config/alacritty/themes",
  "alacritty_config": "/home/xdagiz/.config/alacritty/alacritty.toml",
  "show_preview": true,
  "quit_on_select": false,
  "picker_reversed": false,
  "picker_sort_results": true
}

Config options

Option Type Default Description
themes_dir string ~/.config/alacritty/themes Path to directory containing .toml theme files
alacritty_config string ~/.config/alacritty/alacritty.toml Path to the alacritty config file to rewrite
show_preview bool true Show color palette preview in TUI
quit_on_select bool false Exit TUI after applying a theme
picker_reversed bool false Reverse the picker display order
picker_sort_results bool true Sort fuzzy search results by relevance

You can interactively configure these options by running:

althemer configure

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.


By xdagiz

About

Theme Switcher for Alacritty

Topics

Resources

Stars

19 stars

Watchers

1 watching

Forks

Releases

Contributors

Languages