From e5f7a4c5fd3fc05470e4d52c9545dc327f54830d Mon Sep 17 00:00:00 2001 From: kaotisk Date: Sun, 21 Jul 2024 18:23:07 +0300 Subject: fixed output formating --- lib/_ak_fs | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'lib') diff --git a/lib/_ak_fs b/lib/_ak_fs index ac466b4..79a9956 100755 --- a/lib/_ak_fs +++ b/lib/_ak_fs @@ -145,7 +145,9 @@ _ak_fs_import(){ # The idea is: # sha256sum as quick pointer to root of the tree # + _ak_log_info "Storing original hash of $1 along with its name" sha512sum "$1" > $TEMPORARYDIR/3rd_gen_map + _ak_log_info "Encoding to base64" base64 $1 > file FILE="file" fi @@ -170,6 +172,7 @@ _ak_fs_import(){ # We split the file into 4*1024 bytes and output the chunks into TECHDIR split -a 50 -b $FACTOR --additional-suffix ".chk" -d "$FILE" "$TECHDIR/$(basename "$FILE")-" fi + _ak_log_info "File done splitting" # We go over there... cd $TECHDIR @@ -190,15 +193,15 @@ _ak_fs_import(){ temp=`expr $temp / 2` timesRan=`expr $timesRan + 1` done - printf "Ran %s times \n" "$timesRan" - printf "Total chunks %s \n" "$totalChunks" + _ak_log_debug "Ran $timesRan times" + _ak_log_debug "Total chunks $totalChunks" workingIndex="$TEMPORARYDIR/map" c=$timesRan while [ $c -ne 0 ] do a=1 - printf "Level: %s, will work on %s chunks\n" "$c" "$totalChunks" + _ak_log_debug "Level: $c, will work on $totalChunks chunks" while [[ "$a" -lt "$totalChunks" ]] do b=`expr "$a" + 1` @@ -263,7 +266,7 @@ _ak_fs_import(){ rm -rf $TEMPORARYDIR # and print the MAPFILEHASH - echo "$MAPFILEHASH" + echo "$mp512p" } -- cgit v1.2.3