Swiftpack.co - massdonati/tambo as Swift Package

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.
See all packages published by massdonati.
massdonati/tambo 2.0.3
swift logging framework
⭐️ 2
🕓 17 minutes ago
iOS macOS watchOS tvOS linux macOS iOS
.package(url: "https://github.com/massdonati/tambo.git", from: "2.0.3")

Tambo banner image

supported platforms programming language cocoapod cocoapod

Tambo is a versatile logging framework currently in development.



pod 'Tambo'



To start using Tambo right away all you need to do is:

  1. import Tambo: this is usually done in your AppDelegate.
  2. create a global constant with the default Tambo singleton like so let log = Tambo.default.
  3. start calling the logging api to se the logs in the Xcode console.

Full power

In order to use Tambo the way it's ment to be used, you need to create an instance with an identifier (helpfull to track the logging source in complex application that could have multiple Tambo instances).

let log = Tambo(identifier: "com.my.logger")

Then you need to create a strem object which, in Tambo language, defines where you want the logs to be displayed/sent to. In this example let's create an Xcode console stream using the TConsoleStream class:

let console = TConsoleStream(identifier: "com.my.console", printMode: .print)

Once we have created a stream we can configure it as much as we want and after that we're ready to add it to the Tambo instance in order for it to start logging.

log.add(stream: console)

Now we're ready to show some logs to the console. YAY!! 🎉🎉🎉🎉

Log levels

In priority order:

  1. error
  2. warning
  3. info
  4. debug
  5. verbose

Logging Apis

Every log level has a correspondent method in the Tambo class. When you call that api you can pass anything as a first parameter and optionally a context.

log.info("Request succeeded")
log.info(["one", "two", 3])
log.info(UIViewController(), context: ["url": request.url])

Stream Apis


  1. CI integration
  2. Proven carthage support
  3. Linux testing


This framework is still in development you're welcome to

  1. try it out
  2. contribute
  3. submit issues/feature request


Stars: 2
Last commit: 1 hour ago
jonrohan Something's broken? Yell at me @ptrpavlik. Praise and feedback (and money) is also welcome.

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics