aboutsummaryrefslogtreecommitdiffstats
path: root/examples/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'examples/scripts')
-rw-r--r--examples/scripts/center17
-rwxr-xr-xexamples/scripts/shprompt18
-rw-r--r--examples/scripts/spin.bash16
-rwxr-xr-xexamples/scripts/xterm_title17
-rwxr-xr-xexamples/scripts/zprintf17
5 files changed, 84 insertions, 1 deletions
diff --git a/examples/scripts/center b/examples/scripts/center
index 8d367d3..dbe6133 100644
--- a/examples/scripts/center
+++ b/examples/scripts/center
@@ -5,6 +5,23 @@
# tabs in the lines might cause this to look a little bit off
#
#
+# Chet Ramey <chet.ramey@case.edu>
+#
+# Copyright 1999 Chester Ramey
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# TThis program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
width=${COLUMNS:-80}
diff --git a/examples/scripts/shprompt b/examples/scripts/shprompt
index ec8b997..098c45f 100755
--- a/examples/scripts/shprompt
+++ b/examples/scripts/shprompt
@@ -11,6 +11,22 @@
#
# Chet Ramey
# chet@ins.CWRU.Edu
+#
+# Copyright 2002 Chester Ramey
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# TThis program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
type=file
@@ -44,7 +60,7 @@ do
done
if [ "$OPTIND" -gt 1 ] ; then
- shift $[$OPTIND - 1]
+ shift $(( $OPTIND - 1 ))
fi
while :
diff --git a/examples/scripts/spin.bash b/examples/scripts/spin.bash
index dc6a66a..9fa9125 100644
--- a/examples/scripts/spin.bash
+++ b/examples/scripts/spin.bash
@@ -5,6 +5,22 @@
# Chet Ramey
# chet@po.cwru.edu
#
+# Copyright 1997 Chester Ramey
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# TThis program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
bs=$'\b'
chars="|${bs} \\${bs} -${bs} /${bs}"
diff --git a/examples/scripts/xterm_title b/examples/scripts/xterm_title
index 72ba099..839003f 100755
--- a/examples/scripts/xterm_title
+++ b/examples/scripts/xterm_title
@@ -4,6 +4,23 @@
#
# Derived from http://www.clark.net/pub/dickey/xterm/xterm.faq.html#how2_title
#
+
+# Copyright 1997 Chester Ramey
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# TThis program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
P=${0##*/}
[ -z "$DISPLAY" ] && {
echo "${P}: not running X" >&2
diff --git a/examples/scripts/zprintf b/examples/scripts/zprintf
index 5e2e3ad..86f9e95 100755
--- a/examples/scripts/zprintf
+++ b/examples/scripts/zprintf
@@ -11,6 +11,23 @@
# Chet Ramey
# chet@po.cwru.edu
+# Copyright 1996 Chester Ramey
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# TThis program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+
[ $# -lt 1 ] && {
echo "zprintf: usage: zprintf format [args ...]" >&2
exit 2