diff --git a/.travis.yml b/.travis.yml index 1576afee..a6e66dd8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,12 @@ language: objective-c xcode_project: CleanroomLogger.xcodeproj +os: osx osx_image: xcode9 +branches: + only: + - master + git: depth: 1 submodules: false diff --git a/BuildControl/Info-Target.plist b/BuildControl/Info-Target.plist index 02da3143..a479b57c 100644 --- a/BuildControl/Info-Target.plist +++ b/BuildControl/Info-Target.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 5.1.2 + 6.0.0 CFBundleSignature ???? CFBundleVersion diff --git a/BuildControl/repos.xml b/BuildControl/repos.xml index f09b3641..82ede10d 100644 --- a/BuildControl/repos.xml +++ b/BuildControl/repos.xml @@ -12,20 +12,6 @@ - - - - - - - - - - - - - - @@ -50,7 +36,6 @@ - @@ -62,33 +47,11 @@ - - - - - - - - - - - - - - - - - - - - - - - + - + diff --git a/CleanroomLogger.xcodeproj/project.pbxproj b/CleanroomLogger.xcodeproj/project.pbxproj index 960b55d8..d67e70c0 100644 --- a/CleanroomLogger.xcodeproj/project.pbxproj +++ b/CleanroomLogger.xcodeproj/project.pbxproj @@ -462,7 +462,7 @@ CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; COPY_PHASE_STRIP = NO; - CURRENT_PROJECT_VERSION = 31; + CURRENT_PROJECT_VERSION = 32; DEBUG_INFORMATION_FORMAT = dwarf; ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; @@ -519,7 +519,7 @@ CLANG_WARN_UNREACHABLE_CODE = YES; CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; COPY_PHASE_STRIP = NO; - CURRENT_PROJECT_VERSION = 31; + CURRENT_PROJECT_VERSION = 32; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; ENABLE_NS_ASSERTIONS = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; @@ -545,7 +545,7 @@ buildSettings = { DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 31; + DYLIB_CURRENT_VERSION = 32; DYLIB_INSTALL_NAME_BASE = "@rpath"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; SKIP_INSTALL = YES; @@ -559,7 +559,7 @@ buildSettings = { DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 31; + DYLIB_CURRENT_VERSION = 32; DYLIB_INSTALL_NAME_BASE = "@rpath"; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; SKIP_INSTALL = YES; diff --git a/INTEGRATION.md b/INTEGRATION.md index 58aa5b5a..ed6d98db 100644 --- a/INTEGRATION.md +++ b/INTEGRATION.md @@ -14,7 +14,7 @@ Macintosh|macOS 10.13|macOS 10.9 Apple TV|tvOS 11.0|tvOS 9.0 Apple Watch|watchOS 4.0|watchOS 2.0 -**This is the `swift-4` branch of CleanroomLogger.** It uses **Swift 4.0** and **requires Xcode 9.0 beta** to compile. +CleanroomLogger uses **Swift 4.0** and **requires Xcode 9.0** to compile. ### Options for integration @@ -24,7 +24,7 @@ There are two supported options for integration: - **[Manual integration](#manual-integration)** involves embedding the `CleanroomLogger.xcodeproj` file within your project’s Xcode workspace. -Once properly integrated, you can make use of [the API](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/index.html) provided by CleanroomLogger in any Swift file using the statement: +Once properly integrated, you can make use of [the API](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/index.html) provided by CleanroomLogger in any Swift file using the statement: ```swift import CleanroomLogger @@ -33,7 +33,7 @@ import CleanroomLogger ## Carthage Integration -Carthage is a third-party package dependency manager for Apple platforms. As of this writing, the current supported version of Carthage is 0.24.0. +Carthage is a third-party package dependency manager for Apple platforms. As of this writing, the current supported version of Carthage is 0.25.0. Installing and using Carthage is beyond the scope of this document. If you do not have Carthage installed but would like to use it, [you can find installation instructions on the project page](https://github.com/Carthage/Carthage#installing-carthage). @@ -44,12 +44,12 @@ Within to your project’s root directory, Carthage-based projects will store a To integrate CleanroomLogger in your workspace, you would start by adding the following line to the `Cartfile`: ``` -github "emaloney/CleanroomLogger" ~> 5.1.0 +github "emaloney/CleanroomLogger" ~> 6.0.0 ``` -This specifies that Carthage use the latest version of CleanroomLogger that is API-compatible with 5.1.0, i.e. any 5.1.*x* version. +This specifies that Carthage use the latest version of CleanroomLogger that is API-compatible with 6.0.0, i.e. any 6.0.*x* version. -**Note:** Be sure to check the [latest releases](https://github.com/emaloney/CleanroomLogger/releases); there may be a newer version than 5.1.0 that is no longer API-compatible. +**Note:** Be sure to check the [latest releases](https://github.com/emaloney/CleanroomLogger/releases); there may be a newer version than 6.0.0 that is no longer API-compatible. ### 2. Download CleanroomLogger using Carthage @@ -163,6 +163,6 @@ Select the appropriate Build Scheme for your Target, and press `⌘-B` to try to ## Further Reading -Want to learn more about CleanroomLogger? Check out [the README](https://github.com/emaloney/CleanroomLogger/blob/swift-4/README.md) or [the API documentation](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/index.html). +Want to learn more about CleanroomLogger? Check out [the README](https://github.com/emaloney/CleanroomLogger/blob/master/README.md) or [the API documentation](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/index.html). **_Happy coding!_** diff --git a/README.md b/README.md index 00e341db..a7386926 100644 --- a/README.md +++ b/README.md @@ -12,9 +12,7 @@ CleanroomLogger is part of [the Cleanroom Project](https://github.com/gilt/Clean ### Swift compatibility -**Important:** This is the `swift-4` branch. It uses **Swift 4.0** and **requires Xcode 9.0 beta** to compile. - -If you need Swift 3.1 compatibility, use the [`master`](https://github.com/emaloney/CleanroomLogger) branch, which requires Xcode 8.3. +This is the `master` branch. It uses **Swift 4.0** and **requires Xcode 9.0** to compile. #### Current status @@ -22,7 +20,7 @@ If you need Swift 3.1 compatibility, use the [`master`](https://github.com/emalo Branch|Build status --------|------------------------ [`master`](https://github.com/emaloney/CleanroomLogger)|[![Build status: master branch](https://travis-ci.org/emaloney/CleanroomLogger.svg?branch=master)](https://travis-ci.org/emaloney/CleanroomLogger) -[`swift-4`](https://github.com/emaloney/CleanroomLogger/tree/swift-4)|[![Build status: swift-4 branch](https://travis-ci.org/emaloney/CleanroomLogger.svg?branch=swift-4)](https://travis-ci.org/emaloney/CleanroomLogger) + ### Contents @@ -34,7 +32,7 @@ Branch|Build status - [CleanroomLogger In Depth](#cleanroomlogger-in-depth) - [Configuring CleanroomLogger](#configuring-cleanroomlogger) - [Customized Log Formatting](#customized-log-formatting) - - [API Documentation](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/index.html) + - [API Documentation](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/index.html) - [Design Philosophy](#design-philosophy) - [Architectural Overview](#architectural-overview) @@ -52,11 +50,11 @@ On systems where OSLog isn’t available, CleanroomLogger gracefully falls back #### ▶ 100% documented -Good documentation is critical to the usefulness of any open-source framework. In addition to the extensive high-level documentation you’ll find below, [the CleanroomLogger API](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/index.html) itself is 100% documented. +Good documentation is critical to the usefulness of any open-source framework. In addition to the extensive high-level documentation you’ll find below, [the CleanroomLogger API](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/index.html) itself is 100% documented. #### ▶ Organize and filter messages by severity -Messages are assigned one of five [_severity levels_](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Enums/LogSeverity.html): the most severe is _error_, followed by _warning_, _info_, _debug_ and _verbose_, the least severe. Knowing a message’s severity lets you perform additional filtering; for example, to minimize the overhead of logging in App Store binaries, you could choose to log only warnings and errors in release builds. +Messages are assigned one of five [_severity levels_](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Enums/LogSeverity.html): the most severe is _error_, followed by _warning_, _info_, _debug_ and _verbose_, the least severe. Knowing a message’s severity lets you perform additional filtering; for example, to minimize the overhead of logging in App Store binaries, you could choose to log only warnings and errors in release builds. #### ▶ Color-coded log messages @@ -72,9 +70,9 @@ Quickly spot problems at runtime in the Xcode console, where log messages are co #### ▶ UNIX-friendly -Support for standard UNIX output streams is built-in. Use [`StandardOutputLogRecorder`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Classes/StandardOutputLogRecorder.html) and [`StandardErrorLogRecorder`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Classes/StandardErrorLogRecorder.html) to direct output to `stdout` and `stderr`, respectively. +Support for standard UNIX output streams is built-in. Use [`StandardOutputLogRecorder`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Classes/StandardOutputLogRecorder.html) and [`StandardErrorLogRecorder`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Classes/StandardErrorLogRecorder.html) to direct output to `stdout` and `stderr`, respectively. -Or, use the [`StandardStreamsLogRecorder`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Classes/StandardStreamsLogRecorder.html) to send verbose, debug and info messages to `stdout` while warnings and errors go to `stderr`. +Or, use the [`StandardStreamsLogRecorder`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Classes/StandardStreamsLogRecorder.html) to send verbose, debug and info messages to `stdout` while warnings and errors go to `stderr`. #### ▶ Automatic handling of `OS_ACTIVITY_MODE` @@ -94,7 +92,7 @@ If you’re just using `print()` or `NSLog()` everywhere, it can sometimes be di #### ▶ Rotating log files -CleanroomLogger provides [simple file-based logging](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Classes/FileLogRecorder.html) support as well as [a self-pruning rotating log directory](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Classes/RotatingLogFileConfiguration.html) implementation. +CleanroomLogger provides [simple file-based logging](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Classes/FileLogRecorder.html) support as well as [a self-pruning rotating log directory](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Classes/RotatingLogFileConfiguration.html) implementation. #### ▶ Super-simple execution tracing @@ -111,7 +109,7 @@ Developers often use logging to perform tracing. Rather than writing lots of dif #### ▶ Useful built-in formatters -CleanroomLogger ships with two general-purpose log formatters: the [`ReadableLogFormatter`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Classes/ReadableLogFormatter.html) is handy for human consumption, while the [`ParsableLogFormatter`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Classes/ParsableLogFormatter.html) is useful for machine processing. Both can be customized via the initializer. +CleanroomLogger ships with two general-purpose log formatters: the [`ReadableLogFormatter`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Classes/ReadableLogFormatter.html) is handy for human consumption, while the [`ParsableLogFormatter`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Classes/ParsableLogFormatter.html) is useful for machine processing. Both can be customized via the initializer. A formatter constructed using `ReadableLogFormatter()` yields log output that looks like: @@ -135,7 +133,7 @@ When the same log messages are handled by a formatter constructed using `Parsabl #### ▶ Easy mix-and-match formatting -If the built-in formatters don’t fit the bill, you can use the [`FieldBasedLogFormatter`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Classes/FieldBasedLogFormatter.html) to assemble just about any kind of log format possible. +If the built-in formatters don’t fit the bill, you can use the [`FieldBasedLogFormatter`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Classes/FieldBasedLogFormatter.html) to assemble just about any kind of log format possible. Let’s say you wanted a log formatter with the timestamp in ISO 8601 date format, a tab character, the source file and line number of the call site, followed by the severity as an uppercase string right-justified in a 8-character field, then a colon and a space, and finally the log entry’s payload. You could do this by constructing a `FieldBasedLogFormatter` as follows: @@ -162,14 +160,14 @@ The resulting output would look like: #### ▶ Fully extensible CleanroomLogger exposes three primary extension points for implementing your own custom logic: - - [`LogRecorder`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Protocols/LogRecorder.html)s are used to record formatted log messages. Typically, this involves writing the message to a stream or data store of some kind. You can provide your own `LogRecorder` implementations to utilize facilities not natively supported by CleanroomLogger: to store messages in a database table or send them to a remote HTTP endpoint, for example. - - [`LogFormatter`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Protocols/LogFormatter.html)s are used to generate text representations of each [`LogEntry`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Structs/LogEntry.html) to be recorded. - - [`LogFilter`](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/Protocols/LogFilter.html)s get a chance to inspect—and potentially reject—a `LogEntry` before it is passed to a `LogRecorder`. + - [`LogRecorder`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Protocols/LogRecorder.html)s are used to record formatted log messages. Typically, this involves writing the message to a stream or data store of some kind. You can provide your own `LogRecorder` implementations to utilize facilities not natively supported by CleanroomLogger: to store messages in a database table or send them to a remote HTTP endpoint, for example. + - [`LogFormatter`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Protocols/LogFormatter.html)s are used to generate text representations of each [`LogEntry`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Structs/LogEntry.html) to be recorded. + - [`LogFilter`](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/Protocols/LogFilter.html)s get a chance to inspect—and potentially reject—a `LogEntry` before it is passed to a `LogRecorder`. ### License -CleanroomLogger is distributed under [the MIT license](https://github.com/emaloney/CleanroomLogger/blob/swift-4/LICENSE). +CleanroomLogger is distributed under [the MIT license](https://github.com/emaloney/CleanroomLogger/blob/master/LICENSE). CleanroomLogger is provided for your use—free-of-charge—on an as-is basis. We make no guarantees, promises or apologies. *Caveat developer.* @@ -183,12 +181,12 @@ The simplest way to integrate CleanroomLogger is with the [Carthage](https://git First, add this line to your [`Cartfile`](https://github.com/Carthage/Carthage/blob/master/Documentation/Artifacts.md#cartfile): ``` -github "emaloney/CleanroomLogger" ~> 5.1.0 +github "emaloney/CleanroomLogger" ~> 6.0.0 ``` Then, use the `carthage` command to [update your dependencies](https://github.com/Carthage/Carthage#upgrading-frameworks). -Finally, you’ll need to [integrate CleanroomLogger into your project](https://github.com/emaloney/CleanroomLogger/blob/swift-4/INTEGRATION.md) in order to use [the API](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/index.html) it provides. +Finally, you’ll need to [integrate CleanroomLogger into your project](https://github.com/emaloney/CleanroomLogger/blob/master/INTEGRATION.md) in order to use [the API](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/index.html) it provides. Once successfully integrated, just add the following statement to any Swift file where you want to use CleanroomLogger: @@ -196,7 +194,7 @@ Once successfully integrated, just add the following statement to any Swift file import CleanroomLogger ``` -See [the Integration document](https://github.com/emaloney/CleanroomLogger/blob/swift-4/INTEGRATION.md) for additional details on integrating CleanroomLogger into your project. +See [the Integration document](https://github.com/emaloney/CleanroomLogger/blob/master/INTEGRATION.md) for additional details on integrating CleanroomLogger into your project. ## Using CleanroomLogger @@ -498,7 +496,7 @@ You can also assemble an entirely custom formatter quite easily using the [`Fiel ### API documentation -For detailed information on using CleanroomLogger, [API documentation](https://rawgit.com/emaloney/CleanroomLogger/swift-4/Documentation/API/index.html) is available. +For detailed information on using CleanroomLogger, [API documentation](https://rawgit.com/emaloney/CleanroomLogger/master/Documentation/API/index.html) is available. ## Design Philosophy