build-bundle-win64.bat 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. @ECHO OFF
  2. REM 1) Install newest Node.js and NPM version manager https://github.com/nodists/nodist/releases
  3. REM 2) nodist global 14.x
  4. REM 3) nodist npm global 6.
  5. REM 4) choco install -y 7zip curl wget git
  6. IF [%1] == [] GOTO usage
  7. ECHO 1) Deleting old bundle
  8. CALL DEL /F /S /Q bundle
  9. ECHO 2) Downloading new WeKan.zip
  10. DEL wekan-%1-amd64.zip
  11. wget https://github.com/wekan/wekan/releases/download/v%1/wekan-%1-amd64.zip
  12. ECHO 3) Unarchiving new WeKan
  13. CALL 7z x wekan-%1-amd64.zip
  14. ECHO 4) Reinstalling bcrypt
  15. cmd /c "npm -g install @mapbox/node-pre-gyp"
  16. cmd /c "npm -g install node-gyp"
  17. cmd /c "npm -g install fibers"
  18. CALL DEL /F /S /Q bundle\programs\server\npm\node_modules\meteor\accounts-password\node_modules\bcrypt
  19. cmd /c "CD bundle\programs\server\npm\node_modules\meteor\accounts-password && npm install bcrypt"
  20. REM # Sometimes may require building from source https://github.com/meteor/meteor/issues/11682
  21. REM cmd /c "CD bundle\programs\server\npm\node_modules\meteor\accounts-password && npm rebuild --build-from-source && npm --build-from-source install bcrypt"
  22. ECHO 5) Packing new WeKan.zip
  23. CALL DEL wekan-%1-amd64-windows.zip
  24. CALL 7z a wekan-%1-amd64-windows.zip bundle
  25. REM ECHO 6) Copying WeKan.zip to sync directory
  26. REM CALL COPY wekan-%1-amd64-windows.zip Z:\
  27. REM ECHO 7) Done. Starting WeKan.
  28. REM CD bundle
  29. REM CALL ..\start-wekan.bat
  30. REM CD ..
  31. GOTO :eof
  32. :usage
  33. ECHO Usage: build-windows.bat VERSION-NUMBER
  34. ECHO Example: build-windows.bat 5.00
  35. :eof