pantry/projects/virtualenv.pypa.io/package.yml
Jacob Heider 9dde2d6f14
migrate(pipx, venv) (#6004)
* migrate(pipx, venv)

suggested by @felipecrs ([here](587441621e (commitcomment-141416453))) so we don't lock users of these packages out of newer pythons (now that 3.12 is reasonably well-supported).

* link to venv/lib

* venv is picky
2024-04-26 19:40:41 -04:00

43 lines
1.2 KiB
YAML

distributable:
url: https://github.com/pypa/virtualenv/archive/refs/tags/{{ version }}.tar.gz
strip-components: 1
versions:
github: pypa/virtualenv/releases/tags # reads github *releases* but uses the tags of those releases
strip: /^v/
dependencies:
pkgx.sh: ^1
libexpat.github.io: ^2
openssl.org: ^1.1
build:
dependencies:
python.org: '>=3.7<3.12'
script:
- bkpyvenv stage '{{prefix}}' {{version}}
- ${{prefix}}/venv/bin/pip install .
- bkpyvenv seal '{{prefix}}' virtualenv
# needs this to find its libpython on linux
- run: cp '{{deps.python.org.prefix}}/lib/libpython'* .
working-directory: '{{prefix}}/lib'
test:
script: |
# verify version
echo "$(virtualenv --version)" | grep "^virtualenv {{version}}"
# create venv in venv_dir
virtualenv venv_dir
WANT=$(venv_dir/bin/python -c 'import sys; print(sys.prefix)')
source venv_dir/bin/activate
test $WANT=$VIRTUAL_ENV # verify that venv activates successfully
pip install pycowsay # install a package inside the venv
deactivate # exit venv
venv_dir/bin/pycowsay "All tests pass!" # verify that pycowsay was installed inside the venv
provides:
- bin/virtualenv