Skip to content

Commit

Permalink
Release/0.0.1 (#2)
Browse files Browse the repository at this point in the history
* feat(extension): initialize extension

* feat(extension): update readme and scripts

* feat(extension): add publisher information

* feat(color): add first syntax coloring elements

* feat(arrow): add double = arrow support

* feat(server): disable server diagnostic

* feat(color): better syntax coloring

* feat(color): syntax coloring in text granules

* feat(color): better inner text granule coloring

* feat(code): document and improve packaging process

* fix(map) remove map files

* feat(gitignore) add vsix and map files

* feat(packaging) update dependencies
  • Loading branch information
alacambre-yseop authored and wjeanniard-yseop committed May 14, 2018
1 parent 4b1aeb3 commit c6c7e17
Show file tree
Hide file tree
Showing 45 changed files with 23,840 additions and 1 deletion.
67 changes: 67 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# Typescript v1 declaration files
typings/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env

# next.js build output
.next

# map
*.map

# vsix
*.vsix
32 changes: 32 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"version": "0.2.0",
// List of configurations. Add new configurations or edit existing ones.
"configurations": [
{
"name": "Launch Client",
"type": "extensionHost",
"request": "launch",
"runtimeExecutable": "${execPath}",
"args": [
"--extensionDevelopmentPath=${workspaceRoot}/client"
],
"stopOnEntry": false,
"sourceMaps": true,
"outFiles": [
"${workspaceRoot}/client/out/**/*.js"
],
"preLaunchTask": "watch:client"
},
{
"name": "Attach to Server",
"type": "node",
"request": "attach",
"port": 6009,
"sourceMaps": true,
"outFiles": [
"${workspaceRoot}/client/server/**/*.js"
],
"preLaunchTask": "watch:server"
}
]
}
15 changes: 15 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
// set to false to hide directory from the VS Code Document Sidebar
"files.exclude": {
"client/out/**/*": false,
"client/server/**/*": false,
"client/node_modules": false,
"server/node_modules": false
},
// set this to false to include "out" folder in search results
"search.exclude": {
"out": true
},
"typescript.tsdk": "./node_modules/typescript/lib",
"typescript.tsc.autoDetect": "off"
}
79 changes: 79 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
{
"version": "2.0.0",
"tasks": [
{
"taskName": "compile",
"dependsOn": [
"compile:client",
"compile:server"
],
"problemMatcher": []
},
{
"label": "compile:client",
"type": "npm",
"script": "compile:client",
"group": "build",
"presentation": {
"panel": "dedicated",
"reveal": "never"
},
"problemMatcher": [
"$tsc"
]
},
{
"label": "compile:server",
"type": "npm",
"script": "compile:server",
"group": "build",
"presentation": {
"panel": "dedicated",
"reveal": "never"
},
"problemMatcher": [
"$tsc"
]
},
{
"taskName": "watch",
"dependsOn": [
"watch:client",
"watch:server"
],
"group": {
"kind": "build",
"isDefault": true
},
"problemMatcher": []
},
{
"label": "watch:client",
"type": "npm",
"script": "watch:client",
"isBackground": true,
"group": "build",
"presentation": {
"panel": "dedicated",
"reveal": "never"
},
"problemMatcher": [
"$tsc-watch"
]
},
{
"label": "watch:server",
"type": "npm",
"script": "watch:server",
"isBackground": true,
"group": "build",
"presentation": {
"panel": "dedicated",
"reveal": "never"
},
"problemMatcher": [
"$tsc-watch"
]
}
]
}
1 change: 1 addition & 0 deletions License.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
(c) Copyright 2018 Yseop, all rights reserved.
49 changes: 48 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,48 @@
# vscode-yseopml
# README

## This is the README for the "vscode-yseopml" project

-------------------

This folder contains the VS code extension that runs a YML (Yseop Markup Language) language server

The extension observes all 'yml' documents (documents from all editors associated to YML language - kao files, yclass files, etc.)
and uses the server to provide validation and completion proposals.

