Merge pull request #46 from Lex-2008/master

test markdown before editing *.md files
This commit is contained in:
Carlos Fenollosa 2014-05-23 19:20:11 +02:00
commit fbaa5118dd

5
bb.sh
View file

@ -361,6 +361,11 @@ edit() {
filename="$1"
else
if [[ "${1##*.}" == "md" ]]; then
test_markdown
if [[ "$?" -ne 0 ]]; then
echo "Markdown is not working, please edit HTML file directly."
exit
fi
# editing markdown file
$EDITOR "$1"
TMPFILE="$(markdown "$1")"