diff --git a/validator.rb b/validator.rb new file mode 100644 index 0000000000000000000000000000000000000000..5c009ba8dc37169144eafc7e9b349426ab9d4ab3 --- /dev/null +++ b/validator.rb @@ -0,0 +1,13 @@ +require 'yaml' + +# run `ruby validator.rb` in current directory + +Dir.children('projects').each do |folder| + begin + path = "projects/#{folder}/imports.yml" + YAML.load(File.read(path)) if File.exists?(path) + rescue => exception + puts "#{exception}" + puts "Format wrong with projects/#{folder}/imports.yml" + end +end \ No newline at end of file