Formatting changes

This commit is contained in:
Jon-William Lewis
2016-02-15 00:20:50 -06:00
parent 3664b3b429
commit d11c2597c4
4 changed files with 7 additions and 5 deletions

View File

@@ -24,4 +24,5 @@ cat ./src/main/stage1.sns.sh >> "$S"
cat ./src/main/stage2.sns.sh >> "$S"
cat ./src/main/stage3.sns.sh >> "$S"
chmod u+x "$S"
exit

View File

@@ -12,10 +12,13 @@ cat << EOF
# Prevent freak accidents involving the root directory
if [ -z "\$HOME" ]; then HOME=/home/"\$(whoami)"; fi
PROD_STR="$PROD_STR"
readonly PROD_STR="$PROD_STR"
readonly VER_STR="$VER_STR"
readonly ROOT_DIR="\$HOME"/.config/sns
readonly NOTES_DIR="\$ROOT_DIR"/notes
readonly TMP_DIR="\$ROOT_DIR"/tmp
readonly CONFIG_FILE="\$ROOT_DIR/sns.conf"
printf "%s\n" "\$PROD_STR"
printf "%s\n" "------------------"
EOF

View File

@@ -24,7 +24,7 @@ EOF
chmod 600 "$CONFIG_FILE"
printf " - %s\n" "Rewrote Default Configuration"
printf "\n - %s\n" "Rewrote Default Configuration"
if [ "$WILL_INIT" == "TRUE" ]; then
printf " - %s %s\n" "Environment initialized in" "$ROOT_DIR"

View File

@@ -4,6 +4,7 @@
#==============================================================================
# Stage 1: Read Configuration / Verify Integrity
#==============================================================================
if [ -r "$CONFIG_FILE" ]; then
source "$CONFIG_FILE"
else
@@ -24,14 +25,11 @@
fi
if [ "$ENCRYPTION" == "TRUE" ]; then
PROD_STR="Simple Note System (Encryption Enabled)"
if [ ! -d "$ROOT_DIR"/tmp ]; then
mkdir -p "$ROOT_DIR"/tmp
fi
fi
echo "$PROD_STR, $VER_STR"
if [ -n "$ERR_NO_GPG" ]; then
>&2 echo " Error: Encryption was specified, but GPG is not installed."
exit 100