1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-02-03 01:40:05 +08:00

Add gist manager gista (#1936)

* Add gist manager

* Add gista key bindings

* Add key binding for post gist

* Update doc and wiki
This commit is contained in:
Wang Shidong 2018-07-14 11:37:00 +08:00 committed by GitHub
parent cd7bfdf939
commit f99801a88a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 23 additions and 10 deletions

View File

@ -39,7 +39,7 @@ let s:separators = {
\ }
let s:i_separators = {
\ 'arrow' : ["\ue0b1", "\ue0b3"],
\ 'bar' : ["|", "|"],
\ 'bar' : ['|', '|'],
\ 'nil' : ['', ''],
\ }
let s:loaded_modes = []
@ -331,6 +331,9 @@ function! SpaceVim#layers#core#statusline#get(...) abort
if &filetype ==# 'vimfiler'
return '%#SpaceVim_statusline_ia#' . s:winnr(1) . '%#SpaceVim_statusline_ia_SpaceVim_statusline_b#' . s:lsep
\ . '%#SpaceVim_statusline_b# vimfiler %#SpaceVim_statusline_b_SpaceVim_statusline_c#' . s:lsep . ' '
elseif &filetype ==# 'gista-list'
return '%#SpaceVim_statusline_ia#' . s:winnr(1) . '%#SpaceVim_statusline_ia_SpaceVim_statusline_b#' . s:lsep
\ . '%#SpaceVim_statusline_b# Gista %#SpaceVim_statusline_b_SpaceVim_statusline_c#' . s:lsep . ' '
elseif &filetype ==# 'startify'
try
call fugitive#detect(getcwd())

View File

@ -34,6 +34,7 @@ function! SpaceVim#layers#github#plugins() abort
\ 'on_cmd': ['OpenGithubFile', 'OpenGithubIssue', 'OpenGithubPullReq'],
\ }],
\ ['wsdjeg/GitHub-api.vim', {'merged' : 0}],
\ ['lambdalisue/vim-gista', {'merged' : 0}],
\ ]
endfunction
@ -43,6 +44,13 @@ function! SpaceVim#layers#github#config() abort
\ 'name' : '+VersionControl/git',
\ })
let g:_spacevim_mappings_space.g.h = { 'name': '+GitHub' }
let g:_spacevim_mappings_space.g.g = { 'name': '+Gist' }
" @todo remove the username
call SpaceVim#mapping#space#def('nnoremap', ['g', 'g', 'l'], 'Gista list -u wsdjeg',
\ 'list gist', 1)
call SpaceVim#mapping#space#def('nnoremap', ['g', 'g', 'p'], 'Gista post',
\ 'post selection or current file', 1, 1)
"" jaxbot/github-issues.vim {{{
" Disable completion by github-issues.vim. Because github-complete.vim

View File

@ -29,11 +29,12 @@ To use this configuration layer, add following snippet to your custom configurat
## Key bindings
| Key Binding | Description |
| ----------- | ------------------------------------ |
| ----------- | ---------------------------- |
| `SPC g h i` | show issues |
| `SPC g h a` | show activities |
| `SPC g h d` | show dashboard |
| `SPC g h f` | show current file in browser |
| `SPC g h I` | show issues in browser |
| `SPC g h p` | show PRs in browser |
| `SPC g g l` | list all gist |
| `SPC g g p` | post gist |

View File

@ -14,6 +14,7 @@ The next release is v0.9.0.
- Add lsp support for typescript ([#1870](https://github.com/SpaceVim/SpaceVim/pull/1870))
- Add option for disabling parentheses autocompletion ([#1920](https://github.com/SpaceVim/SpaceVim/pull/1920))
- Add Docker build of Neovim and SpaceVim ([#1923](https://github.com/SpaceVim/SpaceVim/pull/1923))
- Add gist manager vim-gista ([#1936](https://github.com/SpaceVim/SpaceVim/pull/1936))
### Improvement