def GitAdd(args: string) const current_dir = getcwd() try chdir(expand('%:p:h')) echoh MoreMsg echo 'git add --dry-run ' .. args const list = system('git add --dry-run ' .. args) if !!v:shell_error echoh ErrorMsg echo list return endif if !list echo 'none.' return endif for item in split(list, '\n') execute 'echoh' (item =~# '^remove' ? 'DiffDelete' : 'DiffAdd') echo item endfor echoh Question if