https://github.com/cran/fda
Tip revision: f53803be917141c97d93914515a2fb90029853b5 authored by J. O. Ramsay on 08 August 2006, 00:00:00 UTC
version 1.1.6
version 1.1.6
Tip revision: f53803b
add-links.rb
Dir["*/*.[rR]d"].each do |path|
puts path
file = File.new(path, "r")
update = file.read.gsub(/\\seealso\{(.*?)\}/smi) do
"\\seealso{\n" +
$1.gsub("\n","").split(/[\, ]+/).map{|f| "\\code{\\link{#{f}}}"}.join(", \n") +
"\n}"
end
file.close
file = File.new(path, "w")
file.write update
file.close
end