Adopt version 0.0.17 of the language server

This update to 0.0.17 from 0.0.13 includes many features and bug
fixes.

The update includes changes to how workspace/configuration requests
are handled as they have become a part of the official LSP
specification.

textDocument/documentLink requests are now handled by creating links
for image names that open to hub.docker.com.

Signed-off-by: Remy Suen <remy.suen@gmail.com>
This commit is contained in:
Remy Suen 2018-04-16 07:23:25 -04:00
Родитель ea8816e74c
Коммит b1f9bc1650
3 изменённых файлов: 113 добавлений и 45 удалений

Просмотреть файл

@ -26,7 +26,7 @@ import { Reporter } from './telemetry/telemetry';
import DockerInspectDocumentContentProvider, { SCHEME as DOCKER_INSPECT_SCHEME } from './documentContentProviders/dockerInspect';
import { DockerExplorerProvider } from './explorer/dockerExplorer';
import { removeContainer } from './commands/remove-container';
import { LanguageClient, LanguageClientOptions, ServerOptions, TransportKind, Middleware, Proposed, ProposedFeatures, DidChangeConfigurationNotification } from 'vscode-languageclient';
import { LanguageClient, LanguageClientOptions, ServerOptions, TransportKind, Middleware, ConfigurationParams, DidChangeConfigurationNotification } from 'vscode-languageclient';
import { WebAppCreator } from './explorer/deploy/webAppCreator';
import { AzureImageNode, AzureRegistryNode, AzureRepositoryNode } from './explorer/models/azureRegistryNodes';
import { DockerHubImageNode, DockerHubRepositoryNode, DockerHubOrgNode } from './explorer/models/dockerHubNodes';
@ -150,7 +150,7 @@ namespace Configuration {
let configurationListener: vscode.Disposable;
export function computeConfiguration(params: Proposed.ConfigurationParams): vscode.WorkspaceConfiguration[] {
export function computeConfiguration(params: ConfigurationParams): vscode.WorkspaceConfiguration[] {
if (!params.items) {
return null;
}
@ -192,7 +192,7 @@ function activateLanguageClient(ctx: vscode.ExtensionContext) {
debug: { module: serverModule, transport: TransportKind.ipc, options: debugOptions }
}
let middleware: ProposedFeatures.ConfigurationMiddleware | Middleware = {
let middleware: Middleware = {
workspace: {
configuration: Configuration.computeConfiguration
}
@ -207,8 +207,6 @@ function activateLanguageClient(ctx: vscode.ExtensionContext) {
}
client = new LanguageClient("dockerfile-langserver", "Dockerfile Language Server", serverOptions, clientOptions);
// enable the proposed workspace/configuration feature
client.registerProposedFeatures();
client.onReady().then(() => {
// attach the VS Code settings listener
Configuration.initialize();

135
package-lock.json сгенерированный
Просмотреть файл

@ -1,6 +1,6 @@
{
"name": "vscode-docker",
"version": "0.0.26",
"version": "0.0.27",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
@ -629,30 +629,82 @@
}
},
"dockerfile-ast": {
"version": "0.0.1",
"resolved": "https://registry.npmjs.org/dockerfile-ast/-/dockerfile-ast-0.0.1.tgz",
"integrity": "sha1-0b09ju5fJmiilLck/ZCm4BKs+5Y=",
"version": "0.0.3",
"resolved": "https://registry.npmjs.org/dockerfile-ast/-/dockerfile-ast-0.0.3.tgz",
"integrity": "sha1-RnpnKRpqLBnnMgDfR1n4xECVrl4=",
"requires": {
"vscode-languageserver-types": "3.5.0"
"vscode-languageserver-types": "3.7.1"
}
},
"dockerfile-language-server-nodejs": {
"version": "0.0.13",
"resolved": "https://registry.npmjs.org/dockerfile-language-server-nodejs/-/dockerfile-language-server-nodejs-0.0.13.tgz",
"integrity": "sha1-5zJv/cyVIjEZYf/oUr9jmDaRpLA=",
"version": "0.0.17",
"resolved": "https://registry.npmjs.org/dockerfile-language-server-nodejs/-/dockerfile-language-server-nodejs-0.0.17.tgz",
"integrity": "sha512-4hFsCKgLdqHAMAzt2hodoBNjlDuPLOrdWhX52zSG8CWff2CqFlGFozkvD/lQDEeZn6piBWrQmh+wL+UALqdahw==",
"requires": {
"dockerfile-ast": "0.0.1",
"dockerfile-utils": "0.0.5",
"vscode-languageserver": "3.5.0"
"dockerfile-ast": "0.0.3",
"dockerfile-language-service": "0.0.4",
"dockerfile-utils": "0.0.8",
"vscode-languageserver": "4.1.2"
}
},
"dockerfile-language-service": {
"version": "0.0.4",
"resolved": "https://registry.npmjs.org/dockerfile-language-service/-/dockerfile-language-service-0.0.4.tgz",
"integrity": "sha512-5f8CyQMIUtuNSdO6nGU58sbAnI9EEycV/n9dozYryasf83l/3kwR+NyTaN8S6ZktIMQMdPlAuJHm0r4QtR9pFg==",
"requires": {
"dockerfile-ast": "0.0.3",
"dockerfile-utils": "0.0.9",
"vscode-languageserver-types": "3.7.1"
},
"dependencies": {
"dockerfile-utils": {
"version": "0.0.9",
"resolved": "https://registry.npmjs.org/dockerfile-utils/-/dockerfile-utils-0.0.9.tgz",
"integrity": "sha512-yNsWQn6Umv7Wp94hxpwQMcKV3u0ig52dTP0duSe4eJUVieNLFc+UQ2OCpBNTiygfC4gvTB0ymldaPMj5LuSc3Q==",
"requires": {
"dockerfile-ast": "0.0.4",
"vscode-languageserver-types": "3.5.0"
},
"dependencies": {
"dockerfile-ast": {
"version": "0.0.4",
"resolved": "https://registry.npmjs.org/dockerfile-ast/-/dockerfile-ast-0.0.4.tgz",
"integrity": "sha512-eOmS/ygp2tGOiUrBW7XcHqYeUhHePjxCTpboS6tbXA3nE5be78QxdhzM9fSR7paKAIq2xaV5eSVsEixUNVk9bQ==",
"requires": {
"vscode-languageserver-types": "3.5.0"
}
},
"vscode-languageserver-types": {
"version": "3.5.0",
"resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.5.0.tgz",
"integrity": "sha1-5I15li8LjgLelV4/UkkI4rGcA3Q="
}
}
}
}
},
"dockerfile-utils": {
"version": "0.0.5",
"resolved": "https://registry.npmjs.org/dockerfile-utils/-/dockerfile-utils-0.0.5.tgz",
"integrity": "sha1-cSl6hRXJ2/1WKI9NJ6otO8Hc8tw=",
"version": "0.0.8",
"resolved": "https://registry.npmjs.org/dockerfile-utils/-/dockerfile-utils-0.0.8.tgz",
"integrity": "sha512-EPKPIbMK638M6O3Gw9H+QOWiRBNC3apnyL7FsgJsHV1YpJXRFQz2TDW424S8gsqhvDwbtHdLURiH2mvymNAziQ==",
"requires": {
"dockerfile-ast": "0.0.1",
"dockerfile-ast": "0.0.4",
"vscode-languageserver-types": "3.5.0"
},
"dependencies": {
"dockerfile-ast": {
"version": "0.0.4",
"resolved": "https://registry.npmjs.org/dockerfile-ast/-/dockerfile-ast-0.0.4.tgz",
"integrity": "sha512-eOmS/ygp2tGOiUrBW7XcHqYeUhHePjxCTpboS6tbXA3nE5be78QxdhzM9fSR7paKAIq2xaV5eSVsEixUNVk9bQ==",
"requires": {
"vscode-languageserver-types": "3.5.0"
}
},
"vscode-languageserver-types": {
"version": "3.5.0",
"resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.5.0.tgz",
"integrity": "sha1-5I15li8LjgLelV4/UkkI4rGcA3Q="
}
}
},
"dockerode": {
@ -3027,45 +3079,52 @@
}
},
"vscode-jsonrpc": {
"version": "3.5.0",
"resolved": "https://registry.npmjs.org/vscode-jsonrpc/-/vscode-jsonrpc-3.5.0.tgz",
"integrity": "sha1-hyOdnhZrLXNSJFuKgTWXgEwdY6o="
"version": "3.6.1",
"resolved": "https://registry.npmjs.org/vscode-jsonrpc/-/vscode-jsonrpc-3.6.1.tgz",
"integrity": "sha512-+Eb+Dxf2kC2h079msx61hkblxAKE0S2j78+8QpnigLAO2aIIjkCwTIH34etBrU8E8VItRinec7YEwULx9at5bQ=="
},
"vscode-languageclient": {
"version": "3.5.0",
"resolved": "https://registry.npmjs.org/vscode-languageclient/-/vscode-languageclient-3.5.0.tgz",
"integrity": "sha1-NtAswYaoNlpEZ3GaKQ+yAKmuSQo=",
"version": "4.1.3",
"resolved": "https://registry.npmjs.org/vscode-languageclient/-/vscode-languageclient-4.1.3.tgz",
"integrity": "sha512-3tu79B56apocobPGkHm7YWobjhNKCU7H4cUk+rkVFCNoOSAm2wZlN2J6HdC15/ONALY4ai25BeyQ+aQaFmM1Jg==",
"requires": {
"vscode-languageserver-protocol": "3.5.0"
"vscode-languageserver-protocol": "3.7.1"
}
},
"vscode-languageserver": {
"version": "3.5.0",
"resolved": "https://registry.npmjs.org/vscode-languageserver/-/vscode-languageserver-3.5.0.tgz",
"integrity": "sha1-0oCZvG3dqMHdFrcH5FThsd2uDbo=",
"version": "4.1.2",
"resolved": "https://registry.npmjs.org/vscode-languageserver/-/vscode-languageserver-4.1.2.tgz",
"integrity": "sha512-3iej2tuMaI9yirPXF7/fVyIvBhSzbwZ3EWFRb8bP6lc3tGv9SJHDaJLNyQMgo9J8CNpXil6dWarpJvGSA60v/w==",
"requires": {
"vscode-languageserver-protocol": "3.5.0",
"vscode-uri": "1.0.1"
"vscode-languageserver-protocol": "3.7.1",
"vscode-uri": "1.0.3"
}
},
"vscode-languageserver-protocol": {
"version": "3.5.0",
"resolved": "https://registry.npmjs.org/vscode-languageserver-protocol/-/vscode-languageserver-protocol-3.5.0.tgz",
"integrity": "sha1-Bnxcvidwl5U5jRGWksl+u6FFIgk=",
"version": "3.7.1",
"resolved": "https://registry.npmjs.org/vscode-languageserver-protocol/-/vscode-languageserver-protocol-3.7.1.tgz",
"integrity": "sha512-AKX9XQ49m/lpiDLZJBypFNc5eAXNlSecunYU5m4o5WIwGgW86TWnXVdziuFm47W2SdigDa/jVbxLPSNUeut9fQ==",
"requires": {
"vscode-jsonrpc": "3.5.0",
"vscode-languageserver-types": "3.5.0"
"vscode-jsonrpc": "3.6.1",
"vscode-languageserver-types": "3.7.1"
},
"dependencies": {
"vscode-languageserver-types": {
"version": "3.7.1",
"resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.7.1.tgz",
"integrity": "sha512-ftGfU79AnnI3OHCG7kzCCN47jNI7BjECPAH2yhddtYTiQk0bnFbuFeQKvpXQcyNI3GsKEx5b6kSiBYshTiep6w=="
}
}
},
"vscode-languageserver-types": {
"version": "3.5.0",
"resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.5.0.tgz",
"integrity": "sha1-5I15li8LjgLelV4/UkkI4rGcA3Q="
"version": "3.7.1",
"resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.7.1.tgz",
"integrity": "sha512-ftGfU79AnnI3OHCG7kzCCN47jNI7BjECPAH2yhddtYTiQk0bnFbuFeQKvpXQcyNI3GsKEx5b6kSiBYshTiep6w=="
},
"vscode-uri": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/vscode-uri/-/vscode-uri-1.0.1.tgz",
"integrity": "sha1-Eahr7+rDxKo+wIYjZRo8gabQu8g="
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/vscode-uri/-/vscode-uri-1.0.3.tgz",
"integrity": "sha1-Yxvb9xbcyrDmUpGo3CXCMjIIWlI="
},
"winreg": {
"version": "1.2.3",

Просмотреть файл

@ -411,6 +411,17 @@
],
"description": "Controls the diagnostic severity for flagging a Dockerfile with multiple HEALTHCHECK instructions."
},
"docker.languageserver.diagnostics.instructionJSONInSingleQuotes": {
"scope": "resource",
"type": "string",
"default": "warning",
"enum": [
"ignore",
"warning",
"error"
],
"description": "Controls the diagnostic severity for JSON instructions that are written incorrectly with single quotes."
},
"docker.attachShellCommand.linuxContainer": {
"type": "string",
"default": "/bin/sh",
@ -606,7 +617,7 @@
"azure-arm-containerregistry": "^1.0.0-preview",
"azure-arm-resource": "^2.0.0-preview",
"azure-arm-website": "^1.0.0-preview",
"dockerfile-language-server-nodejs": "^0.0.13",
"dockerfile-language-server-nodejs": "^0.0.17",
"dockerode": "^2.5.1",
"gradle-to-js": "^1.0.1",
"moment": "^2.19.3",
@ -614,6 +625,6 @@
"pom-parser": "^1.1.1",
"request-promise": "^4.2.2",
"vscode-extension-telemetry": "^0.0.6",
"vscode-languageclient": "^3.5.0-next.4"
"vscode-languageclient": "^4.0.0"
}
}