Added auto lang listing and CONTRIBUTING.md
Added a small framework for easily updating a list of all languages the repository contains a "Hello World" program in. See CONTRIBUTING.md for a command for updating the listing (using the list_langs.rb Ruby script).
This commit is contained in:
13
list_langs.rb
Normal file
13
list_langs.rb
Normal file
@@ -0,0 +1,13 @@
|
||||
Dir.foreach "." do |odir|
|
||||
next if odir == "." or odir == ".." or not File.directory?(odir)
|
||||
Dir.foreach odir do |dir|
|
||||
next if dir == "." or dir == ".."
|
||||
currdirname = ""
|
||||
dir.split(".")[0].gsub("-", " ").split(" ").each do |str|
|
||||
currdirname << str.capitalize + " "
|
||||
end
|
||||
currdirname.chomp(currdirname[-1])
|
||||
puts "* #{currdirname}"
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user