fix: remove deprecated egrep calls from codebase

This commit is contained in:
Jose Diaz-Gonzalez
2020-02-17 05:59:52 -05:00
parent b04080bcb1
commit e19b52442b
18 changed files with 33 additions and 34 deletions

View File

@@ -16,7 +16,7 @@ trigger-scheduler-docker-local-core-post-deploy() {
fi
dokku_log_info1 "Renaming containers"
local PROCTYPES="$(egrep -v "^#" "$DOKKU_ROOT/$APP/DOKKU_SCALE" | awk -F '=' '{ print $1 }' | xargs)"
local PROCTYPES="$(grep -v -E "^#" "$DOKKU_ROOT/$APP/DOKKU_SCALE" | awk -F '=' '{ print $1 }' | xargs)"
local CONTAINER_FILES="$(find "$DOKKU_ROOT/$APP" -maxdepth 1 -name "CONTAINER.*" -printf "%f\n" 2>/dev/null | sort -t . -k 3 -n | xargs)"
local CONTAINER_FILE

View File

@@ -18,7 +18,7 @@ trigger-scheduler-docker-local-post-delete() {
# remove all application containers & images
# shellcheck disable=SC2046
local DOKKU_APP_CIDS=$("$DOCKER_BIN" container list --all --no-trunc | egrep "dokku/${APP}:" | awk '{ print $1 }' | xargs)
local DOKKU_APP_CIDS=$("$DOCKER_BIN" container list --all --no-trunc | grep "dokku/${APP}:" | awk '{ print $1 }' | xargs)
if [[ -n "$DOKKU_APP_CIDS" ]]; then
# shellcheck disable=SC2086
"$DOCKER_BIN" container rm --force $DOKKU_APP_CIDS >/dev/null 2>&1 || true