wip
This commit is contained in:
parent
0d4c6cfc7a
commit
ba44f7d655
1 changed files with 8 additions and 0 deletions
8
yazi.sh
8
yazi.sh
|
@ -1,11 +1,19 @@
|
||||||
{
|
{
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
PACKAGE=yazi
|
||||||
|
|
||||||
# ─< Check if the given command exists silently >─────────────────────────────────────────
|
# ─< Check if the given command exists silently >─────────────────────────────────────────
|
||||||
command_exists() {
|
command_exists() {
|
||||||
command -v "$@" >/dev/null 2>&1
|
command -v "$@" >/dev/null 2>&1
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if command_exists $PACKAGE; then
|
||||||
|
echo_error "$PACKAGE is already installed!"
|
||||||
|
echo_error "Exiting now!"
|
||||||
|
return 69
|
||||||
|
fi
|
||||||
|
|
||||||
# WHY:
|
# WHY:
|
||||||
# This import will give you the following variables:
|
# This import will give you the following variables:
|
||||||
# _sudo="sudo -E" <- only if non root user
|
# _sudo="sudo -E" <- only if non root user
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue