S&B Volcano vaporizer remote control with Pi Pico W
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

pack_data.sh 1.2KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. #!/bin/bash
  2. # ----------------------------------------------------------------------------
  3. # Copyright (c) 2023 Thomas Buck (thomas@xythobuz.de)
  4. #
  5. # This program is free software: you can redistribute it and/or modify
  6. # it under the terms of the GNU General Public License as published by
  7. # the Free Software Foundation, either version 3 of the License, or
  8. # (at your option) any later version.
  9. #
  10. # This program is distributed in the hope that it will be useful,
  11. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. # GNU General Public License for more details.
  14. #
  15. # See <http://www.gnu.org/licenses/>.
  16. # ----------------------------------------------------------------------------
  17. set -euo pipefail
  18. cd "$(dirname "$0")"
  19. echo "Packing data"
  20. rm -rf build/src
  21. mkdir -p build/src
  22. cp COPYING build/src
  23. cp README.md build/src
  24. cp CMakeLists.txt build/src
  25. cp .gitmodules build/src/gitmodules
  26. cp -r include build/src
  27. cp -r src build/src
  28. cd build
  29. rm -rf data.tar data.tar.xz
  30. tar -f data.tar -c src
  31. xz -z -9 data.tar
  32. xxd -i data.tar.xz > pack_data.h
  33. sed -i 's/unsigned/static const unsigned/g' pack_data.h