@@ -63,7 +63,14 @@ class Installer {
6363 (0, log_1.default)(log_1.LogLevel.Info, `Installing the appmap.yml configuration provided by action input.`);
6464 yield (0, promises_1.writeFile)('appmap.yml', this.appmapConfig);
6565 }
66- yield (0, executeCommand_1.executeCommand)(`${this.appmapToolsPath} install --no-interactive --no-overwrite-appmap-config`);
66+ let cmd = `${this.appmapToolsPath} install --no-interactive --no-overwrite-appmap-config`;
67+ if (this.projectType)
68+ cmd += ` --project-type ${this.projectType}`;
69+ if (this.buildFile)
70+ cmd += ` --build-file ${this.buildFile}`;
71+ if (this.installerName)
72+ cmd += ` --installer-name ${this.installerName}`;
73+ yield (0, executeCommand_1.executeCommand)(cmd);
6774 (0, log_1.default)(log_1.LogLevel.Info, `AppMap language library has been installed and configured.`);
6875 });
6976 }
@@ -262,14 +269,22 @@ function uploadPatchFile(path) {
262269 yield upload.uploadArtifact('appmap-install.patch', [path], '.');
263270 });
264271}
272+ const Options = {
273+ 'appmap-config': 'appmapConfig',
274+ 'project-type': 'projectType',
275+ 'installer-name': 'installerName',
276+ 'build-file': 'buildFile',
277+ };
265278function runInGitHub() {
266279 return __awaiter(this, void 0, void 0, function* () {
267280 (0, verbose_1.default)(core.getBooleanInput('verbose'));
268- const appmapConfig = core.getInput('appmap-config');
269281 const appmapToolsURL = core.getInput('tools-url');
270282 const installer = new Installer_1.default(appmapToolsURL);
271- if (appmapConfig)
272- installer.appmapConfig = appmapConfig;
283+ for (const [inputName, fieldName] of Object.entries(Options)) {
284+ const value = core.getInput(inputName);
285+ if (value)
286+ installer[fieldName] = value;
287+ }
273288 yield installer.installAppMapTools();
274289 yield installer.installAppMapLibrary();
275290 const patch = yield installer.buildPatchFile();
0 commit comments