From 5ff1ead6b2d6da7ba044b11e2824c7cbf5a94cb8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Jos=C3=A9?= Date: Thu, 24 Aug 2023 09:02:04 -0500 Subject: [PATCH] build: add symlink to `compile_commands.json` file if needed MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Usually lsp servers needs the `compile_commands.json` file in the root directory. Signed-off-by: Juan José Arboleda PR-URL: https://github.com/nodejs/node/pull/49260 Reviewed-By: Rafael Gonzaga Reviewed-By: Yagiz Nizipli --- configure.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/configure.py b/configure.py index 9a478c5f983a51..2cb81f200c7194 100755 --- a/configure.py +++ b/configure.py @@ -2116,6 +2116,8 @@ def make_bin_override(): if options.compile_commands_json: gyp_args += ['-f', 'compile_commands_json'] + os.path.islink('./compile_commands.json') and os.unlink('./compile_commands.json') + os.symlink('./out/' + config['BUILDTYPE'] + '/compile_commands.json', './compile_commands.json') # override the variable `python` defined in common.gypi if bin_override is not None: