Skip to content

Commit 4549bd2

Browse files
authored
Extract diff language into its own extension (microsoft#136967)
1 parent 81cf536 commit 4549bd2

File tree

11 files changed

+78
-53
lines changed

11 files changed

+78
-53
lines changed

extensions/diff/.vscodeignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
build/**
2+
cgmanifest.json

extensions/diff/cgmanifest.json

+32
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
{
2+
"registrations": [
3+
{
4+
"component": {
5+
"type": "git",
6+
"git": {
7+
"name": "textmate/diff.tmbundle",
8+
"repositoryUrl": "https://github.com/textmate/diff.tmbundle",
9+
"commitHash": "0593bb775eab1824af97ef2172fd38822abd97d7"
10+
}
11+
},
12+
"licenseDetail": [
13+
"Copyright (c) textmate-diff.tmbundle project authors",
14+
"",
15+
"If not otherwise specified (see below), files in this repository fall under the following license:",
16+
"",
17+
"Permission to copy, use, modify, sell and distribute this",
18+
"software is granted. This software is provided \"as is\" without",
19+
"express or implied warranty, and with no claim as to its",
20+
"suitability for any purpose.",
21+
"",
22+
"An exception is made for files in readable text which contain their own license information,",
23+
"or files where an accompanying file exists (in the same directory) with a \"-license\" suffix added",
24+
"to the base-name name of the original file, and an extension of txt, html, or similar. For example",
25+
"\"tidy\" is accompanied by \"tidy-license.txt\"."
26+
],
27+
"license": "TextMate Bundle License",
28+
"version": "0.0.0"
29+
}
30+
],
31+
"version": 1
32+
}

extensions/git/languages/diff.language-configuration.json renamed to extensions/diff/language-configuration.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@
88
["[", "]"],
99
["(", ")"]
1010
]
11-
}
11+
}

extensions/diff/package.json

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
{
2+
"name": "diff",
3+
"displayName": "%displayName%",
4+
"description": "%description%",
5+
"version": "1.0.0",
6+
"publisher": "vscode",
7+
"license": "MIT",
8+
"engines": {
9+
"vscode": "0.10.x"
10+
},
11+
"scripts": {
12+
"update-grammar": "node ../node_modules/vscode-grammar-updater/bin textmate/diff.tmbundle Syntaxes/Diff.plist ./syntaxes/diff.tmLanguage.json"
13+
},
14+
"contributes": {
15+
"languages": [
16+
{
17+
"id": "diff",
18+
"aliases": [
19+
"Diff",
20+
"diff"
21+
],
22+
"extensions": [
23+
".diff",
24+
".patch",
25+
".rej"
26+
],
27+
"configuration": "./language-configuration.json"
28+
}
29+
],
30+
"grammars": [
31+
{
32+
"language": "diff",
33+
"scopeName": "source.diff",
34+
"path": "./syntaxes/diff.tmLanguage.json"
35+
}
36+
]
37+
}
38+
}

extensions/diff/package.nls.json

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"displayName": "Diff Language Basics",
3+
"description": "Provides syntax highlighting & bracket matching in Diff files."
4+
}

extensions/git/build/update-grammars.js

-6
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,3 @@ var updateGrammar = require('vscode-grammar-updater');
88

99
updateGrammar.update('textmate/git.tmbundle', 'Syntaxes/Git%20Commit%20Message.tmLanguage', './syntaxes/git-commit.tmLanguage.json');
1010
updateGrammar.update('textmate/git.tmbundle', 'Syntaxes/Git%20Rebase%20Message.tmLanguage', './syntaxes/git-rebase.tmLanguage.json');
11-
updateGrammar.update('textmate/diff.tmbundle', 'Syntaxes/Diff.plist', './syntaxes/diff.tmLanguage.json');
12-
13-
14-
15-
16-

extensions/git/cgmanifest.json

+1-28
Original file line numberDiff line numberDiff line change
@@ -33,34 +33,7 @@
3333
],
3434
"license": "MIT",
3535
"version": "0.0.0"
36-
},
37-
{
38-
"component": {
39-
"type": "git",
40-
"git": {
41-
"name": "textmate/diff.tmbundle",
42-
"repositoryUrl": "https://github.com/textmate/diff.tmbundle",
43-
"commitHash": "0593bb775eab1824af97ef2172fd38822abd97d7"
44-
}
45-
},
46-
"licenseDetail": [
47-
"Copyright (c) textmate-diff.tmbundle project authors",
48-
"",
49-
"If not otherwise specified (see below), files in this repository fall under the following license:",
50-
"",
51-
"Permission to copy, use, modify, sell and distribute this",
52-
"software is granted. This software is provided \"as is\" without",
53-
"express or implied warranty, and with no claim as to its",
54-
"suitability for any purpose.",
55-
"",
56-
"An exception is made for files in readable text which contain their own license information,",
57-
"or files where an accompanying file exists (in the same directory) with a \"-license\" suffix added",
58-
"to the base-name name of the original file, and an extension of txt, html, or similar. For example",
59-
"\"tidy\" is accompanied by \"tidy-license.txt\"."
60-
],
61-
"license": "TextMate Bundle License",
62-
"version": "0.0.0"
6336
}
6437
],
6538
"version": 1
66-
}
39+
}

extensions/git/package.json

-18
Original file line numberDiff line numberDiff line change
@@ -2314,19 +2314,6 @@
23142314
],
23152315
"configuration": "./languages/git-rebase.language-configuration.json"
23162316
},
2317-
{
2318-
"id": "diff",
2319-
"aliases": [
2320-
"Diff",
2321-
"diff"
2322-
],
2323-
"extensions": [
2324-
".diff",
2325-
".patch",
2326-
".rej"
2327-
],
2328-
"configuration": "./languages/diff.language-configuration.json"
2329-
},
23302317
{
23312318
"id": "ignore",
23322319
"aliases": [
@@ -2351,11 +2338,6 @@
23512338
"scopeName": "text.git-rebase",
23522339
"path": "./syntaxes/git-rebase.tmLanguage.json"
23532340
},
2354-
{
2355-
"language": "diff",
2356-
"scopeName": "source.diff",
2357-
"path": "./syntaxes/diff.tmLanguage.json"
2358-
},
23592341
{
23602342
"language": "ignore",
23612343
"scopeName": "source.ignore",

0 commit comments

Comments
 (0)