I've got lot of passwords in 1Password and I've got some scripts with login. And it's not so convenient to go to 1Password, unlock, copy the username, password, ... It would be nice if Pythonista can be bundled with OnePasswordExtension.
Integration is pretty simple:
copy OnePasswordExtension.(h|m) to the Pythonista project
copy 1Password.xcassets to the Pythonista project
Add org-appextension-feature-password-management to the LSApplicationQueriesScheme (Info.plist), that's because canOpenURL & iOS 9
To get a password, I do call something like this:
OnePasswordExtension.shared().findLogin(forURLString: Config.onePasswordUrl, for: self, sender: sender) {
[weak self] loginDictionary, error in
if let username = loginDictionary?["username"] as? String,
let password = loginDictionary?["password"] as? String {
self?.emailTextField.text = username
self?.pinTextField.text = password
self?.pinTextField.becomeFirstResponder()
}
}
So there can be a simple wrapper / module named onepassword which can contain two functions.
def is_available():
wraps OnePasswordExtension.shared().isAppExtensionAvailable()
def find_login(url, handler):
wraps OnePasswordExtension.shared().findLogin(...)
calls handler with login dictionary and error
I've got lot of passwords in 1Password and I've got some scripts with login. And it's not so convenient to go to 1Password, unlock, copy the username, password, ... It would be nice if Pythonista can be bundled with OnePasswordExtension.
Integration is pretty simple:
OnePasswordExtension.(h|m)
to the Pythonista project1Password.xcassets
to the Pythonista projectorg-appextension-feature-password-management
to theLSApplicationQueriesScheme
(Info.plist
), that's becausecanOpenURL
& iOS 9To get a password, I do call something like this:
So there can be a simple wrapper / module named
onepassword
which can contain two functions.