Skip to content

Commit 1a7d17e

Browse files
authored
Merge pull request #4439 from DataDog/sarahchen6/add-ignored-files-to-steep-summary
Add ignored files to GHA steep summary.
2 parents b1ff73a + 0b29186 commit 1a7d17e

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

tasks/steep.rake

+12
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,18 @@ namespace :steep do
6464
$stdout.write('|')
6565
$stdout.write("\n")
6666
end
67+
68+
# Append ignored files from Steepfile to the end of the steep/typecheck summary
69+
File
70+
.foreach('Steepfile')
71+
.with_object([]) { |line, ignored_files| line =~ /^\s*ignore\s+(["'])(.*?(?:\\?.)*?)\1/ && ignored_files << $2 }
72+
.each do |file|
73+
if File.exist?(file)
74+
$stdout.write("|datadog|#{file}|ignored|N/A|N/A|N/A|0|\n")
75+
else
76+
warn "Ignored file '#{file}' does not exist. Please remove it from the Steepfile."
77+
end
78+
end
6779
else
6880
sh "steep stats --format=#{format}"
6981
end

0 commit comments

Comments
 (0)