check if toot is installed
This commit is contained in:
parent
a188677c49
commit
0eab42ddf1
|
@ -15,6 +15,7 @@ If I had to choose a license, it would be [MIT](LICENSE.md).
|
|||
## Dependencies
|
||||
|
||||
- `wget`
|
||||
- `toot` (optional for posting on Mastodon)
|
||||
|
||||
## TO DO
|
||||
|
||||
|
|
|
@ -104,6 +104,10 @@ echo "\nCopy and Paste this:\n\n+++++"
|
|||
echo "Latest article from my blog: \"$TITLE\"\n\n$LINK"
|
||||
echo "+++++"
|
||||
|
||||
if [[ "$TOOT" == "1" ]]; then yes_or_no "Post it on Mastodon?"; fi
|
||||
if [[ "$TOOT" == "1" ]]; then
|
||||
which toot > /dev/null # Check if toot is installed
|
||||
if ! [[ $? == "0" ]]; then echo "ERROR. Toot is not installed. Exiting."; cleanup 1; fi
|
||||
yes_or_no "Post it on Mastodon?"
|
||||
fi
|
||||
|
||||
cleanup 0
|
Loading…
Reference in New Issue