]> git repos ~mattia - some.files.git/commitdiff
Storage: alloawing special characters
authorMattia Cabrini <dev@mattiacabrini.com>
Sun, 2 Feb 2025 10:57:07 +0000 (11:57 +0100)
committerMattia Cabrini <dev@mattiacabrini.com>
Sun, 2 Feb 2025 10:57:07 +0000 (11:57 +0100)
.config/some.files/bash/procedures/storage.sh

index 1e47bcbde90846e4bf5570bbcde3465d2adf34a6..73f3e21198653c53181803608b76735abab7da92 100755 (executable)
@@ -1,11 +1,11 @@
 # Storage
 sset() {
        sunset $1
-       echo "$1;$2" >> ~/.storage
+       echo "$1;$(echo -n $2 | base64)" >> ~/.storage
 }
 
 sget() {
-       cat ~/.storage | grep -E "^$1;" | sed "s/$1;//"
+       cat ~/.storage | grep -E "^$1;" | sed "s/$1;//" | base64 -d
 }
 
 sunset() {