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.

38 lines
1.0 KiB

  1. #!/usr/bin/env bash
  2. #
  3. # This script assumes a linux environment
  4. echo "*** uMatrix.firefox: Creating web store package"
  5. echo "*** uMatrix.firefox: Copying files"
  6. DES=dist/build/uMatrix.firefox
  7. rm -rf $DES
  8. mkdir -p $DES
  9. bash ./tools/make-assets.sh $DES
  10. cp -R ./src/* $DES/
  11. cp platform/chromium/*.html $DES/
  12. cp platform/chromium/*.js $DES/js/
  13. cp -R platform/chromium/img/* $DES/img/
  14. cp LICENSE.txt $DES/
  15. cp platform/firefox/polyfill.js $DES/js/
  16. cp platform/firefox/vapi-cachestorage.js $DES/js/
  17. cp platform/firefox/manifest.json $DES/
  18. # firefox-specific
  19. rm $DES/options_ui.html
  20. rm $DES/js/options_ui.js
  21. echo "*** uMatrix.firefox: Generating meta..."
  22. python tools/make-firefox-meta.py $DES/
  23. if [ "$1" = all ]; then
  24. echo "*** uMatrix.firefox: Creating package..."
  25. pushd $DES > /dev/null
  26. zip ../$(basename $DES).xpi -qr *
  27. popd > /dev/null
  28. fi
  29. echo "*** uMatrix.firefox: Package done."