No description
This repository has been archived on 2025-10-26. You can view files and clone it, but you cannot make any changes to its state, such as pushing and creating new issues, pull requests or comments.
Find a file
2025-10-21 00:34:19 +00:00
.github Update mbrobbel/rustfmt-check action to v0.20.0 2025-09-17 04:26:01 +00:00
dist/completions initial commit 2024-05-02 21:24:06 +02:00
media fix readme 2024-05-04 11:51:47 -04:00
src fix clippy lints 2025-01-14 12:21:01 +01:00
.gitignore add pre-commit config 2024-05-03 06:56:49 +02:00
.pre-commit-config.yaml Update pre-commit hook pre-commit/pre-commit-hooks to v5 (#17) 2025-01-14 12:21:28 +01:00
Cargo.lock Update Rust crate clap to v4.5.50 2025-10-21 00:34:19 +00:00
Cargo.toml Update Rust crate toml to 0.9.0 (#20) 2025-08-07 12:35:10 +00:00
LICENSE initial commit 2024-05-02 21:24:06 +02:00
Makefile initial commit 2024-05-02 21:24:06 +02:00
README.md fix readme 2024-05-04 11:51:47 -04:00

alacritty-theme-switcher

A simple tool to quickly switch between different themes for alacritty, with shell completion!

./media/demo.gif

Overview

From the Alacritty website

Alacritty is a modern terminal emulator that comes with sensible defaults, but allows for extensive configuration. By integrating with other applications, rather than reimplementing their functionality, it manages to provide a flexible set of features with high performance.

By default, Alacritty does not have support for applying different themes, color configuration is instead set in the config file. The alacritty-theme provides such theme configurations, but changing the theme has to be done manually in alacritty.toml.

This tool emulates theme support for Alacritty by managing the theme configuration import in using Alacritty's configuration:

# in ~/.config/alacritty/themes/themes/my-theme.toml
[colors.primary]
background = '#282c34'
foreground = '#abb2bf'
[colors.normal]
black = '#1e2127'
red = '#e06c75'
green = '#98c379'
#...

# in ~/.config/alacritty/alacritty.toml
import = [
    "~/.config/alacritty/themes/themes/my-theme-name.toml" # 👈 this line is added and managed by alacritty-theme-switcher
]

Installation

Releases

You can get the most recent release over on the Releases section.

The downloaded archive (either .zip or .tar.gz) contains both the binary and shell completion scripts:

  • Copy the binary to a directory that's in your path, such as /usr/local/bin or ~/.local/bin
  • Copy the completion scripts for your shell into the appropriate directory:
    • For Bash: /usr/local/share/bash-completions/completions/
    • For ZSH: /usr/local/share/zsh/site-functions/

Cargo

If you have cargo installed, you can install this tool from crates.io:

cargo install --locked alacritty-theme-switcher

Note that you will have to install the shell completion scripts manually, see above.

Arch Linux

There is an AUR package available: alacritty-theme-switcher

Manually

Clone this repository, then run make build && sudo make install to compile and install the utility.

Usage

First, put some theme files into your theme directory ($XDG_CONFIG/alacritty/themes/themes by default).

Now you can switch themes by running alacritty-theme-switcher <theme-name>.

You can also list available themes with alacritty-theme-switcher -l.

Author & License

Created by @maxhoesel

Licensed under the GPL 3 (see the LICENSE file)