PowerShell / PowerShell/PowerShell
-NoProfile should not add Modules folder under the user profile in PSModulePath
Đang mở
Chưa có ai nhận issue này.
Needs-Triage
- Ngôn ngữ chính
- C#
- Star
- 55.5k
- Fork
- 8.5k
- Merge trung bình
- 1 ngày 2 giờ
- Pull request đã merge (30 ngày)
- 88
Mô tả
Prerequisites
- Write a descriptive title.
- Make sure you are able to repro it on the latest released version
- Search the existing issues.
- Refer to the FAQ.
- Refer to Differences between Windows PowerShell 5.1 and PowerShell.
Steps to reproduce
- Start cmd
- Clear the environment variable PSModulePath
- Start pwsh.exe -noprofile
- Evaluate $env:PSModulePath
Expected behavior
PSModulePath should not include any path under the user profile.
Actual behavior
PSModulePath includes paths under the user profile.
Error details
N/A
Environment data
Name Value
---- -----
PSVersion 7.4.2
PSEdition Core
GitCommitId 7.4.2
OS Microsoft Windows 10.0.26236
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
Visuals
N/A
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu bằng cách tái hiện các bước cmd và pwsh.exe -noprofile được liệt kê sau khi xóa PSModulePath, rồi kiểm tra cách PSModulePath được khởi tạo. Được xem là hoàn tất khi giá trị kết quả không chứa đường dẫn nào bên dưới hồ sơ người dùng khi sử dụng -noprofile, đồng thời vẫn giữ nguyên ngữ cảnh môi trường được báo cáo.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- powershell
- Lĩnh vực
- cli
- Loại issue
- Lỗi
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 35/100