Skip to content

Commit

Permalink
Update exit code
Browse files Browse the repository at this point in the history
  • Loading branch information
ijjk committed Jul 1, 2021
1 parent dfca360 commit 1f221dc
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions scripts/next-with-deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ for PROJECT_DIR in $@;do :;done

if [ -z $PROJECT_DIR ];then
echo "No project directory provided, exiting..."
exit 0;
exit 1;
fi;

if [ ! -d $PROJECT_DIR ];then
echo "Invalid project directory provided, exiting..."
exit 0;
exit 1;
fi;

if [ $PROJECT_DIR == $PWD ] || [ "$PROJECT_DIR" == "." ];then
echo "Project directory can not be root, exiting..."
exit 0;
exit 1;
fi;

CONFLICTING_DEPS=("react" "react-dom" "styled-jsx" "next")
Expand All @@ -36,4 +36,4 @@ if [ ! -z $HAS_CONFLICTING_DEP ] || [ ! -d "$PROJECT_DIR/node_modules" ];then
fi

cd $START_DIR
yarn next $@
yarn next $@

0 comments on commit 1f221dc

Please sign in to comment.