From 19571875f1c6dc3742f643f4097e11b51dc9338e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Karel=20Ko=C4=8D=C3=AD?= Date: Tue, 21 Apr 2020 14:58:58 +0200 Subject: files/turris_checkout_repo_branch.sh: remove dependency on common.sh --- files/turris_checkout_repo_branch.sh | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/files/turris_checkout_repo_branch.sh b/files/turris_checkout_repo_branch.sh index 486c0b1..ae88656 100755 --- a/files/turris_checkout_repo_branch.sh +++ b/files/turris_checkout_repo_branch.sh @@ -1,9 +1,6 @@ #!/bin/bash set -o errexit -o nounset -helpers_dir="$(dirname "$(readlink -f "$0")")" -. "$helpers_dir/common.sh" - print_usage() { cat >&2 <<-EOF Usage: ${0##*/} [-h] BRANCH [BOARD] @@ -78,8 +75,10 @@ done } [ -z "$board" ] && board="omnia" -[ "$(git rev-parse --is-inside-work-tree 2>/dev/null)" != "true" ] && \ - die "Current working directory is not in git repository" +[ "$(git rev-parse --is-inside-work-tree 2>/dev/null)" != "true" ] && { + echo "Current working directory is not in git repository" + exit 1 +} toplevel="$(git rev-parse --show-toplevel)" -- cgit v1.2.3