我需要将 sbt-launcher.jar 签入 sbt 托管项目吗?
我在 github 上看到了几个 scala 项目,它们将这些文件捆绑到其 sbt 管理项目的根目录中:
- sbt.cmd
- sbt (shell script)
- sbt-launcher.jar
这是推荐的做法吗?
更新 执行此操作的一个 github 项目是 Scalala
I've seen several scala projects on github which bundles these files into the root of their sbt-managed project:
- sbt.cmd
- sbt (shell script)
- sbt-launcher.jar
Is this the recommended practice ?
UPDATE One github project that does this is Scalala
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
当
sbt-launcher.jar
位于“草稿模式”的根目录中时,曾经存在一个错误。我确信它已修复,但从那时起,如果我想将 jar 放在项目的根目录下,我会将 jar 保存在单独的目录中。如果 sbt 启动器捆绑在 github 上,我也会包含许可证。
我猜想包含这些文件并不是最常见的做法,但我认为当您想要克隆并且不确定要克隆到的计算机是否已设置 sbt 时,这是很好的选择。
There used to be a bug when
sbt-launcher.jar
was in the root directory on "scratch mode". I'm sure it's fixed but since then I keep the jar in a separate directory if I feel like putting it under the root of the project.If sbt launcher is bundled on github, I would also include the license.
I would guess including these files is not the most common practice but I think it's good when you want to clone and not sure the machine you're cloning to has
sbt
set up.我们必须在那些位于非常严格的公司防火墙后面的项目中做到这一点。我们甚至提交了 lib_management 目录,因为对存储库的访问受到限制,因此更新必须由具有适当权限的人来完成。
有时拥有已知版本的构建工具也很方便。
We had to do exactly that in projects that live behind very restrictive corporate firewalls. We even commit the lib_managed dir because access to repo's is restricted so updates have to be done by someone with appropriate permission.
It's also convenient to have a known version of your build tools some times.
我认为如果这是一个适合任何人的 github 项目,则不应包含这些文件。尽量保持简单。
I do not think these files should be included if it is a github project meant for anybody. Try to keep it as simple as possible.