github.com/RX14/coz.cr
master / published Jan 7, 2020 / repository
coz.cr
Coz profiling for Crystal.
Installation
-
Add the dependency to your
shard.yml:dependencies: coz: github: RX14/coz.cr -
Run
shards install
Usage
require "coz"
# Progress point
Coz.progress
# Named progress point
Coz.progress("foo")
# Latency profiling
Coz.begin("foo")
foo(...)
Coz.end("foo")
# Latency profiling with block
Coz.latency("foo") { foo(...) }
Run as usual with coz run --- ./executable
Contributing
- Fork it (https://github.com/RX14/coz.cr/fork)
- Create your feature branch (
git checkout -b my-new-feature) - Commit your changes (
git commit -am 'Add some feature') - Push to the branch (
git push origin my-new-feature) - Create a new Pull Request
Contributors
- RX14 - creator and maintainer