From 12c9513f9637ff158593d699d719e1ff18f808b6 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Sun, 6 Dec 2020 18:16:39 +0100 Subject: [PATCH] chore: build wflint against uniworx as a library --- package.yaml | 10 +++++++--- wflint.sh | 9 +++++++++ 2 files changed, 16 insertions(+), 3 deletions(-) create mode 100755 wflint.sh diff --git a/package.yaml b/package.yaml index e6d7aa1e4..48e2c5b40 100644 --- a/package.yaml +++ b/package.yaml @@ -305,12 +305,16 @@ executables: main: WFLint.hs ghc-options: - -main-is WFLint - source-dirs: [wflint, src] + dependencies: + - base + - uniworx + - bytestring + - yaml + other-modules: [] + source-dirs: wflint when: - condition: flag(library-only) buildable: false - - condition: '!flag(dev)' - buildable: false # Test suite tests: diff --git a/wflint.sh b/wflint.sh new file mode 100755 index 000000000..a21f22c47 --- /dev/null +++ b/wflint.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash + +set -e + +[ "${FLOCKER}" != "$0" ] && exec env FLOCKER="$0" flock -en .stack-work.lock "$0" "$@" || : + +stack build --fast --flag uniworx:-library-only --flag uniworx:dev + +stack exec uniworx-wflint -- $@