spk rev 43
Change: use debug function in spk-add
author | Christian Mesh <meshca@clarkson.edu> |
---|---|
date | Tue May 15 21:48:35 2012 -0500 (2012-05-15) |
parents | 07f5864f07a2 |
children | 00c1009ee71b |
files | spk-add |
line diff
1.1 --- a/spk-add Tue May 15 21:42:35 2012 -0500 1.2 +++ b/spk-add Tue May 15 21:48:35 2012 -0500 1.3 @@ -124,7 +124,7 @@ 1.4 files_to_remove="$files_to_remove $file" 1.5 done 1.6 fi 1.7 - [ "$debug" ] && echo "DEBUG: file_to_remove: $files_to_remove" 1.8 + debug "file_to_remove: $files_to_remove" 1.9 1.10 # Create list of all possibly modified files 1.11 local file_list 1.12 @@ -133,10 +133,11 @@ 1.13 [ -d "${root}${i}" ] && continue 1.14 file_list="$file_list $i" 1.15 done 1.16 - [ "$debug" ] && echo "DEBUG: file_list is set" 1.17 + 1.18 + debug "file_list is set" 1.19 1.20 # Check possibly modified files against other packages files.list 1.21 - [ "$debug" ] && echo "DEBUG: check modified files" 1.22 + debug "check modified files" 1.23 for file in $file_list 1.24 do 1.25 filegrep=$(egrep ^${file}$ $installed/*/files.list) 1.26 @@ -153,8 +154,7 @@ 1.27 fi 1.28 # Add $pkg to the modifiers list og $name 1.29 if ! egrep -q ^${package_name}$ $installed/$name/modifiers; then 1.30 - [ "$debug" ] && \ 1.31 - echo -en "\nDEBUG: Added $pkg to: $name/modifiers" 1.32 + debug "Added $pkg to: $name/modifiers" 1.33 echo "$package_name" >> $installed/$name/modifiers 1.34 fi 1.35 status