daml/compiler/ghcide-daml.sh
Andreas Herrmann f4d0eb636e Replace Hazel by stack_snapshot (#2743)
* Unmangled libz.so and libbz2.so

* Use stack_snapshot instead of Hazel

* Remove Hazel

* Define stack_snapshot

* Update rules_haskell

* Document stack_snapshot

* Clean stack's lock file from aborted builds
2019-11-22 14:24:08 +00:00

15 lines
496 B
Bash
Executable File

#!/usr/bin/env bash
# Copyright (c) 2019 The DAML Authors. All rights reserved.
# SPDX-License-Identifier: Apache-2.0
set -euo pipefail
cd "$(dirname "$0")"/..
export RULES_HASKELL_EXEC_ROOT=$PWD/
ENV_FILE=$(mktemp)
ARGS_FILE=$(mktemp)
bazel build @ghcide//:ghcide >/dev/null 2>&1
bazel run --define hie_bios_ghci=True //compiler/damlc:damlc@ghci -- "$ENV_FILE" "$ARGS_FILE" >/dev/null 2>&1
source "$ENV_FILE"
export HIE_BIOS_ARGS="$ARGS_FILE"
./bazel-bin/external/ghcide/_install/bin/ghcide $@