orsnaro / CDV-windows-autoenv-tool

This batch scripted tool will auto activate your python virtual environment just by using `cdv` command just like `cd` for more help use `cdv -h`

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

windows-autoenv-tool

This batch scripted tool will auto activate your python virtual environment just by using cdv. Works like normal cd. for more help use cdv -h


New Release V0.1.2 ✨!

Install , open terminal and use it Rightaway! Here to download v0.1.2

Release Notes:

  • Feature: NOW cdv behaves more like normal cd default behavior when using cdv without ANY positional args!
  • Fix bug with dir/s that include spaces.
  • Fix bug when forward slashes are used instead of backslashes in dirs path
  • Fix bug using cdv / that persists even after fix general forward slash bug
  • Debug mode can be easily activated now: 3rd shell positional argument must be set to -1


How to Use🚀:

  • First Install latest version via cdv.msi (latest)

  • if using cmder console and you want to totally override cd by cdv ( you can re-tract the override any time )

     alias cd=cdv $*

    now cd has all cdv features!

    • to re-tract
    unalias cd
  • Shows help for the cdv command:
    cdv -h
  • initialize & configure new auto venv -only used one time per project- :
    cdv <optional-path>  -i
  • with out any parameters its just similar to cd until you cdv'ed to one of your configured projects it will auto activate the venv for you!
    cdv path  
    • to activate current project venv
     cdv 
  • complete delete for the auto venv configs and files:
    cdv <optional-path>  -d
  • to deactivate your venv .. you can also use deactivate command:
    cdv <optional-path>  -1

Notes📝:

  • (in testing) no need to download the installer for every new version ( just reinstall and it will update to latest release )

  • if <optional-path> parameter wasn't provided will just run cdv command on current directory

  • the folder which holds all venvs is defaulted to C:\Users\%USERNAME%\py_envs

  • virtual environment directoroy names will be same as project name with _env appended to it

  • please dont delete .is_autoVenv file from your proj directory nor edit it ( unless you know what you are doing )

  • command auto ignores it's .is_autoVenv file in .gitignore. (this is only if the project is in a git repository folder)


for more/config your custom auto venv I recommend reading the batch script itself and raise any issues💙

About

This batch scripted tool will auto activate your python virtual environment just by using `cdv` command just like `cd` for more help use `cdv -h`


Languages

Language:Batchfile 100.0%