module GitFeats::History
Constants
- PATH
Public Instance Methods
add(pattern)
click to toggle source
# File lib/git-feats/history.rb, line 18 def add(pattern) if @history[pattern] @history[pattern] += 1 else @history[pattern] = 1 end end
count(pattern)
click to toggle source
# File lib/git-feats/history.rb, line 26 def count(pattern) @history[pattern] end
data()
click to toggle source
# File lib/git-feats/history.rb, line 30 def data @history end
serialize()
click to toggle source
write data to file
# File lib/git-feats/history.rb, line 14 def serialize Serializer.serialize(PATH, @history) end
unserialize()
click to toggle source
load data from file
# File lib/git-feats/history.rb, line 9 def unserialize @history = Serializer.unserialize(PATH) || {} end