From d46adbbb0b8452ea25ba01d2b34d2bdc8a5a3a6d Mon Sep 17 00:00:00 2001 From: azahi Date: Sun, 29 Sep 2019 14:28:37 +0300 Subject: Add build scripts --- build-scripts/build-cabal | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100755 build-scripts/build-cabal (limited to 'build-scripts/build-cabal') diff --git a/build-scripts/build-cabal b/build-scripts/build-cabal new file mode 100755 index 0000000..aa11764 --- /dev/null +++ b/build-scripts/build-cabal @@ -0,0 +1,18 @@ +#!/bin/sh -eu + +SRC_DIR="$HOME/.xmonad" +EXE_NAME="xmonad-ng" +OUT="$1" + +shift + +cd "$SRC_DIR" || exit 1 + +cabal new-configure \ + --enable-optimization \ + --enable-executable-stripping + +cabal new-build + +find "$SRC_DIR"/dist-newstyle -type f -executable -name "$EXE_NAME" \ + -exec mv -u '{}' "$OUT" ';' -- cgit 1.4.1