Skip to content

Commit 8a4c635

Browse files
committed
pretty print json + response on starting server
1 parent 4a99d72 commit 8a4c635

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

mini_compile_commands_server.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,13 @@ def __init__(self, server_address, RequestHandlerClass):
3535

3636
def server_close(self):
3737
with open(compile_commands_output, 'w') as f:
38-
f.write(json.dumps(self.compile_commands))
38+
f.write(json.dumps(self.compile_commands, indent=4))
3939
f.write('\n')
4040

4141
super().server_close()
4242

4343
server = Server(unix_socket_file, Handler)
44+
print("awaiting compile commands...")
4445

4546
def signal_handler(sig, frame):
4647
print('')

0 commit comments

Comments
 (0)