aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
Diffstat (limited to 'bin')
-rwxr-xr-xbin/ak-clean2
-rwxr-xr-xbin/ak-get-balances16
-rwxr-xr-xbin/ak-profile14
-rwxr-xr-xbin/ak-startup2
-rwxr-xr-xbin/ak-transactions2
5 files changed, 18 insertions, 18 deletions
diff --git a/bin/ak-clean b/bin/ak-clean
index 8e55515..675d34a 100755
--- a/bin/ak-clean
+++ b/bin/ak-clean
@@ -37,7 +37,7 @@ descriptionString="Cleans ak temp files"
source $AK_LIBDIR/_ak_script
-_ak_tmp_cleanup(){
+function _ak_tmp_cleanup(){
ls -1 /tmp/aktmp* > /dev/null 2>&1
if [ $? -ne 0 ]
then
diff --git a/bin/ak-get-balances b/bin/ak-get-balances
index 5b13999..c25d2d1 100755
--- a/bin/ak-get-balances
+++ b/bin/ak-get-balances
@@ -73,7 +73,7 @@ fi
TEMP="$(_ak_make_temp_directory)"
cd $TEMP
-_ak_get_zblocks_from_sblock(){
+function _ak_get_zblocks_from_sblock(){
if [ "$(_ak_sblock_show $1 | jq 'has("zblocks")')" == "true" ]
then
mkdir $1 && cd $1
@@ -85,7 +85,7 @@ _ak_get_zblocks_from_sblock(){
fi
}
-_ak_verify_zblocks_found(){
+function _ak_verify_zblocks_found(){
if [ -d $1 ]
then
cd $1
@@ -119,7 +119,7 @@ _ak_verify_zblocks_found(){
fi
}
-_ak_balances_from_sblock(){
+function _ak_balances_from_sblock(){
if [ -z $1 ] || [ ! -n "$1" ]
then
_ak_log_error "No sblock provided $1"
@@ -155,7 +155,7 @@ _ak_balances_from_sblock(){
fi
}
-_ak_rewards_from_sblock(){
+function _ak_rewards_from_sblock(){
if [ ! -z $1 ] && [ -n "$1" ]
then
CUR_TARGET="$1"
@@ -191,7 +191,7 @@ _ak_rewards_from_sblock(){
fi
}
-_ak_sblock_get_previous(){
+function _ak_sblock_get_previous(){
if [ -z $1 ] || [ ! -n "$1" ]
then
_ak_log_error "No sblock provided !!"
@@ -207,7 +207,7 @@ _ak_sblock_get_previous(){
echo -n $PREVIOUS
}
-_ak_balances_calculate(){
+function _ak_balances_calculate(){
if [ ! -z $1 ] && [ -n "$1" ]
then
_ak_log_info "Calculating balance for $1"
@@ -237,7 +237,7 @@ _ak_balances_calculate(){
fi
}
-_ak_balances_print(){
+function _ak_balances_print(){
if [ ! -z $1 ] && [ -n "$1" ]
then
CUR_TARGET="$1"
@@ -255,7 +255,7 @@ _ak_balances_print(){
fi
}
-_ak_schain_counting_balances(){
+function _ak_schain_counting_balances(){
if [ ! -z $1 ] && [ -n "$1" ]
then
CUR_TARGET="$1"
diff --git a/bin/ak-profile b/bin/ak-profile
index a6ce3c8..4232b55 100755
--- a/bin/ak-profile
+++ b/bin/ak-profile
@@ -67,7 +67,7 @@ cd $ZPROFILEDIR
# The profile settings/configuration is part of the blockchain produced.
# Hence, we need a specific DATA block that actually has the announcement of a
# {"key":"value"} pair.
-_ak_modules_profile_show(){
+function _ak_modules_profile_show(){
if [ ! -z $1 ]
then
_ak_log_info "Working with $1"
@@ -80,7 +80,7 @@ _ak_modules_profile_show(){
# This should retrieve a specific value from our profile otherwise it dumps the
# whole profile values.
-_ak_modules_profile_propget(){
+function _ak_modules_profile_propget(){
if [ ! -z $1 ]
then
if [ ! -f $ZPROFILEDIR/$1 ]
@@ -95,7 +95,7 @@ _ak_modules_profile_propget(){
fi
}
-_ak_modules_profile_propwrite(){
+function _ak_modules_profile_propwrite(){
cat > $ZPROPERTY_FILE << EOF
{
"$ZPROPERTY_KEY":"${ZPROPERTY_VALUE}"
@@ -114,7 +114,7 @@ EOF
fi
}
-_ak_modules_profile_propset(){
+function _ak_modules_profile_propset(){
if [ ! -z $1 ]
then
ZPROPERTY_FILE="$ZPROFILEDIR/$1"
@@ -149,7 +149,7 @@ _ak_modules_profile_propset(){
exit 244
fi
}
-_ak_modules_profile_index(){
+function _ak_modules_profile_index(){
FILES="$(ls -1 $ZPROFILEDIR)"
i=0
echo -n "{"
@@ -168,7 +168,7 @@ _ak_modules_profile_index(){
echo "}"
}
-_ak_modules_profile_import(){
+function _ak_modules_profile_import(){
if [ ! -z $1 ]
then
if [ ! -d $1 ]
@@ -191,7 +191,7 @@ _ak_modules_profile_import(){
}
# Adds a file as a profile/add ACTION on the zchain.
-_ak_modules_profile_add(){
+function _ak_modules_profile_add(){
TEMPASSIN="$(_ak_make_temp_directory)"
cd $TEMPASSIN
if [ -f $ZPROFILEDIR/$1 ]; then
diff --git a/bin/ak-startup b/bin/ak-startup
index 06d313c..ed768e7 100755
--- a/bin/ak-startup
+++ b/bin/ak-startup
@@ -38,7 +38,7 @@ source $AK_LIBDIR/_ak_log
source $AK_LIBDIR/_ak_script
source $AK_LIBDIR/_ak_ipfs
-_ak_start_up_sequence(){
+function _ak_start_up_sequence(){
_ak_ipfs_starter
_ak_log_rotate
diff --git a/bin/ak-transactions b/bin/ak-transactions
index 037dbcf..7881733 100755
--- a/bin/ak-transactions
+++ b/bin/ak-transactions
@@ -31,7 +31,7 @@ source $AK_LIBDIR/_ak_ipfs
source $AK_LIBDIR/_ak_gpg
source $AK_LIBDIR/_ak_zblock
-_ak_modules_transactions_main(){
+function _ak_modules_transactions_main(){
_ak_log_info "$FROM_ADDRESS to $TO_ADDRESS value sent: $AMOUNT"
echo "Select an address to send from:"
select FROM_ADDRESS in $(_ak_gpg_list_secret_keys)