Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions python-environment.el
Original file line number Diff line number Diff line change
Expand Up @@ -162,15 +162,17 @@ See `python-environment-make' for how ROOT is interpreted."
(python-environment-root-path root))))
(if (file-exists-p full-path)
full-path
(python-environment--existing (cdr paths))))))
(apply #'python-environment--existing root (cdr paths))))))

(defun python-environment-bin (path &optional root)
"Return full path to \"ROOT/bin/PATH\" or \"ROOT/Script/PATH\" if exists.
``Script`` is used instead of ``bin`` in typical Windows case.
"Return full path to \"ROOT/bin/PATH\" or \"ROOT/Scripts/PATH\" if exists.
``Scripts`` is used instead of ``bin`` in typical Windows case.
In Windows, path with extension \".ext\" may be returned.
See `python-environment-make' for how ROOT is interpreted."
(python-environment--existing root
(concat "bin/" path)
(concat "Script/" path)))
(concat "Scripts/" path)
(concat "Scripts/" path ".exe")))

(defun python-environment-lib (path &optional root)
"Return full path to \"ROOT/lib/PATH\" or \"ROOT/Lib/PATH\" if exists.
Expand Down