aboutsummaryrefslogtreecommitdiff
path: root/pdebuild-internal
diff options
context:
space:
mode:
authorJunichi Uekawa <dancer@netfort.gr.jp>2009-02-26 12:53:15 +0900
committerJunichi Uekawa <dancer@netfort.gr.jp>2009-02-26 14:33:11 +0900
commit06a64a8ce3cbe0e9b7079114f821083ca3c3a8da (patch)
tree516660a2366b18b40d1a823ba1ec188a39a59634 /pdebuild-internal
parent37597b2cb6439cce9571de83218586b0a99e6ea9 (diff)
downloadpbuilder-06a64a8ce3cbe0e9b7079114f821083ca3c3a8da.tar
pbuilder-06a64a8ce3cbe0e9b7079114f821083ca3c3a8da.tar.gz
refactor to use 'log' function rather than using 'echo' directly.
First cut into doing this, hopefully we're not breaking anything.
Diffstat (limited to 'pdebuild-internal')
-rw-r--r--pdebuild-internal9
1 files changed, 7 insertions, 2 deletions
diff --git a/pdebuild-internal b/pdebuild-internal
index 2d42145..ce624b2 100644
--- a/pdebuild-internal
+++ b/pdebuild-internal
@@ -38,10 +38,15 @@ export LOGNAME=root
cd "$1"
shift;
+# dummy function that does enough, real one is defined elsewhere.
+function log() {
+ echo "$*"
+}
+
while [ -n "$1" ]; do
case "$1" in
--debbuildopts)
- echo "Setting DEBBUILDOPTS=$2"
+ log "I: Setting DEBBUILDOPTS=$2"
DEBBUILDOPTS="$2"
shift; shift;
;;
@@ -63,7 +68,7 @@ while [ -n "$1" ]; do
shift;
;;
--*)
- echo "Error: Unknown option [$1] was specified " >&2
+ log "E: Unknown option [$1] was specified "
exit 1;
;;
*)