cologger 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/README.md +7 -6
  2. data/lib/cologger.rb +1 -1
  3. metadata +1 -1
data/README.md CHANGED
@@ -2,9 +2,9 @@
2
2
  *Add some color to your logs!*
3
3
 
4
4
  ## Installation
5
- This utils is packed as a gem, so, simply run `gem install cologger` to install it.
5
+ This utils is packed as a gem, so, simply run `gem install cologger` to install it.
6
6
 
7
- Current version is 0.1.0
7
+ Current version is 0.1.1
8
8
 
9
9
  ## Usage
10
10
  Using cologger is quite easy && straight forward.
@@ -21,7 +21,7 @@ Next, set the log level you want. By default, cologger outputs all the logs to y
21
21
  logger.log_level = Cologger.LEVEL_DEBUG
22
22
  ```
23
23
 
24
- After that, you can start logging. For example,
24
+ After that, you can start logging. For example,
25
25
 
26
26
  ```
27
27
  logger.fatal "universe", "the world is crashing"
@@ -39,7 +39,7 @@ And, here's what you got:
39
39
  The first parameter of any log method, like the `universe` in the `fatal` log above, is taken as a tag, the other strings, concated by a space character, is treated as the log content.
40
40
 
41
41
  ## Log levels
42
- Same as ruby `logger`, there are 5 levels. Namely,
42
+ Same as ruby `logger`, there are 5 levels. Namely,
43
43
 
44
44
  - FATAL, an unhandleable error that results in a program crash
45
45
  - ERROR, a handleable error condition
@@ -57,9 +57,10 @@ The levels are ordered desendingly according to thier level of importance.
57
57
 
58
58
  ## Dependency
59
59
 
60
- This gem depends on the cute [`colored' gem](https://github.com/defunkt/colored) by [defunk](https://github.com/defunkt).
60
+ This gem depends on the cute [`colored' gem](https://github.com/defunkt/colored) by [defunk](https://github.com/defunkt).
61
61
 
62
62
  Thanks sir!
63
63
 
64
64
  ## Change log
65
- - 0.1.0, initial version.
65
+ - 0.1.1, use `\t` to align timestamp.
66
+ - 0.1.0, initial version.
data/lib/cologger.rb CHANGED
@@ -66,7 +66,7 @@ class Cologger
66
66
 
67
67
  tag, *content_array = args
68
68
  content = content_array.join(" ")
69
- log = "#{sym_for method} "
69
+ log = "#{sym_for method}\t"
70
70
  log += "[#{DateTime.now.iso8601}] "
71
71
  log += "[#{tag}] #{content}"
72
72
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cologger
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: