GithubHelp home page GithubHelp logo

Comments (6)

arosien avatar arosien commented on July 23, 2024

I've used the sbt ivyXML override to exclude particular dependencies, which seems to work also (removes those deps from the assembly)l

from sbt-assembly.

eed3si9n avatar eed3si9n commented on July 23, 2024

At the point that I am constructing an assembly, all I see is a list of dirs and jars, so likely it'll be some sort of exclusion mechanism for a set of jars.

from sbt-assembly.

eed3si9n avatar eed3si9n commented on July 23, 2024

You can write something like

excludedJars in Assembly <<= baseDirectory { base => 
  (base / "lib" / "compile" ** "*.jar").classpath   
}

or

excludedJars in Assembly <<= (fullClasspath in Assembly) map { cp => 
  cp filter {_.data.getName == "compile-0.1.0.jar"}
}

from sbt-assembly.

arosien avatar arosien commented on July 23, 2024

Awesome - thanks!

from sbt-assembly.

PiotrCzapla avatar PiotrCzapla commented on July 23, 2024

I haven't found docs about the "provided" scope but it seams that it is working in SBT 12.x end up here looking how to use "provided" dependency scope. It works in recent version of SBT as follows

libraryDependencies += "net.liftweb" %% "lift-json" % "2.4" % "provided"

Then this dependency will be excluded from runtime class path. At least it seems so from: show update

from sbt-assembly.

eed3si9n avatar eed3si9n commented on July 23, 2024

This is what I say in README now:

To exclude some jar file, first consider using "provided" dependency. The dependency will be part of compilation, but excluded from the runtime. Next, try creating a custom configuration that describes your classpath. If all efforts fail, here's a way to exclude jars...

from sbt-assembly.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.