Created
October 20, 2017 03:41
-
-
Save k-oguma/689c9e5e5ec149901583dbca1d6b2f51 to your computer and use it in GitHub Desktop.
If there is no README, this makes the template.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
README = 'README.md' | |
unless File.exist? README | |
puts 'Not found README file' | |
puts "Creating #{README}" | |
print = <<-EOS.gsub(/^ {,4}/, "## ").gsub(/\n/, "\n\n\n") | |
Synopsis | |
Requirements | |
Notice | |
Code Example | |
Installation | |
Command Reference | |
EOS | |
File.write(README, print) | |
puts '=================' | |
puts "#{README} was created." | |
puts | |
puts "Please edit the #{README}" | |
end | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment