File tree Expand file tree Collapse file tree 1 file changed +12
-4
lines changed
Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -125,14 +125,22 @@ async function runAugmentScript(inputs: ActionInputs): Promise<void> {
125125 args . push ( '--instruction' , instruction_value ) ;
126126 }
127127
128- if ( inputs . rules ?. length ) {
129- for ( const rulePath of inputs . rules ) {
128+ const uniqueRules = Array . from ( new Set ( inputs . rules ?? [ ] ) ) . filter ( rule => rule . length > 0 ) ;
129+ if ( uniqueRules . length > 0 ) {
130+ logger . info ( `🔧 Applying ${ uniqueRules . length } rule file(s)` ) ;
131+ for ( const rulePath of uniqueRules ) {
132+ logger . info ( ` - ${ rulePath } ` ) ;
130133 args . push ( '--rules' , rulePath ) ;
131134 }
132135 }
133136
134- if ( inputs . mcpConfigs ?. length ) {
135- for ( const configPath of inputs . mcpConfigs ) {
137+ const uniqueMcpConfigs = Array . from ( new Set ( inputs . mcpConfigs ?? [ ] ) ) . filter (
138+ config => config . length > 0
139+ ) ;
140+ if ( uniqueMcpConfigs . length > 0 ) {
141+ logger . info ( `🧩 Applying ${ uniqueMcpConfigs . length } MCP config file(s)` ) ;
142+ for ( const configPath of uniqueMcpConfigs ) {
143+ logger . info ( ` - ${ configPath } ` ) ;
136144 args . push ( '--mcp-config' , configPath ) ;
137145 }
138146 }
You can’t perform that action at this time.
0 commit comments