mirror of
https://github.com/wasp-lang/wasp.git
synced 2024-11-30 18:23:19 +03:00
70 lines
2.1 KiB
YAML
70 lines
2.1 KiB
YAML
platform: x64
|
|
|
|
version: '{build}'
|
|
|
|
skip_commits:
|
|
message: /\[skip ci\]/
|
|
|
|
branches:
|
|
only:
|
|
- master # This will still build PRs.
|
|
|
|
environment:
|
|
PATH: c:/bin;%PATH%
|
|
STACK_ROOT: c:/stack
|
|
TMP: c:/tmp # https://github.com/haskell/cabal/issues/5386
|
|
|
|
# `a -> b` means that cached item `a` will be invalidated if `b` changes.
|
|
# Important: AppVeyor has 1GB limit on cache for free account.
|
|
cache:
|
|
# We made these caches dependent on stack.yaml, because we want them
|
|
# to clear out if new resolver is set, otherwise they would be taking
|
|
# too much space if they would contain libraries for multiple versions
|
|
# of resolvers.
|
|
- c:/stack -> waspc/stack.yaml
|
|
# This dir is really big, hundreds of MBs, but it reduces build time from 20 to 2 minutes.
|
|
- c:/Users/appveyor/AppData/Local/Programs/stack -> waspc/stack.yaml
|
|
|
|
install:
|
|
- ps: cd waspc
|
|
# Install latest stable stack.
|
|
- ps: |
|
|
curl -OutFile stack.zip -Uri https://get.haskellstack.org/stable/windows-x86_64.zip
|
|
7z x stack.zip stack.exe
|
|
mkdir c:/bin
|
|
mv stack.exe c:/bin
|
|
|
|
build_script:
|
|
# Building external libraries/packages.
|
|
- cmd: stack setup > nul # Do it silently due to lot of not very interesting output.
|
|
- cmd: stack build --test --only-dependencies
|
|
# Building our source code.
|
|
- cmd: stack build --test --no-run-tests
|
|
|
|
test_script:
|
|
- cmd: stack build --test # Run tests
|
|
|
|
after_test:
|
|
- ps: mkdir binary-package
|
|
- ps: mv "$(stack path --local-install-root)/bin/wasp.exe" binary-package/wasp-x86_64.exe
|
|
- ps: mv "$(stack path --project-root)/data" binary-package/data
|
|
- ps: mv tools/run_wasp.ps1 binary-package/wasp.ps1
|
|
|
|
artifacts:
|
|
# Since waspc\binary-package is a directory, AppVeyor will zip it for us and
|
|
# name it by the name of the artifact + .zip.
|
|
- path: waspc\binary-package
|
|
name: wasp-win-x86_64
|
|
|
|
deploy:
|
|
provider: GitHub
|
|
auth_token:
|
|
secure: kyc1YtELeuOSAvRQtg6ppmMWYkbsP16z3eBRu09YozknJEXySteOJTHUUyaMocjC
|
|
description: "Automatic release"
|
|
artifact: wasp-win-x86_64
|
|
force_update: true # Adds files to release even if it already exists.
|
|
draft: true
|
|
on:
|
|
APPVEYOR_REPO_TAG: true # Deploy on tag push only.
|
|
|