Merge branch 'release/v1.1.0'
This commit is contained in:
commit
83005361b6
4 changed files with 30 additions and 2 deletions
10
README.md
10
README.md
|
@ -12,6 +12,13 @@ with a .cpp or .h file as filename to open a new tab containing a vertical split
|
||||||
with the corresponding header file in the left window and the corresponding
|
with the corresponding header file in the left window and the corresponding
|
||||||
source file in the right window.
|
source file in the right window.
|
||||||
|
|
||||||
|
Use
|
||||||
|
|
||||||
|
:Split
|
||||||
|
|
||||||
|
to open the corresponding heder or source file to your currently open file in
|
||||||
|
a vertical split.
|
||||||
|
|
||||||
## Configuration
|
## Configuration
|
||||||
|
|
||||||
You can configure the following settings:
|
You can configure the following settings:
|
||||||
|
@ -41,6 +48,9 @@ SplitOpen is GPL-3.0 licensed. See LICENSE file for more info.
|
||||||
|
|
||||||
## Changelog
|
## Changelog
|
||||||
|
|
||||||
|
v1.1.0
|
||||||
|
* Added Split() command
|
||||||
|
|
||||||
v1.0.0
|
v1.0.0
|
||||||
* Fixed error when reloading plugin
|
* Fixed error when reloading plugin
|
||||||
|
|
||||||
|
|
|
@ -49,8 +49,7 @@ function s:addRightSplit(filename)
|
||||||
execute("wincmd h")
|
execute("wincmd h")
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! splitopen#SplitOpenFile(filename)
|
function s:splitOpenFile(filename)
|
||||||
execute("tabedit " . a:filename)
|
|
||||||
let extension = s:getFileExtension(a:filename)
|
let extension = s:getFileExtension(a:filename)
|
||||||
if s:isLeftSideExtension(extension)
|
if s:isLeftSideExtension(extension)
|
||||||
call s:addRightSplit(a:filename)
|
call s:addRightSplit(a:filename)
|
||||||
|
@ -58,3 +57,12 @@ function! splitopen#SplitOpenFile(filename)
|
||||||
call s:addLeftSplit(a:filename)
|
call s:addLeftSplit(a:filename)
|
||||||
endif
|
endif
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
function! splitopen#SplitOpenFile(filename)
|
||||||
|
execute("tabedit " . a:filename)
|
||||||
|
call s:splitOpenFile(a:filename)
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! splitopen#SplitFile()
|
||||||
|
call s:splitOpenFile(expand("%:p"))
|
||||||
|
endfunction
|
||||||
|
|
|
@ -21,6 +21,13 @@ with a .cpp or .h file as filename to open a new tab containing a vertical split
|
||||||
with the corresponding header file in the left window and the corresponding
|
with the corresponding header file in the left window and the corresponding
|
||||||
source file in the right window.
|
source file in the right window.
|
||||||
|
|
||||||
|
Use
|
||||||
|
|
||||||
|
:Split
|
||||||
|
|
||||||
|
to open the corresponding heder or source file to your currently open file in
|
||||||
|
a vertical split.
|
||||||
|
|
||||||
================================================================================
|
================================================================================
|
||||||
2. Configuration *SplitOpenConfiguration*
|
2. Configuration *SplitOpenConfiguration*
|
||||||
|
|
||||||
|
@ -55,6 +62,8 @@ SplitOpen is GPL-3.0 licensed. See LICENSE file for more info.
|
||||||
================================================================================
|
================================================================================
|
||||||
4. Changelog *SplitOpenChangelog*
|
4. Changelog *SplitOpenChangelog*
|
||||||
|
|
||||||
|
v1.1.0
|
||||||
|
* Added Split() command
|
||||||
v1.0.0
|
v1.0.0
|
||||||
* Fixed error when reloading plugin
|
* Fixed error when reloading plugin
|
||||||
v0.0.4
|
v0.0.4
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
command! -nargs=1 SplitOpen :call splitopen#SplitOpenFile("<args>")
|
command! -nargs=1 SplitOpen :call splitopen#SplitOpenFile("<args>")
|
||||||
|
command! Split :call splitopen#SplitFile()
|
||||||
|
|
||||||
" map left-split / right-split file extensions
|
" map left-split / right-split file extensions
|
||||||
if !exists("g:splitopen_extensions")
|
if !exists("g:splitopen_extensions")
|
||||||
|
|
Loading…
Reference in a new issue