[英]What's the best/clearest solution to adapt “two” versions of a plugin
I have a fork of the redmine_backlogs plugin on github ( https://github.com/SeyZ/redmine_backlogs ). 我在github( https://github.com/SeyZ/redmine_backlogs )上有redmine_backlogs插件的分支。
I want to add some new generic features to improve the plugin. 我想添加一些新的通用功能来改进插件。 However, I need some specific changes for my company.
但是,我需要对公司进行一些特定的更改。
What's the best/clearest solution to adapt "two" versions of the plugin (the first version for everybody and the second one for my company) ? 适应插件的“两个”版本(每个人的第一个版本和我公司的第二个版本)的最佳/最清晰的解决方案是什么?
When I add a feature in the generic_version of the backlogs, I want the same feature in my company_version. 在积压的generic_version中添加功能时,我希望在company_version中具有相同功能。 Not the contrary !
并非相反!
Fork the plugin with github for the generic/public version. 将插件与github一起分叉以获得通用/公共版本。 And make a fork/clone of that one for your company.
并为您的公司制作一个分支/克隆。
You can add public features and use git pull
to get these features into your company version. 您可以添加公共功能,并使用
git pull
将这些功能添加到公司版本中。 When adding company related features, the public version will not have these (unless you perform a git push
I suppose, so better not do that!) 添加公司相关功能时,公共版本将不具有这些功能(除非您执行
git push
,否则最好不要这样做!)
I think that you could also create an empty git repository of your company and use git pull <url>
to get the public features into this version. 我认为您也可以创建公司的空git存储库,并使用
git pull <url>
将公共功能添加到该版本中。 In this situation you cannot easily/accidentally push your companies changes into the public version. 在这种情况下,您不能/偶然地将您的公司更改推向公开版本。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.