This repository has been archived on 2024-04-07. You can view files and clone it, but cannot push or open issues or pull requests.
dotfiles/dotfiles/scripts/terminal

20 lines
406 B
Bash
Executable File

#!/bin/sh
test $# -gt 0 &&
cmd="$1" &&
shift
# {%@@ if terminal == "alacritty" @@%} #
command -v alacritty > /dev/null &&
{
test "$#" -gt "0" &&
exec alacritty -e "$cmd $@" ||
exec alacritty
} & exit
# {%@@ else @@%} #
command -v kitty > /dev/null &&
exec kitty $cmd "$@"
# {%@@ endif @@%} #
notify-send "Error" "Terminal program missing"