mirror of
https://github.com/status-im/timbre.git
synced 2025-02-27 02:20:39 +00:00
Add refer-timbre
This commit is contained in:
parent
07fdddf2f2
commit
b510633f03
@ -1,4 +1,8 @@
|
|||||||
## v2.2.0 → v2.3.0
|
## v2.3.4 → v2.4.0
|
||||||
|
* Added `refer-timbre` for conveniently `require`ing standard timbre vars.
|
||||||
|
|
||||||
|
|
||||||
|
## v2.2.0 → v2.3.4
|
||||||
* Added `with-log-level` for thread-local logging levels: `(with-level :trace (trace "This will log!"))`. Esp. useful for developing & unit tests, etc.
|
* Added `with-log-level` for thread-local logging levels: `(with-level :trace (trace "This will log!"))`. Esp. useful for developing & unit tests, etc.
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
**[API docs](http://ptaoussanis.github.io/timbre/)** | **[CHANGELOG](https://github.com/ptaoussanis/timbre/blob/master/CHANGELOG.md)** | [contact & contributing](#contact--contributing) | [other Clojure libs](https://www.taoensso.com/clojure-libraries) | [Twitter](https://twitter.com/#!/ptaoussanis) | current [semantic](http://semver.org/) version:
|
**[API docs](http://ptaoussanis.github.io/timbre/)** | **[CHANGELOG](https://github.com/ptaoussanis/timbre/blob/master/CHANGELOG.md)** | [contact & contributing](#contact--contributing) | [other Clojure libs](https://www.taoensso.com/clojure-libraries) | [Twitter](https://twitter.com/#!/ptaoussanis) | current [semantic](http://semver.org/) version:
|
||||||
|
|
||||||
```clojure
|
```clojure
|
||||||
[com.taoensso/timbre "2.3.4"] ; See CHANGELOG for breaking changes since 1.x
|
[com.taoensso/timbre "2.4.0"] ; See CHANGELOG for breaking changes since 1.x
|
||||||
```
|
```
|
||||||
|
|
||||||
# Timbre, a (sane) Clojure logging & profiling library
|
# Timbre, a (sane) Clojure logging & profiling library
|
||||||
@ -26,7 +26,7 @@ Logging with Java can be maddeningly, unnecessarily hard. Particularly if all yo
|
|||||||
Add the necessary dependency to your [Leiningen](http://leiningen.org/) `project.clj` and `require` the library in your ns:
|
Add the necessary dependency to your [Leiningen](http://leiningen.org/) `project.clj` and `require` the library in your ns:
|
||||||
|
|
||||||
```clojure
|
```clojure
|
||||||
[com.taoensso/timbre "2.3.4"] ; project.clj
|
[com.taoensso/timbre "2.4.0"] ; project.clj
|
||||||
(ns my-app (:require [taoensso.timbre :as timbre
|
(ns my-app (:require [taoensso.timbre :as timbre
|
||||||
:refer (trace debug info warn error fatal spy with-log-level)])) ; ns
|
:refer (trace debug info warn error fatal spy with-log-level)])) ; ns
|
||||||
```
|
```
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
(defproject com.taoensso/timbre "2.3.4"
|
(defproject com.taoensso/timbre "2.4.0"
|
||||||
:description "Clojure logging & profiling library"
|
:description "Clojure logging & profiling library"
|
||||||
:url "https://github.com/ptaoussanis/timbre"
|
:url "https://github.com/ptaoussanis/timbre"
|
||||||
:license {:name "Eclipse Public License"
|
:license {:name "Eclipse Public License"
|
||||||
|
@ -410,6 +410,14 @@
|
|||||||
(log-and-rethrow-errors (/ 0))
|
(log-and-rethrow-errors (/ 0))
|
||||||
(logged-future (/ 0)))
|
(logged-future (/ 0)))
|
||||||
|
|
||||||
|
(defn refer-timbre
|
||||||
|
"Shorthand for:
|
||||||
|
(require '[taoensso.timbre :as timbre
|
||||||
|
:refer (trace debug info warn error fatal report spy with-log-level)])"
|
||||||
|
[]
|
||||||
|
(require '[taoensso.timbre :as timbre
|
||||||
|
:refer (trace debug info warn error fatal report spy with-log-level)]))
|
||||||
|
|
||||||
;;;; Dev/tests
|
;;;; Dev/tests
|
||||||
|
|
||||||
(comment
|
(comment
|
||||||
|
Loading…
x
Reference in New Issue
Block a user