Skip to content

Commit f340bd7

Browse files
authored
feat: send a new publishDiagnostics notification (#639)
1 parent 7493983 commit f340bd7

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,15 @@ Right now the language server supports the following actions:
8585
]
8686
}
8787
```
88+
- Custom Publish Diagnostics Notification
89+
- method: `$/snyk.publishDiagnostics316`
90+
- payload:
91+
```json5
92+
{
93+
"uri": "/path/to/file",
94+
"diagnostics": [],
95+
}
96+
```
8897
- Authentication Notification
8998
- method: `$/snyk.hasAuthenticated`
9099
- payload:

application/server/notification.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ func registerNotifier(c *config.Config, srv types.Server) {
108108
Msgf("publishing diagnostics overview for %s", params.Product)
109109
case types.PublishDiagnosticsParams:
110110
notifier(c, srv, "textDocument/publishDiagnostics", params)
111+
notifier(c, srv, "$/snyk.publishDiagnostics316", params)
111112
source := "LSP"
112113
if len(params.Diagnostics) > 0 {
113114
source = params.Diagnostics[0].Source

0 commit comments

Comments
 (0)