Skip to content

Commit

Permalink
Merge branch 'feature/log-info' into milestone/1.1
Browse files Browse the repository at this point in the history
Log device, version and locale info #446
  • Loading branch information
hosy committed Jul 10, 2019
2 parents be14b82 + 09b6e63 commit 78d8b03
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ownCloud/Resources/en.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@
"You need to configure an email account first to be able to send emails." = "You need to configure an email account first to be able to send emails.";
"Do you want to open the following URL?" = "Do you want to open the following URL?";

"%@ %@ version %@ build %@ (%@)" = "%@ %@ version %@ build %@ (%@)";
"%@ %@ version %@ build %@ (app: %@, sdk: %@)" = "%@ %@ version %@ build %@ (app: %@, sdk: %@)";
"beta" = "beta";
"release" = "release";

Expand Down
4 changes: 2 additions & 2 deletions ownCloud/Settings/MoreSettingsSection.swift
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ class MoreSettingsSection: SettingsSection {
buildType = "beta".localized
}

let localizedFooter = "%@ %@ version %@ build %@ (%@)".localized
let footerTitle = String(format: localizedFooter, OCAppIdentity.shared.appName!, buildType, VendorServices.shared.appVersion, VendorServices.shared.appBuildNumber, VendorServices.shared.lastGitCommit)
let localizedFooter = "%@ %@ version %@ build %@ (app: %@, sdk: %@)".localized
let footerTitle = String(format: localizedFooter, OCAppIdentity.shared.appName ?? "App", buildType, VendorServices.shared.appVersion, VendorServices.shared.appBuildNumber, VendorServices.shared.lastGitCommit, OCAppIdentity.shared.sdkCommit ?? "unknown")

self.footerTitle = footerTitle

Expand Down
10 changes: 10 additions & 0 deletions ownCloud/Tools/Log.swift
Original file line number Diff line number Diff line change
Expand Up @@ -77,3 +77,13 @@ class Log {
return OCLogger.applyPrivacyMask(obj) ?? "(null)"
}
}

extension OCLogger : OCLogIntroFormat {
public func logIntroFormat() -> String {
return "{{stdIntro}}; Log options: \(Log.logOptionStatus)"
}

public func logHostCommit() -> String? {
return LastGitCommit()
}
}

0 comments on commit 78d8b03

Please sign in to comment.