简体   繁体   English

如何从一个Perl安装中的另一个安装中安装相同版本的模块,就像在Python中使用pip一样?

[英]How can I install the same version of the modules from one Perl installation in another installation, like you can do with pip in Python?

In Python I can use pip to dump a list of versions of installed modules 在Python中,我可以使用pip转储已安装模块的版本列表

pip list > modules.txt

and use it to install that same list of versions of modules in another installation. 并使用它在另一个安装中安装相同的模块版本列表。

pip install -r modules.txt

How is this done with Perl? Perl如何做到这一点?

(Note: I understand that I can install standalone Perl installations using perlbrew, which makes it the equivalent of Python's virtualenv, so I'm just missing the pip piece.) (注意:我了解我可以使用perlbrew安装独立的Perl安装,这使其等效于Python的virtualenv,因此我只是缺少了一些小知识。)

  1. Create a CPAN autobundle file. 创建一个CPAN自动捆绑文件。 It records the specific version of each module. 它记录每个模块的特定版本。
  2. Use a module installer that can target versions, such Carton, perlrocks, cpanminus. 使用可以定位版本的模块安装程序,例如Carton,perlrocks,cpanminus。 Example: cpanm HTTP::Negotiate@6.00 示例: cpanm HTTP::Negotiate@6.00

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何将 OpenCV 安装路径修改为从源代码构建的路径,而不是在环境中使用 pip 安装的路径? - How can I modify the OpenCV installation path as the one built from source instead of the one installed with pip in an environment? 如何从另一个python安装中安装模块 - How to install module from another python installation 我用pip安装破坏了嵌入式Python安装 - I broke an embedded Python installation with a pip install 为什么我不能在我的主Python安装文件夹中插入安装包? Virtualenv妨碍了? - Why can't I pip install packages in my main Python installation folder? Virtualenv getting in the way? 如何在非标准路径的Python 3.3安装中正确安装pip3? - How do I correctly install pip3 in a Python 3.3 installation located at a non-standard path? 如何在WiX中检测Python安装并确定版本? - How can I detect a Python installation in WiX and determine the version? 如何在新的python安装中安装pip - How to install pip in a new python installation 如何根据 pip freeze 的 output 修改安装模块版本 - How can I modify an installation module version based on the output of pip freeze 如何在我当前的mac(而不是2.6)python2.7安装中创建pip安装python模块? - How to make pip install python modules in my current python2.7 installation on mac (instead of 2.6)? 如何构建一个安装后可以从终端全局初始化的 Python 应用程序? - How do you build a Python app which can be globally initialized from the terminal after installation?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM