- GITBOOK=`which gitbook`
- [ "$?" = "1" ] && { echo "You must install gitbook first, using: sudo npm install -g gitbook-cli"; exit 1; }
-
- EBCONV=`which ebook-convert`
- [ "$?" = "1" ] && { echo "You must install calibre first, using: 'sudo apt install calibre' or refer to https://calibre-ebook.com/download"; exit 1; }
+ GITBOOK=`which gitbook` || error "You must install gitbook first, using: sudo npm install -g gitbook-cli"
+ EBCONV=`which ebook-convert` || error "You must install calibre first, using: 'sudo apt install calibre' or refer to https://calibre-ebook.com/download"