|
|
df7669 |
--- vim70/runtime/ftplugin/spec.vim.rh1 2006-05-10 19:37:45.000000000 +0200
|
|
|
df7669 |
+++ vim70/runtime/ftplugin/spec.vim 2006-11-13 12:21:32.000000000 +0100
|
|
|
df7669 |
@@ -18,11 +18,18 @@
|
|
|
df7669 |
|
|
|
df7669 |
if !exists("*s:SpecChangelog")
|
|
|
df7669 |
function s:SpecChangelog(format)
|
|
|
df7669 |
+ let save_time = v:lc_time
|
|
|
df7669 |
if strlen(a:format) == 0
|
|
|
df7669 |
if !exists("g:spec_chglog_format")
|
|
|
df7669 |
- let email = input("Email address: ")
|
|
|
df7669 |
- let g:spec_chglog_format = "%a %b %d %Y " . l:email
|
|
|
df7669 |
- echo "\r"
|
|
|
df7669 |
+ if !exists("g:packager")
|
|
|
df7669 |
+ let email = input("Email address: ")
|
|
|
df7669 |
+ let g:spec_chglog_format = "%a %b %d %Y " . l:email
|
|
|
df7669 |
+ echo "\r"
|
|
|
df7669 |
+ else
|
|
|
df7669 |
+ let email = g:packager
|
|
|
df7669 |
+ let g:spec_chglog_format = "%a %b %d %Y " . l:email
|
|
|
df7669 |
+ echo "\r"
|
|
|
df7669 |
+ endif
|
|
|
df7669 |
endif
|
|
|
df7669 |
let format = g:spec_chglog_format
|
|
|
df7669 |
else
|
|
|
df7669 |
@@ -58,7 +65,7 @@
|
|
|
df7669 |
let line = line+1
|
|
|
df7669 |
endwhile
|
|
|
df7669 |
if (nameline != -1 && verline != -1 && relline != -1)
|
|
|
df7669 |
- let include_release_info = exists("g:spec_chglog_release_info")
|
|
|
df7669 |
+ let include_release_info = 1
|
|
|
df7669 |
let name = s:ParseRpmVars(name, nameline)
|
|
|
df7669 |
let ver = s:ParseRpmVars(ver, verline)
|
|
|
df7669 |
let rel = s:ParseRpmVars(rel, relline)
|
|
|
df7669 |
@@ -79,8 +86,10 @@
|
|
|
df7669 |
endif
|
|
|
df7669 |
endif
|
|
|
df7669 |
if (chgline != -1)
|
|
|
df7669 |
+ execute "language time C"
|
|
|
df7669 |
let parsed_format = "* ".strftime(format)
|
|
|
df7669 |
- let release_info = "+ ".name."-".ver."-".rel
|
|
|
df7669 |
+ execute "language time " . save_time
|
|
|
df7669 |
+ let release_info = ver."-".rel
|
|
|
df7669 |
let wrong_format = 0
|
|
|
df7669 |
let wrong_release = 0
|
|
|
df7669 |
let insert_line = 0
|
|
|
df7669 |
@@ -97,15 +106,14 @@
|
|
|
df7669 |
execute relline
|
|
|
df7669 |
normal ?
|
|
|
df7669 |
let rel = substitute(strpart(getline(relline),8), '^[ ]*\([^ ]\+\)[ ]*$','\1','')
|
|
|
df7669 |
- let release_info = "+ ".name."-".ver."-".rel
|
|
|
df7669 |
+ let release_info = ver."-".rel
|
|
|
df7669 |
endif
|
|
|
df7669 |
endif
|
|
|
df7669 |
let n = 0
|
|
|
df7669 |
- call append(chgline+n, parsed_format)
|
|
|
df7669 |
if include_release_info
|
|
|
df7669 |
- let n = n + 1
|
|
|
df7669 |
- call append(chgline+n, release_info)
|
|
|
df7669 |
+ let parsed_format = parsed_format." ".release_info
|
|
|
df7669 |
endif
|
|
|
df7669 |
+ call append(chgline+n, parsed_format)
|
|
|
df7669 |
let n = n + 1
|
|
|
df7669 |
call append(chgline+n,"- ")
|
|
|
df7669 |
let n = n + 1
|