From 87511b25ce4d0dd8e132ca24a72045aceee3d441 Mon Sep 17 00:00:00 2001
From: Bob Mottram <bob@robotics.uk.to>
Date: Sat, 19 Nov 2016 14:02:08 +0000
Subject: [PATCH] Don't need echo

---
 src/freedombone-pass | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/freedombone-pass b/src/freedombone-pass
index 582a7630e..bae83e45d 100755
--- a/src/freedombone-pass
+++ b/src/freedombone-pass
@@ -72,7 +72,7 @@ function pass_show_help {
 }
 
 function pad_string {
-    echo -n -e "$1" | sed -e :a -e 's/^.\{1,1024\}$/& /;ta'
+    echo -n -e "$1" | sed -e :a -e 's/^.\{1,128\}$/& /;ta'
 }
 
 while [[ $# > 1 ]]
@@ -134,7 +134,7 @@ else
     if [ ! -d ~/.passwords/$CURR_USERNAME ]; then
         mkdir -p ~/.passwords/$CURR_USERNAME
     fi
-    echo -n "$(pad_string '${CURR_PASSWORD}')" | gpg -ca --cipher-algo AES256 --passphrase "$MASTER_PASSWORD" > ~/.passwords/$CURR_USERNAME/$CURR_APP
+    pad_string "${CURR_PASSWORD}" | gpg -ca --cipher-algo AES256 --passphrase "$MASTER_PASSWORD" > ~/.passwords/$CURR_USERNAME/$CURR_APP
     if [ ! -f ~/.passwords/$CURR_USERNAME/$CURR_APP ]; then
         exit 5
     fi
-- 
GitLab