我应该为我的版本包含依赖项吗?

时间:2021-02-14 07:14:38

Should I include dependencies when I do releases for my common projects such as CommonUtils or should I simply specify which dependencies should be referenced when they are to be used?

当我为CommonUtils等常见项目发布版本时,是否应该包含依赖项?还是应该指定在使用它们时应引用哪些依赖项?

4 个解决方案

#1


2  

You users do not want the work if figuring out your dependencies.

如果找出依赖关系,用户不希望工作。

  • What packages do I need?
  • 我需要什么样的包裹?

  • What if it's not available? (dead server, provider out of business)
  • 如果它不可用怎么办? (死服务器,提供商停业)

  • What version of each one do I need?
  • 我需要哪个版本?

  • What if it's not available? (new version)
  • 如果它不可用怎么办? (新版本)

  • How do I download each one?
  • 我如何下载每个?

  • How do I install each one?
  • 我如何安装每一个?

Protect your software from disappearing/unavailable dependencies. Protect your users from the pain of figuring this stuff out.

保护您的软件免于消失/不可用的依赖项。保护您的用户免受弄清楚这些东西的痛苦。

Make your uninstaller do the right thing: remove things you installed, if they're not shared. (That can be hard).

让你的卸载程序做正确的事情:删除你安装的东西,如果它们没有被共享。 (这可能很难)。

#2


1  

I would always include dependencies where legal and practical.

我总是会在法律和实践中包含依赖关系。

Dependencies will not always be in the GAC and you will be easing the deployment of your software.

依赖关系并不总是在GAC中,您将简化软件的部署。

#3


0  

I always create two versions (might not be the perfect solution). One with only my own code and 3-tier party dll used. And a bigger version with all the Framework. This way if it's deploy on a new machine I know I will be fine. Otherwise (if update or on a machine I know that dependencies DLL are already there) I use the lite release.

我总是创建两个版本(可能不是完美的解决方案)。一个只使用我自己的代码和三层派对dll。所有框架都有更大的版本。这样,如果它在新机器上部署,我知道我会没事的。否则(如果更新或在机器上我知道依赖DLL已经存在)我使用lite版本。

#4


0  

I would include the dependencies with your release. When you release you want to control how your application executes and how it behaves. If a user is required to install the dependencies, then they might choose a compatible version, however it might not do X or do X differently. Which will change the way your application behaves and increase application support and maintenance.

我会在您的发布中包含依赖项。发布时,您希望控制应用程序的执行方式及其行为方式。如果用户需要安装依赖项,那么他们可能会选择兼容版本,但是它可能不会执行X或执行不同的X.这将改变您的应用程序的行为方式,并增加应用程序支持和维护。

#1


2  

You users do not want the work if figuring out your dependencies.

如果找出依赖关系,用户不希望工作。

  • What packages do I need?
  • 我需要什么样的包裹?

  • What if it's not available? (dead server, provider out of business)
  • 如果它不可用怎么办? (死服务器,提供商停业)

  • What version of each one do I need?
  • 我需要哪个版本?

  • What if it's not available? (new version)
  • 如果它不可用怎么办? (新版本)

  • How do I download each one?
  • 我如何下载每个?

  • How do I install each one?
  • 我如何安装每一个?

Protect your software from disappearing/unavailable dependencies. Protect your users from the pain of figuring this stuff out.

保护您的软件免于消失/不可用的依赖项。保护您的用户免受弄清楚这些东西的痛苦。

Make your uninstaller do the right thing: remove things you installed, if they're not shared. (That can be hard).

让你的卸载程序做正确的事情:删除你安装的东西,如果它们没有被共享。 (这可能很难)。

#2


1  

I would always include dependencies where legal and practical.

我总是会在法律和实践中包含依赖关系。

Dependencies will not always be in the GAC and you will be easing the deployment of your software.

依赖关系并不总是在GAC中,您将简化软件的部署。

#3


0  

I always create two versions (might not be the perfect solution). One with only my own code and 3-tier party dll used. And a bigger version with all the Framework. This way if it's deploy on a new machine I know I will be fine. Otherwise (if update or on a machine I know that dependencies DLL are already there) I use the lite release.

我总是创建两个版本(可能不是完美的解决方案)。一个只使用我自己的代码和三层派对dll。所有框架都有更大的版本。这样,如果它在新机器上部署,我知道我会没事的。否则(如果更新或在机器上我知道依赖DLL已经存在)我使用lite版本。

#4


0  

I would include the dependencies with your release. When you release you want to control how your application executes and how it behaves. If a user is required to install the dependencies, then they might choose a compatible version, however it might not do X or do X differently. Which will change the way your application behaves and increase application support and maintenance.

我会在您的发布中包含依赖项。发布时,您希望控制应用程序的执行方式及其行为方式。如果用户需要安装依赖项,那么他们可能会选择兼容版本,但是它可能不会执行X或执行不同的X.这将改变您的应用程序的行为方式,并增加应用程序支持和维护。