Skip to content

Add Shortcuts support#107

Merged
cyanzhong merged 5 commits intomainfrom
shortcuts
Mar 11, 2023
Merged

Add Shortcuts support#107
cyanzhong merged 5 commits intomainfrom
shortcuts

Conversation

@cyanzhong
Copy link
Contributor

@cyanzhong cyanzhong merged commit 29c28ba into main Mar 11, 2023
@cyanzhong cyanzhong deleted the shortcuts branch March 11, 2023 03:36
@leits
Copy link

leits commented Mar 14, 2023

Hi @cyanzhong,
I'm Andrii, a https://github.com/leits/MeetingBar maintainer.
Found your pull request with shortcuts implementation in your macOS app. Great work!
I've spent several days trying to make an integration for MeetingBar. Could you help me? How did you get these intents to appear in the Shortcuts app?

@cyanzhong
Copy link
Contributor Author

Hi @leits, thanks for reaching out.

In fact, I don't think you need to do anything special, if you just want to have them shown alphabetically in the Shortcuts app. The system scans all your AppIntent implementations and does that for you. The only thing to take care of is that you probably want to make sure there's only one MeetingBar when you debug, because Shortcuts might be randomly selecting one, which can be the one without Shortcuts support. I don't know if there's a better way other than removing all other versions, please let me know if you figured out.

To have App Intents categorized, you can leverage categoryName in IntentDescription, I haven't done that because I only have a few intents.

@leits
Copy link

leits commented Mar 17, 2023

Thank you @cyanzhong!
Your answer told me I was on the right track and I started looking at possible problems outside the code.
It turned out that the shortcuts did not appear for me, because I had the other version of my app (installed from the AppStore). They appeared when I deleted it and rebuilt the dev version in Xcode!

Thanks for your help and contribution to open source 🙌

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants