drawio-desktop icon indicating copy to clipboard operation
drawio-desktop copied to clipboard

macOS Spotlight mdimporter plugin

Open saf-dmitry opened this issue 3 years ago • 4 comments

  • [x] I agree to follow the Code of Conduct that this project adheres to.
  • [x] I have searched the issue tracker for a feature request that matches the one I want to file, without success.

Is your feature request related to a problem? Please describe. I have found no convenient way to search a collection of draw.io diagrams locally stored on my macOS computer for textual content.

Describe the solution you'd like It would be nice if draw.io desktop app for macOS would include a macOS Spotlight mdimporter plugin for drawio files.

Describe alternatives you've considered I've considered writing a mdimporter plugin by myself, but have found no specs describing the drawio file format.

Additional context No applicable.

saf-dmitry avatar Feb 17 '22 10:02 saf-dmitry

How would such a plugin work, is there an index or is the search dynamic every time?

davidjgraph avatar Feb 17 '22 10:02 davidjgraph

Spotlight is a system-wide desktop search feature of Apple's macOS and iOS operating systems. Spotlight is a selection-based search system, which creates an index of all items and files on the system. It is designed to allow the user to quickly locate a wide variety of items on the computer, including documents, pictures, music, applications, and System Preferences.

Indices of filesystem metadata are maintained by the Metadata Server (which appears in the system as the mds daemon, or mdworker). The Metadata Server is started by launchd when macOS boots and is activated by client requests or changes to the filesystems that it monitors. It is fed information about the files on a computer's hard disks by the mdimport daemon. Aside from basic information about each file like its name, size and timestamps, the mdimport daemon can also index the content of some files, when it has an Importer plug-in that tells it how the file content is formatted. Spotlight comes with importers for certain types of files, such as Microsoft Word, MP3, and PDF documents. Apple publishes APIs that allow developers to write Spotlight Importer plug-ins for their own file formats.

Spotlight metadata importers extract metadata from custom file formats after files are saved, copied, or moved.

More info:

UPD: EPUB mdimporter example

saf-dmitry avatar Feb 17 '22 12:02 saf-dmitry

Would be great to have a QuickLook preview as well. Unless there is an overlap with this ticket it should get into its own story, I guess.

BSVogler avatar Aug 16 '22 09:08 BSVogler

We'll take PRs for this.

davidjgraph avatar Aug 16 '22 11:08 davidjgraph

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. See the FAQ for more information.

stale[bot] avatar Mar 25 '23 12:03 stale[bot]