soywiki 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/soywiki.rb +1 -1
- data/lib/soywiki.vim +12 -5
- metadata +2 -2
data/lib/soywiki.rb
CHANGED
data/lib/soywiki.vim
CHANGED
@@ -207,11 +207,18 @@ func! s:delete_page()
|
|
207
207
|
let file = bufname('%')
|
208
208
|
let bufnr = bufnr('%')
|
209
209
|
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
210
|
+
if winnr('$') == 1
|
211
|
+
" we need a buffer to replace this one with
|
212
|
+
" go to previous buffer
|
213
|
+
let next_window = bufnr('#')
|
214
|
+
if next_window == -1
|
215
|
+
" TODO this fails to execute
|
216
|
+
call s:load_page("main.HomePage", 0)
|
217
|
+
else
|
218
|
+
exec ":b".next_window
|
219
|
+
endif
|
220
|
+
wincmd p
|
221
|
+
endif
|
215
222
|
|
216
223
|
echo system("git rm " . file)
|
217
224
|
call system("git commit " . file . " -m 'deletion'")
|