Allow zk to be sourced without running

This commit is contained in:
The Magician 2023-12-07 16:35:19 +00:00
parent 18cea8c07a
commit 596cdcd624
1 changed files with 8 additions and 1 deletions

9
zk
View File

@ -1,3 +1,10 @@
#!/bin/sh
echo Hello, world
main() {
echo "Hello, world"
}
name="$(basename "$0")"
if test "$name" = "zk"; then
main
fi