summaryrefslogtreecommitdiff
path: root/abuild
diff options
context:
space:
mode:
authorLinux User <ncopa@buildozer.(none)>2008-11-08 13:45:30 +0000
committerLinux User <ncopa@buildozer.(none)>2008-11-08 13:45:30 +0000
commitb89cd09513d48ce26ae698ea1bfae65ce576ac59 (patch)
tree2451df634225f3f67a43fbb628c4077953113012 /abuild
parent83273660a8ceeb4e1e32d1b7f892c335373df1f9 (diff)
downloadabuild-b89cd09513d48ce26ae698ea1bfae65ce576ac59.tar.gz
abuild-b89cd09513d48ce26ae698ea1bfae65ce576ac59.tar.bz2
abuild-b89cd09513d48ce26ae698ea1bfae65ce576ac59.tar.xz
abuild-b89cd09513d48ce26ae698ea1bfae65ce576ac59.zip
set xterm window title
Diffstat (limited to 'abuild')
-rwxr-xr-xabuild15
1 files changed, 13 insertions, 2 deletions
diff --git a/abuild b/abuild
index 214dad2..8cb0df0 100755
--- a/abuild
+++ b/abuild
@@ -58,8 +58,19 @@ error() {
printf "${prompt} ${fake}${name}: $@\n" >&2
}
+set_xterm_title() {
+ if [ "$TERM" = xterm ]; then
+ printf "\033]0;$1\007"
+ fi
+}
+
+cleanup() {
+ set_xterm_title ""
+}
+
die() {
error "$@"
+ cleanup
exit 1
}
@@ -457,8 +468,7 @@ if [ -n "$subpkgname" ]; then
fi
trap 'die "Aborted by user"' INT
-
-[ -n "$forceunpack" ] && rm -f "$srcdir"/.unpack
+set_xterm_title "abuild: $pkgname"
if [ -z "$1" ]; then
@@ -473,4 +483,5 @@ while [ $# -gt 0 ]; do
runpart $1
shift
done
+cleanup