repo.or.cz
/
augment.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
history
|
raw
|
HEAD
outputs coloring for dummy backend
[augment.git]
/
lib
/
backends
/
backend.rb
blob
48b67937421814f073510400e8d6162fe74cbdf1
1
class Backend
2
class << self
3
def write_layers
4
FileUtils.mkpath('.augment')
5
@layers.each do |file, layers|
6
File.open(augment_file(file), 'w') do |f|
7
f.puts "[#{layers.map{ |l| l.to_json }.join(", \n")}]"
8
end
9
end
10
end
11
12
def augment_file(file)
13
'.augment/' + file.gsub(/[^a-zA-Z]/, '_')
14
end
15
end
16
end