Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

venv --help docs don't specify the exact activation command #103077

Open
JosephSBoyle opened this issue Mar 28, 2023 · 4 comments
Open

venv --help docs don't specify the exact activation command #103077

JosephSBoyle opened this issue Mar 28, 2023 · 4 comments
Labels
stdlib Python modules in the Lib dir topic-venv Related to the venv module type-feature A feature request or enhancement

Comments

@JosephSBoyle
Copy link
Contributor

Proposal

Add the commands to activate venv on the current platform to the help text displayed when printing python -m venv --help

Pitch

Many people who work cross-platform and use venv will forget the activation commands on one or both platforms.
For me, this means I have to google the command whenever I'm working on Windows.

The current --help text related to activating the venv is:

Once an environment has been created, you may wish to activate it, e.g. by sourcing an activate script in its bin directory

My thoughts are we could add the activation command somewhere beneath this text.

@JosephSBoyle JosephSBoyle added the type-feature A feature request or enhancement label Mar 28, 2023
@sobolevn
Copy link
Member

There are MULTIPLE ways to activate a venv. It includes: your os, your shell, your path. Maybe something else.

I think it is better to keep this as-is.

@JosephSBoyle
Copy link
Contributor Author

If people are using the CLI (which I assume they are in this example, to even see the --help text) then I also imagine that they would want to use the shell method?

@sobolevn
Copy link
Member

Which one?

» tree .venv/bin
.venv/bin
├── Activate.ps1
├── activate
├── activate.csh
├── activate.fish

@JosephSBoyle
Copy link
Contributor Author

The one for their current shell, if that can be inferred reliably, or all of them, if it cannot

@iritkatriel iritkatriel added stdlib Python modules in the Lib dir topic-venv Related to the venv module labels Nov 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stdlib Python modules in the Lib dir topic-venv Related to the venv module type-feature A feature request or enhancement
Projects
None yet
Development

No branches or pull requests

3 participants