JustinGrote / JustinGrote/ModulePath
Get-ModulePath -AllUsers returns wrong folder path
- Lenguaje dominante
- PowerShell
- Estrellas
- 25
- Forks
- 0
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
When running `Get-ModulePath` with _-AllUsers_ parameter, the returned folder refers to modules that are included with PowerShell, not AllUsers path.
The problem is in https://github.com/JustinGrote/ModulePath/blob/main/ModulePath.psm1#L103, where GetPSModulePath method uses wrong scope reference. The reference should be **Machine** instead of **BuiltIn**.
The problem only surfaces, when there is no custom path in .config.json file.
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Línea de trabajo
Start at ModulePath.psm1 line 103 and inspect the GetPSModulePath scope reference. Reproduce the case with no custom path in .config.json by running Get-ModulePath -AllUsers; done means it returns the AllUsers module path rather than the PowerShell built-in modules path.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- powershell
- Área
- tooling
- Tipo de issue
- Error
- Dificultad
- 1/5
- Tiempo estimado
- Menos de una hora
- Estado de actividad
- Estancado
- Claridad
- Bien especificado
- Aptitud para principiantes
- 50/100