Begone gitlab
This commit is contained in:
		
							parent
							
								
									c2186bb33c
								
							
						
					
					
						commit
						251c82ee9f
					
				
							
								
								
									
										689
									
								
								.gitlab-ci.yml
									
									
									
									
									
								
							
							
						
						
									
										689
									
								
								.gitlab-ci.yml
									
									
									
									
									
								
							@ -1,689 +0,0 @@
 | 
			
		||||
stages:
 | 
			
		||||
  - checks
 | 
			
		||||
  - quick-test
 | 
			
		||||
  - test
 | 
			
		||||
  - expensive-test
 | 
			
		||||
  - release
 | 
			
		||||
 | 
			
		||||
variables:
 | 
			
		||||
  GIT_SSL_NO_VERIFY: "1"
 | 
			
		||||
 | 
			
		||||
  # Commit of ghc/ci-images repository from which to pull Docker images
 | 
			
		||||
  DOCKER_REV: 8d0224e6b2a08157649651e69302380b2bd24e11
 | 
			
		||||
 | 
			
		||||
  # Sequential version number of all cached things.
 | 
			
		||||
  # Bump to invalidate GitLab CI cache.
 | 
			
		||||
  CACHE_REV: 1
 | 
			
		||||
 | 
			
		||||
  GIT_SUBMODULE_STRATEGY: recursive
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
############################################################
 | 
			
		||||
# CI Step
 | 
			
		||||
############################################################
 | 
			
		||||
 | 
			
		||||
.debian:
 | 
			
		||||
  image: "registry.gitlab.haskell.org/ghc/ci-images/x86_64-linux-deb10:$DOCKER_REV"
 | 
			
		||||
  tags:
 | 
			
		||||
    - x86_64-linux
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "LINUX"
 | 
			
		||||
    ARCH: "64"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
    CROSS: ""
 | 
			
		||||
 | 
			
		||||
.alpine:64bit:
 | 
			
		||||
  image: "alpine:3.12"
 | 
			
		||||
  tags:
 | 
			
		||||
    - x86_64-linux
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "LINUX"
 | 
			
		||||
    ARCH: "64"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
 | 
			
		||||
.alpine:32bit:
 | 
			
		||||
  image: "i386/alpine:3.12"
 | 
			
		||||
  tags:
 | 
			
		||||
    - x86_64-linux
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "LINUX"
 | 
			
		||||
    ARCH: "32"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
 | 
			
		||||
.linux:armv7:
 | 
			
		||||
  image: "registry.gitlab.haskell.org/ghc/ci-images/armv7-linux-deb10:$DOCKER_REV"
 | 
			
		||||
  tags:
 | 
			
		||||
    - armv7-linux
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "LINUX"
 | 
			
		||||
    ARCH: "ARM"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
  retry: 2
 | 
			
		||||
 | 
			
		||||
.linux:aarch64:
 | 
			
		||||
  image: "registry.gitlab.haskell.org/ghc/ci-images/aarch64-linux-deb10:$DOCKER_REV"
 | 
			
		||||
  tags:
 | 
			
		||||
    - aarch64-linux
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "LINUX"
 | 
			
		||||
    ARCH: "ARM64"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
 | 
			
		||||
.darwin:
 | 
			
		||||
  tags:
 | 
			
		||||
    - x86_64-darwin
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "DARWIN"
 | 
			
		||||
    ARCH: "64"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
 | 
			
		||||
.darwin:aarch64:
 | 
			
		||||
  tags:
 | 
			
		||||
    - aarch64-darwin-m1
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "DARWIN"
 | 
			
		||||
    ARCH: "ARM64"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
 | 
			
		||||
.freebsd13:
 | 
			
		||||
  tags:
 | 
			
		||||
    - x86_64-freebsd13
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "FREEBSD"
 | 
			
		||||
    ARCH: "64"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
 | 
			
		||||
.freebsd12:
 | 
			
		||||
  tags:
 | 
			
		||||
    - x86_64-freebsd12
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "FREEBSD"
 | 
			
		||||
    ARCH: "64"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
 | 
			
		||||
.windows:
 | 
			
		||||
  tags:
 | 
			
		||||
    - new-x86_64-windows
 | 
			
		||||
  variables:
 | 
			
		||||
    OS: "WINDOWS"
 | 
			
		||||
    ARCH: "64"
 | 
			
		||||
    CABAL_DIR: "$CI_PROJECT_DIR/cabal"
 | 
			
		||||
  retry: 2
 | 
			
		||||
 | 
			
		||||
.root_cleanup:
 | 
			
		||||
  after_script:
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:
 | 
			
		||||
  script:
 | 
			
		||||
    - bash ./.gitlab/script/ghcup_version.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    JSON_VERSION: "0.0.7"
 | 
			
		||||
  artifacts:
 | 
			
		||||
    expire_in: 2 week
 | 
			
		||||
    paths:
 | 
			
		||||
      - test/golden
 | 
			
		||||
      - dist-newstyle/cache/
 | 
			
		||||
    when: on_failure
 | 
			
		||||
  cache:
 | 
			
		||||
    key: ghcup-test-$CACHE_REV
 | 
			
		||||
    paths:
 | 
			
		||||
      - cabal-cache
 | 
			
		||||
 | 
			
		||||
# .test_ghcup_scoop:
 | 
			
		||||
  # script:
 | 
			
		||||
    # - cl /O1 scoop-better-shimexe/shim.c
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:linux:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .debian
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps.sh
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:linux32:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .alpine:32bit
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/alpine/install_deps.sh
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:armv7:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .linux:armv7
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps.sh
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:aarch64:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .linux:aarch64
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps.sh
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:darwin:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .darwin
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/darwin/install_deps.sh
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:darwin:aarch64:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .darwin:aarch64
 | 
			
		||||
  cache:
 | 
			
		||||
    key: darwin-brew-$CACHE_REV
 | 
			
		||||
    paths:
 | 
			
		||||
      - brew_cache
 | 
			
		||||
    key: ghcup-test-$CACHE_REV
 | 
			
		||||
    paths:
 | 
			
		||||
      - cabal-cache
 | 
			
		||||
  before_script:
 | 
			
		||||
    # extract brew cache
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_brew_cache
 | 
			
		||||
    # otherwise we seem to get intel binaries
 | 
			
		||||
    - export HOMEBREW_CHANGE_ARCH_TO_ARM=1
 | 
			
		||||
    # update and install packages
 | 
			
		||||
    - /bin/bash ./.gitlab/script/brew.sh llvm autoconf automake coreutils
 | 
			
		||||
    # extract cabal cache
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  script: |
 | 
			
		||||
    export PATH="$CI_PROJECT_DIR/.brew/opt/llvm/bin:$CI_PROJECT_DIR/.brew/bin:$CI_PROJECT_DIR/.brew/sbin:$PATH"
 | 
			
		||||
    export CC=$CI_PROJECT_DIR/.brew/opt/llvm/bin/clang
 | 
			
		||||
    export CXX=$CI_PROJECT_DIR/.brew/opt/llvm/bin/clang++
 | 
			
		||||
    export LD=ld
 | 
			
		||||
    export AR=$CI_PROJECT_DIR/.brew/opt/llvm/bin/llvm-ar
 | 
			
		||||
    export RANLIB=$CI_PROJECT_DIR/.brew/opt/llvm/bin/llvm-ranlib
 | 
			
		||||
    ./.gitlab/before_script/darwin/install_deps.sh
 | 
			
		||||
    ./.gitlab/script/ghcup_version.sh
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_brew_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:freebsd12:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .freebsd12
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/freebsd/install_deps.sh
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:freebsd13:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .freebsd13
 | 
			
		||||
  before_script:
 | 
			
		||||
    - sudo pkg update
 | 
			
		||||
    - sudo pkg install --yes compat12x-amd64
 | 
			
		||||
    - sudo ln -s libncurses.so.6 /usr/local/lib/libncurses.so.6.2
 | 
			
		||||
    - ./.gitlab/before_script/freebsd/install_deps.sh
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
.test_ghcup_version:windows:
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .windows
 | 
			
		||||
  before_script:
 | 
			
		||||
    - bash ./.gitlab/before_script/windows/install_deps.sh
 | 
			
		||||
    - bash ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
  after_script:
 | 
			
		||||
    - bash ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
 | 
			
		||||
# .test_ghcup_scoop:windows:
 | 
			
		||||
  # extends:
 | 
			
		||||
    # - .windows
 | 
			
		||||
    # - .test_ghcup_scoop
 | 
			
		||||
 | 
			
		||||
.release_ghcup:
 | 
			
		||||
  script:
 | 
			
		||||
    - bash ./.gitlab/script/ghcup_release.sh
 | 
			
		||||
  artifacts:
 | 
			
		||||
    expire_in: 2 week
 | 
			
		||||
    paths:
 | 
			
		||||
      - out
 | 
			
		||||
      - dist-newstyle/cache/
 | 
			
		||||
  only:
 | 
			
		||||
    - tags
 | 
			
		||||
  variables:
 | 
			
		||||
    JSON_VERSION: "0.0.7"
 | 
			
		||||
 | 
			
		||||
######## stack test ########
 | 
			
		||||
 | 
			
		||||
test:linux:stack:
 | 
			
		||||
  stage: test
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_stack_cache
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps_minimal.sh
 | 
			
		||||
  script:
 | 
			
		||||
    - ./.gitlab/script/ghcup_stack.sh
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_stack_cache
 | 
			
		||||
  extends:
 | 
			
		||||
    - .debian
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
######## bootstrap test ########
 | 
			
		||||
 | 
			
		||||
