BeappLogger 0.4.0

BeappLogger 0.4.0

a.dudouitCédric DeracheBeapp 维护。



  • Beapp

BeappLogger

CocoaPods

此 pods 可让您集中管理应用程序日志,并通过 Appender 系统将它们分发到任何您想要的地方

要运行示例项目,请克隆仓库,然后首先从 Example 目录运行 pod install

安装

要安装它,只需将以下行添加到您的 Podfile 中

pod 'BeappLogger'

然后,在您的应用程序中,您可以简单地进行如下使用

Logger.build(with: PrintAppender(), FileAppender(filename: "app_log.txt"))

Logger.build()

以后,在您的应用程序中,使用它就像这样

Logger.debug("TEST")
Logger.info("TEST")
Logger.warn("TEST")
Logger.error("TEST")

2019-02-05 04:51:41.636 [💬][AppDelegate: application(_:didFinishLaunchingWithOptions:) (24)] TEST
2019-02-05 04:51:41.652 [ℹ️][AppDelegate: application(_:didFinishLaunchingWithOptions:) (25)] TEST
2019-02-05 04:51:41.652 [⚠️][AppDelegate: application(_:didFinishLaunchingWithOptions:) (26)] TEST
2019-02-05 04:51:41.653 [🔥][AppDelegate: application(_:didFinishLaunchingWithOptions:) (27)] TEST

作者 Beapp,[email protected]

许可证

BeappLogger 在MIT许可证下可用。有关更多信息,请参阅LICENSE文件。