Generate artifact zips only for tags (#1319)

This commit is contained in:
Javier Neira 2019-09-17 07:33:49 +02:00 committed by mergify[bot]
parent 640913f8d2
commit cc09c56788
1 changed files with 13 additions and 19 deletions

View File

@ -39,15 +39,15 @@ for:
build_script:
- stack build
- stack install --local-bin-path bin
- if /I "%APPVEYOR_REPO_TAG%" EQU "true" (set DEPLOY_TAG=%APPVEYOR_REPO_TAG_NAME%) else (set DEPLOY_TAG=%APPVEYOR_REPO_COMMIT:~0,5%)
- set DEPLOY_SUFFIX=%DEPLOY_TAG%-x86_64-windows.zip
- 7z a "bin\dhall-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\dhall.exe"
- 7z a "bin\dhall-json-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\dhall-to-json.exe"
- 7z a "bin\dhall-json-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\dhall-to-yaml.exe"
- 7z a "bin\dhall-json-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\json-to-dhall.exe"
- 7z a "bin\dhall-json-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\yaml-to-dhall.exe"
- 7z a "bin\dhall-bash-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\dhall-to-bash.exe"
- 7z a "bin\dhall-lsp-server-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\dhall-lsp-server.exe"
- if /I "%APPVEYOR_REPO_TAG%" EQU "true" (set DEPLOY_TAG=%APPVEYOR_REPO_TAG_NAME%-x86_64-windows.zip)
- set DEPLOY_DIR=%APPVEYOR_BUILD_FOLDER%\bin
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall.exe")
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-json-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall-to-json.exe")
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-json-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall-to-yaml.exe")
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-json-%DEPLOY_TAG%" "%DEPLOY_DIR%\json-to-dhall.exe")
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-json-%DEPLOY_TAG%" "%DEPLOY_DIR%\yaml-to-dhall.exe")
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-bash-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall-to-bash.exe")
- if /I "%DEPLOY_TAG%" NEQ "" (7z a "bin\dhall-lsp-server-%DEPLOY_TAG%" "%DEPLOY_DIR%\dhall-lsp-server.exe")
test_script:
# chcp 65001 (utf-8) needed to make doctest work
@ -65,25 +65,19 @@ for:
build_script:
- stack build
- stack install --local-bin-path bin
- if /I "%APPVEYOR_REPO_TAG%" EQU "true" (set DEPLOY_TAG=%APPVEYOR_REPO_TAG_NAME%) else (set DEPLOY_TAG=%APPVEYOR_REPO_COMMIT:~0,5%)
- set DEPLOY_SUFFIX=%DEPLOY_TAG%-x86_64-windows.zip
# dhall-json and dhall-lsp-server is not supported for LTS 6, so do not try to copy the
# corresponding binaries
- 7z a "bin\dhall-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\dhall.exe"
- 7z a "bin\dhall-bash-%DEPLOY_SUFFIX%" "%APPVEYOR_BUILD_FOLDER%\bin\dhall-to-bash.exe"
test_script:
# chcp 65001 (utf-8) needed to make doctest work
- chcp 65001 && stack test dhall
artifacts:
- path: bin\dhall-%DEPLOY_SUFFIX%
- path: bin\dhall-%DEPLOY_TAG%
name: dhall
- path: bin\dhall-json-%DEPLOY_SUFFIX%
- path: bin\dhall-json-%DEPLOY_TAG%
name: dhall-json
- path: bin\dhall-bash-%DEPLOY_SUFFIX%
- path: bin\dhall-bash-%DEPLOY_TAG%
name: dhall-bash
- path: bin\dhall-lsp-server-%DEPLOY_SUFFIX%
- path: bin\dhall-lsp-server-%DEPLOY_TAG%
name: dhall-lsp-server
deploy: