properly escape newlines
This commit is contained in:
parent
be8b1d3e6b
commit
87876ecfa9
1 changed files with 2 additions and 2 deletions
|
|
@ -8,9 +8,9 @@ function journal() {
|
|||
FILE="${JOURNALDIR}$(date '+%Y-%m-%d')"
|
||||
echo "${FILE}"
|
||||
if [ ! -f $FILE ]; then
|
||||
echo "$(date '+%Y-%m-%d')\n" >> $FILE
|
||||
echo -e "$(date '+%Y-%m-%d')\n" >> $FILE
|
||||
else
|
||||
echo "\n" >> $FILE
|
||||
echo -e "\n" >> $FILE
|
||||
fi
|
||||
echo ">> $(date '+%H:%M:%S')" >> $FILE
|
||||
vim +$ ${FILE}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue