Commit Graph

11646 Commits

Author SHA1 Message Date
eugene yokota a451178719
Merge pull request #7041 from eed3si9n/wip/unique-temp
Fix /tmp/.sbt/ collision for domain socket
2022-10-02 13:27:47 -04:00
Eugene Yokota 2a61fb35f9 Fix /tmp/.sbt/ collision for domain socket
Problem
-------
Fixes https://github.com/sbt/sbt/issues/7013
In a shared environment, multiple users will try to create
`/tmp/.sbt/` directory, and fail.

Solution
--------
Append a deterministic hash like `/tmp/.sbt1234ABCD` based
on the user home, so the same directory is used for the given
user, but each user would have a unique runtime directory.
2022-10-02 12:45:30 -04:00
eugene yokota abd9f13b6f
Merge pull request #7039 from eed3si9n/bport/7006
[1.8.x] fix: also include diagnosticCode and related info in InterfaceUtil
2022-10-02 06:33:45 -04:00
eugene yokota 70a76aa8ac
Merge pull request #7034 from eed3si9n/wip/launcher
Launcher 1.4.1
2022-10-02 04:53:28 -04:00
Chris Kipp dadfee5846 fix: also include diagnosticCode and related info in InterfaceUtil
Looks like I missed this in https://github.com/sbt/sbt/pull/6874 and I
hit on it in Mill when I couldn't figure out why it was also empty, and
thanks to @adpi realized it was because of the `LoggedReporter` in zinc
not taking it into account. However before I can bump that this needs to
be bumped as well.

refs: https://github.com/lampepfl/dotty/issues/14904
2022-10-02 04:50:44 -04:00
eugene yokota 87bbdd9f9b
Merge pull request #7023 from sashashura/patch-1
GitHub Workflows security hardening
2022-10-02 04:42:01 -04:00
Eugene Yokota a775fb8f1d Launcher 1.4.1
Launcher 1.4.1 is capable of launching Scala 3 apps.
In other words, launchers prior to 1.4.1 are not capable of
launching Scala 3 apps, including tests for sbt 2.x.
2022-10-02 04:07:49 -04:00
eugene yokota f0cb420fe2
Merge pull request #7031 from gontard/backport_6903_to_1.8.x
Backport #6903 to 1.8.x
2022-09-30 11:43:20 -04:00
eugene yokota e71e0825ed
Merge pull request #7030 from gontard/backport_6824_to_1.8.x
[1.8.x] Improve log for not found remote cache artifact
2022-09-30 11:41:41 -04:00
gontard cc44169fe0 Fix testQuick on changed function in object
Fix https://github.com/sbt/sbt/issues/5504
2022-09-30 11:25:31 +02:00
gontard 11a7ab3ef7 Reproduce issue #5504 in scripted test 2022-09-30 11:25:19 +02:00
gontard 68e2ec872d Activate test-quick scripted test 2022-09-30 11:25:08 +02:00
gontard 7f55e3acbd Fix scripted tests doc 2022-09-30 11:24:54 +02:00
gontard 89acd3eed1 Improve log for not found remote cache artifact
Before
remote cache not found for 0.0.0-7c40144bd1c774e6

After
remote cache artifact not found for org.gontard:sbt-test:0.0.0-7c40144bd1c774e6 Some(cached-compile)
2022-09-30 11:07:20 +02:00
Alex 39d9a8fa18 build: harden nightly.yml permissions
Signed-off-by: Alex <aleksandrosansan@gmail.com>
2022-09-25 19:15:26 +02:00
Alex 459310bc9b build: harden ci.yml permissions
Signed-off-by: Alex <aleksandrosansan@gmail.com>
2022-09-25 19:14:47 +02:00
Alex 9d9e9e5c53 build: harden dependency-graph.yml permissions
Signed-off-by: Alex <aleksandrosansan@gmail.com>
2022-09-25 19:13:42 +02:00
eugene yokota 2becadb7c2
Merge pull request #7010 from easel/fork-use-args-file
Add sbt.argsfile option
2022-09-17 12:20:28 -04:00
eugene yokota ef92809e09
Merge pull request #7021 from eed3si9n/wip/scala
Scala 2.12.17
2022-09-17 11:16:44 -04:00
Eugene Yokota b00792a3a7 Scala 2.12.17
This bumps up scala-xml to 2.x.
2022-09-17 04:09:52 -04:00
eugene yokota f3b9218b77
Merge pull request #7014 from eed3si9n/wip/giter8
Giter8 0.15.0 by default
2022-09-11 19:59:55 -04:00
Eugene Yokota 573cd2de81 Giter8 0.15.0 by default 2022-09-11 13:03:43 -04:00
eugene yokota b403d3a0e5
Merge pull request #7016 from sbt/eed3si9n-patch-1
Try windows-latest
2022-09-11 03:10:26 -04:00
eugene yokota 0f70950ccd
Try windows-latest 2022-09-11 02:42:14 -04:00
Erik LaBianca ca45370ea1 Add sbt.argsfile option
There are a number of scenarios, including long classpaths, that
can cause linux and other systems to fail to fork a jvm. We can work
around this on JDK9 and above by using an "arguments file" [1].

