custom venv_dir
This commit is contained in:
parent
b36b8cc2be
commit
7264fc8d86
2 changed files with 9 additions and 3 deletions
7
pyv
7
pyv
|
@ -1,7 +1,5 @@
|
|||
#!/bin/sh
|
||||
|
||||
# Copyright (C) 2024 Tavo
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify it under
|
||||
# the terms of the GNU General Public License as published by the Free Software
|
||||
# Foundation, either version 3 of the License, or (at your option) any later
|
||||
|
@ -14,6 +12,9 @@
|
|||
# You should have received a copy of the GNU General Public License along with
|
||||
# this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
# Set a custom VENV_DIR
|
||||
#VENV_DIR="$HOME/myvenvs"
|
||||
|
||||
_pyv_err() {
|
||||
printf '\033[91mError:\033[0m \033[2m%s\033[0m\n' "$1"
|
||||
}
|
||||
|
@ -151,3 +152,5 @@ pyv() {
|
|||
esac
|
||||
fi
|
||||
}
|
||||
|
||||
# Copyright (C) 2024 Tavo
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (C) 2024 Tavo
|
||||
# Set a custom VENV_DIR
|
||||
#VENV_DIR="$HOME/myvenvs"
|
||||
|
||||
_pyv_comp() {
|
||||
if [ -z "$VENV_DIR" ] ; then
|
||||
|
@ -28,3 +29,5 @@ _pyv_comp() {
|
|||
}
|
||||
|
||||
complete -F _pyv_comp pyv
|
||||
|
||||
# Copyright (C) 2024 Tavo
|
||||
|
|
Loading…
Reference in a new issue