Skip to content

Commit

Permalink
Fix alacritty theme
Browse files Browse the repository at this point in the history
  • Loading branch information
sestrella committed Aug 28, 2024
1 parent 1a4709b commit ba29841
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 17 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
substituters = https://cache.nixos.org https://devenv.cachix.org
trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= devenv.cachix.org-1:w1cLUi8dv3hnoSPGAuibQv+f9TZLr6cv/Hm9XgU50cw=
- name: Build configuration
run: nix run home-manager/release-23.11 -- build --flake ${{ github.workspace }}
timeout-minutes: 2
run: nix run home-manager/release-24.05 -- build --flake ${{ github.workspace }}
timeout-minutes: 5
- name: Activate the configuration
run: ./result/activate
16 changes: 8 additions & 8 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 7 additions & 7 deletions home/alacritty/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
programs.alacritty = {
enable = true;
settings = {
import = [ "~/.config/alacritty/theme.yml" ];
import = [ "~/.config/alacritty/theme.toml" ];
font.normal = {
family = "FiraCode Nerd Font Mono";
style = "Medium";
Expand All @@ -19,14 +19,14 @@
theme() {
local style=$(/usr/bin/defaults read -g AppleInterfaceStyle 2> /dev/null || echo "Light")
if [ "$style" == "Dark" ]; then
echo "${pkgs.alacritty-theme}/solarized_dark.yaml"
echo "${pkgs.alacritty-theme}/solarized_dark.toml"
else
echo "${pkgs.alacritty-theme}/solarized_light.yaml"
echo "${pkgs.alacritty-theme}/solarized_light.toml"
fi
}
mkdir -p ~/.config/alacritty
ln -sf "$(theme)" ~/.config/alacritty/theme.yml
ln -sf "$(theme)" ~/.config/alacritty/theme.toml
'';

# TODO: Install dark-notify via nix
Expand All @@ -36,11 +36,11 @@
let
alacrittyTheme = pkgs.writeScriptBin "alacritty-theme" ''
if [ "$1" == "dark" ]; then
ln -sf "${pkgs.alacritty-theme}/solarized_dark.yaml" ~/.config/alacritty/theme.yml
ln -sf "${pkgs.alacritty-theme}/solarized_dark.toml" ~/.config/alacritty/theme.toml
else
ln -sf "${pkgs.alacritty-theme}/solarized_light.yaml" ~/.config/alacritty/theme.yml
ln -sf "${pkgs.alacritty-theme}/solarized_light.toml" ~/.config/alacritty/theme.toml
fi
touch -h ~/.config/alacritty/alacritty.yml
touch -h ~/.config/alacritty/alacritty.toml
'';
in
[
Expand Down

0 comments on commit ba29841

Please sign in to comment.