diff --git a/README.md b/README.md index d205d843..e9bace96 100644 --- a/README.md +++ b/README.md @@ -114,6 +114,22 @@ StyleCop.StyleCop,ReSharperPlugin.CognitiveComplexity The directory to run the command in. All paths (solution path, include/exclude patterns, etc) are also relative to this directory. +### noBuild + +- true +- false (default) + +et you specify whether to build the target solution before starting the analysis. +By default, InspectCode always builds the solution. + +More info: https://www.jetbrains.com/help/resharper/InspectCode.html#inspection-parameters + +### cacheHome + +Lets you specify a custom location for the data that InspectCode caches. + +More info: https://www.jetbrains.com/help/resharper/InspectCode.html#inspection-parameters + ## Usage ```yaml diff --git a/action.yml b/action.yml index a69dd9db..57267f65 100644 --- a/action.yml +++ b/action.yml @@ -38,6 +38,13 @@ inputs: extensions: required: false description: Comma-separated list of extensions to install. + noBuild: + required: false + default: 'false' + description: Let you specify whether to build the target solution before starting the analysis. By default (false), InspectCode always builds the solution. + cachesHome: + required: false + description: Lets you specify a custom location for the data that InspectCode caches. runs: using: 'node20' main: 'dist/index.js' diff --git a/package.json b/package.json index dfd79ae8..6014db67 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "resharper_inspectcode", - "version": "1.8.5", + "version": "1.9.0", "private": true, "description": "Run ReSharper Inspection action", "main": "lib/main.js", diff --git a/src/main.ts b/src/main.ts index 15108cfb..dd023487 100644 --- a/src/main.ts +++ b/src/main.ts @@ -44,6 +44,16 @@ async function run(): Promise { .replace(/(,\s?)|(;\s?)/g, ';')}` } + const noBuild = core.getInput('noBuild') ?? '' + if (noBuild.toLowerCase() === 'true') { + command += ' --no-build' + } + + const cachesHome = core.getInput('cachesHome') ?? '' + if (cachesHome !== '') { + command += ` --caches-home=${cachesHome}` + } + const workingDir: string = core.getInput('workingDirectory') if (workingDir) { core.debug(`Changing to working directory: ${workingDir}`)