log4ever 0.0.6 → 0.0.7
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +2 -0
- data/lib/log4r/evernote.rb +1 -1
- data/lib/log4r/outputter/evernoteoutputter.rb +11 -4
- data/log4ever.gemspec +1 -1
- metadata +4 -4
data/README.md
CHANGED
data/lib/log4r/evernote.rb
CHANGED
@@ -15,6 +15,13 @@ module Log4r
|
|
15
15
|
super(_name, hash)
|
16
16
|
validate(hash)
|
17
17
|
end
|
18
|
+
|
19
|
+
# synchronize note
|
20
|
+
def sync
|
21
|
+
@note = @evernote.get_note(@notebook)
|
22
|
+
set_maxsize(@hash) # for rolling
|
23
|
+
set_shift_age(@hash) # for rolling
|
24
|
+
end
|
18
25
|
|
19
26
|
# validation of evernote parameters
|
20
27
|
def validate(hash)
|
@@ -33,17 +40,17 @@ module Log4r
|
|
33
40
|
stack_name = hash[:stack] || hash['stack']
|
34
41
|
@evernote = MyEvernote.new(@env, @auth_token)
|
35
42
|
tags = @evernote.get_tags(hash[:tags] || hash['tags'] || [])
|
36
|
-
notebook = @evernote.get_notebook(notebook_name, stack_name)
|
37
|
-
@note = @evernote.get_note(notebook)
|
38
43
|
@tags = tags.map{|tag_obj| tag_obj.guid}
|
39
|
-
|
40
|
-
|
44
|
+
@notebook = @evernote.get_notebook(notebook_name, stack_name)
|
45
|
+
@hash = hash
|
46
|
+
sync
|
41
47
|
end
|
42
48
|
|
43
49
|
def canonical_log(logevent); super end
|
44
50
|
|
45
51
|
# write log
|
46
52
|
def write(content)
|
53
|
+
sync
|
47
54
|
if note_size_requires_roll? || time_requires_roll?
|
48
55
|
create_log(content)
|
49
56
|
else
|
data/log4ever.gemspec
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: log4ever
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.7
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,12 +9,12 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-10-
|
12
|
+
date: 2012-10-16 00:00:00.000000000 +09:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: log4r
|
17
|
-
requirement: &
|
17
|
+
requirement: &2156644240 !ruby/object:Gem::Requirement
|
18
18
|
none: false
|
19
19
|
requirements:
|
20
20
|
- - ! '>='
|
@@ -22,7 +22,7 @@ dependencies:
|
|
22
22
|
version: 1.1.10
|
23
23
|
type: :runtime
|
24
24
|
prerelease: false
|
25
|
-
version_requirements: *
|
25
|
+
version_requirements: *2156644240
|
26
26
|
description: log4ever is simple logger for evernote. It is available as an extension
|
27
27
|
of log4r.
|
28
28
|
email:
|