英文:
I dont want to upload my dart packages to pub.dev but I want to share them effectively with my team
问题
最近,我们开始创建自己的Dart包,并希望有效地分享它们(如果有人更新它,每个人都可以使用"pub"命令拉取最新版本)。所以我想知道是否有可能为我们自己托管一个小型的"pub.dev",并配置pub以从那里拉取包。
我不知道从哪里开始或如何创建这样的东西。
英文:
So lately we started creating our own dart packages and want to share them effectively (if someone updates it everyone can just pull the newest version with the pub command) So I was wondeing if it would be possible to host our own little "pub.dev" just for us and to configure pub so that it pulls the packages from there
I have no plan on where to start or how to make such a thing
答案1
得分: 1
你可以将包上传到你公司的GitHub,在pubspec.yaml文件中可以这样导入它:
package:
git: https://github.com/user/package.git
ref: main
或者使用https://pub.dev/packages/unpub来托管你的私有Pub服务器。
英文:
You can upload package to your company's GitHub and in pubspec.yaml you can import it as:
package:
git: https://github.com/user/package.git
ref: main
Or use https://pub.dev/packages/unpub to host your private Pub server.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论