Skip to content

Commit 559931d

Browse files
author
Beyang Liu
committed
python.languageServer.url -> python.serverUrl
python.sourcegraph.url -> python.sourcegraphUrl
1 parent e9d04de commit 559931d

4 files changed

Lines changed: 9 additions & 9 deletions

File tree

‎README.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,11 @@ Docker image `sourcegraph/lang-python` from Docker Hub.
3131
1. Add these to your Sourcegraph settings:
3232

3333
```json
34-
"python.languageServer.url": "ws://localhost:4288",
35-
"python.sourcegraph.url": "http://host.docker.internal:7080",
34+
"python.serverUrl": "ws://localhost:4288",
35+
"python.sourcegraphUrl": "http://host.docker.internal:7080",
3636
```
3737

38-
If you're running on Linux, change `python.sourcegraph.url` to the IP given by:
38+
If you're running on Linux, change `python.sourcegraphUrl` to the IP given by:
3939
4040
```bash
4141
ip addr show docker0 | grep -Po 'inet \K[\d.]+'

‎package.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
"configuration": {
2121
"title": "Python settings",
2222
"properties": {
23-
"python.languageServer.url": {
23+
"python.serverUrl": {
2424
"description": "The URL to the Python language server (which is an instance of https://github.com/sourcegraph/python-language-server).",
2525
"type": "string",
2626
"format": "uri",

‎src/settings.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
interface Settings {
2-
['python.languageServer.url']?: string
2+
['python.serverUrl']?: string
33
['python.accessToken']?: string
4-
['python.sourcegraph.url']?: string
4+
['python.sourcegraphUrl']?: string
55
['python.traceLogging']?: boolean
66
}

‎src/sourcegraph-python.ts‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,15 @@ const DUMMY_CTX = { subscriptions: { add: (_unsubscribable: any) => void 0 } }
3434

3535
export function activate(ctx: sourcegraph.ExtensionContext = DUMMY_CTX): void {
3636
const languageServerUrl = sourcegraph.configuration.get<Settings>().value[
37-
'python.languageServer.url'
37+
'python.serverUrl'
3838
]
3939
if (!languageServerUrl) {
4040
if (sourcegraph.app.activeWindow) {
4141
const docURL = `${sourcegraph.internal.sourcegraphURL
4242
.toString()
4343
.replace(/\/$/, '')}/extensions/sourcegraph/python`
4444
sourcegraph.app.activeWindow.showNotification(
45-
'Configure `python.languageServer.url` in user settings for Python code intelligence.\n\n[Documentation](' +
45+
'Configure `python.serverUrl` in user settings for Python code intelligence.\n\n[Documentation](' +
4646
docURL +
4747
')'
4848
)
@@ -67,7 +67,7 @@ export function activate(ctx: sourcegraph.ExtensionContext = DUMMY_CTX): void {
6767

6868
const settings = sourcegraph.configuration.get<Settings>().value
6969
const zipUrl = new URL(
70-
settings['python.sourcegraph.url'] ||
70+
settings['python.sourcegraphUrl'] ||
7171
sourcegraph.internal.sourcegraphURL.toString()
7272
)
7373
const accessToken = await getOrTryToCreateAccessToken()

0 commit comments

Comments
 (0)