如何从 minicpan 存储库中排除模块?

发布于 2024-07-08 13:18:36 字数 320 浏览 7 评论 0原文

我有一个本地 MINICPAN 存储库,但我想删除模块的特定版本,并注入旧版本。

这是我所采取的步骤。

- create the MINICPAN, not filtering any modules
- use mcpani --add for the module in question
- use mcpani --inject

此时,我可以在 MINICPAN 中看到它既有我想要的版本,又有较新的版本,如果我在 cpan 中发出 install,则安装该模块的较新版本。 如何从我的 minicpan 中删除较新版本?

I have a local MINICPAN repository, but I want to remove a specific version of a module, and inject an older version.

This is the steps I've taken.

- create the MINICPAN, not filtering any modules
- use mcpani --add for the module in question
- use mcpani --inject

At this point, I can see in the MINICPAN that it has both the version I want, and the newer version, if I issue install in cpan, then the newer version of the module is install. How can I get rid of the newer version from my minicpan?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

心头的小情儿 2024-07-15 13:18:36

过滤您要注入的模块。 CPAN::Mini 有过滤文档,我想我有一些例子在我之前向您指出的资源中。 :)

如果您已经拥有 minicpan,正如您在 ysth 的评论中所说,您可以从该 minicpan 创建另一个 minicpan。 在这种情况下,“远程”CPAN 就是您所拥有的。 我一直这样做:我有一个规范的 minicpan,但为了测试东西,我从中过滤以创建新的存储库,这样我就不必处理网络了。

Filter the modules that you are going to inject. The CPAN::Mini has the documentation for filtering, and I think I had some examples in the resources I pointed you toward earlier. :)

If you already have the minicpan, as you said in the comment to ysth, you can create another minicpan from that one. The "remote" CPAN in that case is the one that you have. I do that all the time: I have a canonical minicpan, but then for testing things, I filter from that to create new repositories just so I don't have to deal with the network.

兔小萌 2024-07-15 13:18:36

最初过滤掉该模块不起作用吗?

Doesn't filtering out the module initially work?

山川志 2024-07-15 13:18:36

另一种策略是使用 Pinto。 与 minicpan 不同,Pinto 存储库仅包含您想要的发行版(及其依赖项),因此不需要过滤。 这会产生更小且更易于管理的文件堆,因此您可以轻松执行诸如将其签入 SCM 之类的操作。 Pinto 还拥有一些巧妙的工具来处理升级,而不会意外破坏您的应用程序。

此外,Stratopan 在云中托管 Pinto 存储库。 您可以通过浏览器管理存储库,并在可以访问互联网的任何地方安装模块。 它还不支持 Pinto 所具有的所有功能,但 Stratopan 确实消除了维护本地 CPAN 的麻烦。

免责声明:我经营 Stratopan。

Another strategy would be to use Pinto. Unlike a minicpan, a Pinto repository contains only the distributions you want (and their dependencies), so there is no need for filtering. This results in a much smaller and more manageable pile of files, so you can easily do things like check it into your SCM. Pinto also has some neat tools for handling upgrades without accidentally breaking your application.

Also, Stratopan hosts Pinto repositories in the cloud. You can manage the repository through your browser and install modules anywhere that has internet access. It doesn't yet support all the features Pinto has, but Stratopan really takes the hassle out of maintaining a local CPAN.

Disclaimer: I operate Stratopan.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文