Posts

Post not yet marked as solved
1 Replies
727 Views
Example for google.com as an item name, I have two keychain items with the name "Foo", one in KeychainA another in keychainB. When I run the following which password should be retrieved? Password from KeychainA or KeychainB? Does it retrieve items from keychains by prioritizing retrieval from 'default' keychain first? Or it's sorted by the keychain name? or it prioritizes items based on date? security find-generic-password -w -s 'google.com' -a 'Foo' I asked because we often have certs that are duplicated across keychains and when I run the command above, the item is retrieved from a locked keychain. Which causes an OS prompt and that halts our Jenkins/CI.
Posted
by honey9.
Last updated
.
Post not yet marked as solved
1 Replies
1.3k Views
I just going through Xcode’s built-in merge feature. And also using Xcode to resolve git conflicts. It’s my first time. I don’t mean FileMerge. I mean Xcode itself. The only thing is, when it comes to resolving conflicts for pbxproj file, I don’t want to go through selecting 200 conflicts and hit ‘Choose right’ 200 times. I tried copy/pasting from right over to left, but the 'merge' button didn't become green. Is there another way to just select the right file (from main branch) entirely with some other Xcode operation? 
Posted
by honey9.
Last updated
.
Post not yet marked as solved
0 Replies
636 Views
Other than the a WWDC video - 44:18 a sample project there's not much info online.So the actionProvider, when called, has a list of suggestedActions that are passed to it by the system. This can be a mix of UIMenus and UIActions, so potentially a fully constructed hierarchy that are picked up from the system. These could be things that you defined in your responder chain using the new UI command API being introduced in iOS 13 or things that are offered by other system components. So we're doing a fully custom menu here, so we're going to put the suggestedActions aside. First, we'll create our edit menu. But so far what I've learned is that a given Identifier can have pre-defined suggestedActions the suggestionActions are not associated with any identifier. If I change that identifier the suggestedActions won't change. It seems to be based on its context, which here I'm guessing I'm in the context of a tableviewcell... I'm trying to see what it looks like, but nothing shows up. If I tap on the cell nothing shows up. class ViewController: UIViewController { let tableview: UITableView = { let tv = UITableView() tv.frame = UIScreen.main.bounds return tv }() override func viewDidLoad() { super.viewDidLoad() view.addSubview(tableview) tableview.register(UITableViewCell.self, forCellReuseIdentifier: "cell") tableview.delegate = self tableview.dataSource = self } } extension ViewController: UITableViewDelegate, UITableViewDataSource { func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int { return 1 } func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell { var cell = tableView.dequeueReusableCell(withIdentifier: "cell", for: indexPath) if cell.detailTextLabel == nil { cell = UITableViewCell(style: .value1, reuseIdentifier: "cell") } cell.textLabel?.text = "Honey" cell.detailTextLabel?.text = "iOS developer" return cell } @available(iOS 13.0, *) func tableView(_ tableView: UITableView, contextMenuConfigurationForRowAt indexPath: IndexPath, point: CGPoint) -> UIContextMenuConfiguration? { return UIContextMenuConfiguration(identifier: nil, previewProvider: nil, actionProvider: { suggestedActions in print("suggestedActions", suggestedActions) let menu = UIMenu(title: "", children: suggestedActions) return menu }) } I've also printed suggestedActions, what I got out was:- 0 : <UIMenu: 0x6000008e6790; title = Standard Edit; identifier = com.apple.menu.standard-edit; options = (Inline); children = <NSArray: 0x600001318900>> - 1 : <UIMenu: 0x6000008e6820; title = Replace; identifier = com.apple.menu.replace; options = (Inline); children = <NSArray: 0x6000008e64c0>> - 2 : <UIMenu: 0x6000008e7330; title = Text Style; identifier = com.apple.menu.text-style; image = <UIImage:0x60000349c870 symbol(system: bold.italic.underline) {36, 17} baseline=3.66667,contentInsets={1, 2, 1, 2},alignmentRectInsets={-2.9999999999999982, 0, -0.33333333333333348, 0} config=<(null), traits=(UserInterfaceIdiom = Phone, DisplayScale = 3, DisplayGamut = P3, HorizontalSizeClass = Compact, VerticalSizeClass = Regular, UserInterfaceStyle = Light, UserInterfaceLayoutDirection = LTR, PreferredContentSizeCategory = L)>>; children = <NSArray: 0x6000008e6df0>> - 3 : <UIMenu: 0x6000008e6d00; title = Lookup; identifier = com.apple.menu.lookup; options = (Inline); children = <NSArray: 0x60000049c870>> - 4 : <UIMenu: 0x6000008e7060; title = Learn; identifier = com.apple.menu.learn; options = (Inline); children = <NSArray: 0x60000049c220>> - 5 : <UIMenu: 0x6000008e6d90; title = Speech; identifier = com.apple.command.speech; options = (Inline); children = <NSArray: 0x6000008e6490>> - 6 : <UIMenu: 0x6000008e7180; title = Share; identifier = com.apple.menu.share; options = (Inline); children = <NSArray: 0x60000049c6a0>> - 7 : <UIMenu: 0x6000008e6a30; title = Writing Direction; identifier = com.apple.menu.writing-direction; options = (Inline); children = <NSArray: 0x6000006fe1c0>>
Posted
by honey9.
Last updated
.
Post marked as solved
3 Replies
972 Views
I’m going through the sample project:https://developer.apple.com/documentation/uikit/uicommand/adding_menus_and_shortcuts_to_the_menu_bar_and_user_interface?language=objcFor the mac app I get access the main menu bar e.g. by tapping `cmmd + 0` I can access the main menu >> cities >> CupernitoI tried the same on my iPad simulator but nothing happens. I wonder how I can access that main menu on the iPad? Is there is a shortcut or something?
Posted
by honey9.
Last updated
.