Implement Siri shortcut to sync repository per automation task

This commit is contained in:
Danny Moesch 2020-03-04 20:27:23 +01:00 committed by Mingshen Sun
parent 21b5774cc5
commit b3bde9e0e0
12 changed files with 499 additions and 4 deletions

View file

@ -0,0 +1,20 @@
//
// IntentHandler.swift
// passShortcuts
//
// Created by Danny Moesch on 03.03.20.
// Copyright © 2020 Bob Sun. All rights reserved.
//
import Intents
import passKit
class IntentHandler: INExtension {
override func handler(for intent: INIntent) -> Any {
guard intent is SyncRepositoryIntent else {
fatalError("Unhandled intent type \(intent).")
}
return SyncRepositoryIntentHandler()
}
}