#!/bin/sh

if [ ! -t 1 ]; then
  exec alacritty --command zsh -lic etc
fi

file=$(cd "${DOTFILES-}" && fzf)

if [ -z "${file}" ]; then
  return 0
fi

exec ${EDITOR:-vim} "${DOTFILES-}"/"${file}"
