Don't overwrite gophermap if it already exists

This commit is contained in:
~nytpu 2020-05-26 13:27:33 -04:00
parent 07303cf5e3
commit fa6d90a59c
1 changed files with 12 additions and 10 deletions

2
bb.sh
View File

@ -860,6 +860,7 @@ make_gophermap() {
ln -s "${HOME}/public_html/blog/" "${HOME}/public_gopher/blog"
fi
if [ ! -f "${HOME}/public_gopher/blog/gophermap" ]; then
cat <<- 'EOF' > $HOME/public_html/blog/gophermap
#!/bin/bash
echo -e "my bashblog posts\n"
@ -870,6 +871,7 @@ make_gophermap() {
done
EOF
chmod +x $HOME/public_html/blog/gophermap
fi
chmod 644 *.md
}