Skip to content

Commit 233b2c4

Browse files
authored
Merge pull request #448 from owasp-noir/improve-no-log
Improve --no-log flag
2 parents 2f35d95 + c7b5b72 commit 233b2c4

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

src/models/logger.cr

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ class NoirLogger
1616
end
1717

1818
def heading(message)
19+
if @no_log
20+
return
21+
end
22+
1923
prefix = "".colorize(:yellow).toggle(@color_mode)
2024
STDERR.puts "#{prefix} #{message}"
2125
end

src/noir.cr

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,10 @@ if noir_options["exclude_codes"] != ""
5454
end
5555

5656
# Run Noir
57-
banner()
57+
if noir_options["nolog"] == false
58+
banner()
59+
end
60+
5861
app = NoirRunner.new noir_options
5962
start_time = Time.monotonic
6063

0 commit comments

Comments
 (0)