summaryrefslogtreecommitdiff
path: root/mk
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2026-07-30 11:58:11 +0100
committerLeah Rowe <leah@libreboot.org>2026-07-30 11:58:11 +0100
commit1b65e8914c4ad1e140b573fa6bc8feead14542ad (patch)
treeeb2039c59c0d99ff39f9a548fc7c3efc61dfe87e /mk
parent72238d22b508013c0d158746e82456c67ca96166 (diff)
xbmk: general code cleanupHEADmaster
make the code much easier to read i also cleaned up the recent git identity check Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'mk')
-rwxr-xr-xmk12
1 files changed, 11 insertions, 1 deletions
diff --git a/mk b/mk
index 78d2a603..78b3e7f3 100755
--- a/mk
+++ b/mk
@@ -10,12 +10,15 @@ set -u -e
ispwd="true"
if [ "$0" != "./mk" ]; then
+
ispwd="false"
fi
if [ "$ispwd" = "true" ] && [ -L "mk" ]; then
+
ispwd="false"
fi
if [ "$ispwd" = "false" ]; then
+
printf "You must run this in the proper work directory.\n" 1>&2
exit 1
fi
@@ -34,22 +37,29 @@ main()
{
cmd=""
if [ $# -gt 0 ]; then
- cmd="$1"
+ cmd="$1"
shift 1
fi
case "$cmd" in
+
version)
+
printf "%s\nWebsite: %s\n" "$relname" "$projectsite"
;;
+
release|download|inject|prep_mr_import)
+
$cmd "$@"
;;
+
-*)
+
return 0
;;
*)
+
err "bad command" main "$@"
;;
esac