;ci: drop old travis, appveyor configs

This commit is contained in:
Simon Michael 2021-01-11 09:01:34 -08:00
parent b203822cd1
commit a1824c02d7
2 changed files with 0 additions and 351 deletions

View File

@ -1,130 +0,0 @@
# https://www.appveyor.com/docs/appveyor-yml
# https://www.appveyor.com/docs/build-configuration
# https://www.appveyor.com/docs/branches
# https://www.appveyor.com/docs/how-to/filtering-commits
# To ignore a commit: [skip ci], [ci skip] or [skip appveyor] in the commit message
#build: off
platform: x64
clone_folder: c:\pr # shorter file paths were a known workaround in the past
environment:
global:
STACK_ROOT: c:\sr
APPVEYOR_SAVE_CACHE_ON_ERROR: true
APPVEYOR_CACHE_ENTRY_ZIP_ARGS: "-t7z -m0=lzma -mx=9" # smaller (& slower) cache
# Appveyor's free plan allows a 1G cache. https://www.appveyor.com/docs/build-cache
# The cache is saved only on the current vm instance, so when appveyor picks a different vm instance it's like starting again with no cache.
# To wipe the cache (on the current instance ? all instances ?), eg before a GHC upgrade:
# browse ui, open inspector, $.ajax({url: 'https://ci.appveyor.com/api/projects/simonmichael/hledger/buildcache',type: 'DELETE'})
# or curl -s -H "Authorization: Bearer $APPVEYOR_TOKEN" -H "Content-Type: application/json" -X DELETE https://ci.appveyor.com/api/projects/simonmichael/hledger/buildcache
# To skip caching:
# APPVEYOR_CACHE_SKIP_RESTORE - set to true to disable cache restore
# APPVEYOR_CACHE_SKIP_SAVE - set to true to disable cache update
# conditionally:
#init:
#- ps: IF ($env:APPVEYOR_REPO_BRANCH -eq "develop") {$env:APPVEYOR_CACHE_SKIP_SAVE = "true"}
# To declare cache dependency on specific files add "-> FILEPATTERN below. Appveyor will checksum
# only those files for cache invalidation, quicker than checksumming all cached content.
cache:
- "%LOCALAPPDATA%\\Programs\\stack"
- C:\Users\appveyor\AppData\Roaming\local\bin
- C:\sr
- .stack-work
- hledger-lib\.stack-work -> hledger-lib\**
- hledger\.stack-work -> hledger\**
- hledger-web\.stack-work -> hledger-web\**
install:
# install latest stack release
- curl -skL -ostack.zip http://www.stackage.org/stack/windows-x86_64
- 7z x stack.zip stack.exe
- stack --version
# other stack versions eg for the latest workarounds:
#
# install a stack prerelease
#- curl -skLO https://github.com/commercialhaskell/stack/releases/download/v1.9.0.1/stack-1.9.0.1-windows-x86_64.tar.gz
#- 7z x stack-1.9.0.1-windows-x86_64.tar.gz -so | 7z e -si -ttar stack-1.9.0.1-windows-x86_64/stack.exe -aoa
#- stack --version
#
# install latest stack 4125-cabal-style-build-tools branch
# - set PATH=C:\Users\appveyor\AppData\Roaming\local\bin;%PATH%
# - stack-release upgrade --git --git-branch 4125-cabal-style-build-tools
# - copy C:\Users\appveyor\AppData\Roaming\local\bin\stack.exe C:\Users\appveyor\AppData\Roaming\local\bin\stack-4125.exe
# - copy C:\Users\appveyor\AppData\Roaming\local\bin\stack.exe stack.exe
#
# install latest stack master
#- set PATH=C:\Users\appveyor\AppData\Roaming\local\bin;%PATH%
# show the stack-installed binaries that were restored from cache, can vary by instance
#- dir C:\Users\appveyor\AppData\Roaming\local\bin
# - stack-release upgrade --git
#- copy C:\Users\appveyor\AppData\Roaming\local\bin\stack.exe C:\Users\appveyor\AppData\Roaming\local\bin\stack-master.exe
# - copy C:\Users\appveyor\AppData\Roaming\local\bin\stack.exe stack.exe
#- stack --version
# install ghc
- stack setup
#- set PATH=C:\Users\appveyor\AppData\Roaming\local\bin;%PATH%
#- stack install shelltestrunner
# --bench failed on windows, not tried recently
# hledger-ui's vty dep isn't available on windows
build_script:
- stack build --test --copy-bins --local-bin-path=. hledger hledger-web
# https://sevenzip.osdn.jp/chm/cmdline
- 7z a hledger.zip hledger.exe hledger-web.exe
# or use hledger-install ?
#- hledger-install/hledger-install.sh
#- make stacktest
# functional tests - these don't run well on windows currently
#test_script:
#- stack exec -- shelltest --execdir -a -j16 tests # COLUMNS=80
artifacts:
- path: hledger.zip
branches:
only:
- master # master is set as default branch in UI, and built nightly by cron
- /^[0-9.]+$/ # release branches will be build on each push (would prefer on tag)
## overriding common configuration:
#for:
#
## settings specific to master branch
## master is set as default branch in UI, and built nightly by cron
#-
# branches:
# only:
# - master
#
## settings specific to release branches
## release branches are built on tag push
#-
# branches:
# only:
# - /^[0-9.]+$/
# on: # https://ci.appveyor.com/tools/validate-yaml: Invalid setting or section: on
# appveyor_repo_tag: true
# deployment stuff
# https://silky.github.io/posts/2016-01-05-build-windows-haskell-app-with-stack-and-appveyor.html
#
#- cmd: for /f %%i in (".\hledger --version") do set HLEDGER_VERSION=%%i
#- cmd: for /f %%i in (".\hledger-web --version") do set HLEDGER_WEB_VERSION=%%i
#
#deploy:
# - provider: GitHub
# tag: "hledger-$(HLEDGER_VERSION)"
# release: "Release hledger-$(HLEDGER_VERSION)"
# auth_token:
# secure: #FZXhwa1ucQwyFtswv/XNUJkclAxoz4YGGu69dSOEEkwG7Rlh/Gho66SJtOUJ57kN
# artifact: hledger.exe
# on:
# branch: master

