mas/mas-cli/Commands/SignOut.swift

19 lines
441 B
Swift
Raw Normal View History

2016-02-14 01:33:17 +00:00
//
// SignOut.swift
// mas-cli
//
// Created by Andrew Naylor on 14/02/2016.
// Copyright © 2016 Andrew Naylor. All rights reserved.
//
struct SignOutCommand: CommandType {
typealias Options = NoOptions<MASError>
let verb = "signout"
let function = "Sign out of the Mac App Store"
2016-09-17 12:58:38 +00:00
func run(_ options: Options) -> Result<(), MASError> {
CKAccountStore.shared().signOut()
return .success(())
2016-02-14 01:33:17 +00:00
}
2016-09-17 12:58:38 +00:00
}