summaryrefslogtreecommitdiff
path: root/src/rvs-core/lib/stdio.sh
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2009-07-16 14:12:53 -0400
committerLuke Shumaker <lukeshu@sbcglobal.net>2015-06-26 00:30:11 -0600
commit3da845cfc718a09b0050723b8bb49b0b4b118d04 (patch)
treed27e63249766fffab4529b4d5fde4e0777fcb2ea /src/rvs-core/lib/stdio.sh
parent6ca3d3f0cd4437922280724957dc1279e007da1f (diff)
rename source to rvs (`bzr mv' is fail!)
restructure configure and Makefile.orig
Diffstat (limited to 'src/rvs-core/lib/stdio.sh')
-rw-r--r--src/rvs-core/lib/stdio.sh51
1 files changed, 51 insertions, 0 deletions
diff --git a/src/rvs-core/lib/stdio.sh b/src/rvs-core/lib/stdio.sh
new file mode 100644
index 0000000..aff22f1
--- /dev/null
+++ b/src/rvs-core/lib/stdio.sh
@@ -0,0 +1,51 @@
+#!$$SHELL$$
+# abomination module:rvs:lib:stdio
+#name='rvs stdio'
+#ver='0.6.2'
+#usage=''
+# Copyright (C) 2009 Luke Shumaker
+# This 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.
+#
+# Originally written by Luke Shumaker <lukeshu@sbcglobal.net>.
+
+verbose() {
+ if [ "$volume" == '-v' ]; then
+ echo $@
+ fi
+}
+
+out() {
+ if [ "$volume" != '-q' ]; then
+ echo $@
+ fi
+}
+
+version() {
+ echo "$name $ver"
+ if [ "$volume" != '-q' ]; then
+ cat << __disclaimer__
+$name is copyright (C) 2009 Luke Shumaker
+This 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.
+
+Originally written by Luke Shumaker <lukeshu@sbcglobal.net>.
+__disclaimer__
+ fi
+ exit 0
+}
+
+error() {
+ cat << __error__
+$name: $1
+Usage: $name $usage
+
+Try $name \`--help' for more options.
+__error__
+ exit 1
+}
+