UNPKG

@microsoft/compose-language-service

Version:
54 lines 2.99 kB
"use strict"; /*!-------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See LICENSE in the project root for license information. *--------------------------------------------------------------------------------------------*/ Object.defineProperty(exports, "__esModule", { value: true }); exports.VolumesCompletionCollection = void 0; const vscode_languageserver_1 = require("vscode-languageserver"); const CompletionCollection_1 = require("./CompletionCollection"); exports.VolumesCompletionCollection = new CompletionCollection_1.CompletionCollection('volumes', { logicalPaths: [/^\/services\/[.\w-]+\/volumes\/<item>\/.*$/i], indentationDepth: 3 }, ...[ { // Matches ` - ""` or ` -`, with allowances for other amounts of whitespace/quoting matcher: /(\s*-\s*)(?<leadingQuote>"|')?\2\s*$/i, label: 'hostPath:containerPath:mode', insertText: '${1:hostPath}:${2:containerPath}:${3|ro,rw|}$0', insertTextFormat: vscode_languageserver_1.InsertTextFormat.Snippet, isAdvancedComposeCompletion: true, }, { // Matches ` - ""` or ` -`, with allowances for other amounts of whitespace/quoting matcher: /(\s*-\s*)(?<leadingQuote>"|')?\2\s*$/i, label: 'volumeName:containerPath:mode', insertText: '${1:volumeName}:${2:containerPath}:${3|ro,rw|}$0', insertTextFormat: vscode_languageserver_1.InsertTextFormat.Snippet, isAdvancedComposeCompletion: true, }, { // Matches ` - "C:\some\path:"` or ` - /some/path:`, with allowances for other amounts of whitespace/quoting matcher: /(\s*-\s*)(?<leadingQuote>"|')?(([a-z]:\\)?[^:"]+):\2\s*$/i, label: ':containerPath:mode', insertText: '${1:containerPath}:${2|ro,rw|}$0', insertTextFormat: vscode_languageserver_1.InsertTextFormat.Snippet, isAdvancedComposeCompletion: true, }, { // Matches ` - "C:\some\path:/another/path:"` or ` - /some/path:/another/path:`, with allowances for other amounts of whitespace/quoting matcher: /(\s*-\s*)(?<leadingQuote>"|')?(([a-z]:\\)?[^:"]+):(([a-z]:\\)?[^:"]+):\2\s*$/i, label: ':ro', insertText: 'ro', insertTextFormat: vscode_languageserver_1.InsertTextFormat.PlainText, isAdvancedComposeCompletion: true, detail: 'Read-only', }, { // Matches ` - "C:\some\path:/another/path:"` or ` - /some/path:/another/path:`, with allowances for other amounts of whitespace/quoting matcher: /(\s*-\s*)(?<leadingQuote>"|')?(([a-z]:\\)?[^:"]+):(([a-z]:\\)?[^:"]+):\2\s*$/i, label: ':rw', insertText: 'rw', insertTextFormat: vscode_languageserver_1.InsertTextFormat.PlainText, isAdvancedComposeCompletion: true, detail: 'Read-write', }, ]); //# sourceMappingURL=VolumesCompletionCollection.js.map