quickjs-tart

quickjs-based runtime for wallet-core logic
Log | Files | Refs | README | LICENSE

tmp_ignore_makefiles.sh (1040B)


      1 #!/bin/bash
      2 
      3 # Temporarily (de)ignore Makefiles generated by CMake to allow easier
      4 # git development
      5 #
      6 # Copyright The Mbed TLS Contributors
      7 # SPDX-License-Identifier: Apache-2.0 OR GPL-2.0-or-later
      8 
      9 IGNORE=""
     10 
     11 # Parse arguments
     12 #
     13 until [ -z "$1" ]
     14 do
     15   case "$1" in
     16     -u|--undo)
     17       IGNORE="0"
     18       ;;
     19     -v|--verbose)
     20       # Be verbose
     21       VERBOSE="1"
     22       ;;
     23     -h|--help)
     24       # print help
     25       echo "Usage: $0"
     26       echo -e "  -h|--help\t\tPrint this help."
     27       echo -e "  -u|--undo\t\tRemove ignores and continue tracking."
     28       echo -e "  -v|--verbose\t\tVerbose."
     29       exit 1
     30       ;;
     31     *)
     32       # print error
     33       echo "Unknown argument: '$1'"
     34       exit 1
     35       ;;
     36   esac
     37   shift
     38 done
     39 
     40 if [ "X" = "X$IGNORE" ];
     41 then
     42   [ $VERBOSE ] && echo "Ignoring Makefiles"
     43   git update-index --assume-unchanged Makefile library/Makefile programs/Makefile tests/Makefile
     44 else
     45   [ $VERBOSE ] && echo "Tracking Makefiles"
     46   git update-index --no-assume-unchanged Makefile library/Makefile programs/Makefile tests/Makefile
     47 fi