Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| a4c3a1319b | |||
| 3b5aa28838 |
+2
-1
@@ -1,4 +1,5 @@
|
||||
*.swp
|
||||
|
||||
pull.log
|
||||
update.tbl
|
||||
update.tbl
|
||||
dotfiles.git
|
||||
+9
-1
@@ -7,11 +7,19 @@ fi
|
||||
setopt prompt_subst
|
||||
|
||||
kitty_available=n
|
||||
# detection method one
|
||||
if (( ${+KITTY_SHELL_INTEGRATION} )); then
|
||||
kitty_available=y
|
||||
[[ "$KITTY_SHELL_INTEGRATION" == "disabled" ]] && return # don't integrate if configured not to
|
||||
autoload -Uz -- "${KITTY_INSTALLATION_DIR}/shell-integration/zsh/kitty-integration"
|
||||
kitty-integration && unfunction kitty-integration
|
||||
kitty_available=y
|
||||
fi
|
||||
# detection method two
|
||||
if [[ $kitty_available == n && -n "$KITTY_INSTALLATION_DIR" ]]; then
|
||||
export KITTY_SHELL_INTEGRATION=${ZEESH_KITTY_INTEGRATION:-enabled}
|
||||
autoload -Uz -- "${KITTY_INSTALLATION_DIR}/shell-integration/zsh/kitty-integration"
|
||||
kitty-integration && unfunction kitty-integration
|
||||
kitty_available=y
|
||||
fi
|
||||
|
||||
function ticker_message () {
|
||||
|
||||
+4
-1
@@ -1,2 +1,5 @@
|
||||
alias ls="ls --color=auto"
|
||||
ls_arguments=('--color=auto')
|
||||
[[ $kitty_available == y ]] && ls_arguments+='--hyperlink=auto'
|
||||
|
||||
alias ls="ls ${(j/ /)ls_arguments}"
|
||||
alias grep="grep --color=auto"
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
if [[ $_zeesh_fresh_install -eq 1 ]]; then
|
||||
ticker_finish
|
||||
|
||||
if [[ -v ZEESH_DOTFILES_DIR ]]; then
|
||||
if read -q "ZEESH_DOTFILES?Configure dotfile management? [yn] "; then
|
||||
read "ZEESH_DOTFILES_INPUT?Location of dotfile repo? [~/.local/share/zeesh/dotfiles.git] "
|
||||
export ZEESH_DOTFILES_DIR="${ZEESH_DOTFILES_INPUT:-${HOME}/.local/share/zeesh/dotfiles.git}"
|
||||
echo "ZEESH_DOTFILES_DIR=${ZEESH_DOTFILES_DIR}" >> $HOME/.zshrc.preload
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -v ZEESH_DOTFILES_DIR ]]; then
|
||||
if [[ ! -d $ZEESH_DOTFILES_DIR ]]; then
|
||||
ticker_message "initializing dotfiles repository"
|
||||
git init --bare --quiet $ZEESH_DOTFILES_DIR
|
||||
git --git-dir=$ZEESH_DOTFILES_DIR config status.showUntrackedFiles no
|
||||
fi
|
||||
|
||||
alias dotfiles='git --git-dir="$ZEESH_DOTFILES_DIR" --work-tree="$HOME"'
|
||||
fi
|
||||
Reference in New Issue
Block a user