Skip to content

Commit

Permalink
Remove commands loading from main executable
Browse files Browse the repository at this point in the history
Affects #31
  • Loading branch information
ivan-podorozhnyi committed Sep 11, 2017
1 parent 38aca2c commit a25964b
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions src/main/git-elegant
Original file line number Diff line number Diff line change
Expand Up @@ -83,14 +83,6 @@ main() {
COMMAND="$1"; shift
fi
[ -z "$COMMAND" ] || [ "$COMMAND" = "help" ] && usage && exit 10

# @todo #6 Remove commands loading from main executable.
# It will be possible when all commands will be migrated to separate executables.
if type -t "$COMMAND" | grep -q '^function$' >/dev/null 2>&1 ; then
eval '$COMMAND $@'
exit 0
fi

[ ! -e "$BINS/git-elegant-$COMMAND" ] && echo "Unknown command: git elegant $COMMAND" && usage && exit 2
. "$BINS/git-elegant-$COMMAND"

Expand Down

0 comments on commit a25964b

Please sign in to comment.