D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
opt
/
hc_python
/
lib64
/
python3.8
/
site-packages
/
virtualenv
/
activation
/
nushell
/
Filename :
__init__.py
back
Copy
from __future__ import annotations from virtualenv.activation.via_template import ViaTemplateActivator class NushellActivator(ViaTemplateActivator): def templates(self): yield "activate.nu" def replacements(self, creator, dest_folder): # noqa: ARG002 return { "__VIRTUAL_PROMPT__": "" if self.flag_prompt is None else self.flag_prompt, "__VIRTUAL_ENV__": str(creator.dest), "__VIRTUAL_NAME__": creator.env_name, "__BIN_NAME__": str(creator.bin_dir.relative_to(creator.dest)), } __all__ = [ "NushellActivator", ]