-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat!: Implement plugin as only an LSP client (#100)
feat: Support multiple workspaces & individual files chore!: Upgrade dependencies & require much newer VSCode feat: Build extension into a single JS file chore: Update LSP debugging instructions and setup chore!: Remove unused plugin options chore!: Rename settings namespace to just "grain" feat: Add LSP restart command Co-authored-by: Marcus Roberts <marcus@marcusr.com> Co-authored-by: Blaine Bublitz <blaine.bublitz@gmail.com>
- Loading branch information
1 parent
7b82c96
commit 8c12b49
Showing
31 changed files
with
5,808 additions
and
2,245 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
*.vsix | ||
out | ||
syntaxes/grain-type.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
node_modules | ||
dist | ||
out/ | ||
CHANGELOG.md |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,13 @@ | ||
.vscode/** | ||
**/*.ts | ||
**/*.map | ||
.vscode/ | ||
node_modules/ | ||
out/*.js.map | ||
scripts/ | ||
src/ | ||
test/ | ||
.gitignore | ||
**/tsconfig.json | ||
**/tsconfig.base.json | ||
contributing.md | ||
.travis.yml | ||
client/node_modules/** | ||
!client/node_modules/vscode-jsonrpc/** | ||
!client/node_modules/vscode-languageclient/** | ||
!client/node_modules/vscode-languageserver-protocol/** | ||
!client/node_modules/vscode-languageserver-types/** | ||
!client/node_modules/semver/** | ||
|
||
.npmrc | ||
.prettierignore | ||
CHANGELOG.md | ||
package-lock.json | ||
tsconfig.json | ||
*.vsix |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
# VSCode extension for Grain | ||
|
||
The VSCode extension for the [Grain programming language](https://github.com/grain-lang/grain). | ||
|
||
**Requires:** vscode 1.67+ | ||
|
||
## Functionality | ||
|
||
This LSP Protocol client provides the the following language features for grain (`.gr`) files: | ||
|
||
- Show compilation warnings and errors | ||
- Code lenses | ||
- Hover support | ||
|
||
## Running the extension | ||
|
||
- Run `npm ci` in this folder. | ||
- Open VSCode inside this folder. | ||
- Switch to the "Run and Debug" pane. | ||
- Select "Launch Extension" from the drop down. | ||
- Press the ▶️ button next to "Launch Extension", which will start a TypeScript watcher and launch a new VSCode instance titled `[Extension Development Host]`. | ||
- The Grain CLI needs to be on your path. If not, set the `cliPath` setting inside the `[Extension Development Host]` instance to the location of your Grain CLI. | ||
- In the `[Extension Development Host]` instance of VSCode, open a document in 'grain' language mode. | ||
- After a code change, you'll likely need to trigger a "Developer: Reload Window" action in the `[Extension Development Host]` instance before the extension will pick up the changes. | ||
|
||
## Useful files | ||
|
||
- `package.json` - this is the manifest file in which you declare your language support and define | ||
the location of the grammar file that has been copied into your extension. | ||
- `syntaxes/grain.tmLanguage.json` - this is the Text mate grammar file that is used for tokenization. | ||
- `language-configuration.json` - this the language configuration, defining the tokens that are used for | ||
comments and brackets. |
Oops, something went wrong.