From 5ad91806c8ace550977cef109f9d049e063bcad4 Mon Sep 17 00:00:00 2001 From: katauber Date: Wed, 2 Dec 2020 10:15:41 +0100 Subject: [PATCH 1/6] Add instructions to README how to install vsc extension. See https://github.com/metafacture/metafacture-fix/issues/25 --- README.md | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 358cd116..070fdad0 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,8 @@ Run the tests (in `org.metafacture.fix/src/test/java`) and checks (`.editorconfi ## Extension -The project `org.metafacture.fix.vsc` provides an extension for Visual Studio Code for `fix` via the language server protocol (LSP). In the current state the extension supports auto completion, simple syntax highlighting and auto closing brackets and quotes. This project was created using this [tutorial](https://www.typefox.io/blog/building-a-vs-code-extension-with-xtext-and-the-language-server-protocol) and the corresponding [example](https://github.com/TypeFox/languageserver-example). +The project `org.metafacture.fix.vsc` provides an extension for Visual Studio Code / Codium for `fix` via the language server protocol (LSP). In the current state the extension supports auto completion, simple syntax highlighting and auto closing brackets and quotes. This project was created using this [tutorial](https://www.typefox.io/blog/building-a-vs-code-extension-with-xtext-and-the-language-server-protocol) and the corresponding [example](https://github.com/TypeFox/languageserver-example). + Start extension (in development mode, starting a second code/codium instance): @@ -49,10 +50,24 @@ Unix: `./gradlew installServer` Windows: `.\gradlew.bat installServer` 4. In org.metafacture.fix.vsc execute (tip: if you use windows, install cygwin to execute npm commands): `npm install` -5. Open org.metafacture.fix.vsc in Visual Studio Code + +To start the extension in development mode, follow A. To create an vsix file to install the extension permanently follow B. + +A: +5. Open org.metafacture.fix.vsc in Visual Studio Code / Codium 6. Launch vscode extension by pressing F5 (opens new window of Visual Studio Code) 7. Open new file (file-ending .fix) or open existing fix-file (see sample below) +B: +5. Install vsce: `npm install -g vsce` +6. In org.metafacture.fix.vsc execute: `vsce package` +vsce will create a vsix file in the vsc directory which can be used for installation: +7. Open VS Code / Codium +8. Click 'Extensions' section +9. Click menu bar and choose 'Install from VSIX...' + + + ## Web Server Start the web server: From 81ded8203517a014b9e9de1b273ed17cab833bed Mon Sep 17 00:00:00 2001 From: katauber Date: Wed, 2 Dec 2020 10:16:45 +0100 Subject: [PATCH 2/6] Enrich information about fix extension in package.json. See https://github.com/metafacture/metafacture-fix/issues/25 --- org.metafacture.fix.vsc/package.json | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/org.metafacture.fix.vsc/package.json b/org.metafacture.fix.vsc/package.json index 8f4e7958..e6c5adcf 100644 --- a/org.metafacture.fix.vsc/package.json +++ b/org.metafacture.fix.vsc/package.json @@ -1,9 +1,9 @@ { "name": "fix", "displayName": "fix", - "description": "Fix Language Support (Xtext Language Server for Fix)", + "description": "Language Support for Metafacture Fix (Xtext Language Server for Metafacture Fix). For more information, visit https://metafacture.org", "version": "0.0.1", - "publisher": "katauber", + "publisher": "metafacture", "engines": { "vscode": "^1.18.0" }, @@ -47,5 +47,9 @@ }, "dependencies": { "vscode-languageclient": "^3.0.3" + }, + "repository": { + "type": "git", + "url": "https://github.com/metafacture/metafacture-fix.git" } } From 20259301f0c300c47f9af34ec8bd2e08f7ec075f Mon Sep 17 00:00:00 2001 From: katauber Date: Wed, 2 Dec 2020 10:28:17 +0100 Subject: [PATCH 3/6] Refactor 'Extension' section in README. See https://github.com/metafacture/metafacture-fix/issues/25 --- README.md | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 070fdad0..94c25da5 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,7 @@ Run the tests (in `org.metafacture.fix/src/test/java`) and checks (`.editorconfi The project `org.metafacture.fix.vsc` provides an extension for Visual Studio Code / Codium for `fix` via the language server protocol (LSP). In the current state the extension supports auto completion, simple syntax highlighting and auto closing brackets and quotes. This project was created using this [tutorial](https://www.typefox.io/blog/building-a-vs-code-extension-with-xtext-and-the-language-server-protocol) and the corresponding [example](https://github.com/TypeFox/languageserver-example). -Start extension (in development mode, starting a second code/codium instance): +Start extension: 1. Install Visual Studio Code / alternative: VS Codium 2. Install Node.js (including npm) @@ -51,20 +51,20 @@ Windows: `.\gradlew.bat installServer` 4. In org.metafacture.fix.vsc execute (tip: if you use windows, install cygwin to execute npm commands): `npm install` -To start the extension in development mode, follow A. To create an vsix file to install the extension permanently follow B. +To start the extension in development mode (starting a second code/codium instance), follow A. To create an vsix file to install the extension permanently follow B. A: -5. Open org.metafacture.fix.vsc in Visual Studio Code / Codium -6. Launch vscode extension by pressing F5 (opens new window of Visual Studio Code) -7. Open new file (file-ending .fix) or open existing fix-file (see sample below) +1. Open org.metafacture.fix.vsc in Visual Studio Code / Codium +2. Launch vscode extension by pressing F5 (opens new window of Visual Studio Code) +3. Open new file (file-ending .fix) or open existing fix-file (see sample below) B: -5. Install vsce: `npm install -g vsce` -6. In org.metafacture.fix.vsc execute: `vsce package` +1. Install vsce: `npm install -g vsce` +2. In org.metafacture.fix.vsc execute: `vsce package` vsce will create a vsix file in the vsc directory which can be used for installation: -7. Open VS Code / Codium -8. Click 'Extensions' section -9. Click menu bar and choose 'Install from VSIX...' +3. Open VS Code / Codium +4. Click 'Extensions' section +5. Click menu bar and choose 'Install from VSIX...' From 5e027fe635dba01ed682c76fe8784e7cc73b22fe Mon Sep 17 00:00:00 2001 From: Fabian Steeg Date: Fri, 4 Dec 2020 11:17:33 +0100 Subject: [PATCH 4/6] Minor tweaks to make README easier to skim --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 94c25da5..0e099433 100644 --- a/README.md +++ b/README.md @@ -41,7 +41,7 @@ Run the tests (in `org.metafacture.fix/src/test/java`) and checks (`.editorconfi The project `org.metafacture.fix.vsc` provides an extension for Visual Studio Code / Codium for `fix` via the language server protocol (LSP). In the current state the extension supports auto completion, simple syntax highlighting and auto closing brackets and quotes. This project was created using this [tutorial](https://www.typefox.io/blog/building-a-vs-code-extension-with-xtext-and-the-language-server-protocol) and the corresponding [example](https://github.com/TypeFox/languageserver-example). -Start extension: +Build extension: 1. Install Visual Studio Code / alternative: VS Codium 2. Install Node.js (including npm) @@ -53,12 +53,12 @@ Windows: `.\gradlew.bat installServer` To start the extension in development mode (starting a second code/codium instance), follow A. To create an vsix file to install the extension permanently follow B. -A: +A) Run in dev mode: 1. Open org.metafacture.fix.vsc in Visual Studio Code / Codium 2. Launch vscode extension by pressing F5 (opens new window of Visual Studio Code) 3. Open new file (file-ending .fix) or open existing fix-file (see sample below) -B: +B) Install vsix file: 1. Install vsce: `npm install -g vsce` 2. In org.metafacture.fix.vsc execute: `vsce package` vsce will create a vsix file in the vsc directory which can be used for installation: From d11cb48e9c520df798e316aa13a5b50a0c2e11b5 Mon Sep 17 00:00:00 2001 From: Fabian Steeg Date: Fri, 4 Dec 2020 11:18:27 +0100 Subject: [PATCH 5/6] Add generated *.vsix file to .gitignore --- .gitignore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index fa42e18c..82ce78fa 100644 --- a/.gitignore +++ b/.gitignore @@ -9,4 +9,4 @@ out/ node_modules/ xtext-server/ package-lock.json - +*.vsix From 360dee22d0bd682c906bae8cf35612e41f6119a0 Mon Sep 17 00:00:00 2001 From: Fabian Steeg Date: Fri, 4 Dec 2020 11:29:29 +0100 Subject: [PATCH 6/6] Ignore generated *.vsix file in editorconfig check --- build.gradle | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 1c17a8c7..01db0c04 100644 --- a/build.gradle +++ b/build.gradle @@ -11,7 +11,8 @@ editorconfig { '**/.*', 'gradlew*', '**/out', - '**/node_modules' + '**/node_modules', + '**/*.vsix' ] }