Platform: macOS, Sonoma 14.6
Technology stack: Electron v29, TypeScript
Hello,
We're developing a desktop app for macOS that helps with automation of some browser related tasks, using Puppeteer and Chrome/Chromium browsers. One of the conditions of our app running is having Chrome/Chromium installed on the computer.
To check if someone has installed one of the supported browsers our app runs the following command in the shell:
mdfind "kMDItemKind == \'Application\'"
it produces the list of installed apps and then we scan the list in the search of Chrome or Chromium.
Recently we found out that the command's result is not consistent, because on some macOS computers the result is empty and we don't know why.
Are we misunderstanding the usage of mdfind? Or maybe we should try a different way to check if Chrome or Chromium is installed on the computer running our app?
Thank you.