File tree Expand file tree Collapse file tree 3 files changed +25
-2
lines changed Expand file tree Collapse file tree 3 files changed +25
-2
lines changed Original file line number Diff line number Diff line change @@ -127,3 +127,13 @@ jobs:
127
127
- name : Remove venv "${{ matrix.venv-name }}"
128
128
run : |
129
129
rm -rf ${{ matrix.venv-name }}
130
+
131
+ - name : Setup default venv with --no-update option
132
+ run : |
133
+ . cvmfs-venv --no-update
134
+ echo "# Python runtime: $(command -v python)"
135
+ python --version --version
136
+ echo "# python -m pip list"
137
+ python -m pip list
138
+ echo "# python -m pip list --local"
139
+ python -m pip list --local
Original file line number Diff line number Diff line change @@ -28,6 +28,9 @@ Usage: cvmfs-venv [-s|--setup] <virtual environment name>
28
28
Options:
29
29
-h --help Print this help message
30
30
-s --setup String of setup options to be parsed
31
+ --no-update After venv creation don't update pip, setuptools, and wheel
32
+ to the latest releases. Use of this option is not recommended,
33
+ but is faster.
31
34
32
35
Note: cvmfs-venv extends the Python venv module and so requires Python 3.3+.
33
36
Original file line number Diff line number Diff line change @@ -5,11 +5,14 @@ export PIP_REQUIRE_VIRTUALENV=true
5
5
6
6
_help_options () {
7
7
cat << EOF
8
- Usage: cvmfs-venv [-s|--setup] <virtual environment name>
8
+ Usage: cvmfs-venv [-s|--setup] [--no-update] <virtual environment name>
9
9
10
10
Options:
11
11
-h --help Print this help message
12
12
-s --setup String of setup options to be parsed
13
+ --no-update After venv creation don't update pip, setuptools, and wheel
14
+ to the latest releases. Use of this option is not recommended,
15
+ but is faster.
13
16
14
17
Note: cvmfs-venv extends the Python venv module and so requires Python 3.3+.
15
18
@@ -62,6 +65,10 @@ while [ $# -gt 0 ]; do
62
65
_setup_command=" ${2} "
63
66
shift 2
64
67
;;
68
+ --no-update)
69
+ _no_update=true
70
+ shift
71
+ ;;
65
72
--)
66
73
shift
67
74
break
318
325
319
326
# Get latest pip, setuptools, wheel
320
327
# Hide not-real errors from CVMFS by sending to /dev/null
321
- python -m pip --quiet install --upgrade pip setuptools wheel & > /dev/null
328
+ if [ -z " ${_no_update} " ]; then
329
+ python -m pip --quiet install --upgrade pip setuptools wheel & > /dev/null
330
+ fi
322
331
323
332
unset _venv_name
324
333
325
334
fi # _return_break if statement end
326
335
327
336
unset _return_break
337
+ unset _no_update
You can’t perform that action at this time.
0 commit comments