1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-01-23 12:50:04 +08:00

Add lang#vbnet layer (#3359)

This commit is contained in:
Wang Shidong 2020-02-18 20:00:22 +08:00 committed by GitHub
parent 61843684c9
commit 523669337d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 115 additions and 1 deletions

View File

@ -0,0 +1,35 @@
"=============================================================================
" vbnet.vim --- Visual Basic .NET support
" Copyright (c) 2016-2019 Wang Shidong & Contributors
" Author: Wang Shidong < wsdjeg@outlook.com >
" URL: https://spacevim.org
" License: GPLv3
"=============================================================================
function! SpaceVim#layers#lang#vbnet#plugins() abort
let plugins = []
call add(plugins, ['wsdjeg/vim-vbnet', { 'merged' : 0}])
return plugins
endfunction
function! SpaceVim#layers#lang#vbnet#config() abort
call SpaceVim#plugins#runner#reg_runner('vbnet', ['vbc /utf8output /nologo /out:#TEMP# %s', '#TEMP#'])
call SpaceVim#mapping#space#regesit_lang_mappings('vbnet', function('s:language_specified_mappings'))
augroup SpaceVim_lang_vbnet
au!
au! BufRead,BufNewFile *.vb setfiletype vbnet
augroup END
endfunction
function! s:language_specified_mappings() abort
call SpaceVim#mapping#space#langSPC('nmap', ['l','r'], 'call SpaceVim#plugins#runner#open()', 'execute current file', 1)
endf
" ref:
" Making Vim to work in Visual Basic
" http://www.vbforums.com/showthread.php?405230-Making-Vim-to-work-in-Visual-Basic
" Folding like in Visual Basic .NET
" https://vim.fandom.com/wiki/Folding_like_in_Visual_Basic_.NET
" https://github.com/vim-scripts/VB.NET-Syntax
" https://github.com/vim-scripts/vbnet.vim
" http://www.viemu.com/viemu-vi-vim-visual-studio.html

View File

@ -154,6 +154,7 @@ Vim 插件以及相关配置。而 SpaceVim 是以模块的方式来组织和管
| [lang#tcl](lang/tcl/) | 这一模块为 Tcl 开发提供支持,包括交互式编程、一键运行等特性。 |
| [lang#typescript](lang/typescript/) | 这一模块为 SpaceVim 提供了 TypeScript 的开发支持,包括代码补全、语法检查、代码格式化等特性。 |
| [lang#v](lang/v/) | 这一模块为 v 开发提供支持,包括交互式编程、一键运行等特性。 |
| [lang#vbnet](lang/vbnet/) | 这一模块为 Visual Basic .NET 开发提供支持,包括交互式编程、一键运行等特性。 |
| [lang#vim](lang/vim/) | 这一模块为 SpaceVim 提供了 Vimscript 的开发支持,包括代码补全、语法检查、代码格式化等特性。 |
| [lang#vue](lang/vue/) | 这一模块为 SpaceVim 提供了 Vue 的的开发支持,包括代码补全、语法检查、代码格式化等特性。 |
| [lang#wolfram](lang/wolfram/) | 这一模块为 wolfram 开发提供支持,包括交互式编程、一键运行等特性。 |

View File

@ -0,0 +1,38 @@
---
title: "SpaceVim lang#vbnet 模块"
description: "这一模块为 Visual Basic .NET 开发提供支持,包括交互式编程、一键运行等特性。"
lang: zh
---
# [可用模块](../../) >> lang#vbnet
<!-- vim-markdown-toc GFM -->
- [模块简介](#模块简介)
- [启用模块](#启用模块)
- [快捷键](#快捷键)
- [编译并运行](#编译并运行)
<!-- vim-markdown-toc -->
## 模块简介
这一模块为在 SpaceVim 中进行 Visual Basic .NET 开发提供了支持。
## 启用模块
可通过在配置文件内加入如下配置来启用该模块:
```toml
[[layers]]
name = "lang#vbnet"
```
## 快捷键
### 编译并运行
在编辑 Visual Basic .NET 文件时,可通过快捷键 `SPC l r` 快速异步运行当前文件,
运行结果会展示在一个独立的执行窗口内。

View File

@ -165,6 +165,7 @@ Some layers are enabled by default. The following example shows how to disable `
| [lang#tcl](lang/tcl/) | This layer is for Tcl development, provide syntax checking, code runner and repl support for tcl file. |
| [lang#typescript](lang/typescript/) | This layer is for TypeScript development, includding code completion, Syntax lint, and doc generation. |
| [lang#v](lang/v/) | This layer is for v development, provide syntax checking, code runner and repl support for v file. |
| [lang#vbnet](lang/vbnet/) | This layer is for Visual Basic .NET development, provide code runner vb file. |
| [lang#vim](lang/vim/) | This layer is for writting Vimscript, including code completion, syntax checking and buffer formatting |
| [lang#vue](lang/vue/) | This layer adds Vue language support to SpaceVim |
| [lang#wolfram](lang/wolfram/) | This layer is for walfram development, provide syntax checking, code runner and repl support for walfram file. |

39
docs/layers/lang/vbnet.md Normal file
View File

@ -0,0 +1,39 @@
---
title: "SpaceVim lang#vbnet layer"
description: "This layer is for Visual Basic .NET development, provide code runner vb file."
---
# [Available Layers](../../) >> lang#vbnet
<!-- vim-markdown-toc GFM -->
- [Description](#description)
- [Install](#install)
- [Features](#features)
- [Key bindings](#key-bindings)
- [Running current script](#running-current-script)
<!-- vim-markdown-toc -->
## Description
This layer is for Visual Basic .NET development.
## Install
To use this configuration layer, update custom configuration file with:
```toml
[[layers]]
name = "lang#vbnet"
```
## Features
- code runner
## Key bindings
### Running current script
To running a Visual Basic .NET file, you can press `SPC l r` to run current file without loss focus, and the result will be shown in a runner buffer.

View File

@ -60,6 +60,7 @@
| Swift | [lang#swift](https://spacevim.org/layers/lang/swift/) |
| Tcl | [lang#tcl](https://spacevim.org/layers/lang/tcl/) |
| TypeScript | [lang#typescript](https://spacevim.org/layers/lang/typescript/) |
| Visual Basic .NET | [lang#vbnet](https://spacevim.org/layers/lang/vbnet/) |
| zig | [lang#zig](https://spacevim.org/layers/lang/zig/) |
| 4th Dimension | |
| ABAP | |
@ -246,7 +247,6 @@
| VBScript | |
| Verilog | |
| VHDL | |
| Visual Basic .NET | |
| Visual Basic | |
| WebAssembly | |
| WebDNA | |