Merge VS Code 1.21 source code (#1067)

* Initial VS Code 1.21 file copy with patches

* A few more merges

* Post npm install

* Fix batch of build breaks

* Fix more build breaks

* Fix more build errors

* Fix more build breaks

* Runtime fixes 1

* Get connection dialog working with some todos

* Fix a few packaging issues

* Copy several node_modules to package build to fix loader issues

* Fix breaks from master

* A few more fixes

* Make tests pass

* First pass of license header updates

* Second pass of license header updates

* Fix restore dialog issues

* Remove add additional themes menu items

* fix select box issues where the list doesn't show up

* formatting

* Fix editor dispose issue

* Copy over node modules to correct location on all platforms
This commit is contained in:
Karl Burtram
2018-04-04 15:27:51 -07:00
committed by GitHub
parent 5fba3e31b4
commit dafb780987
9412 changed files with 141255 additions and 98813 deletions

View File

@@ -0,0 +1,5 @@
# Merge Conflict
See [documentation](https://code.visualstudio.com/docs/editor/versioncontrol#_merge-conflicts).
**Notice** This is a an extension that is bundled with Visual Studio Code.

View File

@@ -1,26 +0,0 @@
{
"name": "merge-conflict",
"version": "0.7.0",
"dependencies": {
"applicationinsights": {
"version": "0.18.0",
"from": "applicationinsights@0.18.0",
"resolved": "https://registry.npmjs.org/applicationinsights/-/applicationinsights-0.18.0.tgz"
},
"vscode-extension-telemetry": {
"version": "0.0.8",
"from": "vscode-extension-telemetry@0.0.8",
"resolved": "https://registry.npmjs.org/vscode-extension-telemetry/-/vscode-extension-telemetry-0.0.8.tgz"
},
"vscode-nls": {
"version": "2.0.2",
"from": "vscode-nls@>=2.0.2 <3.0.0",
"resolved": "https://registry.npmjs.org/vscode-nls/-/vscode-nls-2.0.2.tgz"
},
"winreg": {
"version": "1.2.3",
"from": "winreg@1.2.3",
"resolved": "https://registry.npmjs.org/winreg/-/winreg-1.2.3.tgz"
}
}
}

View File

@@ -1,9 +1,10 @@
{
"name": "merge-conflict",
"publisher": "vscode",
"displayName": "merge-conflict",
"description": "Merge Conflict",
"version": "0.7.0",
"displayName": "%displayName%",
"description": "%description%",
"icon": "resources/icons/merge-conflict.png",
"version": "1.0.0",
"aiKey": "AIF-d9b70cd4-b9f9-4d70-929b-a071c400b217",
"engines": {
"vscode": "^1.5.0"
@@ -24,51 +25,61 @@
{
"category": "%command.category%",
"title": "%command.accept.all-current%",
"original": "Accept All Current",
"command": "merge-conflict.accept.all-current"
},
{
"category": "%command.category%",
"title": "%command.accept.all-incoming%",
"original": "Accept All Incoming",
"command": "merge-conflict.accept.all-incoming"
},
{
"category": "%command.category%",
"title": "%command.accept.all-both%",
"original": "Accept All Both",
"command": "merge-conflict.accept.all-both"
},
{
"category": "%command.category%",
"title": "%command.accept.current%",
"original": "Accept Current",
"command": "merge-conflict.accept.current"
},
{
"category": "%command.category%",
"title": "%command.accept.incoming%",
"original": "Accept Incoming",
"command": "merge-conflict.accept.incoming"
},
{
"category": "%command.category%",
"title": "%command.accept.selection%",
"original": "Accept Selection",
"command": "merge-conflict.accept.selection"
},
{
"category": "%command.category%",
"title": "%command.accept.both%",
"original": "Accept Both",
"command": "merge-conflict.accept.both"
},
{
"category": "%command.category%",
"title": "%command.next%",
"original": "Next Conflict",
"command": "merge-conflict.next"
},
{
"category": "%command.category%",
"title": "%command.previous%",
"original": "Previous Conflict",
"command": "merge-conflict.previous"
},
{
"category": "%command.category%",
"title": "%command.compare%",
"original":"Compare Current Conflict",
"command": "merge-conflict.compare"
}
],
@@ -89,8 +100,7 @@
}
},
"dependencies": {
"vscode-extension-telemetry": "0.0.8",
"vscode-nls": "^2.0.2"
"vscode-nls": "^3.2.1"
},
"devDependencies": {
"@types/node": "8.0.33"

View File

@@ -1,4 +1,6 @@
{
"displayName": "Merge Conflict",
"description": "Highlighting and commands for inline merge conflicts.",
"command.category": "Merge Conflict",
"command.accept.all-current": "Accept All Current",
"command.accept.all-incoming": "Accept All Incoming",

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

View File

@@ -9,8 +9,8 @@ import { loadMessageBundle } from 'vscode-nls';
const localize = loadMessageBundle();
export default class MergeConflictCodeLensProvider implements vscode.CodeLensProvider, vscode.Disposable {
private codeLensRegistrationHandle: vscode.Disposable | null;
private config: interfaces.IExtensionConfiguration;
private codeLensRegistrationHandle?: vscode.Disposable | null;
private config?: interfaces.IExtensionConfiguration;
private tracker: interfaces.IDocumentMergeConflictTracker;
constructor(trackerService: interfaces.IDocumentMergeConflictTrackerService) {

View File

@@ -3,8 +3,6 @@
* Licensed under the Source EULA. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
import * as nls from 'vscode-nls';
nls.config(process.env.VSCODE_NLS_CONFIG)();
import * as vscode from 'vscode';
import MergeConflictServices from './services';

View File

@@ -7,13 +7,13 @@ import * as interfaces from './interfaces';
import { loadMessageBundle } from 'vscode-nls';
const localize = loadMessageBundle();
export default class MergeDectorator implements vscode.Disposable {
export default class MergeDecorator implements vscode.Disposable {
private decorations: { [key: string]: vscode.TextEditorDecorationType } = {};
private decorationUsesWholeLine: boolean = true; // Useful for debugging, set to false to see exact match ranges
private config: interfaces.IExtensionConfiguration;
private config?: interfaces.IExtensionConfiguration;
private tracker: interfaces.IDocumentMergeConflictTracker;
private updating = new Map<vscode.TextEditor, boolean>();
@@ -210,7 +210,7 @@ export default class MergeDectorator implements vscode.Disposable {
}
});
if (this.config.enableDecorations) {
if (this.config!.enableDecorations) {
pushDecoration('current.header', { range: conflict.current.header });
pushDecoration('splitter', { range: conflict.splitter });
pushDecoration('incoming.header', { range: conflict.incoming.header });
@@ -249,4 +249,4 @@ export default class MergeDectorator implements vscode.Disposable {
}
});
}
}
}

View File

@@ -6,21 +6,6 @@
version "8.0.33"
resolved "https://registry.yarnpkg.com/@types/node/-/node-8.0.33.tgz#1126e94374014e54478092830704f6ea89df04cd"
applicationinsights@0.18.0:
version "0.18.0"
resolved "https://registry.yarnpkg.com/applicationinsights/-/applicationinsights-0.18.0.tgz#162ebb48a383408bc4de44db32b417307f45bbc1"
vscode-extension-telemetry@0.0.8:
version "0.0.8"
resolved "https://registry.yarnpkg.com/vscode-extension-telemetry/-/vscode-extension-telemetry-0.0.8.tgz#2261bff986b6690a6f1f746a45ac5bd1f85d29e0"
dependencies:
applicationinsights "0.18.0"
winreg "1.2.3"
vscode-nls@^2.0.2:
version "2.0.2"
resolved "https://registry.yarnpkg.com/vscode-nls/-/vscode-nls-2.0.2.tgz#808522380844b8ad153499af5c3b03921aea02da"
winreg@1.2.3:
version "1.2.3"
resolved "https://registry.yarnpkg.com/winreg/-/winreg-1.2.3.tgz#93ad116b2696da87d58f7265a8fcea5254a965d5"
vscode-nls@^3.2.1:
version "3.2.1"
resolved "https://registry.yarnpkg.com/vscode-nls/-/vscode-nls-3.2.1.tgz#b1f3e04e8a94a715d5a7bcbc8339c51e6d74ca51"