summary refs log tree commit diff
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2020-12-19 22:53:41 -0500
committerJune McEnroe <june@causal.agency>2020-12-19 22:53:41 -0500
commit43d3018ccda264bb6ccf28b646f74acee25c0db0 (patch)
tree192c7d1aad29639be37c9b881e144ed0d3e6fa6b
parentMove :RFC to plugin script (diff)
downloadsrc-43d3018ccda264bb6ccf28b646f74acee25c0db0.tar.gz
src-43d3018ccda264bb6ccf28b646f74acee25c0db0.zip
Convert :RFC number to number
This removes any leading zeros such as in rfc-index.txt.
-rw-r--r--home/.config/nvim/plugin/rfc.vim4
1 files changed, 2 insertions, 2 deletions
diff --git a/home/.config/nvim/plugin/rfc.vim b/home/.config/nvim/plugin/rfc.vim
index d0aac655..0c724492 100644
--- a/home/.config/nvim/plugin/rfc.vim
+++ b/home/.config/nvim/plugin/rfc.vim
@@ -3,12 +3,12 @@ if !exists('g:rfc_path')
 endif
 
 function! s:RFC(number)
-	let number = (empty(a:number) ? '-index' : a:number)
+	let number = (empty(a:number) ? '-index' : str2nr(a:number, 10))
 	let path = expand(g:rfc_path . '/rfc' . number . '.txt.gz')
 	if filereadable(path)
 		execute 'silent' 'noswapfile' 'view' path
 	else
-		echohl ErrorMsg | echo 'No such RFC' number | echohl None
+		echohl ErrorMsg | echo 'No such RFC' a:number | echohl None
 	endif
 endfunction
 
'/cgit-pink/commit/ui-stats.c?h=1.4.1&id=2eea471a7821f1f8bf2a4ce61bb748dcb9f7fa17&follow=1'>ui-stats.c: set parent pointer to NULL after freeing itJohn Keeping 2014-07-28git: update to v2.0.3John Keeping 2014-07-28parsing.c: make commit buffer constJohn Keeping 2014-06-30Bump version.Jason A. Donenfeld 2014-06-29remove debug fprinf() calls that sneaked in with commit 79c985Christian Hesse 2014-06-28git: update to 2.0.1Christian Hesse 2014-06-28ui-patch: Flush stdout after outputting dataJohn Keeping 2014-06-28ui-log: ignore unhandled argumentsJohn Keeping 2014-06-28git: update for git 2.0Christian Hesse 2014-04-17remove trailing whitespaces from source filesChristian Hesse 2014-04-12git: update to 1.9.2Christian Hesse 2014-04-05Fix cgit_parse_url when a repo url is contained in another repo urlJulian Maurice 2014-03-20Makefile: use more reliable git tarball mirrorJason A. Donenfeld 2014-03-20git: update to 1.9.1Christian Hesse