diff --git a/Passepartout-iOS/AppDelegate.swift b/Passepartout-iOS/AppDelegate.swift index 82ea9bae..720c419a 100644 --- a/Passepartout-iOS/AppDelegate.swift +++ b/Passepartout-iOS/AppDelegate.swift @@ -120,8 +120,8 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UISplitViewControllerDele let alert = Macros.alert(L10n.Organizer.Sections.Hosts.header, L10n.Wizards.Host.Alerts.unsupported(option)) alert.addCancelAction(L10n.Global.ok) root.present(alert, animated: true, completion: nil) - } catch { - let alert = Macros.alert(L10n.Organizer.Sections.Hosts.header, L10n.Wizards.Host.Alerts.parsing) + } catch let e { + let alert = Macros.alert(L10n.Organizer.Sections.Hosts.header, L10n.Wizards.Host.Alerts.parsing(e.localizedDescription)) alert.addCancelAction(L10n.Global.ok) root.present(alert, animated: true, completion: nil) } diff --git a/Passepartout/Resources/en.lproj/Localizable.strings b/Passepartout/Resources/en.lproj/Localizable.strings index 1bc3b9cf..ce1bb8ea 100644 --- a/Passepartout/Resources/en.lproj/Localizable.strings +++ b/Passepartout/Resources/en.lproj/Localizable.strings @@ -47,7 +47,7 @@ "wizards.host.sections.existing.header" = "Existing profiles"; "wizards.host.alerts.existing" = "A host profile with the same title already exists. Replace it?"; "wizards.host.alerts.unsupported" = "The configuration file contains an unsupported option (%@)."; -"wizards.host.alerts.parsing" = "Unable to parse the provided configuration file."; +"wizards.host.alerts.parsing" = "Unable to parse the provided configuration file (%@)."; "service.welcome.message" = "Welcome to Passepartout!\n\nUse the organizer to add a new profile."; "service.sections.general.header" = "General"; diff --git a/Passepartout/Sources/SwiftGen+Strings.swift b/Passepartout/Sources/SwiftGen+Strings.swift index 2b2ed25d..66e18426 100644 --- a/Passepartout/Sources/SwiftGen+Strings.swift +++ b/Passepartout/Sources/SwiftGen+Strings.swift @@ -666,8 +666,10 @@ internal enum L10n { internal enum Alerts { /// A host profile with the same title already exists. Replace it? internal static let existing = L10n.tr("Localizable", "wizards.host.alerts.existing") - /// Unable to parse the provided configuration file. - internal static let parsing = L10n.tr("Localizable", "wizards.host.alerts.parsing") + /// Unable to parse the provided configuration file (%@). + internal static func parsing(_ p1: String) -> String { + return L10n.tr("Localizable", "wizards.host.alerts.parsing", p1) + } /// The configuration file contains an unsupported option (%@). internal static func unsupported(_ p1: String) -> String { return L10n.tr("Localizable", "wizards.host.alerts.unsupported", p1)