[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/nix-mode d6e895969b 400/500: Set the 'LD_LIBRARY_PATH' env
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/nix-mode d6e895969b 400/500: Set the 'LD_LIBRARY_PATH' environment variable for mkShell |
Date: |
Sat, 29 Jan 2022 08:27:49 -0500 (EST) |
branch: elpa/nix-mode
commit d6e895969bc731d92a530ab17045baf2521aca6e
Author: yilinwei <yilin.wei10@gmail.com>
Commit: yilinwei <yilin.wei10@gmail.com>
Set the 'LD_LIBRARY_PATH' environment variable for mkShell
This relies on the 'LD_LIBRARY_PATH' attribute in the
mkShell derivation and won't work for other commonly
used methods such as setting the 'shellHook' attribute.
---
nix-shell.el | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/nix-shell.el b/nix-shell.el
index c6d23e0c04..ba755db2f7 100644
--- a/nix-shell.el
+++ b/nix-shell.el
@@ -131,7 +131,9 @@ The DRV file to use."
(apply 'append
(mapcar (lambda (prop)
(split-string (alist-get prop env)))
- nix-shell-inputs)))))
+ nix-shell-inputs))))
+ ;; This attribute is in `mkShell' — ideally, we'd only check this
variable in those cases.
+ (ld-library-path (alist-get 'LD_LIBRARY_PATH env)))
;; Prevent accidentally rebuilding the world.
(unless (file-directory-p stdenv)
@@ -152,6 +154,13 @@ The DRV file to use."
;; (setq-local process-environment nil)
)
+ ;; Set the LD_LIBRARY_PATH where applicable
+ (when ld-library-path
+ (make-local-variable 'process-environment)
+ (setq process-environment
+ (cons (format "LD_LIBRARY_PATH=%s" ld-library-path)
+ process-environment)))
+
(dolist (input inputs)
(when (and (not (file-directory-p input))
nix-shell-auto-realise)
- [nongnu] elpa/nix-mode 55ed31214a 053/500: Add "in" for closing., (continued)
- [nongnu] elpa/nix-mode 55ed31214a 053/500: Add "in" for closing., ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode ec0546a41d 051/500: Tweak hanging indent, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 0f94476b7e 117/500: nix-syntax-match-antiquote: Handle case where point has the property, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 183d4212e2 134/500: Fix fontification bug, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 42632ee471 168/500: Remove misc/ folder, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 93bfb4428d 182/500: Add nix-build function., ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 9d4eb7d199 274/500: Make find-file-at-point support <nixpkgs>, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 54f28871a3 376/500: Fix issue #70, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode ef64fa293b 388/500: Set nix-version to nil, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 218c885d78 414/500: Merge pull request #116 from taku0/update-install-nix-action, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode d6e895969b 400/500: Set the 'LD_LIBRARY_PATH' environment variable for mkShell,
ELPA Syncer <=
- [nongnu] elpa/nix-mode c041115673 301/500: Fix failing test., ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 01c53b7ff1 289/500: Merge pull request #66 from etu/add-travis-badge, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 1d31733ef8 311/500: Add more function documentation, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode be06d675b8 315/500: Run tests for nix-indent-line and smie-indent-line, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode a33ccd4fd7 322/500: Add more issue test cases, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode ce8f523eb6 330/500: Set the indent function to the value passed in in with-nix-mode-test, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 023a471576 329/500: Remove unnecessary while loop., ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 82d26d496a 335/500: Fix easy-menu name, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode bf027132d0 341/500: Merge pull request #83 from j-piecuch/smie-tweaks, ELPA Syncer, 2022/01/29
- [nongnu] elpa/nix-mode 5b5961780f 358/500: Merge pull request #90 from purcell/dash-syntax, ELPA Syncer, 2022/01/29