Skip to content

:AttachFile doesn't correctly handle filenames containing blank spaces #2

@daaugusto

Description

@daaugusto
Dear Christian Brabandt,

First of all, thank you for developing such a useful Vim plugin!

I would like to contribute a little bit by reporting a bug I have encountered.
The issue occurs when I attach a file with spaces in its name via :AttachFile.
Suppose I have the following file in /tmp:

   /tmp/file with space.txt

Typing 

   :AttachFile /tmp/file<tab>

results in

   :AttachFile /tmp/file\ with\ space.txt

Then, when I press <enter>, CheckAttach adds the following malformed pseudo
headers

   Attach: space.txt
   Attach: with\\
   Attach: /tmp/file\\

instead of just adding

   Attach: /tmp/file\ with\ space.txt

Out of curiosity, the plugin behaves correctly if I type

   :AttachFile /tmp/file*<enter>

(without trying tab completion)

I'm using CheckAttach-0.13 (download from www.vim.org).

Thank you.


Best regards,

-- 
Douglas A. Augusto

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions