Skip to content

Commit 13c5b5b

Browse files
fix: nix shell use sed instead
1 parent c14cc0c commit 13c5b5b

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

nix/shell.nix

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,10 @@ in mkShell {
2525

2626
shellHook = lib.optionalString (!isMacM1) ''
2727
echo "Patching env.sh to use Nix Nim..."
28-
env_sh="$PWD/vendor/github.com/waku-org/sds-go-bindings/third_party/nim-sds/vendor/nimbus-build-system/scripts/env.sh"
28+
env_sh="${toString ./vendor/github.com/waku-org/sds-go-bindings/third_party/nim-sds/vendor/nimbus-build-system/scripts/env.sh}"
2929
if [ -f "$env_sh" ]; then
3030
echo "Replacing nim by ${pkgs.nim}/bin/nim"
31-
${pkgs.gnused}/bin/substituteInPlace "$env_sh" \
32-
--replace-warn "/vendor/Nim/bin/nim" "${pkgs.nim}/bin/nim"
31+
${pkgs.gnused}/bin/sed -i 's#/vendor/Nim/bin/nim#${pkgs.nim}/bin/nim#g' "$env_sh"
3332
else
3433
echo "Warning: $env_sh not found (PWD=$PWD)"
3534
fi

0 commit comments

Comments
 (0)