commit 28a49bd0db905c38f0a869136f34eb8755428f9b parent 08bca8469e757b557fad6932bc082d1765a72fdd Author: Ed van Bruggen <edvb54@gmail.com> Date: Thu, 9 Jun 2016 22:15:32 -0700 Bin: If no args are given to sett set title to cwd Diffstat:
bin/sett | | | 6 | +++++- |
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/bin/sett b/bin/sett @@ -1,3 +1,7 @@ #!/bin/bash -echo -n "]0;$1" +title=$1 +if [[ -z $title ]]; then + title="$(basename "$PWD")" +fi +echo -n "]0;$title"