From 5d20adfd8b6b6827d9ca89e749185a0655de9981 Mon Sep 17 00:00:00 2001 From: Stuart Date: Wed, 11 Jan 2023 18:35:15 +1030 Subject: [PATCH] feat: add repository label to package.json format all code --- CHANGELOG.md | 2 +- README.md | 14 +++---- language-configuration.json | 70 +++++++++++++++++++++++++++------- package-lock.json | 15 ++++++++ package.json | 38 ++++++++++++------ syntaxes/ccini.tmLanguage.json | 10 +++-- vsc-extension-quickstart.md | 26 ++++++------- 7 files changed, 124 insertions(+), 51 deletions(-) create mode 100644 package-lock.json diff --git a/CHANGELOG.md b/CHANGELOG.md index aeb3343..d1dc3e4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,4 +6,4 @@ Check [Keep a Changelog](http://keepachangelog.com/) for recommendations on how ## [Unreleased] -- Initial release \ No newline at end of file +- Initial release diff --git a/README.md b/README.md index a492cc0..326eaf4 100644 --- a/README.md +++ b/README.md @@ -24,8 +24,8 @@ For example: This extension contributes the following settings: -* `myExtension.enable`: Enable/disable this extension. -* `myExtension.thing`: Set to `blah` to do something. +- `myExtension.enable`: Enable/disable this extension. +- `myExtension.thing`: Set to `blah` to do something. ## Known Issues @@ -53,13 +53,13 @@ Added features X, Y, and Z. You can author your README using Visual Studio Code. Here are some useful editor keyboard shortcuts: -* Split the editor (`Cmd+\` on macOS or `Ctrl+\` on Windows and Linux). -* Toggle preview (`Shift+Cmd+V` on macOS or `Shift+Ctrl+V` on Windows and Linux). -* Press `Ctrl+Space` (Windows, Linux, macOS) to see a list of Markdown snippets. +- Split the editor (`Cmd+\` on macOS or `Ctrl+\` on Windows and Linux). +- Toggle preview (`Shift+Cmd+V` on macOS or `Shift+Ctrl+V` on Windows and Linux). +- Press `Ctrl+Space` (Windows, Linux, macOS) to see a list of Markdown snippets. ## For more information -* [Visual Studio Code's Markdown Support](http://code.visualstudio.com/docs/languages/markdown) -* [Markdown Syntax Reference](https://help.github.com/articles/markdown-basics/) +- [Visual Studio Code's Markdown Support](http://code.visualstudio.com/docs/languages/markdown) +- [Markdown Syntax Reference](https://help.github.com/articles/markdown-basics/) **Enjoy!** diff --git a/language-configuration.json b/language-configuration.json index 8f162a0..07cc94f 100644 --- a/language-configuration.json +++ b/language-configuration.json @@ -3,28 +3,70 @@ // symbol used for single line comment. Remove this entry if your language does not support line comments "lineComment": "//", // symbols used for start and end a block comment. Remove this entry if your language does not support block comments - "blockComment": [ "/*", "*/" ] + "blockComment": [ + "/*", + "*/" + ] }, // symbols used as brackets "brackets": [ - ["{", "}"], - ["[", "]"], - ["(", ")"] + [ + "{", + "}" + ], + [ + "[", + "]" + ], + [ + "(", + ")" + ] ], // symbols that are auto closed when typing "autoClosingPairs": [ - ["{", "}"], - ["[", "]"], - ["(", ")"], - ["\"", "\""], - ["'", "'"] + [ + "{", + "}" + ], + [ + "[", + "]" + ], + [ + "(", + ")" + ], + [ + "\"", + "\"" + ], + [ + "'", + "'" + ] ], // symbols that can be used to surround a selection "surroundingPairs": [ - ["{", "}"], - ["[", "]"], - ["(", ")"], - ["\"", "\""], - ["'", "'"] + [ + "{", + "}" + ], + [ + "[", + "]" + ], + [ + "(", + ")" + ], + [ + "\"", + "\"" + ], + [ + "'", + "'" + ] ] } \ No newline at end of file diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..7e06cf2 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,15 @@ +{ + "name": "cortex-command-community-project-language-support", + "version": "0.0.1", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "cortex-command-community-project-language-support", + "version": "0.0.1", + "engines": { + "vscode": "^1.74.0" + } + } + } +} \ No newline at end of file diff --git a/package.json b/package.json index 486464b..4923bac 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,10 @@ "displayName": "Cortex Command Community Project Language Support", "description": "INI and Lua language support for development of content for the game Cortex Command", "version": "0.0.1", + "repository": { + "type": "git", + "url": "git+https://github.com/traunts/Cortex-Command-Community-Project-VSCode-Extension.git" + }, "engines": { "vscode": "^1.74.0" }, @@ -10,16 +14,26 @@ "Programming Languages" ], "contributes": { - "languages": [{ - "id": "ccini", - "aliases": ["INI (Cortex Command)", "ccini"], - "extensions": [".ini",".lua"], - "configuration": "./language-configuration.json" - }], - "grammars": [{ - "language": "ccini", - "scopeName": "source.ccini", - "path": "./syntaxes/ccini.tmLanguage.json" - }] + "languages": [ + { + "id": "ccini", + "aliases": [ + "INI (Cortex Command)", + "ccini" + ], + "extensions": [ + ".ini", + ".lua" + ], + "configuration": "./language-configuration.json" + } + ], + "grammars": [ + { + "language": "ccini", + "scopeName": "source.ccini", + "path": "./syntaxes/ccini.tmLanguage.json" + } + ] } -} +} \ No newline at end of file diff --git a/syntaxes/ccini.tmLanguage.json b/syntaxes/ccini.tmLanguage.json index cb88737..909f53c 100644 --- a/syntaxes/ccini.tmLanguage.json +++ b/syntaxes/ccini.tmLanguage.json @@ -11,10 +11,12 @@ ], "repository": { "keywords": { - "patterns": [{ - "name": "keyword.control.ccini", - "match": "\\b(if|while|for|return)\\b" - }] + "patterns": [ + { + "name": "keyword.control.ccini", + "match": "\\b(if|while|for|return)\\b" + } + ] }, "strings": { "name": "string.quoted.double.ccini", diff --git a/vsc-extension-quickstart.md b/vsc-extension-quickstart.md index 3b1c624..e5d46b1 100644 --- a/vsc-extension-quickstart.md +++ b/vsc-extension-quickstart.md @@ -2,28 +2,28 @@ ## What's in the folder -* This folder contains all of the files necessary for your extension. -* `package.json` - this is the manifest file in which you declare your language support and define the location of the grammar file that has been copied into your extension. -* `syntaxes/ccini.tmLanguage.json` - this is the Text mate grammar file that is used for tokenization. -* `language-configuration.json` - this is the language configuration, defining the tokens that are used for comments and brackets. +- This folder contains all of the files necessary for your extension. +- `package.json` - this is the manifest file in which you declare your language support and define the location of the grammar file that has been copied into your extension. +- `syntaxes/ccini.tmLanguage.json` - this is the Text mate grammar file that is used for tokenization. +- `language-configuration.json` - this is the language configuration, defining the tokens that are used for comments and brackets. ## Get up and running straight away -* Make sure the language configuration settings in `language-configuration.json` are accurate. -* Press `F5` to open a new window with your extension loaded. -* Create a new file with a file name suffix matching your language. -* Verify that syntax highlighting works and that the language configuration settings are working. +- Make sure the language configuration settings in `language-configuration.json` are accurate. +- Press `F5` to open a new window with your extension loaded. +- Create a new file with a file name suffix matching your language. +- Verify that syntax highlighting works and that the language configuration settings are working. ## Make changes -* You can relaunch the extension from the debug toolbar after making changes to the files listed above. -* You can also reload (`Ctrl+R` or `Cmd+R` on Mac) the VS Code window with your extension to load your changes. +- You can relaunch the extension from the debug toolbar after making changes to the files listed above. +- You can also reload (`Ctrl+R` or `Cmd+R` on Mac) the VS Code window with your extension to load your changes. ## Add more language features -* To add features such as IntelliSense, hovers and validators check out the VS Code extenders documentation at https://code.visualstudio.com/docs +- To add features such as IntelliSense, hovers and validators check out the VS Code extenders documentation at https://code.visualstudio.com/docs ## Install your extension -* To start using your extension with Visual Studio Code copy it into the `/.vscode/extensions` folder and restart Code. -* To share your extension with the world, read on https://code.visualstudio.com/docs about publishing an extension. +- To start using your extension with Visual Studio Code copy it into the `/.vscode/extensions` folder and restart Code. +- To share your extension with the world, read on https://code.visualstudio.com/docs about publishing an extension.