Skip to content

Commit e675999

Browse files
committed
Add documentation for the IDE support
1 parent 6eed39f commit e675999

File tree

3 files changed

+64
-3
lines changed

3 files changed

+64
-3
lines changed

docs/docs/index.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,9 @@ Contents
1616

1717
* Usage
1818
- [Migrating from Scala 2](usage/migrating.md): migration information
19-
- [Dotty projects with cbt](usage/cbt-projects.md): using cbt
2019
- [Dotty projects with sbt](usage/sbt-projects.md): using sbt
20+
- [IDE support for Dotty](usage/ide-support.md)
21+
- [Dotty projects with cbt](usage/cbt-projects.md): using cbt
2122
* Contributing
2223
- [Getting Started](contributing/getting-started.md): details on how to run tests, use the cli scripts
2324
- [Workflow](contributing/workflow.md): common dev patterns and hints

docs/docs/usage/ide-support.md

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
---
2+
layout: doc-page
3+
title: "IDE support for Dotty"
4+
---
5+
6+
Dotty comes built-in with the Dotty Language Server, an implementation of the
7+
[Language Server Protocol](https://github.com/Microsoft/language-server-protocol),
8+
which means that any editor that implements support for the LSP can get a great
9+
Dotty integration. Currently, the only IDE we officially support
10+
is [Visual Studio Code](https://code.visualstudio.com/).
11+
12+
Prerequisites
13+
============
14+
To use this in your own Scala project, you must first get it to compile with
15+
Dotty, please follow the instructions at https://github.com/lampepfl/dotty-example-project
16+
17+
Usage
18+
=====
19+
1. Install [Visual Studio Code](https://code.visualstudio.com/).
20+
2. In your project, run:
21+
```shell
22+
sbt launchIDE
23+
```
24+
25+
Status
26+
======
27+
28+
## Fully supported features:
29+
- Typechecking as you type to show compiler errors/warnings
30+
- Type information on hover
31+
- Go to definition (in the current project)
32+
- Find all references
33+
34+
## Partially working features:
35+
- Completion
36+
- Renaming
37+
- Go to definition in external projects
38+
39+
## Unimplemented features:
40+
- Documentation on hover
41+
- Formatting code (requires integrating with scalafmt)
42+
- Quick fixes (probably by integrating with scalafix)
43+
44+
## Current limitations, to be fixed:
45+
- Projects should be compiled with sbt before starting the IDE, this is
46+
automatically done for you if you run `sbt launchIDE`.
47+
- Once the IDE is started, source files that are not opened in the IDE
48+
should not be modified in some other editor, the IDE won't pick up
49+
these changes.
50+
- Not all compiler errors/warnings are displayed, just those occuring
51+
during typechecking.
52+
53+
54+
Feedback
55+
========
56+
Please report issues on https://github.com/lampepfl/dotty/issues,
57+
you can also come chat with use on the
58+
[Dotty gitter channel](https://gitter.im/lampepfl/dotty)!

docs/sidebar.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,12 @@ sidebar:
33
url: blog/index.html
44
- title: Usage
55
subsection:
6-
- title: cbt-projects
7-
url: docs/usage/cbt-projects.html
86
- title: sbt-projects
97
url: docs/usage/sbt-projects.html
8+
- title: IDE support for Dotty
9+
url: docs/usage/ide-support.html
10+
- title: cbt-projects
11+
url: docs/usage/cbt-projects.html
1012
- title: Dottydoc
1113
url: docs/usage/dottydoc.html
1214
- title: Migrating

0 commit comments

Comments
 (0)