aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkaotisk <kaotisk@arching-kaos.com>2022-02-11 08:00:54 +0200
committerkaotisk <kaotisk@arching-kaos.com>2022-02-11 08:00:54 +0200
commit3376c472fada0453eaed54b66fb62316deab22ef (patch)
treecd81eeba8f58efbf989aaf4958812e303d516ecf
parentcf5e5e6833383fde13bf91c82daa76e3114ecfda (diff)
downloadarching-kaos-tools-3376c472fada0453eaed54b66fb62316deab22ef.tar.gz
arching-kaos-tools-3376c472fada0453eaed54b66fb62316deab22ef.tar.bz2
arching-kaos-tools-3376c472fada0453eaed54b66fb62316deab22ef.zip
Further solving
-rwxr-xr-xbin/ak-files14
1 files changed, 9 insertions, 5 deletions
diff --git a/bin/ak-files b/bin/ak-files
index f698290..ac81100 100755
--- a/bin/ak-files
+++ b/bin/ak-files
@@ -32,15 +32,19 @@ usage(){
}
add(){
- PWD="$(pwd)"
- FILE="$PWD/$1"
- main
+ CRP="$(pwd)"
+ FILENAME="$1"
+ main $FILENAME $CRP
cat $PWD/data | json_pp
pack_z_block file/add $PWD/data
}
main(){
- echo "Adding $FILE"
-
+ FILENAME="$1"
+ CRP="$2"
+ echo "Adding $FILENAME"
+ tempassin
+ cp $2/$1 $TEMPASSIN/$1
+ FILE="$TEMPASSIN/$1"
FILE_IPFS_HASH=$(ipfs add -q $FILE)
SIGN_FILE=$FILE".asc"