View File

@ -1,221 +0,0 @@
# https://docs.travis-ci.com/user/customizing-the-build
# https://docs.travis-ci.com/user/caching/
# https://docs.travis-ci.com/user/languages/haskell/
# http://docs.haskellstack.org/en/stable/travis_ci.html
# https://raw.githubusercontent.com/commercialhaskell/stack/master/doc/travis-simple.yml
# https://raw.githubusercontent.com/commercialhaskell/stack/master/doc/travis-complex.yml
# https://github.com/hvr/multi-ghc-travis#user-content-travisyml-template-for-non-container-based-infrastructure
# https://docs.travis-ci.com/user/common-build-problems/#Build-times-out-because-no-output-was-received
# https://github.com/koterpillar/tianbar/blob/master/Dockerfile.base - custom docker image to save time
# https://github.com/mapnik/mapnik/blob/master/.travis.yml
#
# The Build Lifecycle #
# A build on Travis CI is made up of two steps:
# install: install any dependencies required
# script: run the build script
# You can run custom commands before the installation step (before_install), and before (before_script) or after (after_script) the script step.
# In a before_install step, you can install additional dependencies required by your project such as Ubuntu packages or custom services.
# You can perform additional steps when your build succeeds or fails using the after_success (such as building documentation, or deploying to a custom server) or after_failure (such as uploading log files) options. In both after_failure and after_success, you can access the build result using the $TRAVIS_TEST_RESULT environment variable.
# The complete build lifecycle, including three optional deployment steps and after checking out the git repository and changing to the repository directory, is:
#
# OPTIONAL Install apt addons
# OPTIONAL Install cache components
# before_install
# install
# before_script
# script
# OPTIONAL before_cache (for cleaning up cache)
# Travis CI uploads the cache after the script phase of the build, but before either after_success or after_failure.
# Failure to upload the cache does not mark the job as failed.
# after_success or after_failure
# OPTIONAL before_deploy
# OPTIONAL deploy
# OPTIONAL after_deploy
# after_script
#
# we limit the `make` to 40 min
# to ensure that slow builds still upload their
# cache results and therefore should be faster
# (and might work) for the next build
# - DURATION=2400
# - scripts/travis-command-wrapper.py -s "date" -i 120 --deadline=$(( $(date +%s) + ${DURATION} )) make
sudo: false
dist: trusty
language: generic
cache:
timeout: 1000
directories:
- $HOME/.stack/
- $HOME/.local/bin/
- .stack-work/
- hledger-lib/.stack-work/
- hledger/.stack-work/
- hledger-ui/.stack-work/
- hledger-web/.stack-work/
# - shelltestrunner/
# addons:
# apt:
# packages:
# - libgmp-dev
branches:
only:
- master
# matrix:
# include:
# - env: ARGS=""
# - env: ARGS="--stack-yaml stack-7.10.yaml"
# - ghc: 7.10.3
# - ghc: 8.0.2
#before_install:
# - ./.travis-maybe-skip.sh
# never seemed to work, and can fail, eg:
# https://travis-ci.org/simonmichael/hledger/builds/316707766
install: # command output is hidden as they complete
# if any command fails, end the travis script
- set -e
# warn about nulls ? no, breaks travis
#- set -u
# stack
- mkdir -p ~/.local/bin
- export PATH=~/.local/bin:$PATH
# Fetch latest stack unconditionally. Do this after a stack release or if in doubt.
#- travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'; chmod a+x ~/.local/bin/stack
# Or, fetch latest stack if a stack is not already installed. Saves a little time/fragility.
- if [[ ! -x ~/.local/bin/stack ]]; then travis_retry curl -L https://www.stackage.org/stack/linux-x86_64 | tar xz --wildcards --strip-components=1 -C ~/.local/bin '*/stack'; chmod a+x ~/.local/bin/stack; fi
- which stack
- type -a stack
- stack --version
- echo ~
- ~/.local/bin/stack --version
# GHC
- stack setup
- stack exec -- ghc --version
# hledger dependencies, or at least some of them, built separately to use less memory
# - stack build --only-dependencies hledger-lib #hledger hledger-ui # --test
# TODO does this build hledger-lib & hledger, then rebuild them later with -Werror ?
# - stack build cryptohash
# - stack build --only-dependencies hledger-web # --test
# addon dependencies
#- stack build Chart Chart-diagrams colour Diff
# shelltestrunner
- if [[ ! -x ~/.local/bin/shelltest ]]; then stack install shelltestrunner-1.9; fi
- shelltest --version
script: # command output is not hidden
# less slow
# build hledger packages, ensuring no warnings,
# and any deps not already cached, separately to use less memory
- stack build --ghc-options=-Werror hledger-lib
- stack build --ghc-options=-Werror hledger
# run hledger-lib/hledger functional tests, skipping the ones for addons
- COLUMNS=80 stack exec -- shelltest --execdir -j16 tests -x /bin -x /addons
- stack build --ghc-options=-Werror hledger-ui
- stack build --ghc-options=-Werror hledger-web
# run the built-in hunit tests. This doesn't run the doctests,
# but doesn't require rebuilding and is fast
#- stack exec -- hledger test
# more slow
# build hledger packages, ensuring no warnings, no haddock failures, package test suites passing,
# and any deps not already cached, separately to use less memory
#- stack build --ghc-options=-Werror --test --haddock --no-haddock-deps hledger-lib
#- stack build --ghc-options=-Werror --test --haddock --no-haddock-deps hledger
#- stack build --ghc-options=-Werror --test --haddock --no-haddock-deps hledger-ui
#- stack build --ghc-options=-Werror --test --haddock --no-haddock-deps hledger-web
# build hledger addons, ensuring no warnings
#- stack build Diff
#- stack build Chart
#- stack build diagrams-lib
#- stack build Chart-diagrams
#- sh -e bin/compile.sh
# run functional tests
#- make functest
#after_script:
#
# # list directory contents
# - pwd
# - ls -laF /
# - ls -laF $HOME
# - ls -laF
#
# # coveralls.io coverage reports
# # - stack install hpc-coveralls
# # - hpc-coveralls count-von-count-tests --exclude-dir=tests --exclude-dir=src/Gyrid --display-report
notifications:
# don't need this one, skylink webhook covers it
# irc:
# channels:
# - "chat.freenode.net#hledger-bots"
# on_success: change # [always|never|change] default: always
# on_failure: change # default: always
# use_notice: true
# skip_join: true
# # If you enable skip_join, remember to remove the NO_EXTERNAL_MSGS flag (n) on the IRC channel(s) the bot notifies.
# template:
# - "%{commit}: %{message} %{build_url}"
# # - "%{repository_name} (%{commit}) : %{message} %{build_url}"
# # You can interpolate the following variables:
# # repository_slug: your GitHub repo identifier (like svenfuchs/minimal)
# # repository_name: the slug without the username
# # repository: same as repository_slug [Deprecated]
# # build_number: build number
# # build_id: build id
# # branch: branch build name
# # commit: shortened commit SHA
# # author: commit author name
# # commit_message: commit message of build
# # commit_subject: first line of the commit message
# # result: result of build
# # message: travis message to the build
# # duration: duration of the build
# # compare_url: commit change view URL
# # build_url: URL of the build detail
# # The default template is:
# # - "%{repository}#%{build_number} (%{branch} - %{commit} : %{author}): %{message}"
# # - "Change view : %{compare_url}"
# # - "Build details : %{build_url}"
# email: # false
# recipients:
# - one@example.com
# - other@example.com
# on_success: [always|never|change] # default: change
# on_failure: [always|never|change] # default: always
webhooks:
urls:
# travis webhook for skylink irc bot, https://devmode.cloud/docs/webhooks.html#hook-travisci
- "https://ingest.devmode.cloud/hooks/travisci?channel=%23hledger-bots&longurl=1"
# on_success: change # default: always
# on_failure: always # default: always
on_start: always # default: never
# on_cancel: always # default: always
# on_error: always # default: always