Repository navigation
Add PowerShell command in "install packages in venv" guide - #1542
dharmatech wants to merge 3 commits into
Conversation
|
Thanks! Let's put the command into another code block with PowerShell code lexer? |
|
Hey @dharmatech, would you address the review comment? |
Use `Get-Command` if on PowerShell
Co-authored-by: Éric <merwok@netwok.org>
rgommers
left a comment
There was a problem hiding this comment.
The original didn't quite work, but after the review suggestions it also doesn't work, since the tabs no longer match and activating is also a different command under PowerShell:
I pushed a second commit that fixes that. However, this doesn't look all that good. I question whether PowerShell should get a special tab or mention at all here. There are no other tabs or examples in the whole Packaging Guide that use PowerShell. So I'm kind of inclined to close this rather than merge it. Any thoughts on that @webknjaz, @merwok or other maintainers?
|
Oh, I expected the guide to generally show the native windows commands! If this is not the case, then don’t add one just for this PR, but I do wonder if windows users are well served by unix-centric docs then. |
I think it's the case that the way Python and installers work is generally less "native" on Windows; CLI tools are just foreign and badly served there. There's no way we can fix that. That there are multiple shells with different commands makes that worse. It will only be fixed if there's a completely integrated tool/launcher I think. PowerShell is not something I'd call "more native" than other shells, it's just generally for a niche sysadmin audience, not for the average Python user. @brettcannon maybe you want to make this decision? |
|
I checked the Python Devguide and the windows tabs there don’t use powershell commands actually, but for example I think I was remembering some commands in the pip documentation (or another) that used native powershell commands instead of curl & co. So please let’s fix the activate command, and if needed which/where/etc. native shell (i.e. command prompt or whatever is opened by windows devs) commands, but let’s not introduce powershell then. |
Use
Get-Commandif on PowerShellwherein PowerShell is an alias forWhere-Object.If you use
wherein Powershell, no output is returned. UseGet-Commandinstead:📚 Documentation preview 📚: https://python-packaging-user-guide--1542.org.readthedocs.build/en/1542/