summaryrefslogtreecommitdiff
path: root/lib/tasks/flay.rake
blob: 4b4881cecb88569bc98d05ce9e1a2c06813509de (plain)
1
2
3
4
5
6
7
8
9
desc 'Code duplication analyze via flay'
task :flay do
  output = `bundle exec flay --mass 35 app/ lib/gitlab/ 2> #{File::NULL}`

  if output.include?("Similar code found") || output.include?("IDENTICAL code found")
    puts output
    exit 1
  end
end