diff options
author | Ben Sima <ben@bsima.me> | 2020-07-25 14:49:11 -0700 |
---|---|---|
committer | Ben Sima <ben@bsima.me> | 2020-07-25 14:49:11 -0700 |
commit | 6a6aa57afe94f8ffee3a648ca66aa16099714b94 (patch) | |
tree | ed4cee7997d9bf72e286d541abf380671ad785ce /bild | |
parent | 3acaa1034b8d9da69acdc52d1fb8e03f50223488 (diff) |
bild: port to haskell
Diffstat (limited to 'bild')
-rwxr-xr-x | bild | 25 |
1 files changed, 0 insertions, 25 deletions
@@ -1,25 +0,0 @@ -#!/usr/bin/env bash -set -exo pipefail -prefix=$(echo $PWD | sed -e "s|^$BIZ_ROOT/*||g" -e "s|/|.|g") -if [[ "$prefix" == "" ]] -then - # TODO: make this accept any number of build targets - target="$1" -else - target="$prefix.$1" -fi -log=$(mktemp) -nix-build \ - -o "$BIZ_ROOT/_bild/$target" \ - $BIZ_ROOT/default.nix \ - --attr "$target" \ - --show-trace \ - 2>&1 \ - | tee $log -if [[ ${PIPESTATUS[0]} != 0 ]] -then - o=$(gawk "match(\$0, /'(.*)'\sfailed/, a) {print a[1]}" $log \ - | head -n 1) - nix log $o -fi - |