Skip to content

Commit

Permalink
feat: support venv detection with PDM
Browse files Browse the repository at this point in the history
Signed-off-by: Jack Cherng <[email protected]>
  • Loading branch information
jfcherng committed Nov 6, 2023
1 parent 1e8cfe4 commit 681ddad
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import sublime
from LSP.plugin import ClientConfig, DottedDict, Response, WorkspaceFolder
from LSP.plugin.core.protocol import CompletionItem, Hover, SignatureHelp
from LSP.plugin.core.typing import Any, Callable, Iterable, List, Optional, Tuple, cast
from LSP.plugin.core.typing import Any, Callable, List, Optional, Tuple, cast
from lsp_utils import NpmClientHandler
from sublime_lib import ResourcePath

Expand Down Expand Up @@ -226,6 +226,7 @@ def binary_from_python_path(path: str) -> Optional[str]:

# Config file, venv resolution command, post-processing
venv_config_files = [
(".pdm-python", "pdm info --python", None),
(".python-version", "pyenv which python", None),
("Pipfile", "pipenv --py", None),
("poetry.lock", "poetry env info -p", binary_from_python_path),
Expand Down

0 comments on commit 681ddad

Please sign in to comment.