Latest 1.0.0
Homepage https://github.com/smartnsoft/SwiftyBeaver-Destinations
License MIT
Platforms ios 9.0
Authors

SwiftyBeaver-Destinations

CI Status
Version
License
Platform

Add pre-configured console destinations 🔌 for, and based on SwiftyBeaver.

Available destinations:

Requirements

  • iOS 9
  • Xcode 9.2+
  • Swift 4

Installation

SwiftyBeaver-Destinations is available through CocoaPods. To install it, simply add the following line to your Podfile with your desired destination:

pod "SwiftyBeaver-Destinations/LogEntries"
pod "SwiftyBeaver-Destinations/Logmatic"

If you just want utils :

pod "SwiftyBeaver-Destinations/Core" (SwiftyBeaver + Utils)

Example

To run the example project, clone the repo, and run pod install from the Example directory first.

Usage

In your AppDelegate class, add let log = SwiftyBeaver.self

Add a destination

Configure SwiftyBeaver by adding your destinations: log.addDestination(<YourDestination>)

Available destinations at the moment are:

  • LogEntriesDestination(token: String, level: SwiftyBeaver.Level)
  • Logmatic(apiKey: String, level: SwiftyBeaver.Level)

Utils

LogUtils file contains methods for logs:

  • device details’s dictionary (OS version, host name, device name and model): deviceDetails() -> [String: String]
  • thread name if you aren’t on the main thread: threadName() -> String

Destinations file contains methods for SwiftyBeaver:

SwiftyBeaver’s extensions:

  • remove a destination: log.removeDestination(_ dest: BaseDestination.Type)

Default destinations:

  • Default console with emojis 🎉: log.addDestination(Destinations.console)

Contributors

Made in 🇫🇷 by the Smart&Soft iOS Team.

License

SwiftyBeaver-Destinations is available under the MIT license. See the LICENSE file for more info.

Latest podspec

{
    "name": "SwiftyBeaver-Destinations",
    "version": "1.0.0",
    "summary": "Additionals destinations ud83dudd0c (LogEntries, Logmatic) and utilities for SwiftyBeaver.",
    "homepage": "https://github.com/smartnsoft/SwiftyBeaver-Destinations",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "Smart&Soft": "[email protected]"
    },
    "source": {
        "git": "https://github.com/smartnsoft/SwiftyBeaver-Destinations.git",
        "tag": "1.0.0"
    },
    "social_media_url": "https://twitter.com/smartnsoft",
    "default_subspecs": "Core",
    "platforms": {
        "ios": "9.0"
    },
    "subspecs": [
        {
            "name": "Core",
            "source_files": "SwiftyBeaver-Destinations/Classes/Utils/*.{swift,h,m}",
            "dependencies": {
                "SwiftyBeaver": [
                    "~> 1.5"
                ]
            }
        },
        {
            "name": "LogEntries",
            "source_files": "SwiftyBeaver-Destinations/Classes/LogEntries/**/*.{swift,h,m}",
            "dependencies": {
                "SwiftyBeaver-Destinations/Core": [],
                "iOSLogEntries": [
                    "~> 1.2"
                ]
            }
        },
        {
            "name": "Logmatic",
            "source_files": "SwiftyBeaver-Destinations/Classes/Logmatic/**/*.{swift,h,m}",
            "dependencies": {
                "SwiftyBeaver-Destinations/Core": [],
                "Logmatic": [
                    "~> 1.0"
                ]
            }
        }
    ]
}

Pin It on Pinterest

Share This