-
Notifications
You must be signed in to change notification settings - Fork 7
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
CSV auto-detection does not work when "A File Icon" package is enabled #25
Comments
Hello, This could happen because your file doesn't have ".csv" extension AND is very small ( < 5 lines ) - I decided to add this threshold to avoid false-positive auto-detection. I will try to make this value adjustable in the next version so you can set it to 3 lines. Also it could be that the number of fields in the file is not consistent and extension is not ".csv", in this case autodetection will also fail: you can manually enable highlighting, and then run CSVLint to check if there is anything wrong with the file. |
I recorded my sublime text 3 with the CSV example above, those files are CSV files and they have more than 5 lines. https://drive.google.com/open?id=1cMCb33xryoLgoPdB_L8wecmMfCjVesoS |
Thank you very much for providing the recording! I've noticed that the filetype in the bottom lower corner is "Plain Text (CSV)" and not "Rainbow CSV". I searched github for name: Plain Text (CSV) and found "A File Icon" plugin. I had no idea that it declares it's own "Plain Text (CSV)" filetype. I will try to adjust Rainbow CSV code to correctly work together with "A File Icon" plugin, at the first glance it shouldn't be hard. Or maybe I will contact "A File Icon" authors. I am afraid that until this filetype conflict is resolved there is no way to use Rainbow ".csv" auto-detection feature together with "A File Icon" plugin. Ironically auto-detection would have worked if your files had some other non '.csv' extension e.g. '.txt' because in that case "A File Icon" would not assign it's own "Plain Text (CSV)" |
Ok thank you for the investigation. I will wait for the fix because I really like your package! |
…Icon" package as plain text for autodetection purposes
@jeremyfourna I fixed interop with "A File Icon" in version 2.2.0. |
Hello,
I have CSV file like this
But when I open the CSV in sublime text, there is not an auto highlight, which value should I put inside
rainbow_csv_autodetect_dialects
to have it highlighted?The text was updated successfully, but these errors were encountered: