Skip to content
This repository has been archived by the owner on Jan 27, 2025. It is now read-only.

Commit

Permalink
Align subproject layout with metafacture-core. (#71)
Browse files Browse the repository at this point in the history
  • Loading branch information
blackwinter committed Nov 15, 2021
1 parent 6349bca commit 90021c2
Show file tree
Hide file tree
Showing 63 changed files with 18 additions and 17 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,15 @@ Go to the Git repository root:

`cd metafacture-fix/`

Run the tests (in `org.metafacture.fix/src/test/java`) and checks (`.editorconfig`, `config/checkstyle/checkstyle.xml`):
Run the tests (in `metafix/src/test/java`) and checks (`.editorconfig`, `config/checkstyle/checkstyle.xml`):

`./gradlew clean check`

(To import the projects in Eclipse, choose File > Import > Existing Gradle Project and select the `metafacture-fix` directory.)

## Extension

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).
The project `metafix-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).


Build extension:
Expand All @@ -44,19 +44,19 @@ Build extension:
3. In metafacture-fix execute:
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):
4. In `metafix-vsc/` execute (tip: if you use windows, install cygwin to execute npm commands):
`npm install`

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) Run in dev mode:
1. Open org.metafacture.fix.vsc in Visual Studio Code / Codium
1. Open `metafix-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)
3. Open new file (file-ending `.fix`) or open existing fix-file (see sample below)

B) Install vsix file:
1. Install vsce: `npm install -g vsce`
2. In org.metafacture.fix.vsc execute: `vsce package`
2. In `metafix-vsc/` execute: `vsce package`
vsce will create a vsix file in the vsc directory which can be used for installation:
3. Open VS Code / Codium
4. Click 'Extensions' section
Expand Down
6 changes: 3 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ subprojects {
}

task installServer(type: Copy) {
dependsOn(':org.metafacture.fix.ide:installDist')
from "org.metafacture.fix.ide/build/install/xtext-server"
into "org.metafacture.fix.vsc/xtext-server"
dependsOn(':metafix-ide:installDist')
from "metafix-ide/build/install/xtext-server"
into "metafix-vsc/xtext-server"
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ plugins {

dependencies {
implementation project(':metafix')
implementation project(':org.metafacture.fix.ide')
implementation project(':metafix-ide')

implementation "org.eclipse.xtend:org.eclipse.xtend.lib:${versions.xtext}"
implementation "org.eclipse.xtext:org.eclipse.xtext.web.servlet:${versions.xtext}"
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,16 @@ Workflow {
component = XtextGenerator {
configuration = {
project = StandardProjectConfig {
baseName = "org.metafacture.fix"
baseName = "metafix"
rootPath = ".."
runtimeTest = {
enabled = true
}
genericIde = {
name = "metafix-ide"
}
web = {
name = "metafix-web"
enabled = true
}
mavenLayout = true
Expand Down
9 changes: 3 additions & 6 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
include 'org.metafacture.fix'
include 'org.metafacture.fix.ide'
include 'org.metafacture.fix.web'

// change subproject name
project(":org.metafacture.fix").name = "metafix"
include 'metafix'
include 'metafix-ide'
include 'metafix-web'

0 comments on commit 90021c2

Please sign in to comment.