Skip to content

Commit

Permalink
chore: update readme (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
andylokandy authored Jun 16, 2024
1 parent ba8b7d5 commit 407a7f8
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# logcall

[![Crates.io](https://img.shields.io/crates/v/logcall?style=flat-square&logo=rust)](https://crates.io/crates/logcall)
[![Crates.io](https://img.shields.io/crates/d/logcall?style=flat-square&logo=rust)](https://crates.io/crates/logcall)
[![Documentation](https://img.shields.io/docsrs/logcall?style=flat-square&logo=rust)](https://docs.rs/logcall/)
[![CI Status](https://img.shields.io/github/actions/workflow/status/andylokandy/logcall/ci.yml?style=flat-square&logo=github)](https://github.com/andylokandy/logcall/actions)
[![Crates.io](https://img.shields.io/crates/l/logcall?style=flat-square&logo=)](https://crates.io/crates/logcall)

`logcall` is a Rust procedural macro crate designed to automatically log function calls, their inputs, and their outputs. This macro facilitates debugging and monitoring by providing detailed logs of function executions with minimal boilerplate code.

This is a re-implementation of the [`log-derive`](https://crates.io/crates/log-derive) crate with [`async-trait`](https://crates.io/crates/async-trait) compatibility.
Expand Down Expand Up @@ -75,7 +81,7 @@ fn main() {

When the `main` function runs, it initializes the logger and logs each function call as specified:

```ignore
```rust,ignore
[2024-06-16T12:41:04Z DEBUG main] add(a = 2, b = 3) => 5
[2024-06-16T12:41:04Z INFO main] multiply(a = 2, b = 3) => 6
[2024-06-16T12:41:04Z ERROR main] divide(a = 2, b = 0) => Err("Division by zero")
Expand Down

0 comments on commit 407a7f8

Please sign in to comment.