sum.sh 700 B

12345678910111213141516171819202122232425262728
  1. #!/bin/bash
  2. sum_file () {
  3. if [[ -f "$1" ]]; then
  4. shasum -a 256 $1 > $1.sha256
  5. fi
  6. }
  7. if [[ "$SHOULD_BUILD" == "yes" ]]; then
  8. if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
  9. sum_file VSCodium-darwin-*.zip
  10. elif [[ "$CI_WINDOWS" == "True" ]]; then
  11. sum_file VSCodium-win32*.zip
  12. sum_file VSCodiumSetup*.exe
  13. sum_file VSCodiumUserSetup*.exe
  14. else # linux
  15. if [[ "$BUILDARCH" == "x64" ]]; then
  16. deb_arch=amd64
  17. rpm_arch=x86_64
  18. elif [[ "$BUILDARCH" == "ia32" ]]; then
  19. deb_arch=i386
  20. rpm_arch=i386
  21. fi
  22. sum_file VSCodium-linux*.tar.gz
  23. sum_file vscode/.build/linux/deb/$(arch)/deb/*.deb
  24. sum_file vscode/.build/linux/rpm/$(arch_alt)/*.rpm
  25. fi
  26. fi