Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
21514: minor improvements to the error messages
Browse files Browse the repository at this point in the history
  • Loading branch information
nthiery committed Nov 24, 2016
1 parent 4be49e4 commit 08cba4b
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/bin/sage-rst2ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,17 @@ fail () {
}

# tests if dependencies are available
pandoc -v > /dev/null 2>&1 || fail 'You should install pandoc on your system.'
pandoc -v > /dev/null 2>&1 || fail 'Please install pandoc on your system.'
[ $(sage-list-packages installed | grep '^rst2ipynb\.\.\.') ] || fail \
'You should install the rst2ipynb optional package.'
'Please install the rst2ipynb optional package with `sage -i rst2ipynb`.'

case "${#}" in
(1)
rst2ipynb --kernel='sagemath' ${1} ;;
(2)
rst2ipynb --kernel='sagemath' ${1} -o ${2} ;;
(*)
fail 'You should provide one or two file names.' ;;
fail 'Usage: sage -rst2ipynb input.rst [output.ipynb].' ;;
esac

exit 0

0 comments on commit 08cba4b

Please sign in to comment.