1
1
mirror of https://github.com/github/semantic.git synced 2024-11-27 03:09:48 +03:00
semantic/generate_hie_yaml.rb

18 lines
362 B
Ruby
Raw Normal View History

#!/usr/bin/env ruby
require 'yaml'
components = []
Dir.glob("./semantic*").each do |dir|
components << {'path' => dir + '/src', 'component' => "lib:" + dir[2..]}
end
Dir.glob("./semantic*/test").each do |dir|
components << {'path' => dir, 'component' => "test:" + dir[2..-6]}
end
result = {'cradle' => { 'cabal' => components }}
puts YAML.dump(result)