Skip to content

Unable to open files with dollar ($) character #863

Closed

Description

@daniele-orlando

MacVim: 8.1.950 (155)

MacVim is unable to open a file when it is invoked from Finder with a file name or a parent directory contains the character $.
Example: project/$config/main.yml

Steps to reproduce

  1. mkdir -p 'test/$config'
  2. echo "test" > 'test/$config/test.txt'
  3. open -a Finder .
  4. From Finder, try to open the file with MacVim double clicking the file name (the file type must be associated with MacVim)

or download the attached archive.

Expected result

test.txt file should open inside MacVim displaying test content.

Actual result

MacVim opens a not existing file test//test.txt displaying an empty content.

Activity

  1. ychin commented on Feb 22, 2019

    @ychin
    Member

    Hmm I'm having some issues reproducing this. It almost seems to me that someone is doing a variable substitution for $config here. What if you just name your file test_$_file and test_$var_file?

    Also, what OS are you using? Does this not happen if you load the file from command line (i.e. mvim <filename>)? Do you have any plugins that you think could interfere with this?

  2. daniele-orlando commented on Feb 22, 2019

    @daniele-orlando
    Author

    The problem arises when the dollar sign is in the directory name.
    To reproduce, please follow literally the Steps to reproduce or download the attached archive.

  3. ychin commented on Feb 23, 2019

    @ychin
    Member

    Yes I did follow the steps literally which is why I asked the followup questions to help identify why I couldn't reproduce the issue. Did you have a chance to test whether file names with $ work?

    Also, what macOS version are you using? Did you only see this issue when you double click on the file or when you drag the file to the dock's icon too?

    Edit: Actually, nevermind. I reproduced it! I will need to take a look.

  4. daniele-orlando commented on Feb 23, 2019

    @daniele-orlando
    Author

    Yes, file names with $ character work as expected, no problem with them.

  5. added this to the snapshot-156 milestone on Feb 23, 2019
  6. added a commit that references this issue on May 22, 2019
    4ef03ed
  7. added a commit that references this issue on Jun 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions