diff options
author | Leah Rowe <leah@libreboot.org> | 2023-09-02 10:22:39 +0100 |
---|---|---|
committer | Leah Rowe <leah@libreboot.org> | 2023-09-02 10:22:39 +0100 |
commit | 4885c7962d493087ab916e59040b134b8d2fabf7 (patch) | |
tree | a3de7267bd04a4bcd026734abc473db03b37e8f3 /lbmk | |
parent | 56f16bc88357054ac19318e5e4f293a4d9776752 (diff) |
handle TMPDIR from include/export.sh
it looks a bit cluttered just sitting there in
the main script. make it an include.
Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'lbmk')
-rwxr-xr-x | lbmk | 21 |
1 files changed, 1 insertions, 20 deletions
@@ -25,26 +25,7 @@ set -u -e . "include/err.sh" - -tmpdir="" -tmpdir_was_set="y" -set | grep TMPDIR 1>/dev/null 2>/dev/null || tmpdir_was_set="n" -if [ "${tmpdir_was_set}" = "y" ]; then - tmpdir="${TMPDIR##*/}" - tmpdir="${TMPDIR%_*}" - if [ "${tmpdir}" = "lbmk" ]; then - tmpdir="" - tmpdir_was_set="n" - fi -fi -if [ "${tmpdir_was_set}" = "n" ]; then - export TMPDIR="/tmp" - tmpdir="$(mktemp -d -t lbmk_XXXXXXXX)" - export TMPDIR="${tmpdir}" -else - export TMPDIR="${TMPDIR}" -fi -tmpdir="${TMPDIR}" +. "include/export.sh" projectname="$(cat projectname)" buildpath="" |