apache / apache/daffodil-sbt

packageDaffodilBin / javaOptions should use ++= instead of :=

Open Beginner friendly
#212 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Scala
Stars
2
Forks
7
PR merge metrics
No merged PRs in 30d

Description

The `packageDaffodilBin / javaOptions` setting current defaults to:

```scala
packageDaffodilBin / javaOptions := Seq(
...
),
```
https://github.com/apache/daffodil-sbt/blob/main/src/main/scala/org/apache/daffodil/DaffodilPlugin.scala#L524-L528

By using `:=` it means we ignore the unscoped `javaOptions` setting, which is not standard SBT behavior. We should change this to use `++=` so that users can put settings in their build.sbt file like this:

```scala
javaOptions ++= Seq(...)
```

And have it apply to all tasks that fork, including tests (if `fork := true`) and packageDaffodilBin. Some daffodil-sbt plugin users might prefer this to avoid duplication, since often times all things that fork require similar javaOptions, like additional memory, and so it's easier to just specific it once as javaOptions.

Contributor guide

No contributing guide indexed for this repository

Research direction

Open src/main/scala/org/apache/daffodil/DaffodilPlugin.scala around lines 524-528 and inspect the packageDaffodilBin / javaOptions setting. Change the setting so unscoped javaOptions from build.sbt are preserved, including for forked tasks; done when shared javaOptions apply to packageDaffodilBin without duplication.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala
Domain
build-system
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
88/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.