test:linux:bootstrap_script:
 | 
			
		||||
  stage: quick-test
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps_minimal.sh
 | 
			
		||||
  script:
 | 
			
		||||
    - ./.gitlab/script/ghcup_bootstrap.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  extends:
 | 
			
		||||
    - .debian
 | 
			
		||||
    - .root_cleanup
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
test:windows:bootstrap_powershell_script:
 | 
			
		||||
  stage: quick-test
 | 
			
		||||
  script:
 | 
			
		||||
    - ./scripts/bootstrap/bootstrap-haskell.ps1 -InstallDir $CI_PROJECT_DIR -BootstrapUrl $CI_PROJECT_DIR/bootstrap-haskell -InBash
 | 
			
		||||
  after_script:
 | 
			
		||||
    - "[Environment]::SetEnvironmentVariable('GHCUP_INSTALL_BASE_PREFIX', $null, [System.EnvironmentVariableTarget]::User)"
 | 
			
		||||
    - "[Environment]::SetEnvironmentVariable('GHCUP_MSYS2', $null, [System.EnvironmentVariableTarget]::User)"
 | 
			
		||||
    - "[Environment]::SetEnvironmentVariable('CABAL_DIR', $null, [System.EnvironmentVariableTarget]::User)"
 | 
			
		||||
    - bash ./.gitlab/after_script.sh
 | 
			
		||||
    - bash ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  extends:
 | 
			
		||||
    - .windows
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
######## linux test ########
 | 
			
		||||
 | 
			
		||||
test:linux:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:linux
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
test:linux:hls:
 | 
			
		||||
  stage: expensive-test
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .debian
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    HLS_TARGET_VERSION: "1.4.0"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  needs: []
 | 
			
		||||
  when: manual
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps.sh
 | 
			
		||||
  script:
 | 
			
		||||
    - ./.gitlab/script/ghcup_hls.sh
 | 
			
		||||
 | 
			
		||||
test:linux:cross-armv7:
 | 
			
		||||
  stage: expensive-test
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .debian
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.6"
 | 
			
		||||
    GHC_TARGET_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
    CROSS: "arm-linux-gnueabihf"
 | 
			
		||||
  needs: []
 | 
			
		||||
  when: manual
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps.sh
 | 
			
		||||
  script:
 | 
			
		||||
    - ./.gitlab/script/ghcup_cross.sh
 | 
			
		||||
 | 
			
		||||
test:linux:git:hadrian:
 | 
			
		||||
  stage: expensive-test
 | 
			
		||||
  extends:
 | 
			
		||||
    - .test_ghcup_version
 | 
			
		||||
    - .debian
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    GHC_GIT_TAG: "ghc-9.0.1-release"
 | 
			
		||||
    GHC_GIT_VERSION: "9.0.1"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
    CROSS: ""
 | 
			
		||||
  needs: []
 | 
			
		||||
  when: manual
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps.sh
 | 
			
		||||
  script:
 | 
			
		||||
    - ./.gitlab/script/ghcup_git.sh
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
######## linux 32bit test ########
 | 
			
		||||
 | 
			
		||||
test:linux:32bit:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:linux32
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
######## arm tests ########
 | 
			
		||||
 | 
			
		||||
test:linux:armv7:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:armv7
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
    CROSS: ""
 | 
			
		||||
  when: manual
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
test:linux:aarch64:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:aarch64
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
    CROSS: ""
 | 
			
		||||
  when: manual
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
######## darwin test ########
 | 
			
		||||
 | 
			
		||||
test:mac:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:darwin
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
test:mac:aarch64:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:darwin:aarch64
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  needs: []
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
  when: manual
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
######## freebsd test ########
 | 
			
		||||
 | 
			
		||||
test:freebsd12:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:freebsd12
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  allow_failure: true # freebsd runners are unreliable
 | 
			
		||||
  when: manual
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
test:freebsd13:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:freebsd13
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  allow_failure: true # freebsd runners are unreliable
 | 
			
		||||
  when: manual
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
######## windows test ########
 | 
			
		||||
 | 
			
		||||
test:windows:
 | 
			
		||||
  stage: test
 | 
			
		||||
  extends: .test_ghcup_version:windows
 | 
			
		||||
  variables:
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  needs: []
 | 
			
		||||
 | 
			
		||||
# test:windows:scoop:
 | 
			
		||||
  # stage: test
 | 
			
		||||
  # extends: .test_ghcup_scoop:windows
 | 
			
		||||
  # needs: []
 | 
			
		||||
 | 
			
		||||
######## linux release ########
 | 
			
		||||
 | 
			
		||||
release:linux:64bit:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:linux"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .alpine:64bit
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/alpine/install_deps.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "x86_64-linux-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
release:linux:32bit:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:linux:32bit"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .alpine:32bit
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/alpine/install_deps.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "i386-linux-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
 | 
			
		||||
release:linux:armv7:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:linux:armv7"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .linux:armv7
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "armv7-linux-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
    CROSS: ""
 | 
			
		||||
 | 
			
		||||
release:linux:aarch64:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:linux:aarch64"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .linux:aarch64
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/linux/install_deps.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "aarch64-linux-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
    CROSS: ""
 | 
			
		||||
 | 
			
		||||
######## darwin release ########
 | 
			
		||||
 | 
			
		||||
release:darwin:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:mac"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .darwin
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
    - .root_cleanup
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/darwin/install_deps.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "x86_64-apple-darwin-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
    MACOSX_DEPLOYMENT_TARGET: "10.7"
 | 
			
		||||
 | 
			
		||||
release:darwin:aarch64:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:mac:aarch64"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .darwin:aarch64
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
    - .root_cleanup
 | 
			
		||||
  cache:
 | 
			
		||||
    key: darwin-brew-$CACHE_REV
 | 
			
		||||
    paths:
 | 
			
		||||
      - brew_cache
 | 
			
		||||
    key: ghcup-test-$CACHE_REV
 | 
			
		||||
    paths:
 | 
			
		||||
      - cabal-cache
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_brew_cache
 | 
			
		||||
    - ./.gitlab/script/ci.sh extract_cabal_cache
 | 
			
		||||
    # otherwise we seem to get intel binaries
 | 
			
		||||
    - export HOMEBREW_CHANGE_ARCH_TO_ARM=1
 | 
			
		||||
    # update and install packages
 | 
			
		||||
    - /bin/bash ./.gitlab/script/brew.sh llvm autoconf automake coreutils
 | 
			
		||||
  script: |
 | 
			
		||||
    export PATH="$CI_PROJECT_DIR/.brew/opt/llvm/bin:$CI_PROJECT_DIR/.brew/bin:$CI_PROJECT_DIR/.brew/sbin:$PATH"
 | 
			
		||||
    export CC=$CI_PROJECT_DIR/.brew/opt/llvm/bin/clang
 | 
			
		||||
    export CXX=$CI_PROJECT_DIR/.brew/opt/llvm/bin/clang++
 | 
			
		||||
    export LD=ld
 | 
			
		||||
    export AR=$CI_PROJECT_DIR/.brew/opt/llvm/bin/llvm-ar
 | 
			
		||||
    export RANLIB=$CI_PROJECT_DIR/.brew/opt/llvm/bin/llvm-ranlib
 | 
			
		||||
    ./.gitlab/before_script/darwin/install_deps.sh
 | 
			
		||||
    ./.gitlab/script/ghcup_release.sh
 | 
			
		||||
  after_script:
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_cabal_cache
 | 
			
		||||
    - ./.gitlab/script/ci.sh save_brew_cache
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "aarch64-apple-darwin-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
    MACOSX_DEPLOYMENT_TARGET: "10.7"
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
  when: manual
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
######## freebsd release ########
 | 
			
		||||
 | 
			
		||||
release:freebsd12:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:freebsd12"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .freebsd12
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
    - .root_cleanup
 | 
			
		||||
  before_script:
 | 
			
		||||
    - ./.gitlab/before_script/freebsd/install_deps.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "x86_64-portbld-freebsd-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
 | 
			
		||||
release:freebsd13:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:freebsd13"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .freebsd13
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
    - .root_cleanup
 | 
			
		||||
  before_script:
 | 
			
		||||
    - sudo pkg update
 | 
			
		||||
    - sudo pkg install --yes compat12x-amd64
 | 
			
		||||
    - sudo ln -s libncurses.so.6 /usr/local/lib/libncurses.so.6.2
 | 
			
		||||
    - ./.gitlab/before_script/freebsd/install_deps.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "x86_64-portbld-freebsd-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
 | 
			
		||||
######## windows release ########
 | 
			
		||||
 | 
			
		||||
release:windows:
 | 
			
		||||
  stage: release
 | 
			
		||||
  needs: ["test:windows"]
 | 
			
		||||
  extends:
 | 
			
		||||
    - .windows
 | 
			
		||||
    - .release_ghcup
 | 
			
		||||
    - .root_cleanup
 | 
			
		||||
  before_script:
 | 
			
		||||
    - bash ./.gitlab/before_script/windows/install_deps.sh
 | 
			
		||||
  variables:
 | 
			
		||||
    ARTIFACT: "x86_64-mingw64-ghcup"
 | 
			
		||||
    GHC_VERSION: "8.10.7"
 | 
			
		||||
    CABAL_VERSION: "3.6.2.0"
 | 
			
		||||
 | 
			
		||||
######## hlint ########
 | 
			
		||||
 | 
			
		||||
