33 * SPDX-License-Identifier: Apache-2.0
44 */
55
6- import { fs , getNodeExecutableName , BaseLspInstaller , ResourcePaths } from 'aws-core-vscode/shared'
6+ import { fs , getNodeExecutableName , getRgExecutableName , BaseLspInstaller , ResourcePaths } from 'aws-core-vscode/shared'
77import path from 'path'
88import { ExtendedAmazonQLSPConfig , getAmazonQLspConfig } from './config'
99
@@ -22,21 +22,25 @@ export class AmazonQLspInstaller extends BaseLspInstaller.BaseLspInstaller<
2222 protected override async postInstall ( assetDirectory : string ) : Promise < void > {
2323 const resourcePaths = this . resourcePaths ( assetDirectory )
2424 await fs . chmod ( resourcePaths . node , 0o755 )
25+ await fs . chmod ( resourcePaths . rg , 0o755 )
2526 }
2627
2728 protected override resourcePaths ( assetDirectory ?: string ) : AmazonQResourcePaths {
2829 if ( ! assetDirectory ) {
2930 return {
3031 lsp : this . config . path ?? '' ,
3132 node : getNodeExecutableName ( ) ,
33+ rg : getRgExecutableName ( ) ,
3234 ui : this . config . ui ?? '' ,
3335 }
3436 }
3537
3638 const nodePath = path . join ( assetDirectory , `servers/${ getNodeExecutableName ( ) } ` )
39+ const rgPath = path . join ( assetDirectory , `servers/${ getRgExecutableName ( ) } ` )
3740 return {
3841 lsp : path . join ( assetDirectory , 'servers/aws-lsp-codewhisperer.js' ) ,
3942 node : nodePath ,
43+ rg : rgPath ,
4044 ui : path . join ( assetDirectory , 'clients/amazonq-ui.js' ) ,
4145 }
4246 }
0 commit comments