xcodemacosfindersync

How to debug FinderSync extension in Xcode


I created a FinderSync extension, when I run the extension target, the console and the breakpoints did nothing, so how to debug the extension in xcode? I'm a new devleoper for MacOS.


Solution

  • This works for me...

    1. Create a new application project
    2. Add a new target - File -> New Target and add the finder sync target.
    3. When you are ready to debug, select the extension target - Product -> Scheme -> --Your FINDER_SYNC_EXT Name --
    4. Choose the Xcode Debugger for attaching finder sync extension - Debug -> Attach to Process by PID or Name
    5. Chose your extension and click Attach
    6. Xcode status panel will be updated to "Waiting to attach to -- Your FINDER_SYNC_EXT Name --"
    7. Set your breakpoints and run your extension.

    Your breakpoints will be triggered.