Skip to content
This repository was archived by the owner on Oct 23, 2025. It is now read-only.

Commit 1cc72d6

Browse files
authored
fix: improve environment display name for pipenv (#850)
fixes microsoft/vscode-python-environments#824
1 parent 088afaf commit 1cc72d6

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

src/managers/pipenv/pipenvUtils.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,8 +96,9 @@ async function nativeToPythonEnv(
9696
}
9797

9898
const sv = shortVersion(info.version);
99-
const name = info.name || info.displayName || path.basename(info.prefix);
100-
const displayName = info.displayName || `pipenv (${sv})`;
99+
const folderName = path.basename(info.prefix);
100+
const name = info.name || info.displayName || folderName;
101+
const displayName = info.displayName || `${folderName} (${sv})`;
101102

102103
// Derive the environment's bin/scripts directory from the python executable
103104
const binDir = path.dirname(info.executable);

0 commit comments

Comments
 (0)