mirror of
https://github.com/SqrtMinusOne/micromamba.el.git
synced 2025-12-10 13:23:02 +03:00
Merge 2ef6ac7e19 into f0cc31ea2e
This commit is contained in:
commit
8d78ba7f7d
1 changed files with 20 additions and 6 deletions
|
|
@ -49,7 +49,7 @@
|
|||
"Micromamba (environment manager) integration for Emacs."
|
||||
:group 'python)
|
||||
|
||||
(defcustom micromamba-executable (executable-find "micromamba")
|
||||
(defcustom micromamba-executable (executable-find "micromamba" 1)
|
||||
"Path to micromamba executable."
|
||||
:type 'string
|
||||
:group 'micromamba)
|
||||
|
|
@ -94,7 +94,9 @@ Pass ARGS as arguments to the program."
|
|||
(unless micromamba-executable
|
||||
(user-error "Micromamba-executable is not set!"))
|
||||
(with-temp-buffer
|
||||
(apply #'call-process micromamba-executable nil t nil args)
|
||||
(if (file-remote-p default-directory)
|
||||
(shell-command (mapconcat #'shell-quote-argument (cons micromamba-executable args) " ") (current-buffer))
|
||||
(apply #'call-process micromamba-executable nil t nil args))
|
||||
(goto-char (point-min))
|
||||
(json-read)))
|
||||
|
||||
|
|
@ -228,8 +230,13 @@ Return `micromamba-fallback-environment' if not found."
|
|||
The parameters value is an alist as defined by
|
||||
`micromamba--parse-script-buffer'."
|
||||
(with-temp-buffer
|
||||
(if (file-remote-p default-directory)
|
||||
(shell-command
|
||||
(concat micromamba-executable " shell"
|
||||
" activate " prefix " -s" " bash")
|
||||
(current-buffer))
|
||||
(call-process micromamba-executable nil t nil
|
||||
"shell" "activate" prefix "-s" "bash")
|
||||
"shell" "activate" prefix "-s" "bash"))
|
||||
(goto-char (point-min))
|
||||
(micromamba--parse-script-buffer)))
|
||||
|
||||
|
|
@ -239,8 +246,15 @@ The parameters value is an alist as defined by
|
|||
The parameters value is an alist as defined by
|
||||
`micromamba--parse-script-buffer'."
|
||||
(with-temp-buffer
|
||||
(if (file-remote-p default-directory)
|
||||
(shell-command
|
||||
(concat micromamba-executable " run"
|
||||
" micromamba" " shell"
|
||||
" deactivate" " -s" " bash")
|
||||
(current-buffer))
|
||||
(call-process micromamba-executable nil t nil
|
||||
"shell" "deactivate" "-s" "bash")
|
||||
"shell" "deactivate" "-s" "bash"))
|
||||
|
||||
(goto-char (point-min))
|
||||
(micromamba--parse-script-buffer)))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue