#!/bin/zsh # This script is modeled after Omarchy's omarchy-theme-set script and my theme-switching # approach is modeled after Omarchy's theme-switching approach. # (See: https://github.com/basecamp/omarchy) # Omarchy is licensed under the MIT License. See the original LICENSE file for details at: # https://github.com/basecamp/omarchy/blob/master/LICENSE # Copyright (c) David Heinemeier Hansson ########################################################################################## [[ ! -z $1 ]] && raw_target="$1" || raw_target=$( find $DIR_THEME_SETTINGS -mindepth 1 -maxdepth 1 -type d -exec basename -- {} \; | fzf ) target_theme="$DIR_THEME_SETTINGS/$(echo $raw_target | tr ' ' '-' | tr '[:upper:]' '[:lower:]')" [[ ! -d "$target_theme" ]] && echo "theme not found: $target_theme" && exit 1 ln -sF "$target_theme" $DIR_THEME_SETTINGS/.current-theme theme-update-terminal theme-update-tmux theme-update-neovim & # theme-update-obsidian # TODO: implement # theme-update-browser # TODO: implement # theme-update-reaper # TODO: implement # theme-update-gimp # TODO: possible and actually desired? my main use case is just a blackboard, maybe let it be # theme-update-mutt # TODO: possible and actually desired? # theme-update-irc # TODO: possible and actually desired? theme-update-wallpaper "zz-default-for-theme" &