From 0e1dbfc55383c8d7ed1abee74ec4c5638e0832da Mon Sep 17 00:00:00 2001 From: Simeon Carstens Date: Mon, 2 Sep 2024 14:48:45 +0200 Subject: [PATCH] Allow libs file in CWD to be given without leading "./" --- fix-python | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/fix-python b/fix-python index 2988422..296c575 100755 --- a/fix-python +++ b/fix-python @@ -89,6 +89,14 @@ fi # load libs from Nix file if [ "$LIBS_PATH" ]; then + # if $LIBS_PATH is just a file in the current working directory, + # specified without leading "./", we add "./" so that $LIBS_PATH + # can be interpreted directly as a Nix path in the following + # expression + if [[ ! "$LIBS_PATH" == *"/"* ]]; + then + LIBS_PATH="./$LIBS_PATH" + fi custom_libs_expression="(import $LIBS_PATH)" mkdir -p .nix/fix-python nix_libs_build_status=$(