Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
d7e0c2c
feat: automatic light/dark theme switching
djensenius Feb 26, 2026
82dfc70
fix: prevent theme switching from dirtying git status
djensenius Feb 26, 2026
9e8aa19
fix: resolve symlinks for sed and use absolute fish path
djensenius Feb 26, 2026
edf25be
fix: use Title Case Ghostty theme names (required since 1.2.0)
djensenius Feb 26, 2026
b3c1eac
fix: tmux flavor reloading and neovim background switching
djensenius Feb 26, 2026
5ab4eb8
fix: reliable theme watcher and tmux/neovim switching
djensenius Feb 26, 2026
efeefe8
fix: clear catppuccin tmux variables before re-sourcing
djensenius Feb 26, 2026
f2a27d8
fix: preserve tmux rounded tab style during theme switch
djensenius Feb 26, 2026
3a8b89f
fix: improve eza light theme contrast
djensenius Feb 26, 2026
c750b3d
feat: switch fish syntax highlighting colors with theme
djensenius Feb 26, 2026
3eebf54
fix: rename 01-theme.fish to 99-theme.fish to load after fish_frozen_…
djensenius Feb 26, 2026
30c3440
fix: remove fish_frozen_theme.fish (overrode dynamic theme colors)
djensenius Feb 26, 2026
df8676a
fix: remove duplicate golangci-lint from nvim-lint
djensenius Feb 26, 2026
f298609
fix: neovim reads theme-mode file on startup
djensenius Feb 26, 2026
4e7a3e3
feat: black background in dark mode only for Ghostty
djensenius Feb 26, 2026
d89743f
fix: use custom Ghostty theme with black background for dark mode
djensenius Feb 26, 2026
a9c50ee
Set COLORFGBG env var for CLI theme detection
djensenius Feb 27, 2026
c762fa0
Skip-worktree fish_variables to hide theme changes
djensenius Feb 27, 2026
db5a57c
Add skip-worktree reminder comments to theme-switched files
djensenius Feb 27, 2026
bdef395
Fix YAML line length and shellcheck quoting warnings
djensenius Feb 27, 2026
d28d8a6
refactor: replace skip-worktree with git clean filter and condense sw…
djensenius Feb 27, 2026
8b857f3
fix: restrict starship sed to palette selection line only
djensenius Feb 27, 2026
5eed3df
fix: use catppuccin-mocha-black theme for dark mode in ghostty
djensenius Feb 27, 2026
3c74f00
fix: add .conf extension to ghostty dark theme name
djensenius Feb 27, 2026
37dabad
fix: add fish_variables to git clean filter for theme mode changes
djensenius Feb 27, 2026
0a93152
Phase 1: Native light/dark mode switching for tmux, bat, yazi, fish
djensenius Feb 28, 2026
5168a46
Remove unused THEME_MODE from fish_variables
djensenius Feb 28, 2026
5e12dc9
Remove stale yazi symlinks and fish_variables filter
djensenius Feb 28, 2026
fbb3bef
Remove stale skip-worktree comments
djensenius Feb 28, 2026
3bc306c
feat: extend neo-tree keybindings
djensenius Feb 28, 2026
a86f97c
Merge branch 'main' into auto-theme-switching
djensenius Feb 28, 2026
1c6f289
Merge branch 'main' into auto-theme-switching
djensenius Feb 28, 2026
d6356b1
Merge branch 'main' into auto-theme-switching
djensenius Mar 1, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
starship.toml filter=catppuccin-normalize
gitconfig filter=catppuccin-normalize
atuin/config.toml filter=catppuccin-normalize
zellij/config.kdl filter=catppuccin-normalize
btop/btop.conf filter=catppuccin-normalize
k9s/config.yaml filter=catppuccin-normalize
tmux/tmux.conf filter=catppuccin-normalize
5 changes: 5 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,8 @@ tmux/plugins
actionlint
stylua
stylua.zip

# Theme-switched symlinks (dark/light variant files are tracked instead)
bottom/bottom.toml
eza/theme.yml
gh-dash/config.yml
53 changes: 51 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,63 @@
Modern development environment configuration files optimized for productivity and visual consistency. This setup provides a comprehensive development environment with integrated tools for coding, git workflow, terminal enhancement, and system monitoring.

