language: generic jobs: include: - name: release-linux language: generic dist: bionic deploy: provider: releases edge: true token: secure: zRJV96jl3zchT88YAtT6irCXgm96qVcIokVmCHrzcAXsRHgTHQURKcdpPzFdZQnNkxwfS1akA3fW5icr+U6WZIxIe56sHYEaBg7VXR1RiGW/qNOAhSvbJGva75iUllTiELa2FL2gEb8bNhVOy3+bQr5Z7RMeHFiC4FFmbMvaQhd5ss3yR5+bqKufEuJPDpFap93XHUoczXH+lXp1v90Cia1gskHsSl+YgfGWQAc89yOxETwFOSqr3CScZGV6oJpGM2rsflN5arFS/8JqDwuemttfrt74wDdKR4Mk94tcqXqMrledUsXR1NEjWAEWW6QMj05ztZ76TkT2hKpG+WVmUTaJjNKS+RJnf4WKzv1vo2EHZuAuPvwR21NGVYTxvV4o3Zvs4YODGXiUxQgeF5LFA3jbZw9ODyloStUV7zIPqzL7qJEIehnMtkjo2JPav5ORz6B7GwVrDC4LJHn95on3/3Voo3mPeyepoz1gFoh3iovTKAc+IXQXGOhT7cATP9DAWLO/Epct7hWPCEflm+oSS4rNiVbMW/61O3yIpxgkJ/oTsixLk6LOhWNdr2hfP95nAtD+It7LSsJABmWJ0FVO9RtQC7fLmEPaoGdZIdeRk/0yig9vA78Y+q46B6LBalmZO+0V60rdLdrnggJsyt3DZKM/4Z+QUwe494NodE7hU9U= on: tags: true overwrite: true cleanup: false file: ldgallery-linux-amd64.tar.gz cache: directories: - viewer/node_modules - "$HOME/.stack" before_install: - nvm install 12.16.2 - nvm use 12.16.2 - mkdir -p ~/.local/bin - export PATH=$HOME/.local/bin:$PATH - travis_retry curl -L https://get.haskellstack.org/stable/linux-x86_64.tar.gz | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack' - sudo apt-get update -qq - sudo apt-get install -y pandoc install: - cd viewer - npm install - cd .. - cd compiler - stack setup --no-terminal - cd .. script: - mkdir dist - cd viewer - npm run lint - npm run build -- --dest ../dist/viewer - cd .. - cd compiler - stack build --no-terminal - stack install --local-bin-path ../dist/ - cd .. - pandoc --standalone --to man ldgallery-quickstart.7.md --output dist/ldgallery-quickstart.7 - pandoc --standalone --to man compiler/ldgallery.1.md --output dist/ldgallery.1 - pandoc --standalone --to man viewer/ldgallery-viewer.7.md --output dist/ldgallery-viewer.7 - cp changelog.md license.md dist/ - tar -cvzf ldgallery-linux-amd64.tar.gz dist #============================================================= - name: release-win64 if: tag IS present OR branch IN (master, staging) language: shell os: windows deploy: provider: releases edge: true token: secure: zRJV96jl3zchT88YAtT6irCXgm96qVcIokVmCHrzcAXsRHgTHQURKcdpPzFdZQnNkxwfS1akA3fW5icr+U6WZIxIe56sHYEaBg7VXR1RiGW/qNOAhSvbJGva75iUllTiELa2FL2gEb8bNhVOy3+bQr5Z7RMeHFiC4FFmbMvaQhd5ss3yR5+bqKufEuJPDpFap93XHUoczXH+lXp1v90Cia1gskHsSl+YgfGWQAc89yOxETwFOSqr3CScZGV6oJpGM2rsflN5arFS/8JqDwuemttfrt74wDdKR4Mk94tcqXqMrledUsXR1NEjWAEWW6QMj05ztZ76TkT2hKpG+WVmUTaJjNKS+RJnf4WKzv1vo2EHZuAuPvwR21NGVYTxvV4o3Zvs4YODGXiUxQgeF5LFA3jbZw9ODyloStUV7zIPqzL7qJEIehnMtkjo2JPav5ORz6B7GwVrDC4LJHn95on3/3Voo3mPeyepoz1gFoh3iovTKAc+IXQXGOhT7cATP9DAWLO/Epct7hWPCEflm+oSS4rNiVbMW/61O3yIpxgkJ/oTsixLk6LOhWNdr2hfP95nAtD+It7LSsJABmWJ0FVO9RtQC7fLmEPaoGdZIdeRk/0yig9vA78Y+q46B6LBalmZO+0V60rdLdrnggJsyt3DZKM/4Z+QUwe494NodE7hU9U= on: tags: true overwrite: true cleanup: false file: ldgallery-win64.zip cache: directories: - viewer/node_modules - "$HOME/.stack" env: - NVM_HOME="$ProgramData/nvm/" - NVM_SYMLINK="$ProgramData/nvm/nodejs/" - STACK_ROOT="$ProgramData/haskell/" before_install: - export "PATH=$NVM_HOME:$NVM_SYMLINK:$STACK_ROOT:$PATH" - echo $PATH - choco install nvm - nvm install 12.16.2 - nvm use 12.16.2 - choco install haskell-stack install: - cd viewer - npm install - cd .. - cd compiler - stack setup --no-terminal - cd .. script: - mkdir dist - cd viewer - npm run lint - npm run build -- --dest ../dist/viewer - cd .. - cd compiler - stack build --no-terminal - stack install --local-bin-path ../dist/ - cd .. - mkdir dist/scripts - cp scripts/win_* dist/scripts/ - cp ldgallery-quickstart.7.md dist/ldgallery-quickstart.7.md - cp viewer/ldgallery-viewer.7.md dist/ldgallery-viewer.7.md - cp compiler/ldgallery.1.md dist/ldgallery.1.md - cp changelog.md license.md dist/ - curl --output magick.zip -L https://imagemagick.org/download/binaries/ImageMagick-7.0.10-10-portable-Q16-x64.zip - 7z e magick.zip -odist/ magick.exe - 7z e magick.zip -so LICENSE.txt > dist/magick.license.txt - 7z e magick.zip -so NOTICE.txt > dist/magick.notice.txt - 7z e magick.zip -so README.txt > dist/magick.readme.txt - 7z a -r -tzip ldgallery-win64.zip ./dist/*