1. Vim Notes
1.1. Stash Copy of File When Writing
The RT CLI clientautocmd BufWrite /tmp/rt.form.* w! <afile>-preserve
The
BufWrite adds a hook for any files names /tmp/rt.form.* that runs every time the file is written. The
<afile> is a Vim variable-like that is substituted for the name of the current file name; the -preserve is added to the end to differentiate it from the original file, which is deleted by the RT client. It is necessary to use w! instead of just w, otherwise you get an error after the first write due to the destination file already existing.
