10

For different reasons I have to do pip install as a command in my tox.ini (I do skipsdist=True so tox will not install my dependencies for me, but I still need some of them installed into the virtual environment).

The problem is that I have a local dependency stored as a tarball, that has its version in its filename, such as my-module-1.0.tar.gz. I therefore need to use a wildcard in my command, such as

pip install my-module-*.tar.gz

but tox does not seem to support bash semantics in this sense, as I get the error

Requirement 'my-module-*.tar.gz' looks like a filename, but the file does not exist

I have tried putting quotes around the filename as well as escaping the asterisk, without success.

Any ideas?

Daniel Larsson
  • 6,278
  • 5
  • 44
  • 82
  • Which subdirectory do you run that command? Is that tarball found in the same subdirectory where you run pip? – Jdamian Sep 13 '14 at 11:50

1 Answers1

18

I am not a tox user, but it looks like tox does not use a shell to execute commands. You could try calling a shell explicitly, e.g.:

/bin/bash -c 'pip install my-module-*.tar.gz'
Michael Jaros
  • 4,586
  • 1
  • 22
  • 39