This patch adds an "sbt.argsfile" property and SBT_ARGSFILE environment
variable. This option defaults to true.  When active on
Java 9+, long command lines are translated to an arguments file by
adding all command line arguments to the arguments file format at [1]
and java is invoked using the arguments file instead of passing the
arguments on the command line.

1. https://docs.oracle.com/javase/9/tools/java.htm#

Fixes: #2974
2022-09-08 15:17:19 -04:00
eugene yokota 5bd44058ef
Update --feature-request.md 2022-08-31 16:07:11 -04:00
eugene yokota 28850ace5a
Merge pull request #7011 from sbt/dependabot/github_actions/actions/cache-3.0.8
Bump actions/cache from 3.0.7 to 3.0.8
2022-08-29 00:49:24 -04:00
dependabot[bot] 6ef9d5d244
Bump actions/cache from 3.0.7 to 3.0.8
Bumps [actions/cache](https://github.com/actions/cache) from 3.0.7 to 3.0.8.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v3.0.7...v3.0.8)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-29 04:07:24 +00:00
Adrien Piquerez fd62debc47
Merge pull request #7004 from sbt/dependabot/github_actions/actions/cache-3.0.7
Bump actions/cache from 3.0.6 to 3.0.7
2022-08-15 10:20:34 +02:00
dependabot[bot] 6cafc89574
Bump actions/cache from 3.0.6 to 3.0.7
Bumps [actions/cache](https://github.com/actions/cache) from 3.0.6 to 3.0.7.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v3.0.6...v3.0.7)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-15 04:02:16 +00:00
eugene yokota e05acf9ca1
Merge pull request #6999 from eed3si9n/bport/6994
[1.8.x] add output when boot server socket fails to create
2022-08-10 20:46:47 -04:00
eugene yokota 5abb51f3ef
Merge pull request #7001 from eed3si9n/bport/6998
[1.7.x] feat: start forwarding diagnosticCode via BSP
2022-08-10 20:34:39 -04:00
Chris Kipp 92a9f0e583 feat: start forwarding diagnosticCode via BSP
This change is a continuation of the work that was done in
https://github.com/sbt/sbt/pull/6874 to allow the Scala 3 compiler to
forward the `diagnosticCode` of an error as well as the other normal
things. This change in dotty was merged in
https://github.com/lampepfl/dotty/pull/15565 and also backported so it
will be in the 3.2.x series release. This change captures the
`diagnosticCode` and forwards it on via BSP so that tools like Metals
can can use this code.

You can see this in the BSP trace now for a diagnostic:

For example with some code that contains the following:

```scala
val x: Int = "hi"
```

You'll see the code in the BSP diagnostic:
```  "diagnostics": [
    {
      "range": {
        "start": {
          "line": 9,
          "character": 15
        },
        "end": {
          "line": 9,
          "character": 19
        }
      },
      "severity": 1,
      "code": "7",
      "source": "sbt",
      "message": "Found:    (\u001b[32m\"hi\"\u001b[0m : String)\nRequired: Int\n\nThe following import might make progress towards fixing the problem:\n\n  import sourcecode.Text.generate\n\n"
    }
  ]
```

Co-authored-by: Adrien Piquerez <adrien.piquerez@gmail.com>
Refs: https://github.com/lampepfl/dotty/issues/14904
2022-08-10 10:12:54 -04:00
Devin Fisher 9f9b08edbd refactor printing error to an in-function function 2022-08-10 10:08:49 -04:00
Devin Fisher 5874ad920e add output when book server socket fails to create 2022-08-10 10:08:42 -04:00
eugene yokota ab59e4c6ba
Merge pull request #6998 from ckipp01/captureCodeBsp
feat: start forwarding diagnosticCode via BSP
2022-08-10 10:03:40 -04:00
Chris Kipp 15a45cb3c0 feat: start forwarding diagnosticCode via BSP
This change is a continuation of the work that was done in
https://github.com/sbt/sbt/pull/6874 to allow the Scala 3 compiler to
forward the `diagnosticCode` of an error as well as the other normal
things. This change in dotty was merged in
https://github.com/lampepfl/dotty/pull/15565 and also backported so it
will be in the 3.2.x series release. This change captures the
`diagnosticCode` and forwards it on via BSP so that tools like Metals
can can use this code.

You can see this in the BSP trace now for a diagnostic:

For example with some code that contains the following:

```scala
val x: Int = "hi"
```

You'll see the code in the BSP diagnostic:
```  "diagnostics": [
    {
      "range": {
        "start": {
          "line": 9,
          "character": 15
        },
        "end": {
          "line": 9,
          "character": 19
        }
      },
      "severity": 1,
      "code": "7",
      "source": "sbt",
      "message": "Found:    (\u001b[32m\"hi\"\u001b[0m : String)\nRequired: Int\n\nThe following import might make progress towards fixing the problem:\n\n  import sourcecode.Text.generate\n\n"
    }
  ]
```

Co-authored-by: Adrien Piquerez <adrien.piquerez@gmail.com>
Refs: https://github.com/lampepfl/dotty/issues/14904
2022-08-09 19:02:52 +02:00
eugene yokota a1e0f6a904
Merge pull request #6995 from sbt/dependabot/github_actions/actions/cache-3.0.6
Bump actions/cache from 3.0.5 to 3.0.6
2022-08-08 18:23:57 -04:00
dependabot[bot] 5b09ba03a3
Bump actions/cache from 3.0.5 to 3.0.6
Bumps [actions/cache](https://github.com/actions/cache) from 3.0.5 to 3.0.6.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v3.0.5...v3.0.6)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-08-08 04:04:59 +00:00
Adrien Piquerez 73fd426847
Merge pull request #6992 from adpi2/fix-bg-logging
Fix background job logging
2022-08-06 09:19:42 +02:00
Adrien Piquerez 634e8799e7 Catch ClosedChannelException in background job logger
We want the background job to stay alive even if its terminal
has been closed and we cannot write to it anymore
2022-08-05 14:45:38 +02:00
Adrien Piquerez 592086b889 Don't use ProxyTerminal in background job
If we use the ProxyTerminal in the background jobs, the logs
would be spread across different terminals, switching from active
client to active client. We want the logs to stick
to the client that started the job.
2022-08-04 16:48:13 +02:00
Adrien Piquerez 6bcda6684a Use BackgroundJobService context instead of MainLoop context
A new context is created and closed for each state of the MainLoop.
But the context of the backgroundJob must stay alive.
So we use a context that is owned by the BackgroundJobService.
It creates a new logger for each background job and cleans it when
the job stops.
2022-08-04 16:48:13 +02:00
Adrien Piquerez 59ee1b1d37
Merge pull request #6990 from adpi2/bckp_bsp_output_paths
[1.8.x] Add support for BSP's buildTarget/outputPaths method
2022-08-03 15:26:57 +02:00
Krzysztof Pado 2bffb2731e Add support for BSP's buildTarget/outputPaths method 2022-08-03 10:13:48 +02:00
eugene yokota 1f29c9053c
Merge pull request #6977 from sbt/dependabot/github_actions/actions/cache-3.0.5
Bump actions/cache from 3.0.4 to 3.0.5
2022-07-18 01:19:16 -04:00
dependabot[bot] 683f2e9291
Bump actions/cache from 3.0.4 to 3.0.5
Bumps [actions/cache](https://github.com/actions/cache) from 3.0.4 to 3.0.5.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v3.0.4...v3.0.5)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-18 04:02:58 +00:00
Adrien Piquerez 992dfd5649
Merge pull request #6972 from adpi2/dependency-submission-v2
Bump sbt-dependency-submission
2022-07-15 13:03:56 +02:00
Adrien Piquerez 8dba607ed8 Bump sbt-dependency-submission
Fix the build on 2.13.8 to submit the corresponding graphs:
Remove 2.13.8 in the crossScalaVersions of sbt-dependency-graph
scripted-sbt-redux and scripted-sbt because they
depend on sbtProj.
2022-07-15 11:07:33 +02:00
Eugene Yokota 38125c5347 sbt 1.7.1 2022-07-11 23:43:06 -04:00