Skip to content

Commit

Permalink
Merge 0638cd5 into master
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] authored May 23, 2021
2 parents 28d5803 + 0638cd5 commit 1a1a5a1
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 14 deletions.
32 changes: 20 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,18 +130,17 @@ By default `vien` will try to use `python3` as the interpreter for the virtual
environment.

If you have more than one Python version, you can provide an argument to point
to the proper interpreter. For example,
to the proper interpreter.

``` bash
$ vien create python3.8
$ vien create /usr/local/opt/python@3.8/bin/python3
```

Here `python3.8` is literally the name of the command you are running python
with (file available from `$PATH` or a symlink). Since not all shell commands
can be easily resolved, sometimes you have to specify the full path.
In many cases, a shorter command will also work. If the needed interpreter can
be executed in the shell as `python3.8`, you can try

``` bash
$ vien create /usr/local/opt/python@3.8/bin/python3
$ vien create python3.8
```

## shell
Expand Down Expand Up @@ -181,7 +180,7 @@ Now you're back.

``` bash
$ cd /path/to/myProject
$ vien run python3 use_requests.py arg1 arg2 # runs in virtual environment
$ vien run python3 use_requests.py arg1 arg2 # runs script in virtual environment
$ vien run pip3 install requests # installs packages into virtual environment
```

Expand Down Expand Up @@ -211,15 +210,24 @@ $ cd /path/to/myProject
$ vien call main.py
```

The optional `-p` parameter allows you to specify the project directory relative
to the parent directory of the file being run.
The optional `-p` parameter allows you to specify the project directory
**relative** to the parent directory of the **file** being run.

``` bash
$ cd any/where
$ vien call -p /path/to/myProject main.py
$ vien call -p . main.py
$ cd any/where # working dir is irrelevant

# absolute (using venv for /abc/myProject):
$ vien call -p /abc/myProject /abc/myProject/main.py

# relative (using venv for /abc/myProject):
$ vien call -p . /abc/myProject/main.py

# error (there is no venv for any/where)
$ vien call /abc/myProject/main.py
```

This parameter makes things like [shebang](#Shebang) possible.

## delete

`vien delete` deletes the virtual environment.
Expand Down
3 changes: 1 addition & 2 deletions vien/constants.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
__version__ = "4.3.1"
__version__ = "4.3.2"
__copyright__ = "(c) 2020-2021 Artëm IG <github.com/rtmigo>"
__license__ = "BSD-3-Clause"

0 comments on commit 1a1a5a1

Please sign in to comment.