Enable SwiftLint rule 'multiline_literal_brackets' and fix all violations
This commit is contained in:
parent
776c813f94
commit
55e2cd7939
6 changed files with 78 additions and 46 deletions
|
|
@ -99,7 +99,7 @@ whitelist_rules:
|
|||
- multiline_arguments
|
||||
- multiline_arguments_brackets
|
||||
- multiline_function_chains
|
||||
# - multiline_literal_brackets
|
||||
- multiline_literal_brackets
|
||||
# - multiline_parameters
|
||||
# - multiline_parameters_brackets
|
||||
# - multiple_closures_with_trailing_closure
|
||||
|
|
|
|||
|
|
@ -61,12 +61,14 @@ class AboutRepositoryTableViewController: BasicStaticTableViewController {
|
|||
let type = UITableViewCell.AccessoryType.none
|
||||
strongSelf.tableData = [
|
||||
// section 0
|
||||
[[.style: CellDataStyle.value1, .accessoryType: type, .title: "Passwords".localize(), .detailText: passwords],
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "Size".localize(), .detailText: size],
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "LocalCommits".localize(), .detailText: localCommits],
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "LastSynced".localize(), .detailText: lastSynced],
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "Commits".localize(), .detailText: commits],
|
||||
[.title: "CommitLogs".localize(), .action: "segue", .link: "showCommitLogsSegue"]],
|
||||
[
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "Passwords".localize(), .detailText: passwords],
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "Size".localize(), .detailText: size],
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "LocalCommits".localize(), .detailText: localCommits],
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "LastSynced".localize(), .detailText: lastSynced],
|
||||
[.style: CellDataStyle.value1, .accessoryType: type, .title: "Commits".localize(), .detailText: commits],
|
||||
[.title: "CommitLogs".localize(), .action: "segue", .link: "showCommitLogsSegue"],
|
||||
],
|
||||
]
|
||||
strongSelf.indicator.stopAnimating()
|
||||
strongSelf.tableView.reloadData()
|
||||
|
|
|
|||
|
|
@ -12,13 +12,17 @@ class AboutTableViewController: BasicStaticTableViewController {
|
|||
override func viewDidLoad() {
|
||||
tableData = [
|
||||
// section 0
|
||||
[[.title: "Website".localize(), .action: "link", .link: "https://github.com/mssun/pass-ios.git"],
|
||||
[.title: "Help".localize(), .action: "link", .link: "https://github.com/mssun/passforios/wiki"],
|
||||
[.title: "ContactDeveloper".localize(), .action: "link", .link: "mailto:developer@passforios.mssun.me?subject=Pass%20for%20iOS"]],
|
||||
[
|
||||
[.title: "Website".localize(), .action: "link", .link: "https://github.com/mssun/pass-ios.git"],
|
||||
[.title: "Help".localize(), .action: "link", .link: "https://github.com/mssun/passforios/wiki"],
|
||||
[.title: "ContactDeveloper".localize(), .action: "link", .link: "mailto:developer@passforios.mssun.me?subject=Pass%20for%20iOS"],
|
||||
],
|
||||
|
||||
// section 1,
|
||||
[[.title: "OpenSourceComponents".localize(), .action: "segue", .link: "showOpenSourceComponentsSegue"],
|
||||
[.title: "SpecialThanks".localize(), .action: "segue", .link: "showSpecialThanksSegue"]],
|
||||
[
|
||||
[.title: "OpenSourceComponents".localize(), .action: "segue", .link: "showOpenSourceComponentsSegue"],
|
||||
[.title: "SpecialThanks".localize(), .action: "segue", .link: "showSpecialThanksSegue"],
|
||||
],
|
||||
]
|
||||
super.viewDidLoad()
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,30 +11,46 @@ import UIKit
|
|||
|
||||
class OpenSourceComponentsTableViewController: BasicStaticTableViewController {
|
||||
private static let openSourceComponents = [
|
||||
["FavIcon",
|
||||
"https://github.com/bitserf/FavIcon",
|
||||
"https://github.com/bitserf/FavIcon/blob/master/LICENSE"],
|
||||
["GopenPGP",
|
||||
"https://gopenpgp.org/",
|
||||
"https://github.com/ProtonMail/gopenpgp/blob/master/LICENSE"],
|
||||
["KeychainAccess",
|
||||
"https://github.com/kishikawakatsumi/KeychainAccess",
|
||||
"https://github.com/kishikawakatsumi/KeychainAccess/blob/master/LICENSE"],
|
||||
["ObjectiveGit",
|
||||
"https://github.com/libgit2/objective-git",
|
||||
"https://github.com/libgit2/objective-git/blob/master/LICENSE"],
|
||||
["OneTimePassword",
|
||||
"https://github.com/mattrubin/OneTimePassword",
|
||||
"https://github.com/mattrubin/OneTimePassword/blob/develop/LICENSE.md"],
|
||||
["SVProgressHUD",
|
||||
"https://github.com/SVProgressHUD/SVProgressHUD",
|
||||
"https://github.com/SVProgressHUD/SVProgressHUD/blob/master/LICENSE"],
|
||||
["SwiftyUserDefaults",
|
||||
"https://github.com/radex/SwiftyUserDefaults",
|
||||
"https://github.com/radex/SwiftyUserDefaults/blob/master/LICENSE"],
|
||||
["EFF's Wordlists",
|
||||
"https://www.eff.org/deeplinks/2016/07/new-wordlists-random-passphrases",
|
||||
"http://creativecommons.org/licenses/by/3.0"],
|
||||
[
|
||||
"FavIcon",
|
||||
"https://github.com/bitserf/FavIcon",
|
||||
"https://github.com/bitserf/FavIcon/blob/master/LICENSE",
|
||||
],
|
||||
[
|
||||
"GopenPGP",
|
||||
"https://gopenpgp.org/",
|
||||
"https://github.com/ProtonMail/gopenpgp/blob/master/LICENSE",
|
||||
],
|
||||
[
|
||||
"KeychainAccess",
|
||||
"https://github.com/kishikawakatsumi/KeychainAccess",
|
||||
"https://github.com/kishikawakatsumi/KeychainAccess/blob/master/LICENSE",
|
||||
],
|
||||
[
|
||||
"ObjectiveGit",
|
||||
"https://github.com/libgit2/objective-git",
|
||||
"https://github.com/libgit2/objective-git/blob/master/LICENSE",
|
||||
],
|
||||
[
|
||||
"OneTimePassword",
|
||||
"https://github.com/mattrubin/OneTimePassword",
|
||||
"https://github.com/mattrubin/OneTimePassword/blob/develop/LICENSE.md",
|
||||
],
|
||||
[
|
||||
"SVProgressHUD",
|
||||
"https://github.com/SVProgressHUD/SVProgressHUD",
|
||||
"https://github.com/SVProgressHUD/SVProgressHUD/blob/master/LICENSE",
|
||||
],
|
||||
[
|
||||
"SwiftyUserDefaults",
|
||||
"https://github.com/radex/SwiftyUserDefaults",
|
||||
"https://github.com/radex/SwiftyUserDefaults/blob/master/LICENSE",
|
||||
],
|
||||
[
|
||||
"EFF's Wordlists",
|
||||
"https://www.eff.org/deeplinks/2016/07/new-wordlists-random-passphrases",
|
||||
"http://creativecommons.org/licenses/by/3.0",
|
||||
],
|
||||
]
|
||||
|
||||
override func viewDidLoad() {
|
||||
|
|
|
|||
|
|
@ -10,14 +10,22 @@ import UIKit
|
|||
|
||||
class SpecialThanksTableViewController: BasicStaticTableViewController {
|
||||
let openSourceComponents = [
|
||||
["Contributors".localize(),
|
||||
"https://github.com/mssun/passforios/graphs/contributors"],
|
||||
["Password Store",
|
||||
"https://passwordstore.org"],
|
||||
["Icon8",
|
||||
"https://icons8.com"],
|
||||
["FlatIcon",
|
||||
"https://www.flaticon.com"],
|
||||
[
|
||||
"Contributors".localize(),
|
||||
"https://github.com/mssun/passforios/graphs/contributors",
|
||||
],
|
||||
[
|
||||
"Password Store",
|
||||
"https://passwordstore.org",
|
||||
],
|
||||
[
|
||||
"Icon8",
|
||||
"https://icons8.com",
|
||||
],
|
||||
[
|
||||
"FlatIcon",
|
||||
"https://www.flaticon.com",
|
||||
],
|
||||
]
|
||||
|
||||
override func viewDidLoad() {
|
||||
|
|
|
|||
|
|
@ -162,8 +162,10 @@ class ExtensionViewController: UIViewController, UITableViewDataSource, UITableV
|
|||
switch self.extensionAction {
|
||||
case .findLogin:
|
||||
let extensionItem = NSExtensionItem()
|
||||
var returnDictionary = [OnePasswordExtensionKey.usernameKey: username,
|
||||
OnePasswordExtensionKey.passwordKey: password]
|
||||
var returnDictionary = [
|
||||
OnePasswordExtensionKey.usernameKey: username,
|
||||
OnePasswordExtensionKey.passwordKey: password,
|
||||
]
|
||||
if let totpPassword = decryptedPassword.currentOtp {
|
||||
returnDictionary[OnePasswordExtensionKey.totpKey] = totpPassword
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue