如何使用SBT跳过Javadoc依赖项下载 [英] How to skip javadoc dependency download with sbt

查看:143
本文介绍了如何使用SBT跳过Javadoc依赖项下载的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

1)Javadoc工件倾向于占用太多空间和时间来下载. 例如,scala-library-2.10.2-sources.jar为1 Mb,但scala-library-2.10.2-javadoc.jar为34 Mb.

1) Javadoc artifacts tend to take too much space and time to download. For example, scala-library-2.10.2-sources.jar is 1 Mb, but scala-library-2.10.2-javadoc.jar is 34 Mb.

2)几乎根本不需要Javadoc.由于现代的IDE可以从源中获取所有信息.

2) Javadoc is mostly not needed at all. As modern IDEs can fetch all info from sources.

所以我想找到一种方法来更改sbt设置,以完全禁用第三方库依赖项之间的javadoc下载.

So I wanted to find a way to alter sbt settings to completely disable javadoc download among third-party library dependencies.

推荐答案

https://github.com/mpeltonen/sbt-idea/issues/225#issuecomment-19150022 请给出答案:

javadoc通常比 资料来源.我至少关闭了通过下载来下载javadocs的功能 〜/.sbt/build.sbt中的此设置:

The javadoc is typically much more bulky and less useful than the sources. I have at least turned off downloading javadocs by putting this setting in ~/.sbt/build.sbt:

transitiveClassifiers in Global := Seq(Artifact.SourceClassifier)

另请参见什么是SBT中的分类器.

请注意,Linux上的~/.sbt/build.sbt对应Windows上的%USERPROFILE%\.sbt\build.sbt.

Note that ~/.sbt/build.sbt on Linux corresponds to %USERPROFILE%\.sbt\build.sbt on Windows.

这篇关于如何使用SBT跳过Javadoc依赖项下载的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