aboutsummaryrefslogtreecommitdiffstats
path: root/backup-cloud.rsc
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2023-11-15 11:44:38 +0100
committerGravatar Christian Hesse <mail@eworm.de>2023-11-15 14:34:40 +0100
commit180d6b8733504cab058aaf4928a54e24b980c696 (patch)
treeec8e9796dca736b7fcf69a74e3dd96df8aed5436 /backup-cloud.rsc
parent890cd6c58d3de7e91a95c4593243d30f1b6234af (diff)
backup-cloud: use $HumanReadableNum for file size
Diffstat (limited to 'backup-cloud.rsc')
-rw-r--r--backup-cloud.rsc3
1 files changed, 2 insertions, 1 deletions
diff --git a/backup-cloud.rsc b/backup-cloud.rsc
index 934edb9..c1bbe11 100644
--- a/backup-cloud.rsc
+++ b/backup-cloud.rsc
@@ -18,6 +18,7 @@
:global DeviceInfo;
:global FormatLine;
+:global HumanReadableNum;
:global LogPrintExit2;
:global RandomDelay;
:global ScriptFromTerminal;
@@ -51,7 +52,7 @@ $WaitFullyConnected;
message=("Uploaded backup for " . $Identity . " to cloud.\n\n" . \
[ $DeviceInfo ] . "\n\n" . \
[ $FormatLine "Name" ($Cloud->"name") ] . "\n" . \
- [ $FormatLine "Size" ($Cloud->"size" . " B (" . ($Cloud->"size" / 1024) . " KiB)") ] . "\n" . \
+ [ $FormatLine "Size" ([ $HumanReadableNum ($Cloud->"size") 1024 ] . "iB") ] . "\n" . \
[ $FormatLine "Download key" ($Cloud->"secret-download-key") ]); silent=true });
} on-error={
$SendNotification2 ({ origin=$0; \