improvements

This commit is contained in:
csh 2025-06-14 22:04:33 +08:00
parent 40634c2fda
commit 4c50938bff
13 changed files with 4241 additions and 70 deletions

2
.gitignore vendored
View File

@ -1 +1 @@
vscode/tsl-syntax/node_modules
vscode/node_modules

View File

@ -1,12 +1,20 @@
# TSL Syntax
# TSL Devkit
该插件提供 tsl 语言的语法高亮
## VSCode
### 安装方式一
### 安装方式一(推荐)
复制[tsl-syntax](./vscode/tsl-syntax/)文件夹到`VSCode`扩展目录
安装[vsix](./vscode/tsl-devkit-1.0.0.vsix)扩展
```txt
code --install-extension tsl-devkit-1.0.0.vsix
```
### 安装方式二
复制[vscode](./vscode)文件夹到`VSCode`扩展目录(建议更改文件夹名)
```txt
Windows: %USERPROFILE%\.vscode\extensions
@ -14,12 +22,16 @@ macOS: ~/.vscode/extensions
Linux: ~/.vscode/extensions
```
### 安装方式
### 安装方式
安装[vsix](./vscode/tsl-syntax/tsl-syntax-1.0.0.vsix)扩展
本项目`vscode`目录下执行
```txt
code --install-extension tsl-syntax-1.0.0.vsix
```bash
npm install
npx vsce package
# 安装
code --install-extension tsl-devkit-1.0.0.vsix
```
## Vim
@ -27,6 +39,6 @@ code --install-extension tsl-syntax-1.0.0.vsix
将[tsl.vim](./vim/tsl.vim)放入`~/.vim/syntax/`
```vim
" 你的vimrc加入可同时支持tsl和tsf
" vimrc加入可同时支持tsl和tsf
autocmd BufNewFile,BufRead *.ts[lf] setf tsl
```

0
vscode/CHANGELOG.md Normal file
View File

0
vscode/LICENSE.txt Normal file
View File

3
vscode/README.md Normal file
View File

@ -0,0 +1,3 @@
# TSL
`VSCode``ts[lf]`语法插件

View File

Before

Width:  |  Height:  |  Size: 2.3 KiB

After

Width:  |  Height:  |  Size: 2.3 KiB

4204
vscode/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff

View File

@ -1,17 +1,22 @@
{
"name": "tsl-syntax",
"displayName": "TSL Syntax",
"description": "Syntax highlighting for tsl/tsf files",
"version": "1.0.0",
"name": "tsl-devkit",
"displayName": "TSL",
"version": "1.1.0",
"description": "TSL syntax highlighter support for VSCode.",
"publisher": "csh",
"homepage": "https://git.mytsl.cn/csh/tsl-syntax",
"homepage": "https://git.mytsl.cn/csh/tsl-devkit",
"author": {
"name": "csh"
},
"scripts": {},
"repository": {
"type": "git",
"url": "https://git.mytsl.cn/csh/tsl-syntax"
"url": "https://git.mytsl.cn/csh/tsl-devkit"
},
"bugs": {
"url": "https://git.mytsl.cn/csh/tsl-syntax/issues"
"url": "https://git.mytsl.cn/csh/tsl-devkit/issues"
},
"license": "Please see LICENSE.txt",
"icon": "images/ts.png",
"categories": [
"Programming Languages"
@ -39,7 +44,6 @@
}
]
},
"scripts": {},
"devDependencies": {
"@types/vscode": "^1.101.0",
"@vscode/vsce": "^3.5.0",
@ -48,4 +52,4 @@
"engines": {
"vscode": "^1.101.0"
}
}
}

View File

@ -1,12 +0,0 @@
# TSL Syntax
`VSCode``ts[lf]`语法插件
## 编译&安装
```bash
npm install
vsce package
code --install-extension tsl-syntax-1.0.0.vsix
```

View File

@ -1,40 +0,0 @@
{
"name": "tsl-syntax",
"version": "1.0.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "tsl-syntax",
"version": "1.0.0",
"devDependencies": {
"@types/vscode": "^1.101.0",
"typescript": "^5.8.3"
},
"engines": {
"vscode": "^1.101.0"
}
},
"node_modules/@types/vscode": {
"version": "1.101.0",
"resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.101.0.tgz",
"integrity": "sha512-ZWf0IWa+NGegdW3iU42AcDTFHWW7fApLdkdnBqwYEtHVIBGbTu0ZNQKP/kX3Ds/uMJXIMQNAojHR4vexCEEz5Q==",
"dev": true,
"license": "MIT"
},
"node_modules/typescript": {
"version": "5.8.3",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-5.8.3.tgz",
"integrity": "sha512-p1diW6TqL9L07nNxvRMM7hMMw4c5XOo/1ibL4aAIGmSAt9slTE1Xgw5KWuof2uTOvCg9BY7ZRi+GaF+7sfgPeQ==",
"dev": true,
"license": "Apache-2.0",
"bin": {
"tsc": "bin/tsc",
"tsserver": "bin/tsserver"
},
"engines": {
"node": ">=14.17"
}
}
}
}