Browse files

Adding a small code example to demonstrate usage

  • Loading branch information...
1 parent 672d927 commit f5b9255761207e329fbd23bfd37130631fbaed93 @abedra abedra committed Mar 13, 2011
Showing with 11 additions and 0 deletions.
  1. +11 −0
@@ -8,6 +8,17 @@ Logging occurs with the log macro, or the level-specific convenience macros, whi
## Usage
+The following short example should give you what you need to get started:
+ (ns example.core
+ (:use [ :only (info error)]))
+ (defn divide [one two]
+ (try
+ (info "Calculated" (/ one two))
+ (catch Exception ex
+ (error "There was an error in caculation" ex))))
For those new to using a java logging library, the following is a very basic configuration for log4j. Place it in a file called \"\" and place that file (and the log4j JAR) on the classpath.
log4j.rootLogger=WARN, A1

0 comments on commit f5b9255

Please sign in to comment.