From 872ddd766b1e3c11e25863e4c694b9bdd44b457b Mon Sep 17 00:00:00 2001 From: Hugh Ratsch Date: Sun, 9 Feb 2025 03:31:44 -0600 Subject: [PATCH] updated project 2 --- projects/02-command-line-mastery/play.sh | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/projects/02-command-line-mastery/play.sh b/projects/02-command-line-mastery/play.sh index 81f2b25..1614607 100644 --- a/projects/02-command-line-mastery/play.sh +++ b/projects/02-command-line-mastery/play.sh @@ -251,7 +251,8 @@ print_challenge_header() { # Function to setup challenge environment setup_challenge_env() { local challenge_id=$1 - if ! bash "$CHALLENGE_DIR/.tracking/level1-setup.sh" > /dev/null 2>&1; then + echo -e "${BLUE}Setting up challenge files...${NC}" + if ! bash "$CHALLENGE_DIR/.tracking/level1-setup.sh"; then echo -e "${RED}Error: Failed to setup challenge environment${NC}" echo -e "${YELLOW}Try running: $0 clean && $0 setup${NC}" return 1 @@ -295,8 +296,9 @@ start_challenge() { # Setup challenge environment echo -e "${BLUE}Setting up challenge environment...${NC}" - setup_challenge_env "$challenge_id" & - show_spinner $! + if ! setup_challenge_env "$challenge_id"; then + return 1 + fi if ! get_challenge_details "$challenge_id" 2>/dev/null; then echo -e "${RED}Error: Challenge $challenge_id not found${NC}"