Was going to add a shortcut to an app via INIntent. I followed the WWDC developer.apple.com/videos/play/wwdc2021/10232/?time=986
Steps:
- Created a .intentdefinition file and created an intent.
- Added the intent to .intentdefinition and compiled the app.
- Import the header file for the custom intent in the AppDelegate MyIntentname.h
- Have the AppDelegate conform to the protocol created in the generated code.
- Implement: -application:handlerForIntent: and return self (the app delegate)
- Run the app.
- Open the Shortcuts app and search for the 'shortcut' (according to the WWDC video linked above it should show up in the actions list).
- Doesn't show up in the list.
I tried moving the build application out from Debug to my Applications folder to see if that would help the Shortcuts app find it, but it didn't.
Am I missing a step/doing something wrong?
So clearly Shortcuts app wasn't responding to my app being built with changes made to the .intentdefinition file. I tried taking the built app out of Derived data and moving it. Still no juice.
Finally was able to get it to work by moving the built app out of Derived Data to my Applications folder and restarting my Mac.