parse_api_ver.sh 547 B

123456789101112131415161718
  1. #!/bin/bash
  2. # Parse API Version from api_symbols.csv
  3. FILE=unleashed-firmware/firmware/targets/f7/api_symbols.csv
  4. OLDIFS=$IFS
  5. IFS=','
  6. [ ! -f $FILE ] && { echo "$FILE not found"; exit 99; }
  7. while read entry status name type params
  8. do
  9. if [ "$entry" == "Version" ]; then
  10. echo "API: $name"
  11. echo '' >> CHANGELOG.md
  12. echo "Apps build for Unleashed FW with API version: $name" >> CHANGELOG.md
  13. echo '' >> CHANGELOG.md
  14. echo "Extra pack = all apps / Base pack = apps that was in UL by default" >> CHANGELOG.md
  15. break;
  16. fi
  17. done < $FILE
  18. IFS=$OLDIFS