mirror of
https://github.com/casjaysdevdocker/transmission
synced 2025-01-18 12:34:22 -05:00
🗃️ Committing everything that changed 🗃️
rootfs/usr/local/bin/entrypoint.sh rootfs/usr/local/etc/docker/functions/entrypoint.sh
This commit is contained in:
parent
45de4eec95
commit
8b20e7756a
@ -52,6 +52,7 @@ for set_env in "/root/env.sh" "/usr/local/etc/docker/env"/*.sh "/config/env"/*.s
|
|||||||
done
|
done
|
||||||
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
# Builtin functions
|
# Builtin functions
|
||||||
|
__is_dir_empty() { [ "$(ls -A "$1" 2>/dev/null | wc -l)" -ne 0 ] && return 0 || return 1; }
|
||||||
|
|
||||||
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
# Custom functions
|
# Custom functions
|
||||||
|
@ -32,9 +32,9 @@ __cd() { [ -d "$1" ] && builtin cd "$1" || return 1; }
|
|||||||
__rm() { [ -n "$1" ] && [ -e "$1" ] && rm -Rf "${1:?}"; }
|
__rm() { [ -n "$1" ] && [ -e "$1" ] && rm -Rf "${1:?}"; }
|
||||||
__grep_test() { grep -s "$1" "$2" | grep -qwF "${3:-$1}" || return 1; }
|
__grep_test() { grep -s "$1" "$2" | grep -qwF "${3:-$1}" || return 1; }
|
||||||
__netstat() { [ -f "$(type -P netstat)" ] && netstat "$@" || return 10; }
|
__netstat() { [ -f "$(type -P netstat)" ] && netstat "$@" || return 10; }
|
||||||
__is_dir_empty() { [ "$(ls -A "$1" 2>/dev/null | wc -l)" -eq 0 ] || return 1; }
|
|
||||||
__curl() { curl -q -sfI --max-time 3 -k -o /dev/null "$@" &>/dev/null || return 10; }
|
__curl() { curl -q -sfI --max-time 3 -k -o /dev/null "$@" &>/dev/null || return 10; }
|
||||||
__find() { find "$1" -mindepth 1 -type ${2:-f,d} 2>/dev/null | grep '^' || return 10; }
|
__find() { find "$1" -mindepth 1 -type ${2:-f,d} 2>/dev/null | grep '^' || return 10; }
|
||||||
|
__is_dir_empty() { [ "$(ls -A "$1" 2>/dev/null | wc -l)" -ne 0 ] && return 0 || return 1; }
|
||||||
__pcheck() { [ -n "$(which pgrep 2>/dev/null)" ] && pgrep -o "$1" &>/dev/null || return 10; }
|
__pcheck() { [ -n "$(which pgrep 2>/dev/null)" ] && pgrep -o "$1" &>/dev/null || return 10; }
|
||||||
__sed() { sed -i 's|'$1'|'$2'|g' "$3" &>/dev/null || sed -i "s|$1|$2|g" "$3" &>/dev/null || return 1; }
|
__sed() { sed -i 's|'$1'|'$2'|g' "$3" &>/dev/null || sed -i "s|$1|$2|g" "$3" &>/dev/null || return 1; }
|
||||||
__ps() { [ -f "$(type -P ps)" ] && ps "$@" 2>/dev/null | grep -Fw " ${1:-$GEN_SCRIPT_REPLACE_APPNAME}" || return 10; }
|
__ps() { [ -f "$(type -P ps)" ] && ps "$@" 2>/dev/null | grep -Fw " ${1:-$GEN_SCRIPT_REPLACE_APPNAME}" || return 10; }
|
||||||
|
Loading…
x
Reference in New Issue
Block a user