**Key Features:**
- 🎨 **Consistent Theming**: [Catppuccin Mocha theme](https://github.com/catppuccin/catppuccin) across all applications
- 🎨 **Consistent Theming**: [Catppuccin theme](https://github.com/catppuccin/catppuccin) across all applications with automatic light/dark mode switching
- 🌗 **Auto Light/Dark Mode**: Switches between Catppuccin Mocha (dark) and Latte (light) based on macOS system appearance or sunrise/sunset times
- 🚀 **Parallel Installation**: 40-60% faster setup with concurrent package installation
- ⚡ **Performance Optimized**: Fast startup times and efficient resource usage
- 🔧 **Development Focused**: Comprehensive language support and development tools
- 📦 **Automated Setup**: One-script installation for GitHub Codespaces
- 🐚 **Modern Shell**: Fish shell with starship prompt and productivity enhancements

All configurations use the [Catppuccin Mocha theme](https://github.com/catppuccin/catppuccin) for a consistent and visually appealing look across all tools and applications.
All configurations use the [Catppuccin theme](https://github.com/catppuccin/catppuccin) with automatic light/dark mode switching for a consistent look across all tools.

## Light/Dark Mode Switching

The theme automatically switches between **Catppuccin Mocha** (dark) and **Catppuccin Latte** (light) based on your system settings.

### How It Works

- **macOS**: A Swift daemon watches for system appearance changes and instantly switches all tools. Ghostty and Neovim also detect this natively.
- **Linux/Remote**: Uses sunrise/sunset calculations from `~/.config/tz.conf` to determine light or dark mode. Falls back to 7 AM–7 PM if no config exists.

### tz.conf (for non-macOS systems)

Create `~/.config/tz.conf` to enable time-based theme switching:

```ini
# Theme Mode Configuration
# Used for sunrise/sunset-based light/dark mode switching
# on non-macOS systems. On macOS, system appearance is used instead.
#
# timezone: IANA timezone identifier (e.g., America/Toronto, Europe/Berlin)
# latitude: Decimal degrees, positive = North, negative = South
# longitude: Decimal degrees, positive = East, negative = West

timezone = America/Toronto
latitude = 43.65
longitude = -79.38
```

### Manual Override

```bash
# Switch manually at any time
scripts/switch-theme.fish light
scripts/switch-theme.fish dark
```

### macOS Theme Watcher Setup

The install script handles this automatically, but for manual setup:

```bash
# Compile the watcher
swiftc -O scripts/theme-watcher.swift -o ~/.local/bin/theme-watcher

# Install and start the launchd agent
cp scripts/com.dotfiles.theme-watcher.plist ~/Library/LaunchAgents/
launchctl bootstrap gui/$(id -u) ~/Library/LaunchAgents/com.dotfiles.theme-watcher.plist
```

## Installation

Expand Down
File renamed without changes.
26 changes: 26 additions & 0 deletions bottom/bottom-light.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
[styles.tables]
headers = {color = "#dc8a78"}
[styles.cpu]
all_entry_color = "#dc8a78"
avg_entry_color = "#e64553"
cpu_core_colors = ["#d20f39","#fe640b","#df8e1d","#40a02b","#209fb5","#8839ef"]
[styles.memory]
ram_color = "#40a02b"
swap_color = "#fe640b"
gpu_colors = ["#209fb5","#8839ef","#d20f39","#fe640b","#df8e1d","#40a02b"]
arc_color = "#04a5e5"
[styles.network]
rx_color = "#40a02b"
tx_color = "#d20f39"
[styles.widgets]
widget_title = {color = "#dd7878"}
border_color = "#acb0be"
selected_border_color = "#ea76cb"
text = {color = "#4c4f69"}
selected_text = {color = "#dce0e8", bg_color = "#8839ef"}
[styles.graphs]
graph_color = "#6c6f85"
[styles.battery]
high_battery_color = "#40a02b"
medium_battery_color = "#df8e1d"
low_battery_color = "#d20f39"
File renamed without changes.
103 changes: 103 additions & 0 deletions eza/theme-light.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
---
colourful: true

filekinds:
normal: {foreground: "#5C5F77"}
directory: {foreground: "#1E66F5"}
symlink: {foreground: "#04A5E5"}
pipe: {foreground: "#7C7F93"}
block_device: {foreground: "#E64553"}
char_device: {foreground: "#E64553"}
socket: {foreground: "#7C7F93"}
special: {foreground: "#8839EF"}
executable: {foreground: "#40A02B"}
mount_point: {foreground: "#209FB5"}

perms:
user_read: {foreground: "#4C4F69"}
user_write: {foreground: "#DF8E1D"}
user_execute_file: {foreground: "#40A02B"}
user_execute_other: {foreground: "#40A02B"}
group_read: {foreground: "#5C5F77"}
group_write: {foreground: "#DF8E1D"}
group_execute: {foreground: "#40A02B"}
other_read: {foreground: "#6C6F85"}
other_write: {foreground: "#DF8E1D"}
other_execute: {foreground: "#40A02B"}
special_user_file: {foreground: "#8839EF"}
special_other: {foreground: "#7C7F93"}
attribute: {foreground: "#5C5F77"}

size:
major: {foreground: "#6C6F85"}
minor: {foreground: "#04A5E5"}
number_byte: {foreground: "#4C4F69"}
number_kilo: {foreground: "#5C5F77"}
number_mega: {foreground: "#1E66F5"}
number_giga: {foreground: "#8839EF"}
number_huge: {foreground: "#8839EF"}
unit_byte: {foreground: "#5C5F77"}
unit_kilo: {foreground: "#1E66F5"}
unit_mega: {foreground: "#8839EF"}
unit_giga: {foreground: "#8839EF"}
unit_huge: {foreground: "#209FB5"}

users:
user_you: {foreground: "#4C4F69"}
user_root: {foreground: "#D20F39"}
user_other: {foreground: "#8839EF"}
group_yours: {foreground: "#5C5F77"}
group_other: {foreground: "#7C7F93"}
group_root: {foreground: "#D20F39"}

links:
normal: {foreground: "#04A5E5"}
multi_link_file: {foreground: "#209FB5"}

git:
new: {foreground: "#40A02B"}
modified: {foreground: "#DF8E1D"}
deleted: {foreground: "#D20F39"}
renamed: {foreground: "#179299"}
typechange: {foreground: "#EA76CB"}
ignored: {foreground: "#7C7F93"}
conflicted: {foreground: "#E64553"}

git_repo:
branch_main: {foreground: "#4C4F69"}
branch_other: {foreground: "#8839EF"}
git_clean: {foreground: "#40A02B"}
git_dirty: {foreground: "#D20F39"}

security_context:
colon: {foreground: "#7C7F93"}
user: {foreground: "#4C4F69"}
role: {foreground: "#8839EF"}
typ: {foreground: "#7C7F93"}
range: {foreground: "#8839EF"}

file_type:
image: {foreground: "#DF8E1D"}
video: {foreground: "#D20F39"}
music: {foreground: "#40A02B"}
lossless: {foreground: "#179299"}
crypto: {foreground: "#7C7F93"}
document: {foreground: "#4C4F69"}
compressed: {foreground: "#EA76CB"}
temp: {foreground: "#E64553"}
compiled: {foreground: "#209FB5"}
build: {foreground: "#7C7F93"}
source: {foreground: "#1E66F5"}

punctuation: {foreground: "#7C7F93"}
date: {foreground: "#DF8E1D"}
inode: {foreground: "#5C5F77"}
blocks: {foreground: "#6C6F85"}
header: {foreground: "#4C4F69"}
octal: {foreground: "#179299"}
flags: {foreground: "#8839EF"}

symlink_path: {foreground: "#04A5E5"}
control_char: {foreground: "#209FB5"}
broken_symlink: {foreground: "#D20F39"}
broken_path_overlay: {foreground: "#7C7F93"}
12 changes: 7 additions & 5 deletions fish/conf.d/00-env.fish
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,14 @@ set -gx EDITOR nvim
set -gx EZA_CONFIG_DIR "$HOME/.config/eza"
set -gx EZA_ICONS_AUTO true

# fzf theme/options
set -gx FZF_DEFAULT_OPTS '--color=bg+:#313244,bg:#1e1e2e,spinner:#f5e0dc,hl:#f38ba8 --color=fg:#cdd6f4,header:#f38ba8,info:#cba6f7,pointer:#f5e0dc --color=marker:#b4befe,fg+:#cdd6f4,prompt:#cba6f7,hl+:#f38ba8 --color=selected-bg:#45475a --multi'
# fzf theme/options (colors are set dynamically by 01-theme.fish)

# From your previous fish_variables (portable defaults)
set -gx BAT_THEME Catppuccin-mocha
set -gx DARK_MODE true
# bat: auto-detect terminal dark/light mode (no manual switching needed)
set -gx BAT_THEME "auto:system"
set -gx BAT_THEME_DARK "Catppuccin Mocha"
set -gx BAT_THEME_LIGHT "Catppuccin Latte"

# DARK_MODE and FZF_DEFAULT_OPTS are managed by 99-theme.fish

# Go module env (host-specific GOPROXY is handled in 30-host-conditional.fish)
set -gx GONOPROXY ""
Expand Down
74 changes: 74 additions & 0 deletions fish/conf.d/99-theme.fish
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
# Theme mode management — sets env vars for external tools based on terminal color scheme.
# Fish 4.x auto-detects dark/light via $fish_terminal_color_theme (OSC 11 query).
# This handler fires on terminal color scheme changes AND on shell startup.

function _theme_apply --on-variable fish_terminal_color_theme
if test "$fish_terminal_color_theme" = light
set -gx DARK_MODE false
set -gx COLORFGBG '0;15'
set -gx FZF_DEFAULT_OPTS '--color=bg+:#ccd0da,bg:#eff1f5,spinner:#dc8a78,hl:#d20f39 --color=fg:#4c4f69,header:#d20f39,info:#8839ef,pointer:#dc8a78 --color=marker:#7287fd,fg+:#4c4f69,prompt:#8839ef,hl+:#d20f39 --color=selected-bg:#bcc0cc --multi'

# Fish syntax highlighting — Catppuccin Latte
set -g fish_color_normal 4c4f69
set -g fish_color_command 1e66f5
set -g fish_color_keyword d20f39
set -g fish_color_quote 40a02b
set -g fish_color_redirection ea76cb
set -g fish_color_end fe640b
set -g fish_color_error d20f39
set -g fish_color_param dd7878
set -g fish_color_option 40a02b
set -g fish_color_comment 8c8fa1
set -g fish_color_selection --background=ccd0da
set -g fish_color_search_match --background=ccd0da
set -g fish_color_operator ea76cb
set -g fish_color_escape e64553
set -g fish_color_autosuggestion 9ca0b0
set -g fish_color_cancel d20f39
set -g fish_color_cwd df8e1d
set -g fish_color_user 179299
set -g fish_color_host 1e66f5
set -g fish_color_host_remote 40a02b
set -g fish_color_status d20f39
set -g fish_color_gray 9ca0b0
set -g fish_pager_color_completion 4c4f69
set -g fish_pager_color_description 9ca0b0
set -g fish_pager_color_prefix ea76cb
set -g fish_pager_color_progress 9ca0b0
else
set -gx DARK_MODE true
set -gx COLORFGBG '15;0'
set -gx FZF_DEFAULT_OPTS '--color=bg+:#313244,bg:#1e1e2e,spinner:#f5e0dc,hl:#f38ba8 --color=fg:#cdd6f4,header:#f38ba8,info:#cba6f7,pointer:#f5e0dc --color=marker:#b4befe,fg+:#cdd6f4,prompt:#cba6f7,hl+:#f38ba8 --color=selected-bg:#45475a --multi'

# Fish syntax highlighting — Catppuccin Mocha
set -g fish_color_normal cdd6f4
set -g fish_color_command 89b4fa
set -g fish_color_keyword f38ba8
set -g fish_color_quote a6e3a1
set -g fish_color_redirection f5c2e7
set -g fish_color_end fab387
set -g fish_color_error f38ba8
set -g fish_color_param f2cdcd
set -g fish_color_option a6e3a1
set -g fish_color_comment 7f849c
set -g fish_color_selection --background=313244
set -g fish_color_search_match --background=313244
set -g fish_color_operator f5c2e7
set -g fish_color_escape eba0ac
set -g fish_color_autosuggestion 6c7086
set -g fish_color_cancel f38ba8
set -g fish_color_cwd f9e2af
set -g fish_color_user 94e2d5
set -g fish_color_host 89b4fa
set -g fish_color_host_remote a6e3a1
set -g fish_color_status f38ba8
set -g fish_color_gray 6c7086
set -g fish_pager_color_completion cdd6f4
set -g fish_pager_color_description 6c7086
set -g fish_pager_color_prefix f5c2e7
set -g fish_pager_color_progress 6c7086
end
end

# Apply theme on shell init
_theme_apply
49 changes: 0 additions & 49 deletions fish/conf.d/fish_frozen_theme.fish

This file was deleted.

Loading