vnews 0.3.1 → 0.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/README.markdown +19 -4
- data/lib/vnews.vim +16 -2
- data/lib/vnews/version.rb +1 -1
- metadata +2 -2
data/README.markdown
CHANGED
@@ -255,14 +255,12 @@ like so:
|
|
255
255
|
#!/bin/bash
|
256
256
|
lpr -o cpi=12 -o lpi=8 -o page-right=36 -o page-left=42 -o page-top=36 -o page-bottom=48 $1
|
257
257
|
|
258
|
-
|
258
|
+
Put this on your PATH. Then you can run this to print your concatenated
|
259
|
+
view:
|
259
260
|
|
260
261
|
:w !lprcustom
|
261
262
|
|
262
263
|
|
263
|
-
|
264
|
-
|
265
|
-
|
266
264
|
## Updating your feeds
|
267
265
|
|
268
266
|
Starting vnews with
|
@@ -290,6 +288,23 @@ hour:
|
|
290
288
|
|
291
289
|
This assumes that you installed Vnews through RVM and on Ruby 1.9.2.
|
292
290
|
|
291
|
+
## Reloading your item list
|
292
|
+
|
293
|
+
* `,r` and `r` reloads the item list
|
294
|
+
|
295
|
+
You might want to reload the item list that you're currently viewing
|
296
|
+
without fetching updates from over the internet. There are two reasons
|
297
|
+
you may want to do this:
|
298
|
+
|
299
|
+
* You updated your feeds in a background process since your Vnews
|
300
|
+
session started and you want to refresh your view of the items to
|
301
|
+
reflect the latest data in MySQL.
|
302
|
+
|
303
|
+
* You change the width of the Vim window displaying the item list. Vnews
|
304
|
+
can adjust the column widths to fit your new window width if you reload
|
305
|
+
your item list.
|
306
|
+
|
307
|
+
|
293
308
|
|
294
309
|
## OPML import
|
295
310
|
|
data/lib/vnews.vim
CHANGED
@@ -26,9 +26,15 @@ let s:cat_items_command = s:client_script . 'cat_items '
|
|
26
26
|
|
27
27
|
let s:folder = "All"
|
28
28
|
let s:feed = "All"
|
29
|
-
|
29
|
+
|
30
|
+
func! s:get_selection_name()
|
30
31
|
let end_index = match(s:last_selection, '(\d\+)$')
|
31
32
|
let selection = s:last_selection[0:end_index-1]
|
33
|
+
return selection
|
34
|
+
endfunc
|
35
|
+
|
36
|
+
function! VnewsStatusLine()
|
37
|
+
let selection = s:get_selection_name()
|
32
38
|
return "%<%f\ " . s:selectiontype . " " . selection . "%r%=%-14.(%l,%c%V%)\ %P"
|
33
39
|
endfunction
|
34
40
|
|
@@ -49,6 +55,8 @@ function! s:common_mappings()
|
|
49
55
|
nnoremap <buffer> <leader>3 :call <SID>delete_item()<CR>
|
50
56
|
nnoremap <buffer> u :call <SID>update_feed()<CR>
|
51
57
|
nnoremap <buffer> <leader>u :call <SID>update_feed()<CR>
|
58
|
+
nnoremap <buffer> r :call <SID>reload_feed()<CR>
|
59
|
+
nnoremap <buffer> <leader>r :call <SID>reload_feed()<CR>
|
52
60
|
nnoremap <silent> <leader>? :call <SID>show_help()<cr>
|
53
61
|
command! -bar -nargs=0 VNUpdateFeed :call <SID>update_feed()
|
54
62
|
command! -bar -nargs=1 VNSearch :call s:search_items(<f-args>)
|
@@ -475,8 +483,14 @@ func! s:update_feed()
|
|
475
483
|
end
|
476
484
|
redraw!
|
477
485
|
normal G
|
478
|
-
|
486
|
+
endfunc
|
487
|
+
|
488
|
+
func! s:reload_feed()
|
489
|
+
if exists("s:last_selection")
|
490
|
+
call s:fetch_items(s:last_selection)
|
491
|
+
end
|
479
492
|
redraw!
|
493
|
+
echom "Reloaded ". s:get_selection_name()
|
480
494
|
endfunc
|
481
495
|
|
482
496
|
|
data/lib/vnews/version.rb
CHANGED