Page 1 of 1

"contents contain" rules with .csv files?

PostPosted: Thu Oct 01, 2020 2:00 pm
by gcoghill
I see two older posts with conflicting info about matching rules to the contents of a CSV file:

This post implies that .csv files are Excel docs, but that's not the case. This later post suggests converting Excel files to .csv in order to get Hazel to read its contents.

But if the earlier post is correct, then .csv files are not recognized by Hazel.

Either way, Hazel is not matching content for .csv files, and these were downloaded from Amazon and other various online services, not exported from or created in Excel.

It's my understanding that the .csv format is a plain text/ASCII format, so Hazel should be able to read these as-is, rather than require the workaround in the first post linked above (changing the file extension to .txt and then back to .csv after rules have been run).

Am I missing something about the .csv format, and why Hazel cannot open them as-is? I was under the impression that CSV format was specifically intended to be a text-based format independent of proprietary software. Seems Hazel should be able to read them if it can read .txt files.

Curious which of the above is the correct approach to .csv files.

Re: "contents contain" rules with .csv files?

PostPosted: Thu Oct 01, 2020 2:05 pm
by gcoghill
OK so it seems Hazel is indeed matching content for the .csv file, but for some reason it is not recognizing the text.

Usually in these cases, copying the content right from the error window popup will fix this, because there may be some invisible characters that are causing the mis-match. But that's not working here.

Image

Re: "contents contain" rules with .csv files?

PostPosted: Fri Oct 02, 2020 10:26 am
by Mr_Noodle
You might want to use "contain match" instead of "contain". The latter uses Spotlight which either may not be indexing the file or may have a problem with a multi-word phrase.

Re: "contents contain" rules with .csv files?

PostPosted: Mon Oct 05, 2020 1:15 pm
by gcoghill
That did the trick, thanks!