hlint:
 | 
			
		||||
  stage: checks
 | 
			
		||||
  extends:
 | 
			
		||||
    - .debian
 | 
			
		||||
  script:
 | 
			
		||||
    - curl -sSL https://raw.github.com/ndmitchell/hlint/master/misc/run.sh | sh -s -- -r lib/ test/
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
  artifacts:
 | 
			
		||||
    expire_in: 2 week
 | 
			
		||||
    paths:
 | 
			
		||||
      - report.html
 | 
			
		||||
    when: on_failure
 | 
			
		||||
 | 
			
		||||
######## mkdocs ########
 | 
			
		||||
 | 
			
		||||
mkdocs:
 | 
			
		||||
  stage: checks
 | 
			
		||||
  extends:
 | 
			
		||||
    - .debian
 | 
			
		||||
  before_script:
 | 
			
		||||
    - sudo apt-get update -y
 | 
			
		||||
    - sudo apt-get install -y python3-pip
 | 
			
		||||
    - pip3 install mkdocs
 | 
			
		||||
  script:
 | 
			
		||||
    - ~/.local/bin/mkdocs build
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
 | 
			
		||||
######## shellcheck ########
 | 
			
		||||
 | 
			
		||||
shellcheck:
 | 
			
		||||
  image: "koalaman/shellcheck-alpine"
 | 
			
		||||
  tags:
 | 
			
		||||
    - x86_64-linux
 | 
			
		||||
  stage: checks
 | 
			
		||||
  script:
 | 
			
		||||
    - shellcheck scripts/bootstrap/bootstrap-haskell
 | 
			
		||||
  allow_failure: true
 | 
			
		||||
 | 
			
		||||
@ -1,19 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
BUILD_DIR=$CI_PROJECT_DIR
 | 
			
		||||
echo "Cleaning $BUILD_DIR"
 | 
			
		||||
cd $HOME
 | 
			
		||||
test -n "$BUILD_DIR"
 | 
			
		||||
shopt -s extglob
 | 
			
		||||
rm -Rf "$BUILD_DIR"/!(out)
 | 
			
		||||
