Linux command
conda-run 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
Run a command
conda run -n [env_name] [command]
Run Python script
conda run -n [env_name] python [script.py]
Run with live output
conda run --live-stream -n [env_name] [command]
说明
conda run executes a command within a conda environment without activating it. This is useful for scripts and automation where you need to run commands in different environments.
参数
- -n, --name _name_
- Run in named environment.
- -p, --prefix _path_
- Run in environment at path.
- --live-stream
- Stream output in real-time.
- --no-capture-output
- Don't capture stdout/stderr.
FAQ
What is the conda-run command used for?
conda run executes a command within a conda environment without activating it. This is useful for scripts and automation where you need to run commands in different environments.
How do I run a basic conda-run example?
Run `conda run -n [env_name] [command]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -n, --name _name_ do in conda-run?
Run in named environment.