File tree Expand file tree Collapse file tree 3 files changed +19
-1
lines changed Expand file tree Collapse file tree 3 files changed +19
-1
lines changed Original file line number Diff line number Diff line change 2
2
Release History
3
3
===============
4
4
5
+ dev
6
+
7
+ - Use VIRTUALENVWRAPPER_VIRTUALENV in `cpvirtualenv ` (:bbissue: `104 `).
8
+
5
9
2.7.2
6
10
7
11
- Move setup code for tab completion later in the startup code so
Original file line number Diff line number Diff line change @@ -43,6 +43,20 @@ test_virtual_env_variable () {
43
43
assertTrue " $WORKON_HOME not in $VIRTUAL_ENV " " echo $VIRTUAL_ENV | grep -q $WORKON_HOME "
44
44
}
45
45
46
+ fake_virtualenv () {
47
+ typeset envname=" $1 "
48
+ touch " $envname /fake_virtualenv_was_here"
49
+ virtualenv $@
50
+ }
51
+
52
+ test_virtualenvwrapper_virtualenv_variable () {
53
+ mkvirtualenv " source"
54
+ export VIRTUALENVWRAPPER_VIRTUALENV=fake_virtualenv
55
+ cpvirtualenv " source" " destination"
56
+ unset VIRTUALENVWRAPPER_VIRTUALENV
57
+ assertTrue " wrapper was not run" " [ -f $VIRTUAL_ENV /fake_virtualenv_was_here ]"
58
+ }
59
+
46
60
test_source_relocatable () {
47
61
mkvirtualenv " source"
48
62
(cd tests/testpackage && python setup.py install) > /dev/null 2>&1
Original file line number Diff line number Diff line change @@ -612,7 +612,7 @@ cpvirtualenv() {
612
612
\c hmod a+x " $script "
613
613
done
614
614
615
- virtualenv " $target_env " --relocatable
615
+ " $VIRTUALENVWRAPPER_VIRTUALENV " " $target_env " --relocatable
616
616
\s ed " s/VIRTUAL_ENV\(.*\)$env_name /VIRTUAL_ENV\1$new_env /g" < " $source_env /bin/activate" > " $target_env /bin/activate"
617
617
618
618
(cd " $WORKON_HOME " && (
You can’t perform that action at this time.
0 commit comments