Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

file extensions not working #146

Closed
rickmed opened this issue Aug 5, 2016 · 12 comments
Closed

file extensions not working #146

rickmed opened this issue Aug 5, 2016 · 12 comments
Assignees
Labels

Comments

@rickmed
Copy link

rickmed commented Aug 5, 2016

vscode 1.4
win 10 x64

I have this

    // Configure file associations to languages (e.g. "*.extension": "html"). These have precedence over the default associations of the languages installed.
    "files.associations": {
        "*.js?": "javascript",
        "*.es": "javascript"
    },

    "vsicons.useFileAssociations": true,

Actual behaviour:
only .js files are "iconized"

image

@jens1o
Copy link
Member

jens1o commented Aug 6, 2016

Can confirm it.
This does not work. (I just don't recognized.)
http://prntscr.com/c26rpi

VSCode 1.4 Stable.
Windows 10 64x

(Disable and Re-Enable it does not help.)

@robertohuertasm
Copy link
Member

My bad... First of all, no regular expression or glob patterns are supported. Second, I didn't really think about file associations already having its own convention (they use "javascript" instead of "js" for associations) so this won't work. I will fix it asap and let you know 😞 The only way for this to work at the moment would be this:

"*.es": "js"

But as I said, wait for the fix. 😉

@robertohuertasm
Copy link
Member

I've just published 1.5.6 that will fix this. Still not supporting complex patterns but will cover the most common scenarios.

To use it, you won't be using file.associations anymore but a custom property inside vsicons:

{
  "vsicons": {
     "useFileAssociations": true,
      "associations":{
        "*.cc": "css"
      }
    }
}

In your case, first case is not supported at the moment, but I will try to implement it if possible 😉

@rickmed
Copy link
Author

rickmed commented Aug 6, 2016

@robertohuertasm updated but does not seem to be working for me.

in user settings.json

// VS Icons

  "vsicons": {
     "useFileAssociations": true,
      "associations":{
        "*.es": "js"
      }
    }

the options does not appear on the workspace settings (not sure if relevant)

same environment as above

@robertohuertasm
Copy link
Member

You're right, now only supported extensions will work... . es is not in the list of supported extensions so it won't be considered.

I'll try to fix it tonight. Sorry for the inconveniences!

@robertohuertasm robertohuertasm self-assigned this Aug 6, 2016
@robertohuertasm robertohuertasm modified the milestones: Next version, Solve Bugs Aug 6, 2016
@robertohuertasm
Copy link
Member

It's already fixed. #152
Will be released soon in a major version with other enhancements.

@chai2010
Copy link

chai2010 commented Aug 7, 2016

@robertohuertasm great work, thanks!

@robertohuertasm
Copy link
Member

Already released in 1.6.0

@rickmed
Copy link
Author

rickmed commented Aug 7, 2016

@robertohuertasm does not work for me. Same config as above (also tried several extensions values

@robertohuertasm
Copy link
Member

Please, read the new readme as this has changed to support regular expressions.

@rickmed
Copy link
Author

rickmed commented Aug 7, 2016

@robertohuertasm Tried a bunch of configs until I hit the update command 😅

@robertohuertasm
Copy link
Member

@rickmed thanks for your feedback. I'll update the readme to make it more explicit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants