Revision 6feb961b setup.sh

View differences:

setup.sh
87 87
    BUILD_STM32FLASH=true
88 88

  
89 89
    # test for existing bonary
90
    if [ -f bin/stm32flash ]; then
90
    if [ -f stm32flash ]; then
91 91
      printf "WARNING: stm32flash binary already exists.\n"
92 92
      read -p "Would you like to delete and rebuild it? [Y/n] " -n 1 -i "Y" -e USER_INPUT
93 93
      if [[ $USER_INPUT =~ ^[Yy]$ ]]; then
94 94
        BUILD_STM32FLASH=true
95
        rm -rf bin/
95
        make clean
96 96
      elif [[ ! $USER_INPUT =~ ^[YyNn]$ ]]; then
97 97
        BUILD_STM32FLASH=false
98 98
        printf "'%s' is no valid selection. Aborting setup.\n" $USER_INPUT
......
103 103

  
104 104
    # build the tool if required
105 105
    if [ $BUILD_STM32FLASH = true ]; then
106
      mkdir bin
107 106
      make
108
      mv stm32flash bin/
109
      make clean
110 107
    fi
111 108

  
112 109
    cd $USER_DIR

Also available in: Unified diff