Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Allow spark to be sourced by other scripts easily

  • Loading branch information...
commit 60c4d0d7ab4127a0e74a8e6fb80c07cd60dc536e 1 parent 1194fa6
@akatrevorjay akatrevorjay authored
Showing with 3 additions and 0 deletions.
  1. +3 −0  spark
View
3  spark
@@ -75,6 +75,9 @@ spark()
echo
}
+# If we're being sourced, don't worry about such things
+[[ ${#BASH_SOURCE[@]} -eq 1 ]] || return
+
# show help for no arguments if stdin is a terminal
if ([ -z $1 ] && [ -t 0 ]) || [ "$1" == '-h' ]
then
Please sign in to comment.
Something went wrong with that request. Please try again.