miller/scripts/escbak
2022-01-03 13:49:21 -05:00

10 lines
256 B
Ruby
Executable file

#!/usr/bin/env ruby
# Replaces L` and R` with Go-compatible backtick-inside-backticking.
# Makes it easier for me to type markdown-generating Go code.
ARGF.each do |line|
line.chomp!
line.gsub!('L`', '`+"`')
line.gsub!('R`', '`"+`')
puts line
end