Skip to content

Commit 7d625e1

Browse files
committed
change doc to recommend metals worksheet
1 parent 712d53b commit 7d625e1

File tree

5 files changed

+14
-99
lines changed

5 files changed

+14
-99
lines changed

docs/docs/usage/worksheet-mode-implementation-details.md

Lines changed: 0 additions & 79 deletions
This file was deleted.

docs/docs/usage/worksheet-mode.md

Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,22 @@
11
---
22
layout: doc-page
3-
title: "Worksheet mode with Dotty IDE"
3+
title: "Worksheet mode with Metals"
44
---
55

6-
A worksheet is a Scala file that is evaluated on save, and the result of each
7-
expression is shown in a column to the right of your program. Worksheets are
6+
A worksheet is a Scala file that is evaluated on save, powered
7+
by [Scala Metals](https://scalameta.org/metals/), and the result of each
8+
expression is shown at the end of the line it is defined on. Worksheets are
89
like a REPL session on steroids, and enjoy 1st class editor support: completion,
910
hyperlinking, interactive errors-as-you-type, etc. Worksheet use the extension
10-
`.sc`.
11+
`.worksheet.sc`.
1112

1213
How to use the worksheets
1314
=========================
1415
The only supported client for the Worksheet mode is [Visual Studio
1516
Code](https://code.visualstudio.com/).
1617

17-
To use the worksheets, start Dotty IDE by [following the
18-
instruction](ide-support.md) and create a new file `MyWorksheet.sc` and
18+
To use the worksheets, start Metals by [following the
19+
instruction](ide-support.md) and create a new file `MyWorksheet.worksheet.sc` and
1920
write some code:
2021

2122
```scala
@@ -24,27 +25,20 @@ println("Hello, worksheets!")
2425
456 + xyz
2526
```
2627

27-
On top of the buffer, the message `Run this worksheet` appears. Click it to
28-
evaluate the code of the worksheet. Each line of output is printed on the right
28+
On top of the buffer, the message `Copy Worksheet Output` appears. Save the file to evaluate the code of the worksheet. Each line of output is printed on the right
2929
of the expression that produced it. The worksheets run with the classes of your
3030
project and its dependencies on their classpath.
3131

3232
![](images/worksheets/worksheet-run.png "Run worksheet")
3333

34-
By default, the worksheets are also run when the file is saved. This can be
35-
configured in VSCode preferences:
36-
37-
![](images/worksheets/config-autorun.png "Configure run on save")
38-
39-
Note that the worksheet are fully integrated with the rest of Dotty IDE: While
40-
typing, errors are shown, completions are suggested, and you can use all the
41-
other features of Dotty IDE such as go to definition, find all references, etc.
34+
Note that the worksheet are fully integrated with the rest of Metals:
35+
When you type, completions are suggested, and when you save errors are shown.
36+
You can use all the other features of Metals such as go to definition,
37+
find all references, etc.
4238

4339
![](images/worksheets/worksheet-help.png "IDE features in the worksheet")
4440

45-
Implementation details
41+
More Information
4642
======================
4743

48-
The implementation details of the worksheet mode and the information necessary to add support for
49-
other clients are available in [Worksheet mode - Implementation
50-
details](worksheet-mode-implementation-details.md).
44+
find out more in the [Metals Documentation](https://scalameta.org/metals/docs/editors/vscode.html#worksheets).
-33.6 KB
Binary file not shown.
31 KB
Loading
30.5 KB
Loading

0 commit comments

Comments
 (0)