Method: Mdoc#find_out_file
- Defined in:
- lib/mdoc.rb
#find_out_file(fname) ⇒ Object
rubocop:enable MethodLength
91 92 93 94 95 |
# File 'lib/mdoc.rb', line 91 def find_out_file(fname) return opts.output if opts.output ext = '.' + opts.template.split('.')[-1] fname =~ /\.\w{2,5}$/ ? fname.gsub(/\.\w+$/, ext) : fname + ext end |