mirror of
https://github.com/athityakumar/colorls.git
synced 2024-09-12 05:31:14 +02:00
rubocop => Security/IoMethods: File.write is safer than IO.write
This commit is contained in:
parent
e7211b0e69
commit
cff2f2c578
1 changed files with 2 additions and 2 deletions
4
Rakefile
4
Rakefile
|
@ -25,7 +25,7 @@ file 'man/colorls.1' => ['man/colorls.1.ronn', 'lib/colorls/flags.rb'] do
|
|||
organization: "colorls #{ColorLS::VERSION}"
|
||||
}
|
||||
doc = Ronn::Document.new(nil, attributes) do
|
||||
template = IO.read('man/colorls.1.ronn')
|
||||
template = File.read('man/colorls.1.ronn')
|
||||
|
||||
section = ''
|
||||
flags.options.each do |o|
|
||||
|
@ -37,7 +37,7 @@ OPTION
|
|||
end
|
||||
template.sub('{{ OPTIONS }}', section)
|
||||
end
|
||||
IO.write('man/colorls.1', doc.convert('roff'))
|
||||
File.write('man/colorls.1', doc.convert('roff'))
|
||||
end
|
||||
|
||||
desc 'Build the Zsh completion file'
|
||||
|
|
Loading…
Reference in a new issue