init
This commit is contained in:
2
.gitattributes
vendored
Normal file
2
.gitattributes
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
# Set default behavior to automatically normalize line endings.
|
||||
* text=auto
|
||||
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
node_modules
|
||||
*.vsix
|
||||
17
.vscode/launch.json
vendored
Normal file
17
.vscode/launch.json
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
// A launch configuration that launches the extension inside a new window
|
||||
// Use IntelliSense to learn about possible attributes.
|
||||
// Hover to view descriptions of existing attributes.
|
||||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
|
||||
{
|
||||
"version": "0.2.0",
|
||||
"configurations": [
|
||||
{
|
||||
"name": "Extension",
|
||||
"type": "extensionHost",
|
||||
"request": "launch",
|
||||
"args": [
|
||||
"--extensionDevelopmentPath=${workspaceFolder}"
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
4
.vscodeignore
Normal file
4
.vscodeignore
Normal file
@@ -0,0 +1,4 @@
|
||||
.vscode/**
|
||||
.vscode-test/**
|
||||
.gitignore
|
||||
vsc-extension-quickstart.md
|
||||
9
CHANGELOG.md
Normal file
9
CHANGELOG.md
Normal file
@@ -0,0 +1,9 @@
|
||||
# Change Log
|
||||
|
||||
All notable changes to the "lsi-syntax-support" extension will be documented in this file.
|
||||
|
||||
Check [Keep a Changelog](http://keepachangelog.com/) for recommendations on how to structure this file.
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
- Initial release
|
||||
65
README.md
Normal file
65
README.md
Normal file
@@ -0,0 +1,65 @@
|
||||
# lsi-syntax-support README
|
||||
|
||||
This is the README for your extension "lsi-syntax-support". After writing up a brief description, we recommend including the following sections.
|
||||
|
||||
## Features
|
||||
|
||||
Describe specific features of your extension including screenshots of your extension in action. Image paths are relative to this README file.
|
||||
|
||||
For example if there is an image subfolder under your extension project workspace:
|
||||
|
||||
\!\[feature X\]\(images/feature-x.png\)
|
||||
|
||||
> Tip: Many popular extensions utilize animations. This is an excellent way to show off your extension! We recommend short, focused animations that are easy to follow.
|
||||
|
||||
## Requirements
|
||||
|
||||
If you have any requirements or dependencies, add a section describing those and how to install and configure them.
|
||||
|
||||
## Extension Settings
|
||||
|
||||
Include if your extension adds any VS Code settings through the `contributes.configuration` extension point.
|
||||
|
||||
For example:
|
||||
|
||||
This extension contributes the following settings:
|
||||
|
||||
* `myExtension.enable`: Enable/disable this extension.
|
||||
* `myExtension.thing`: Set to `blah` to do something.
|
||||
|
||||
## Known Issues
|
||||
|
||||
Calling out known issues can help limit users opening duplicate issues against your extension.
|
||||
|
||||
## Release Notes
|
||||
|
||||
Users appreciate release notes as you update your extension.
|
||||
|
||||
### 1.0.0
|
||||
|
||||
Initial release of ...
|
||||
|
||||
### 1.0.1
|
||||
|
||||
Fixed issue #.
|
||||
|
||||
### 1.1.0
|
||||
|
||||
Added features X, Y, and Z.
|
||||
|
||||
---
|
||||
|
||||
## Working with Markdown
|
||||
|
||||
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.
|
||||
|
||||
## 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/)
|
||||
|
||||
**Enjoy!**
|
||||
39
language-configuration.json
Normal file
39
language-configuration.json
Normal file
@@ -0,0 +1,39 @@
|
||||
{
|
||||
"brackets": [
|
||||
["[", "]"],
|
||||
["(", ")"]
|
||||
],
|
||||
"autoClosingPairs": [
|
||||
{"open": "[", "close": "]"},
|
||||
{"open": "(", "close": ")"}
|
||||
],
|
||||
"surroundingPairs": [
|
||||
{"open": "[", "close": "]"},
|
||||
{"open": "(", "close": ")"},
|
||||
{"open": "\"", "close": "\""},
|
||||
{"open": "'", "close": "'"}
|
||||
],
|
||||
"wordPattern": "[a-zA-Z_]+",
|
||||
"tokenizer": {
|
||||
"root": [
|
||||
["[a-zA-Z_]+", {
|
||||
"cases": {
|
||||
"@comments": "comment",
|
||||
"@default": "identifier"
|
||||
}
|
||||
}],
|
||||
["\\b(Integer|Double|Float)\\b", "type.identifier"],
|
||||
["[0-9]+", "number"],
|
||||
["\\[", "bracket.square.open"],
|
||||
["\\]", "bracket.square.close"],
|
||||
["\\(", "bracket.parenthesis.open"],
|
||||
["\\)", "bracket.parenthesis.close"],
|
||||
["\\{", "bracket.curly.open"],
|
||||
["\\}", "bracket.curly.close"],
|
||||
["[\\+\\-\\*\\/\\.=\\=\\<=\\>=]", "keyword.operator"], // Incluidos operadores
|
||||
["\\b(min|max|sum|in)\\b", "keyword"],
|
||||
["\\b([a-z][A-Za-z0-9_]*)\\b", "variable.other.local"],
|
||||
["\\.\\s*([a-z][A-Za-z0-9_]*)", "method"]
|
||||
]
|
||||
}
|
||||
}
|
||||
25
package.json
Normal file
25
package.json
Normal file
@@ -0,0 +1,25 @@
|
||||
{
|
||||
"name": "lsi-syntax-support",
|
||||
"displayName": "LSI Syntax Support",
|
||||
"description": "Helps visualizing files using LSI Syntax created by LSI department at University of Seville",
|
||||
"version": "0.0.1",
|
||||
"engines": {
|
||||
"vscode": "^1.87.0"
|
||||
},
|
||||
"categories": [
|
||||
"Programming Languages"
|
||||
],
|
||||
"contributes": {
|
||||
"languages": [{
|
||||
"id": "lsi",
|
||||
"aliases": ["LSI", "lsi"],
|
||||
"extensions": [".lsi"],
|
||||
"configuration": "./language-configuration.json"
|
||||
}],
|
||||
"grammars": [{
|
||||
"language": "lsi",
|
||||
"scopeName": "source.lsi",
|
||||
"path": "./syntaxes/lsi.tmLanguage.json"
|
||||
}]
|
||||
}
|
||||
}
|
||||
64
syntaxes/lsi.tmLanguage.json
Normal file
64
syntaxes/lsi.tmLanguage.json
Normal file
@@ -0,0 +1,64 @@
|
||||
{
|
||||
"$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",
|
||||
"name": "LSI",
|
||||
"patterns": [
|
||||
{
|
||||
"include": "#keywords"
|
||||
},
|
||||
{
|
||||
"include": "#types"
|
||||
},
|
||||
{
|
||||
"include": "#variables"
|
||||
},
|
||||
{
|
||||
"include": "#methods"
|
||||
},
|
||||
{
|
||||
"include": "#operators"
|
||||
}
|
||||
],
|
||||
"repository": {
|
||||
"keywords": {
|
||||
"patterns": [
|
||||
{
|
||||
"name": "keyword.control.lsi",
|
||||
"match": "\\b(head section|goal section|constraints section|bounds section|int|bin|min|max|sum|in)\\b"
|
||||
}
|
||||
]
|
||||
},
|
||||
"types": {
|
||||
"patterns": [
|
||||
{
|
||||
"name": "support.type.lsi",
|
||||
"match": "\\b(Integer|Double|Float)\\b"
|
||||
}
|
||||
]
|
||||
},
|
||||
"variables": {
|
||||
"patterns": [
|
||||
{
|
||||
"name": "variable.other.local.lsi",
|
||||
"match": "\\b([a-z][A-Za-z0-9_]*)\\b"
|
||||
}
|
||||
]
|
||||
},
|
||||
"methods": {
|
||||
"patterns": [
|
||||
{
|
||||
"name": "entity.name.function.lsi",
|
||||
"match": "\\.[\\s]*([a-z][A-Za-z0-9_]*)"
|
||||
}
|
||||
]
|
||||
},
|
||||
"operators": {
|
||||
"patterns": [
|
||||
{
|
||||
"name": "keyword.operator.lsi",
|
||||
"match": "\\b(\\+|\\-|\\*|\\/|\\<=|\\>=|\\..|\\=)\\b"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"scopeName": "source.lsi"
|
||||
}
|
||||
29
vsc-extension-quickstart.md
Normal file
29
vsc-extension-quickstart.md
Normal file
@@ -0,0 +1,29 @@
|
||||
# Welcome to your VS Code Extension
|
||||
|
||||
## 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/lsi.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 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
|
||||
|
||||
## Install your extension
|
||||
|
||||
* To start using your extension with Visual Studio Code copy it into the `<user home>/.vscode/extensions` folder and restart Code.
|
||||
* To share your extension with the world, read on https://code.visualstudio.com/docs about publishing an extension.
|
||||
Reference in New Issue
Block a user