Skip to content

Commit

Permalink
Fix duplicate environments showing up on macOS (microsoft#22030)
Browse files Browse the repository at this point in the history
  • Loading branch information
Kartik Raj authored and eleanorjboyd committed Oct 2, 2023
1 parent 77f7303 commit 75818bd
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ async function getGlobalVirtualEnvDirs(): Promise<string[]> {
const homeDir = getUserHomeDir();
if (homeDir && (await pathExists(homeDir))) {
const subDirs = ['Envs', '.direnv', '.venvs', '.virtualenvs', path.join('.local', 'share', 'virtualenvs')];
if (getOSType() !== OSType.Windows) {
if (![OSType.Windows, OSType.OSX].includes(getOSType())) {
// Not a case insensitive platform, push both upper and lower cases.
subDirs.push('envs');
}
const filtered = await asyncFilter(
Expand Down

0 comments on commit 75818bd

Please sign in to comment.