
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
virtualenv cloning script.
A script for cloning a non-relocatable virtualenv.
Virtualenv provides a way to make virtualenv's relocatable which could then be
copied as we wanted. However making a virtualenv relocatable this way breaks
the no-site-packages isolation of the virtualenv as well as other aspects that
come with relative paths and /usr/bin/env
shebangs that may be undesirable.
Also, the .pth and .egg-link rewriting doesn't seem to work as intended. This attempts to overcome these issues and provide a way to easily clone an existing virtualenv.
It performs the following:
copies sys.argv[1]
dir to sys.argv[2]
updates the hardcoded VIRTUAL_ENV
variable in the activate script to the
new repo location. (--relocatable
doesn't touch this)
updates the shebangs of the various scripts in bin to the new Python if they pointed to the old Python. (version numbering is retained.)
it can also change /usr/bin/env python
shebangs to be absolute too,
though this functionality is not exposed at present.
checks sys.path
of the cloned virtualenv and if any of the paths are from
the old environment it finds any .pth
or .egg
link files within sys.path
located in the new environment and makes sure any absolute paths to the
old environment are updated to the new environment.
finally it double checks sys.path
again and will fail if there are still
paths from the old environment present.
NOTE: This script requires Python 2.7 or 3.4+
FAQs
script to clone virtualenvs.
We found that virtualenv-clone demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.