if [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
	rm -Rf /c/ghcup
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
if [ "${OS}" = "DARWIN" ] ; then
 | 
			
		||||
	rm -Rf /private/tmp/.brew_tmp
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
exit 0
 | 
			
		||||
@ -1,32 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "${TMPDIR}"
 | 
			
		||||
 | 
			
		||||
if [ $ARCH = 'ARM64' ] ; then
 | 
			
		||||
	curl -sSfL https://downloads.haskell.org/~ghcup/aarch64-apple-darwin-ghcup > ./ghcup-bin
 | 
			
		||||
	chmod +x ghcup-bin
 | 
			
		||||
else
 | 
			
		||||
	curl -sSfL https://downloads.haskell.org/~ghcup/x86_64-apple-darwin-ghcup > ./ghcup-bin
 | 
			
		||||
	chmod +x ghcup-bin
 | 
			
		||||
	./ghcup-bin upgrade -i -f
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
./ghcup-bin install ${GHC_VERSION}
 | 
			
		||||
./ghcup-bin set ${GHC_VERSION}
 | 
			
		||||
./ghcup-bin install-cabal ${CABAL_VERSION}
 | 
			
		||||
 | 
			
		||||
if [ $ARCH = 'ARM64' ] ; then
 | 
			
		||||
	cabal update
 | 
			
		||||
	mkdir vendored
 | 
			
		||||
	cd vendored
 | 
			
		||||
	cabal unpack network-3.1.2.1
 | 
			
		||||
	cd network*
 | 
			
		||||
	autoreconf -fi
 | 
			
		||||
	cd ../..
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
exit 0
 | 
			
		||||
@ -1,27 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
# pkg install --force --yes --no-repo-update curl gcc gmp gmake ncurses perl5 libffi libiconv
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "${TMPDIR}"
 | 
			
		||||
 | 
			
		||||
if freebsd-version | grep -E '^12.*' ; then
 | 
			
		||||
	freebsd_ver=12
 | 
			
		||||
elif freebsd-version | grep -E '^13.*' ; then
 | 
			
		||||
	freebsd_ver=13
 | 
			
		||||
else
 | 
			
		||||
	(>&2 echo "Unsupported FreeBSD version! Please report a bug at https://gitlab.haskell.org/haskell/ghcup-hs/-/issues")
 | 
			
		||||
	exit 1
 | 
			
		||||
fi
 | 
			
		||||
curl -sSfL https://downloads.haskell.org/~ghcup/x86_64-freebsd${freebsd_ver}-ghcup > ./ghcup-bin
 | 
			
		||||
chmod +x ghcup-bin
 | 
			
		||||
 | 
			
		||||
./ghcup-bin -v upgrade -i -f
 | 
			
		||||
./ghcup-bin -v install ${GHC_VERSION}
 | 
			
		||||
./ghcup-bin -v set ${GHC_VERSION}
 | 
			
		||||
./ghcup-bin -v install-cabal ${CABAL_VERSION}
 | 
			
		||||
 | 
			
		||||
exit 0
 | 
			
		||||
@ -1,58 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../../../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "${TMPDIR}"
 | 
			
		||||
 | 
			
		||||
apk add --no-cache \
 | 
			
		||||
	curl \
 | 
			
		||||
	gcc \
 | 
			
		||||
	g++ \
 | 
			
		||||
	binutils \
 | 
			
		||||
	binutils-gold \
 | 
			
		||||
	bsd-compat-headers \
 | 
			
		||||
	gmp-dev \
 | 
			
		||||
	ncurses-dev \
 | 
			
		||||
	libffi-dev \
 | 
			
		||||
	make \
 | 
			
		||||
	xz \
 | 
			
		||||
	tar \
 | 
			
		||||
	perl
 | 
			
		||||
 | 
			
		||||
if [ "${ARCH}" = "32" ] ; then
 | 
			
		||||
	curl -sSfL https://downloads.haskell.org/ghcup/i386-linux-ghcup > ./ghcup-bin
 | 
			
		||||
else
 | 
			
		||||
	curl -sSfL https://downloads.haskell.org/ghcup/x86_64-linux-ghcup > ./ghcup-bin
 | 
			
		||||
fi
 | 
			
		||||
chmod +x ghcup-bin
 | 
			
		||||
./ghcup-bin upgrade -i -f
 | 
			
		||||
./ghcup-bin install ${GHC_VERSION}
 | 
			
		||||
./ghcup-bin install-cabal ${CABAL_VERSION}
 | 
			
		||||
 | 
			
		||||
# utils
 | 
			
		||||
apk add --no-cache \
 | 
			
		||||
	bash \
 | 
			
		||||
	git
 | 
			
		||||
 | 
			
		||||
## Package specific
 | 
			
		||||
apk add --no-cache \
 | 
			
		||||
	zlib \
 | 
			
		||||
	zlib-dev \
 | 
			
		||||
	zlib-static \
 | 
			
		||||
	bzip2 \
 | 
			
		||||
	bzip2-dev \
 | 
			
		||||
	bzip2-static \
 | 
			
		||||
	gmp \
 | 
			
		||||
	gmp-dev \
 | 
			
		||||
	openssl-dev \
 | 
			
		||||
	openssl-libs-static \
 | 
			
		||||
	xz \
 | 
			
		||||
	xz-dev \
 | 
			
		||||
	ncurses-static
 | 
			
		||||
 | 
			
		||||
if [ "${ARCH}" = "32" ] ; then
 | 
			
		||||
	apk add --no-cache \
 | 
			
		||||
		bsd-compat-headers
 | 
			
		||||
fi
 | 
			
		||||
@ -1,27 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "${TMPDIR}"
 | 
			
		||||
 | 
			
		||||
sudo apt-get update -y
 | 
			
		||||
sudo apt-get install -y libnuma-dev zlib1g-dev libgmp-dev libgmp10 libssl-dev liblzma-dev libbz2-dev git wget lsb-release software-properties-common gnupg2 apt-transport-https gcc autoconf automake build-essential
 | 
			
		||||
 | 
			
		||||
if [ "${CROSS}" = "arm-linux-gnueabihf" ] ; then
 | 
			
		||||
	sudo apt-get install -y gcc-arm-linux-gnueabihf
 | 
			
		||||
	sudo dpkg --add-architecture armhf
 | 
			
		||||
	sudo apt-get update -y
 | 
			
		||||
	sudo apt-get install -y libncurses-dev:armhf
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
export BOOTSTRAP_HASKELL_NONINTERACTIVE=1
 | 
			
		||||
export BOOTSTRAP_HASKELL_GHC_VERSION=$GHC_VERSION
 | 
			
		||||
export BOOTSTRAP_HASKELL_CABAL_VERSION=$CABAL_VERSION
 | 
			
		||||
export BOOTSTRAP_HASKELL_VERBOSE=1
 | 
			
		||||
 | 
			
		||||
curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | sh
 | 
			
		||||
 | 
			
		||||
rm "${GHCUP_INSTALL_BASE_PREFIX}"/.ghcup/bin/ghcup
 | 
			
		||||
 | 
			
		||||
@ -1,10 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "${TMPDIR}"
 | 
			
		||||
 | 
			
		||||
sudo apt-get update -y
 | 
			
		||||
sudo apt-get install -y libnuma-dev zlib1g-dev libgmp-dev libgmp10 libssl-dev liblzma-dev libbz2-dev git wget
 | 
			
		||||
@ -1,21 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "${TMPDIR}" "${CABAL_DIR}"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$GHCUP_INSTALL_BASE_PREFIX/ghcup/bin"
 | 
			
		||||
 | 
			
		||||
CI_PROJECT_DIR=$(pwd)
 | 
			
		||||
curl -o ghcup.exe https://downloads.haskell.org/~ghcup/x86_64-mingw64-ghcup.exe
 | 
			
		||||
chmod +x ghcup.exe
 | 
			
		||||
 | 
			
		||||
./ghcup.exe install ${GHC_VERSION}
 | 
			
		||||
./ghcup.exe set ${GHC_VERSION}
 | 
			
		||||
./ghcup.exe install-cabal ${CABAL_VERSION}
 | 
			
		||||
 | 
			
		||||
rm ./ghcup.exe
 | 
			
		||||
 | 
			
		||||
exit 0
 | 
			
		||||
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							
										
											
												File diff suppressed because it is too large
												Load Diff
											
										
									
								
							@ -1,37 +0,0 @@
 | 
			
		||||
.
 | 
			
		||||
./cabal
 | 
			
		||||
./ghc
 | 
			
		||||
./ghc-8.10.7
 | 
			
		||||
./ghc-pkg
 | 
			
		||||
./ghc-pkg-8.10.7
 | 
			
		||||
./ghci
 | 
			
		||||
./ghci-8.10.7
 | 
			
		||||
./haddock
 | 
			
		||||
./haddock-8.10.7
 | 
			
		||||
./haskell-language-server-8.10.6
 | 
			
		||||
./haskell-language-server-8.10.6~1.6.1.0
 | 
			
		||||
./haskell-language-server-8.10.7
 | 
			
		||||
./haskell-language-server-8.10.7~1.6.1.0
 | 
			
		||||
./haskell-language-server-8.6.5
 | 
			
		||||
./haskell-language-server-8.6.5~1.6.1.0
 | 
			
		||||
./haskell-language-server-8.8.4
 | 
			
		||||
./haskell-language-server-8.8.4~1.6.1.0
 | 
			
		||||
./haskell-language-server-9.0.1
 | 
			
		||||
./haskell-language-server-9.0.1~1.6.1.0
 | 
			
		||||
./haskell-language-server-9.0.2
 | 
			
		||||
./haskell-language-server-9.0.2~1.6.1.0
 | 
			
		||||
./haskell-language-server-9.2.1
 | 
			
		||||
./haskell-language-server-9.2.1~1.6.1.0
 | 
			
		||||
./haskell-language-server-wrapper
 | 
			
		||||
./haskell-language-server-wrapper-1.6.1.0
 | 
			
		||||
./hp2ps
 | 
			
		||||
./hp2ps-8.10.7
 | 
			
		||||
./hpc
 | 
			
		||||
./hpc-8.10.7
 | 
			
		||||
./hsc2hs
 | 
			
		||||
./hsc2hs-8.10.7
 | 
			
		||||
./runghc
 | 
			
		||||
./runghc-8.10.7
 | 
			
		||||
./runhaskell
 | 
			
		||||
./runhaskell-8.10.7
 | 
			
		||||
./stack
 | 
			
		||||
@ -1,81 +0,0 @@
 | 
			
		||||
.
 | 
			
		||||
./cabal.exe
 | 
			
		||||
./cabal.shim
 | 
			
		||||
./ghc-8.10.7.exe
 | 
			
		||||
./ghc-8.10.7.shim
 | 
			
		||||
./ghc-pkg-8.10.7.exe
 | 
			
		||||
./ghc-pkg-8.10.7.shim
 | 
			
		||||
./ghc-pkg.exe
 | 
			
		||||
./ghc-pkg.shim
 | 
			
		||||
./ghc.exe
 | 
			
		||||
./ghc.shim
 | 
			
		||||
./ghci-8.10.7.exe
 | 
			
		||||
./ghci-8.10.7.shim
 | 
			
		||||
./ghci.exe
 | 
			
		||||
./ghci.shim
 | 
			
		||||
./ghcii-8.10.7.sh-8.10.7.exe
 | 
			
		||||
./ghcii-8.10.7.sh-8.10.7.shim
 | 
			
		||||
./ghcii-8.10.7.sh.exe
 | 
			
		||||
./ghcii-8.10.7.sh.shim
 | 
			
		||||
./ghcii.sh-8.10.7.exe
 | 
			
		||||
./ghcii.sh-8.10.7.shim
 | 
			
		||||
./ghcii.sh.exe
 | 
			
		||||
./ghcii.sh.shim
 | 
			
		||||
./haddock-8.10.7.exe
 | 
			
		||||
./haddock-8.10.7.shim
 | 
			
		||||
./haddock.exe
 | 
			
		||||
./haddock.shim
 | 
			
		||||
./haskell-language-server-8.10.6.exe
 | 
			
		||||
./haskell-language-server-8.10.6.shim
 | 
			
		||||
./haskell-language-server-8.10.6~1.6.1.0.exe
 | 
			
		||||
./haskell-language-server-8.10.6~1.6.1.0.shim
 | 
			
		||||
./haskell-language-server-8.10.7.exe
 | 
			
		||||
./haskell-language-server-8.10.7.shim
 | 
			
		||||
./haskell-language-server-8.10.7~1.6.1.0.exe
 | 
			
		||||
./haskell-language-server-8.10.7~1.6.1.0.shim
 | 
			
		||||
./haskell-language-server-8.6.5.exe
 | 
			
		||||
./haskell-language-server-8.6.5.shim
 | 
			
		||||
./haskell-language-server-8.6.5~1.6.1.0.exe
 | 
			
		||||
./haskell-language-server-8.6.5~1.6.1.0.shim
 | 
			
		||||
./haskell-language-server-8.8.4.exe
 | 
			
		||||
./haskell-language-server-8.8.4.shim
 | 
			
		||||
./haskell-language-server-8.8.4~1.6.1.0.exe
 | 
			
		||||
./haskell-language-server-8.8.4~1.6.1.0.shim
 | 
			
		||||
./haskell-language-server-9.0.1.exe
 | 
			
		||||
./haskell-language-server-9.0.1.shim
 | 
			
		||||
./haskell-language-server-9.0.1~1.6.1.0.exe
 | 
			
		||||
./haskell-language-server-9.0.1~1.6.1.0.shim
 | 
			
		||||
./haskell-language-server-9.0.2.exe
 | 
			
		||||
./haskell-language-server-9.0.2.shim
 | 
			
		||||
./haskell-language-server-9.0.2~1.6.1.0.exe
 | 
			
		||||
./haskell-language-server-9.0.2~1.6.1.0.shim
 | 
			
		||||
./haskell-language-server-9.2.1.exe
 | 
			
		||||
./haskell-language-server-9.2.1.shim
 | 
			
		||||
./haskell-language-server-9.2.1~1.6.1.0.exe
 | 
			
		||||
./haskell-language-server-9.2.1~1.6.1.0.shim
 | 
			
		||||
./haskell-language-server-wrapper-1.6.1.0.exe
 | 
			
		||||
./haskell-language-server-wrapper-1.6.1.0.shim
 | 
			
		||||
./haskell-language-server-wrapper.exe
 | 
			
		||||
./haskell-language-server-wrapper.shim
 | 
			
		||||
./hp2ps-8.10.7.exe
 | 
			
		||||
./hp2ps-8.10.7.shim
 | 
			
		||||
./hp2ps.exe
 | 
			
		||||
./hp2ps.shim
 | 
			
		||||
./hpc-8.10.7.exe
 | 
			
		||||
./hpc-8.10.7.shim
 | 
			
		||||
./hpc.exe
 | 
			
		||||
./hpc.shim
 | 
			
		||||
./hsc2hs-8.10.7.exe
 | 
			
		||||
./hsc2hs-8.10.7.shim
 | 
			
		||||
./hsc2hs.exe
 | 
			
		||||
./hsc2hs.shim
 | 
			
		||||
./runghc-8.10.7.exe
 | 
			
		||||
./runghc-8.10.7.shim
 | 
			
		||||
./runghc.exe
 | 
			
		||||
./runghc.shim
 | 
			
		||||
./runhaskell-8.10.7.exe
 | 
			
		||||
./runhaskell-8.10.7.shim
 | 
			
		||||
./runhaskell.exe
 | 
			
		||||
./runhaskell.shim
 | 
			
		||||
./stack.exe
 | 
			
		||||
./stack.shim
 | 
			
		||||
@ -1,23 +0,0 @@
 | 
			
		||||
if [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
    export GHCUP_INSTALL_BASE_PREFIX="$CI_PROJECT_DIR"
 | 
			
		||||
    export GHCUP_BIN="$CI_PROJECT_DIR/ghcup/bin"
 | 
			
		||||
    export PATH="$GHCUP_BIN:$CI_PROJECT_DIR/.local/bin:$PATH"
 | 
			
		||||
    export TMPDIR="$CI_PROJECT_DIR/tmp"
 | 
			
		||||
    export CABAL_DIR="$CI_PROJECT_DIR/cabal"
 | 
			
		||||
    export CABAL_CACHE="$CI_PROJECT_DIR/cabal-cache"
 | 
			
		||||
    export STACK_ROOT="$CI_PROJECT_DIR/stack"
 | 
			
		||||
    export STACK_CACHE="$CI_PROJECT_DIR/stack-cache"
 | 
			
		||||
    export BREW_DIR="$CI_PROJECT_DIR/.brew_cache"
 | 
			
		||||
    export BREW_CACHE="$CI_PROJECT_DIR/brew-cache"
 | 
			
		||||
else
 | 
			
		||||
    export GHCUP_INSTALL_BASE_PREFIX="$CI_PROJECT_DIR"
 | 
			
		||||
    export GHCUP_BIN="$CI_PROJECT_DIR/.ghcup/bin"
 | 
			
		||||
    export PATH="$GHCUP_BIN:$CI_PROJECT_DIR/.local/bin:$PATH"
 | 
			
		||||
    export TMPDIR="$CI_PROJECT_DIR/tmp"
 | 
			
		||||
    export CABAL_DIR="$CI_PROJECT_DIR/cabal"
 | 
			
		||||
    export CABAL_CACHE="$CI_PROJECT_DIR/cabal-cache"
 | 
			
		||||
    export STACK_ROOT="$CI_PROJECT_DIR/stack"
 | 
			
		||||
    export STACK_CACHE="$CI_PROJECT_DIR/stack-cache"
 | 
			
		||||
    export BREW_DIR="$CI_PROJECT_DIR/.brew_cache"
 | 
			
		||||
    export BREW_CACHE="$CI_PROJECT_DIR/brew-cache"
 | 
			
		||||
fi
 | 
			
		||||
@ -1,19 +0,0 @@
 | 
			
		||||
#!/usr/bin/env bash
 | 
			
		||||
 | 
			
		||||
set -Eeuxo pipefail
 | 
			
		||||
 | 
			
		||||
# Install brew locally in the project dir. Packages will also be installed here.
 | 
			
		||||
[ -e "$CI_PROJECT_DIR/.brew" ] || git clone --depth=1 https://github.com/Homebrew/brew $CI_PROJECT_DIR/.brew
 | 
			
		||||
export PATH="$CI_PROJECT_DIR/.brew/bin:$CI_PROJECT_DIR/.brew/sbin:$PATH"
 | 
			
		||||
 | 
			
		||||
# make sure to not pollute the machine with temp files etc
 | 
			
		||||
mkdir -p $CI_PROJECT_DIR/.brew_cache
 | 
			
		||||
export HOMEBREW_CACHE=$CI_PROJECT_DIR/.brew_cache
 | 
			
		||||
mkdir -p $CI_PROJECT_DIR/.brew_logs
 | 
			
		||||
export HOMEBREW_LOGS=$CI_PROJECT_DIR/.brew_logs
 | 
			
		||||
mkdir -p /private/tmp/.brew_tmp
 | 
			
		||||
export HOMEBREW_TEMP=/private/tmp/.brew_tmp
 | 
			
		||||
 | 
			
		||||
# update and install packages
 | 
			
		||||
brew update
 | 
			
		||||
brew install ${1+"$@"}
 | 
			
		||||
@ -1,70 +0,0 @@
 | 
			
		||||
#!/usr/bin/env bash
 | 
			
		||||
 | 
			
		||||
set -Eeuo pipefail
 | 
			
		||||
 | 
			
		||||
TOP="$( cd "$(dirname "$0")" ; pwd -P )"
 | 
			
		||||
. "${TOP}/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
function save_cabal_cache () {
 | 
			
		||||
  echo "Storing cabal cache from $CABAL_DIR to $CABAL_CACHE..."
 | 
			
		||||
  rm -Rf "$CABAL_CACHE"
 | 
			
		||||
  mkdir -p "$CABAL_CACHE"
 | 
			
		||||
  if [ -d "$CABAL_DIR" ]; then
 | 
			
		||||
	  cp -Rf "$CABAL_DIR" "$CABAL_CACHE/"
 | 
			
		||||
  fi
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
function extract_cabal_cache () {
 | 
			
		||||
  if [ -d "$CABAL_CACHE" ]; then
 | 
			
		||||
      echo "Extracting cabal cache from $CABAL_CACHE to $CABAL_DIR..."
 | 
			
		||||
      mkdir -p "$CABAL_DIR"
 | 
			
		||||
      cp -Rf "$CABAL_CACHE"/* "$CABAL_DIR"
 | 
			
		||||
  fi
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
function save_stack_cache () {
 | 
			
		||||
  echo "Storing stack cache from $STACK_ROOT to $STACK_CACHE..."
 | 
			
		||||
  rm -Rf "$STACK_CACHE"
 | 
			
		||||
  mkdir -p "$STACK_CACHE"
 | 
			
		||||
  if [ -d "$STACK_ROOT" ]; then
 | 
			
		||||
	  cp -Rf "$STACK_DIR" "$STACK_CACHE"
 | 
			
		||||
  fi
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
function extract_stack_cache () {
 | 
			
		||||
  if [ -d "$STACK_CACHE" ]; then
 | 
			
		||||
      echo "Extracting stack cache from $STACK_CACHE to $STACK_ROOT..."
 | 
			
		||||
      mkdir -p "$STACK_ROOT"
 | 
			
		||||
      cp -Rf "$STACK_CACHE"/* "$STACK_ROOT"
 | 
			
		||||
  fi
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
function save_brew_cache () {
 | 
			
		||||
  echo "Storing brew cache from $BREW_DIR to $BREW_CACHE..."
 | 
			
		||||
  rm -Rf "$BREW_CACHE"
 | 
			
		||||
  mkdir -p "$BREW_CACHE"
 | 
			
		||||
  if [ -d "$BREW_DIR" ]; then
 | 
			
		||||
	  cp -Rf "$BREW_DIR" "$BREW_CACHE"
 | 
			
		||||
  fi
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
function extract_brew_cache () {
 | 
			
		||||
  if [ -d "$BREW_CACHE" ]; then
 | 
			
		||||
      echo "Extracting stack cache from $BREW_CACHE to $BREW_DIR..."
 | 
			
		||||
      mkdir -p "$BREW_DIR"
 | 
			
		||||
      cp -Rf "$BREW_CACHE"/* "$BREW_DIR"
 | 
			
		||||
  fi
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
case $1 in
 | 
			
		||||
  extract_cabal_cache) extract_cabal_cache ;;
 | 
			
		||||
  save_cabal_cache) save_cabal_cache ;;
 | 
			
		||||
  extract_stack_cache) extract_stack_cache ;;
 | 
			
		||||
  save_stack_cache) save_stack_cache ;;
 | 
			
		||||
  extract_brew_cache) extract_brew_cache ;;
 | 
			
		||||
  save_brew_cache) save_brew_cache ;;
 | 
			
		||||
  *) echo "unknown mode $1" ; exit 11 ;;
 | 
			
		||||
esac
 | 
			
		||||
@ -1,20 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.local/bin
 | 
			
		||||
 | 
			
		||||
git describe --always
 | 
			
		||||
 | 
			
		||||
### build
 | 
			
		||||
 | 
			
		||||
export BOOTSTRAP_HASKELL_NONINTERACTIVE=yes
 | 
			
		||||
export BOOTSTRAP_HASKELL_GHC_VERSION=$GHC_VERSION
 | 
			
		||||
export BOOTSTRAP_HASKELL_CABAL_VERSION=$CABAL_VERSION
 | 
			
		||||
 | 
			
		||||
./scripts/bootstrap/bootstrap-haskell
 | 
			
		||||
 | 
			
		||||
[ "$(ghc --numeric-version)" = "${GHC_VERSION}" ]
 | 
			
		||||
 | 
			
		||||
@ -1,52 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.local/bin
 | 
			
		||||
 | 
			
		||||
CI_PROJECT_DIR=$(pwd)
 | 
			
		||||
 | 
			
		||||
ecabal() {
 | 
			
		||||
	cabal "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
eghcup() {
 | 
			
		||||
	ghcup -v -c -s file://$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
git describe --always
 | 
			
		||||
 | 
			
		||||
### build
 | 
			
		||||
 | 
			
		||||
ecabal update
 | 
			
		||||
 | 
			
		||||
ecabal build -w ghc-${GHC_VERSION}
 | 
			
		||||
cp "$(ecabal new-exec -w ghc-${GHC_VERSION} --verbose=0 --offline sh -- -c 'command -v ghcup')" "$CI_PROJECT_DIR"/.local/bin/ghcup
 | 
			
		||||
 | 
			
		||||
### cleanup
 | 
			
		||||
 | 
			
		||||
rm -rf "${GHCUP_INSTALL_BASE_PREFIX}"/.ghcup
 | 
			
		||||
 | 
			
		||||
### manual cli based testing
 | 
			
		||||
 | 
			
		||||
eghcup --numeric-version
 | 
			
		||||
 | 
			
		||||
eghcup install ghc ${GHC_VERSION}
 | 
			
		||||
eghcup set ghc ${GHC_VERSION}
 | 
			
		||||
eghcup install cabal ${CABAL_VERSION}
 | 
			
		||||
 | 
			
		||||
cabal --version
 | 
			
		||||
 | 
			
		||||
eghcup debug-info
 | 
			
		||||
 | 
			
		||||
eghcup compile ghc -j $(nproc) -v ${GHC_TARGET_VERSION} -b ${GHC_VERSION} -x ${CROSS} -- --enable-unregisterised
 | 
			
		||||
eghcup set ghc ${CROSS}-${GHC_TARGET_VERSION}
 | 
			
		||||
 | 
			
		||||
[ `$(eghcup whereis ghc ${CROSS}-${GHC_TARGET_VERSION}) --numeric-version` = "${GHC_TARGET_VERSION}" ]
 | 
			
		||||
 | 
			
		||||
# nuke
 | 
			
		||||
eghcup nuke
 | 
			
		||||
[ ! -e "${GHCUP_INSTALL_BASE_PREFIX}/.ghcup" ]
 | 
			
		||||
 | 
			
		||||
@ -1,52 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.local/bin
 | 
			
		||||
 | 
			
		||||
CI_PROJECT_DIR=$(pwd)
 | 
			
		||||
 | 
			
		||||
ecabal() {
 | 
			
		||||
	cabal "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
eghcup() {
 | 
			
		||||
	ghcup -v -c -s file://$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
git describe --always
 | 
			
		||||
 | 
			
		||||
### build
 | 
			
		||||
 | 
			
		||||
ecabal update
 | 
			
		||||
 | 
			
		||||
ecabal build -w ghc-${GHC_VERSION}
 | 
			
		||||
cp "$(ecabal new-exec -w ghc-${GHC_VERSION} --verbose=0 --offline sh -- -c 'command -v ghcup')" "$CI_PROJECT_DIR"/.local/bin/ghcup
 | 
			
		||||
 | 
			
		||||
### cleanup
 | 
			
		||||
 | 
			
		||||
rm -rf "${GHCUP_INSTALL_BASE_PREFIX}"/.ghcup
 | 
			
		||||
 | 
			
		||||
### manual cli based testing
 | 
			
		||||
 | 
			
		||||
eghcup --numeric-version
 | 
			
		||||
 | 
			
		||||
eghcup install ghc ${GHC_VERSION}
 | 
			
		||||
eghcup set ghc ${GHC_VERSION}
 | 
			
		||||
eghcup install cabal ${CABAL_VERSION}
 | 
			
		||||
 | 
			
		||||
cabal --version
 | 
			
		||||
 | 
			
		||||
eghcup debug-info
 | 
			
		||||
 | 
			
		||||
eghcup compile ghc -j $(nproc) -g ${GHC_GIT_TAG} -b ${GHC_VERSION} -- --enable-unregisterised
 | 
			
		||||
eghcup set ghc ${GHC_GIT_VERSION}
 | 
			
		||||
 | 
			
		||||
[ `$(eghcup whereis ghc ${GHC_GIT_VERSION}) --numeric-version` = "${GHC_GIT_VERSION}" ]
 | 
			
		||||
 | 
			
		||||
# nuke
 | 
			
		||||
eghcup nuke
 | 
			
		||||
[ ! -e "${GHCUP_INSTALL_BASE_PREFIX}/.ghcup" ]
 | 
			
		||||
 | 
			
		||||
@ -1,51 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.local/bin
 | 
			
		||||
 | 
			
		||||
CI_PROJECT_DIR=$(pwd)
 | 
			
		||||
 | 
			
		||||
ecabal() {
 | 
			
		||||
	cabal "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
eghcup() {
 | 
			
		||||
	ghcup -v -c -s file://$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
git describe --always
 | 
			
		||||
 | 
			
		||||
### build
 | 
			
		||||
 | 
			
		||||
ecabal update
 | 
			
		||||
 | 
			
		||||
ecabal build -w ghc-${GHC_VERSION}
 | 
			
		||||
cp "$(ecabal new-exec -w ghc-${GHC_VERSION} --verbose=0 --offline sh -- -c 'command -v ghcup')" "$CI_PROJECT_DIR"/.local/bin/ghcup
 | 
			
		||||
 | 
			
		||||
### cleanup
 | 
			
		||||
 | 
			
		||||
rm -rf "${GHCUP_INSTALL_BASE_PREFIX}"/.ghcup
 | 
			
		||||
 | 
			
		||||
### manual cli based testing
 | 
			
		||||
 | 
			
		||||
eghcup --numeric-version
 | 
			
		||||
 | 
			
		||||
eghcup install ghc ${GHC_VERSION}
 | 
			
		||||
eghcup set ghc ${GHC_VERSION}
 | 
			
		||||
eghcup install cabal ${CABAL_VERSION}
 | 
			
		||||
 | 
			
		||||
cabal --version
 | 
			
		||||
 | 
			
		||||
eghcup debug-info
 | 
			
		||||
 | 
			
		||||
eghcup compile hls -j $(nproc) -v ${HLS_TARGET_VERSION} --ghc ${GHC_VERSION}
 | 
			
		||||
 | 
			
		||||
[ `$(eghcup whereis hls ${HLS_TARGET_VERSION}) --numeric-version` = "${HLS_TARGET_VERSION}" ] || [ `$(eghcup whereis hls ${HLS_TARGET_VERSION}) --numeric-version | sed 's/.0$//'` = "${HLS_TARGET_VERSION}" ]
 | 
			
		||||
 | 
			
		||||
# nuke
 | 
			
		||||
eghcup nuke
 | 
			
		||||
[ ! -e "${GHCUP_INSTALL_BASE_PREFIX}/.ghcup" ]
 | 
			
		||||
 | 
			
		||||
@ -1,44 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.local/bin
 | 
			
		||||
 | 
			
		||||
ecabal() {
 | 
			
		||||
	cabal "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
git describe
 | 
			
		||||
 | 
			
		||||
# build
 | 
			
		||||
ecabal update
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
if [ "${OS}" = "LINUX" ] ; then
 | 
			
		||||
	if [ "${ARCH}" = "32" ] ; then
 | 
			
		||||
		ecabal build -w ghc-${GHC_VERSION} --ghc-options='-split-sections -optl-static' -ftui
 | 
			
		||||
	elif [ "${ARCH}" = "64" ] ; then
 | 
			
		||||
		ecabal build -w ghc-${GHC_VERSION} --ghc-options='-split-sections -optl-static' -ftui
 | 
			
		||||
	else
 | 
			
		||||
		ecabal build -w ghc-${GHC_VERSION} -ftui
 | 
			
		||||
	fi
 | 
			
		||||
elif [ "${OS}" = "FREEBSD" ] ; then
 | 
			
		||||
	ecabal build -w ghc-${GHC_VERSION} --ghc-options='-split-sections' --constraint="zlib +bundled-c-zlib" --constraint="zip +disable-zstd" -ftui
 | 
			
		||||
elif [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
	ecabal build -w ghc-${GHC_VERSION} --constraint="zlib +bundled-c-zlib" --constraint="lzma +static"
 | 
			
		||||
else
 | 
			
		||||
	ecabal build -w ghc-${GHC_VERSION} --constraint="zlib +bundled-c-zlib" --constraint="lzma +static" -ftui
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
mkdir out
 | 
			
		||||
binary=$(ecabal new-exec -w ghc-${GHC_VERSION} --verbose=0 --offline sh -- -c 'command -v ghcup')
 | 
			
		||||
ver=$("${binary}" --numeric-version)
 | 
			
		||||
if [ "${OS}" = "DARWIN" ] ; then
 | 
			
		||||
	strip "${binary}"
 | 
			
		||||
else
 | 
			
		||||
	strip -s "${binary}"
 | 
			
		||||
fi
 | 
			
		||||
cp "${binary}" out/${ARTIFACT}-${ver}
 | 
			
		||||
 | 
			
		||||
@ -1,21 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.local/bin
 | 
			
		||||
 | 
			
		||||
git describe --always
 | 
			
		||||
 | 
			
		||||
### build
 | 
			
		||||
 | 
			
		||||
curl -L -O https://get.haskellstack.org/stable/linux-x86_64.tar.gz
 | 
			
		||||
tar xf linux-x86_64.tar.gz
 | 
			
		||||
cp stack-*-linux-*/stack "$CI_PROJECT_DIR"/.local/bin/stack
 | 
			
		||||
chmod +x "$CI_PROJECT_DIR"/.local/bin/stack
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.stack_root
 | 
			
		||||
export TAR_OPTIONS=--no-same-owner
 | 
			
		||||
stack --allow-different-user --stack-root "$CI_PROJECT_DIR"/.stack_root build
 | 
			
		||||
stack --allow-different-user --stack-root "$CI_PROJECT_DIR"/.stack_root test
 | 
			
		||||
@ -1,314 +0,0 @@
 | 
			
		||||
#!/usr/bin/env bash
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.local/bin
 | 
			
		||||
 | 
			
		||||
CI_PROJECT_DIR=$(pwd)
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
ecabal() {
 | 
			
		||||
	cabal "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
raw_eghcup() {
 | 
			
		||||
	ghcup -v -c "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
eghcup() {
 | 
			
		||||
	if [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
		ghcup -v -c -s file:/$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml "$@"
 | 
			
		||||
	else
 | 
			
		||||
		ghcup -v -c -s file://$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml "$@"
 | 
			
		||||
	fi
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
if [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
	GHCUP_DIR="${GHCUP_INSTALL_BASE_PREFIX}"/ghcup
 | 
			
		||||
else
 | 
			
		||||
	GHCUP_DIR="${GHCUP_INSTALL_BASE_PREFIX}"/.ghcup
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
git describe --always
 | 
			
		||||
 | 
			
		||||
### build
 | 
			
		||||
 | 
			
		||||
rm -rf "${GHCUP_DIR}"/share
 | 
			
		||||
 | 
			
		||||
ecabal update
 | 
			
		||||
 | 
			
		||||
if [ "${OS}" = "DARWIN" ] ; then
 | 
			
		||||
	ecabal build -w ghc-${GHC_VERSION} -ftui
 | 
			
		||||
	ecabal test -w ghc-${GHC_VERSION} -ftui ghcup-test
 | 
			
		||||
	ecabal haddock -w ghc-${GHC_VERSION} -ftui
 | 
			
		||||
elif [ "${OS}" = "LINUX" ] ; then
 | 
			
		||||
	if [ "${ARCH}" = "32" ] ; then
 | 
			
		||||
		ecabal build -w ghc-${GHC_VERSION} -finternal-downloader -ftui
 | 
			
		||||
		ecabal test -w ghc-${GHC_VERSION} -finternal-downloader -ftui ghcup-test
 | 
			
		||||
		ecabal haddock -w ghc-${GHC_VERSION} -finternal-downloader -ftui
 | 
			
		||||
	else
 | 
			
		||||
		ecabal build -w ghc-${GHC_VERSION} -finternal-downloader -ftui
 | 
			
		||||
		ecabal test -w ghc-${GHC_VERSION} -finternal-downloader -ftui ghcup-test
 | 
			
		||||
		ecabal haddock -w ghc-${GHC_VERSION} -finternal-downloader -ftui
 | 
			
		||||
 | 
			
		||||
		if [ "${ARCH}" = "64" ] ; then
 | 
			
		||||
			# doctest
 | 
			
		||||
			curl -sL https://downloads.haskell.org/~ghcup/unofficial-bindists/cabal-docspec/cabal-docspec-0.0.0.20210228_p1.tar.bz2 > cabal-docspec.tar.bz2
 | 
			
		||||
			echo '3a10f6fec16dbd18efdd331b1cef5d2d342082da42f5b520726d1fa6a3990d12  cabal-docspec.tar.bz2' | sha256sum -c -
 | 
			
		||||
			tar -xjf cabal-docspec.tar.bz2 cabal-docspec
 | 
			
		||||
			mv cabal-docspec "$CI_PROJECT_DIR"/.local/bin/cabal-docspec
 | 
			
		||||
			rm -f cabal-docspec.tar.bz2
 | 
			
		||||
			chmod a+x "$CI_PROJECT_DIR"/.local/bin/cabal-docspec
 | 
			
		||||
 | 
			
		||||
			cabal-docspec -XCPP -XTypeSynonymInstances -XOverloadedStrings -XPackageImports --check-properties
 | 
			
		||||
		fi
 | 
			
		||||
	fi
 | 
			
		||||
elif [ "${OS}" = "FREEBSD" ] ; then
 | 
			
		||||
	ecabal build -w ghc-${GHC_VERSION} -finternal-downloader -ftui --constraint="zip +disable-zstd"
 | 
			
		||||
	ecabal test -w ghc-${GHC_VERSION} -finternal-downloader -ftui --constraint="zip +disable-zstd" ghcup-test
 | 
			
		||||
	ecabal haddock -w ghc-${GHC_VERSION} -finternal-downloader -ftui --constraint="zip +disable-zstd"
 | 
			
		||||
elif [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
	ecabal build -w ghc-${GHC_VERSION}
 | 
			
		||||
	ecabal test -w ghc-${GHC_VERSION} ghcup-test
 | 
			
		||||
	ecabal haddock -w ghc-${GHC_VERSION}
 | 
			
		||||
else
 | 
			
		||||
	ecabal build -w ghc-${GHC_VERSION} -finternal-downloader -ftui
 | 
			
		||||
	ecabal test -w ghc-${GHC_VERSION} -finternal-downloader -ftui ghcup-test
 | 
			
		||||
	ecabal haddock -w ghc-${GHC_VERSION} -finternal-downloader -ftui
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
if [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
	ext=".exe"
 | 
			
		||||
else
 | 
			
		||||
	ext=''
 | 
			
		||||
fi
 | 
			
		||||
	cp "$(ecabal new-exec -w ghc-${GHC_VERSION} --verbose=0 --offline sh -- -c 'command -v ghcup')" "$CI_PROJECT_DIR"/.local/bin/ghcup${ext}
 | 
			
		||||
 | 
			
		||||
### cleanup
 | 
			
		||||
 | 
			
		||||
rm -rf "${GHCUP_DIR}"
 | 
			
		||||
 | 
			
		||||
### manual cli based testing
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
eghcup --numeric-version
 | 
			
		||||
 | 
			
		||||
eghcup install ghc ${GHC_VERSION}
 | 
			
		||||
eghcup unset ghc ${GHC_VERSION}
 | 
			
		||||
ls -lah "$(eghcup whereis -d ghc ${GHC_VERSION})"
 | 
			
		||||
[ "`$(eghcup whereis ghc ${GHC_VERSION}) --numeric-version`" = "${GHC_VERSION}" ]
 | 
			
		||||
[ "`eghcup run --ghc ${GHC_VERSION} -- ghc --numeric-version`" = "${GHC_VERSION}" ]
 | 
			
		||||
[ "`ghcup run --ghc ${GHC_VERSION} -- ghc -e 'Control.Monad.join (Control.Monad.fmap System.IO.putStr System.Environment.getExecutablePath)'`" = "`$(ghcup whereis ghc ${GHC_VERSION}) -e 'Control.Monad.join (Control.Monad.fmap System.IO.putStr System.Environment.getExecutablePath)'`" ]
 | 
			
		||||
eghcup set ghc ${GHC_VERSION}
 | 
			
		||||
eghcup install cabal ${CABAL_VERSION}
 | 
			
		||||
[ "`$(eghcup whereis cabal ${CABAL_VERSION}) --numeric-version`" = "${CABAL_VERSION}" ]
 | 
			
		||||
eghcup unset cabal
 | 
			
		||||
"$GHCUP_BIN"/cabal --version && exit 1 || echo yes
 | 
			
		||||
 | 
			
		||||
# make sure no cabal is set when running 'ghcup run' to check that PATH propagages properly
 | 
			
		||||
# https://gitlab.haskell.org/haskell/ghcup-hs/-/issues/375
 | 
			
		||||
[ "`eghcup run --cabal ${CABAL_VERSION} -- cabal --numeric-version`" = "${CABAL_VERSION}" ]
 | 
			
		||||
eghcup set cabal ${CABAL_VERSION}
 | 
			
		||||
 | 
			
		||||
[ "`$(eghcup whereis cabal ${CABAL_VERSION}) --numeric-version`" = "${CABAL_VERSION}" ]
 | 
			
		||||
 | 
			
		||||
if [ "${OS}" != "FREEBSD" ] ; then
 | 
			
		||||
	if [ "${ARCH}" = "64" ] ; then
 | 
			
		||||
		eghcup run --ghc 8.10.7 --cabal 3.4.1.0 --hls 1.6.1.0 --stack 2.7.3 --install --bindir "$(pwd)/.bin"
 | 
			
		||||
		if [ "${OS}" == "WINDOWS" ] ; then
 | 
			
		||||
			expected=$(cat "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup-run.files.windows" | sort)
 | 
			
		||||
		else
 | 
			
		||||
			expected=$(cat "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup-run.files" | sort)
 | 
			
		||||
		fi
 | 
			
		||||
		actual=$(cd ".bin" && find . | sort)
 | 
			
		||||
		[ "${actual}" = "${expected}" ]
 | 
			
		||||
		unset actual expected
 | 
			
		||||
		rm -rf .bin
 | 
			
		||||
	fi
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
cabal --version
 | 
			
		||||
 | 
			
		||||
eghcup debug-info
 | 
			
		||||
 | 
			
		||||
# also test etags
 | 
			
		||||
eghcup list
 | 
			
		||||
eghcup list -t ghc
 | 
			
		||||
eghcup list -t cabal
 | 
			
		||||
 | 
			
		||||
ghc_ver=$(ghc --numeric-version)
 | 
			
		||||
ghc --version
 | 
			
		||||
ghc-${ghc_ver} --version
 | 
			
		||||
if [ "${OS}" != "WINDOWS" ] ; then
 | 
			
		||||
		ghci --version
 | 
			
		||||
		ghci-${ghc_ver} --version
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
if [ "${OS}" = "DARWIN" ] && [ "${ARCH}" = "ARM64" ] ; then
 | 
			
		||||
	echo
 | 
			
		||||
else
 | 
			
		||||
	# test installing new ghc doesn't mess with currently set GHC
 | 
			
		||||
	# https://gitlab.haskell.org/haskell/ghcup-hs/issues/7
 | 
			
		||||
	if [ "${OS}" = "LINUX" ] ; then
 | 
			
		||||
		eghcup --downloader=wget prefetch ghc 8.10.3
 | 
			
		||||
		eghcup --offline install ghc 8.10.3
 | 
			
		||||
		if [ "${ARCH}" = "64" ] ; then
 | 
			
		||||
			expected=$(cat "$( cd "$(dirname "$0")" ; pwd -P )/../ghc-8.10.3-linux.files" | sort)
 | 
			
		||||
			actual=$(cd "${GHCUP_DIR}/ghc/8.10.3/" && find . | sort)
 | 
			
		||||
			[ "${actual}" = "${expected}" ]
 | 
			
		||||
			unset actual expected
 | 
			
		||||
		fi
 | 
			
		||||
	elif [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
		eghcup prefetch ghc 8.10.3
 | 
			
		||||
		eghcup --offline install ghc 8.10.3
 | 
			
		||||
		expected=$(cat "$( cd "$(dirname "$0")" ; pwd -P )/../ghc-8.10.3-windows.files" | sort)
 | 
			
		||||
		actual=$(cd "${GHCUP_DIR}/ghc/8.10.3/" && find . | sort)
 | 
			
		||||
		[ "${actual}" = "${expected}" ]
 | 
			
		||||
		unset actual expected
 | 
			
		||||
	else
 | 
			
		||||
		eghcup prefetch ghc 8.10.3
 | 
			
		||||
		eghcup --offline install ghc 8.10.3
 | 
			
		||||
	fi
 | 
			
		||||
	[ "$(ghc --numeric-version)" = "${ghc_ver}" ]
 | 
			
		||||
	eghcup --offline set 8.10.3
 | 
			
		||||
	eghcup set 8.10.3
 | 
			
		||||
	[ "$(ghc --numeric-version)" = "8.10.3" ]
 | 
			
		||||
	eghcup set ${GHC_VERSION}
 | 
			
		||||
	[ "$(ghc --numeric-version)" = "${ghc_ver}" ]
 | 
			
		||||
	eghcup unset ghc
 | 
			
		||||
    "$GHCUP_BIN"/ghc --numeric-version && exit 1 || echo yes
 | 
			
		||||
	eghcup set ${GHC_VERSION}
 | 
			
		||||
	eghcup --offline rm 8.10.3
 | 
			
		||||
	[ "$(ghc --numeric-version)" = "${ghc_ver}" ]
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
	ls -lah "$GHCUP_BIN"
 | 
			
		||||
 | 
			
		||||
	if [ "${OS}" = "DARWIN" ] ; then
 | 
			
		||||
		eghcup install hls
 | 
			
		||||
		$(eghcup whereis hls) --version
 | 
			
		||||
 | 
			
		||||
		eghcup install stack
 | 
			
		||||
		$(eghcup whereis stack) --version
 | 
			
		||||
	elif [ "${OS}" = "LINUX" ] ; then
 | 
			
		||||
		if [ "${ARCH}" = "64" ] ; then
 | 
			
		||||
			eghcup install hls
 | 
			
		||||
			haskell-language-server-wrapper --version
 | 
			
		||||
			eghcup unset hls
 | 
			
		||||
			"$GHCUP_BIN"/haskell-language-server-wrapper --version && exit 1 || echo yes
 | 
			
		||||
 | 
			
		||||
			eghcup install stack
 | 
			
		||||
			stack --version
 | 
			
		||||
			eghcup unset stack
 | 
			
		||||
			"$GHCUP_BIN"/stack --version && exit 1 || echo yes
 | 
			
		||||
		fi
 | 
			
		||||
	fi
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
# check that lazy loading works for 'whereis'
 | 
			
		||||
cp "$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml" "$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml.bak"
 | 
			
		||||
echo '**' > "$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml"
 | 
			
		||||
eghcup whereis ghc $(ghc --numeric-version)
 | 
			
		||||
mv -f "$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml.bak" "$CI_PROJECT_DIR/data/metadata/ghcup-${JSON_VERSION}.yaml"
 | 
			
		||||
 | 
			
		||||
eghcup rm $(ghc --numeric-version)
 | 
			
		||||
 | 
			
		||||
# https://gitlab.haskell.org/haskell/ghcup-hs/-/issues/116
 | 
			
		||||
if [ "${OS}" = "LINUX" ] ; then
 | 
			
		||||
	if [ "${ARCH}" = "64" ] ; then
 | 
			
		||||
		eghcup install cabal -u https://downloads.haskell.org/~ghcup/unofficial-bindists/cabal/3.7.0.0-pre20220407/cabal-install-3.7-x86_64-linux-alpine.tar.xz 3.4.0.0-rc4
 | 
			
		||||
		eghcup rm cabal 3.4.0.0-rc4
 | 
			
		||||
	fi
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
eghcup gc -c
 | 
			
		||||
 | 
			
		||||
sha_sum() {
 | 
			
		||||
	if [ "${OS}" = "FREEBSD" ] ; then
 | 
			
		||||
		sha256 "$@"
 | 
			
		||||
	else
 | 
			
		||||
		sha256sum "$@"
 | 
			
		||||
	fi
 | 
			
		||||
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
# test etags
 | 
			
		||||
rm -f "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml"
 | 
			
		||||
raw_eghcup -s https://www.haskell.org/ghcup/data/ghcup-${JSON_VERSION}.yaml list
 | 
			
		||||
# snapshot yaml and etags file
 | 
			
		||||
etag=$(cat "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml.etags")
 | 
			
		||||
sha=$(sha_sum "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml")
 | 
			
		||||
# invalidate access time timer, which is 5minutes, so we re-download
 | 
			
		||||
touch -a -m -t '199901010101' "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml"
 | 
			
		||||
# redownload same file with some newlines added
 | 
			
		||||
raw_eghcup -s https://www.haskell.org/ghcup/exp/ghcup-${JSON_VERSION}.yaml list
 | 
			
		||||
# snapshot new yaml and etags file
 | 
			
		||||
etag2=$(cat "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml.etags")
 | 
			
		||||
sha2=$(sha_sum "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml")
 | 
			
		||||
# compare
 | 
			
		||||
[ "${etag}" != "${etag2}" ]
 | 
			
		||||
[ "${sha}" != "${sha2}" ]
 | 
			
		||||
# invalidate access time timer, which is 5minutes, but don't expect a re-download
 | 
			
		||||
touch -a -m -t '199901010101' "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml"
 | 
			
		||||
# this time, we expect the same hash and etag
 | 
			
		||||
raw_eghcup -s https://www.haskell.org/ghcup/exp/ghcup-${JSON_VERSION}.yaml list
 | 
			
		||||
etag3=$(cat "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml.etags")
 | 
			
		||||
sha3=$(sha_sum "${GHCUP_DIR}/cache/ghcup-${JSON_VERSION}.yaml")
 | 
			
		||||
[ "${etag2}" = "${etag3}" ]
 | 
			
		||||
[ "${sha2}" = "${sha3}" ]
 | 
			
		||||
 | 
			
		||||
# test isolated installs
 | 
			
		||||
eghcup install ghc -i "$(pwd)/isolated" 8.10.5
 | 
			
		||||
[ "$(isolated/bin/ghc --numeric-version)" = "8.10.5" ]
 | 
			
		||||
! eghcup install ghc -i "$(pwd)/isolated" 8.10.5
 | 
			
		||||
if [ "${ARCH}" = "64" ] ; then
 | 
			
		||||
	if [ "${OS}" = "LINUX" ] || [ "${OS}" = "WINDOWS" ] ; then
 | 
			
		||||
		eghcup install cabal -i "$(pwd)/isolated" 3.4.0.0
 | 
			
		||||
		[ "$(isolated/cabal --numeric-version)" = "3.4.0.0" ]
 | 
			
		||||
		eghcup install stack -i "$(pwd)/isolated" 2.7.3
 | 
			
		||||
		[ "$(isolated/stack --numeric-version)" = "2.7.3" ]
 | 
			
		||||
		eghcup install hls -i "$(pwd)/isolated" 1.3.0
 | 
			
		||||
		[ "$(isolated/haskell-language-server-wrapper --numeric-version)" = "1.3.0" ] ||
 | 
			
		||||
			[ "$(isolated/haskell-language-server-wrapper --numeric-version)" = "1.3.0.0" ]
 | 
			
		||||
 | 
			
		||||
		# test that isolated installs don't clean up target directory
 | 
			
		||||
		cat <<EOF > "${GHCUP_BIN}/gmake"
 | 
			
		||||
#!/bin/bash
 | 
			
		||||
exit 1
 | 
			
		||||
EOF
 | 
			
		||||
		chmod +x "${GHCUP_BIN}/gmake"
 | 
			
		||||
		mkdir isolated_tainted/
 | 
			
		||||
		touch isolated_tainted/lol
 | 
			
		||||
 | 
			
		||||
		! eghcup install ghc -i "$(pwd)/isolated_tainted" 8.10.5 --force
 | 
			
		||||
		[ -e "$(pwd)/isolated_tainted/lol" ]
 | 
			
		||||
		rm "${GHCUP_BIN}/gmake"
 | 
			
		||||
	fi
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
eghcup upgrade
 | 
			
		||||
eghcup upgrade -f
 | 
			
		||||
 | 
			
		||||
# test that doing fishy symlinks into GHCup dir doesn't cause weird stuff on 'ghcup nuke'
 | 
			
		||||
mkdir no_nuke/
 | 
			
		||||
mkdir no_nuke/bar
 | 
			
		||||
echo 'foo' > no_nuke/file
 | 
			
		||||
echo 'bar' > no_nuke/bar/file
 | 
			
		||||
ln -s "$CI_PROJECT_DIR"/no_nuke/ "${GHCUP_DIR}"/cache/no_nuke
 | 
			
		||||
ln -s "$CI_PROJECT_DIR"/no_nuke/ "${GHCUP_DIR}"/logs/no_nuke
 | 
			
		||||
 | 
			
		||||
# nuke
 | 
			
		||||
eghcup nuke
 | 
			
		||||
[ ! -e "${GHCUP_DIR}" ]
 | 
			
		||||
 | 
			
		||||
# make sure nuke doesn't resolve symlinks
 | 
			
		||||
[ -e "$CI_PROJECT_DIR"/no_nuke/file ]
 | 
			
		||||
[ -e "$CI_PROJECT_DIR"/no_nuke/bar/file ]
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
@ -1,19 +0,0 @@
 | 
			
		||||
#!/bin/sh
 | 
			
		||||
 | 
			
		||||
set -eux
 | 
			
		||||
 | 
			
		||||
. "$( cd "$(dirname "$0")" ; pwd -P )/../ghcup_env"
 | 
			
		||||
 | 
			
		||||
mkdir -p "$CI_PROJECT_DIR"/.local/bin
 | 
			
		||||
 | 
			
		||||
ecabal() {
 | 
			
		||||
	cabal --store-dir="$(pwd)"/.store "$@"
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
git describe
 | 
			
		||||
 | 
			
		||||
ecabal update
 | 
			
		||||
ecabal install -w ghc-${GHC_VERSION} --installdir="$CI_PROJECT_DIR"/.local/bin hlint
 | 
			
		||||
 | 
			
		||||
hlint -r app/ lib/ test/ 
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user