A simple, colorful logger for Xcode.
-
You need to install XcodeColors plugin to enable color in the Xcode console, otherwise you will see some messed-up code.
-
If you want to open the specific file and highlight the line when you click on the hyperlink in the console, you need to install KZLinkedConsole plugin.
Suggestion:The best way of installing plugin is by Alcatraz. Install Alcatraz followed by the instruction, restart your Xcode and press ⇧⌘9. You can find XcodeColors and KZLinkedConsole in the list and click the icon on left to install.
You can use Cocoapods to install FunnyLogger
by adding it to your Podfile
:
target 'MyApp' do
pod 'FunnyLogger'
end
Clone the repo and add FunnyLogger.swift
to your project.
First:
import FunnyLogger
And, Use directly:
FunnyLogger.v("Normal")
FunnyLogger.d("Normal")
FunnyLogger.i("Normal")
FunnyLogger.w("Normal")
FunnyLogger.e("Normal")
FunnyLogger.v(.Flower, message: "Flower")
FunnyLogger.d(.Flower, message: "Flower")
FunnyLogger.i(.Flower, message: "Flower")
FunnyLogger.w(.Flower, message: "Flower")
FunnyLogger.e(.Flower, message: "Flower")
FunnyLogger is released under the MIT license. See LICENSE for details.