Announcing: Timelane
Today I’m announcing the public release of Timelane.
Timelane is a free, open source Instrument that helps you profile and debug asynchronous code.
Timelane is available today on: http://timelane.tools.
The Timelane Instrument leverages signpost logging and the powerful Instruments UI to help you visually inspect asynchronous subscriptions and drill down through logged events over time.
Installation
Install the latest build from http://timelane.tools or fork the repository on GitHub and build the app yourself.
Move the app to your /Applications
folder and start it up.
Click on the instrument package to install the Timelane instrument into your Instruments app:
Once finished, you can profile any of your projects using the Timelane instrument:
Usage
This example uses TimelaneCombine with Apple’s Combine - the steps to use RxTimelane + RxSwift are almost identical.
Add TimelaneCombine
to your project via Swift Package Manager or Xcode:
.package(url: "https://github.com/icanzilb/TimelaneCombine",
.from("1.0.0"))
Import TimelaneCombine in a source file:
import TimelaneCombine
Use the lane(_)
operator to profile a subscription via the TimelaneInstrument. Insert lane(_)
at the precise spot in your code you’d like to profile like so:
downloadImagePublisher(at: url).
.lane("Download: \(url.path)")
.assign(to: \.image, on: myImageView)
Then profile your project by clicking Product > Profile in Xcode’s main menu, choose the Timelane instrument and run a new recording:
For more details go to http://timelane.tools.
Release details
The initial release of Timelane offers:
- The free and open source Timelane app and instrument: timelane.tools
- Combine Timelane package: TimelaneCombine
- RxSwift Timelane package: RxTimelane
- All purpose generic Timelane package to use with any code: TimelaneCore
Thank you and if you have any questions, feedback, or press inquiries do get in contact at https://twitter.com/icanzilb.
Where to go from here?
To learn about all Combine check Combine: Asynchronous programming with Swift - this is where you can see all updates, discuss in the website forums, and more.