Implement a secure ICS protocol targeting LoRa Node151 microcontroller for controlling irrigation.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

31 lines
510 B

  1. #!/bin/sh -
  2. COD=$1
  3. if [ ! -d "$COD" ]; then
  4. echo "usage: $0 <checkoutdir>"
  5. echo ""
  6. echo "checkoutdir is the directory where the STM32CubeXX files are"
  7. echo "checked out."
  8. exit 1
  9. fi
  10. err=0
  11. while read lclfn cube cubefn; do
  12. cubefile="$COD/$cube/$cubefn"
  13. if [ ! -f "$cubefile" ]; then
  14. echo file "$cubefile" does not exist, but specified.
  15. err=1
  16. continue
  17. fi
  18. cp "$cubefile" "$lclfn"
  19. git add "$lclfn"
  20. done << EOF
  21. $(cat .srcs)
  22. EOF
  23. if [ x"$err" != x"0" ]; then
  24. echo There was one or more errors.
  25. fi