The code for the extension is in the 'client' folder. It uses the 'vscode-languageclient' node module to launch the language server.

The language server is located in the 'server' folder.

## How to run locally

* `npm install` to initialize the extension and the server
* `npm run compile` to compile the extension and the server
* open this folder in VS Code. In the Debug viewlet, run 'Launch Client' from drop-down to launch the extension and attach to the extension.
* open `test.kao` which is in the `client/test` folder. You should see some validation errors.
* to debug the server use the 'Attach to Server' launch config.
* set breakpoints in the client or the server.

## How to generate antlr4 files

* if not already the case, install `ANTLR tool` as explained [here](http://www.antlr.org/download.html) and [here](https://github.com/antlr/antlr4/blob/master/doc/getting-started.md)
* modify `YmlToBdl.g4` grammar file
* `npm run antlr4ts` to generate tokens, lexer and parser files

## How to update Syntax Coloring

In order to update the syntax coloring, you must modify the file `yml.tmLanguage.json` accordingly to the [TextMate Manual](http://manual.macromates.com/en/language_grammars#language_grammars).

The format available in this manual is a little bit different than the one we are using (json). However it is easy to understand how to change it to fit our needs.

## Package the extension

Do the following in your terminal:

```[bash]
npm install
npm run compile
cd client
vsce package
```

You should now have a new file with `.vsix` file extension. This is the packaged extension to provide for installation.
31 changes: 31 additions & 0 deletions ThirdPartyNotices.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
THIRD-PARTY SOFTWARE NOTICES AND INFORMATION
For Microsoft vscode-languageserver-node-example

This project incorporates material from the project(s) listed below (collectively, “Third Party Code”).
Microsoft is not the original author of the Third Party Code. The original copyright notice and license
under which Microsoft received such Third Party Code are set out below. This Third Party Code is licensed
to you under their original license terms set forth below. Microsoft reserves all other rights not expressly
granted, whether by implication, estoppel or otherwise.

1. DefinitelyTyped version 0.0.1 (https://github.com/borisyankov/DefinitelyTyped)

This project is licensed under the MIT license.
Copyrights are respective of each contributor listed at the beginning of each definition file.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
9 changes: 9 additions & 0 deletions client/.vscodeignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
.vscode/**
typings/**
out/test/**
test/**
src/**
**/*.map
.gitignore
tsconfig.json
vsc-extension-quickstart.md
16 changes: 16 additions & 0 deletions client/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Yseop Markup Language for VS Code

This extension provides a YseopML basic support for VS Code.

## Features

- Syntax coloring for classic code
- Syntax coloring for text granules and inside text granules
- Snippets for textualization objects, granules, class fields, instances
- Code folding

## Release Notes

### 0.0.1 (2018-05-02)

- Initial release
Binary file added client/images/compose-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 32 additions & 0 deletions client/language-configuration.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"comments": {
"lineComment": "//",
"blockComment": [ "/*", "*/" ]
},
"brackets": [
["{", "}"],
["[", "]"],
["\\(", "\\)"],
["<", ">"]
],
"autoClosingPairs": [
{ "open": "{", "close": "}" },
{ "open": "[", "close": "]" },
{ "open": "\\(", "close": "\\)" },
{ "open": "\\if", "close": "\n\\endIf" },
{ "open": "'", "close": "'", "notIn": ["string", "comment"] },
{ "open": "\"", "close": "\"", "notIn": ["string"] },
{ "open": "`", "close": "`", "notIn": ["string", "comment"] },
{ "open": "/**", "close": " */", "notIn": ["string"] }
],
"surroundingPairs": [
["{", "}"],
["[", "]"],
["(", ")"],
["<", ">"],
["'", "'"],
["\"", "\""],
["`", "`"],
["\\(", "\\)"]
]
}
39 changes: 39 additions & 0 deletions client/out/src/extension.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions client/out/src/extension.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit c6c7e17

Please sign in to comment.