We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 15485c3 commit 16d48c0Copy full SHA for 16d48c0
lib/fdiff/__main__.py
@@ -144,8 +144,17 @@ def run(argv):
144
iterable = diff
145
146
# print unified diff results to standard output stream
147
+ # TODO: add support for text output to indicate that there was no diff found
148
+ # TODO: ( see https://stackoverflow.com/a/661967 )
149
+ has_output = False
150
if args.color:
151
for line in iterable:
152
+ has_output = True
153
sys.stdout.write(color_unified_diff_line(line))
154
else:
- sys.stdout.writelines(iterable)
155
+ for line in iterable:
156
157
+ sys.stdout.write(line)
158
+
159
+ if not has_output:
160
+ print("[*] There is no difference between the files.")
0 commit comments