@@ -130,6 +130,8 @@ export interface SyncResult {
130130 error ?: string ;
131131 /** Warnings for plugins that were skipped during sync */
132132 warnings ?: string [ ] ;
133+ /** Informational messages (non-warning) */
134+ messages ?: string [ ] ;
133135 /** Result of syncing MCP server configs to VS Code */
134136 mcpResult ?: McpMergeResult ;
135137 /** Result of native CLI plugin installations */
@@ -141,6 +143,7 @@ export interface SyncResult {
141143 */
142144export function mergeSyncResults ( a : SyncResult , b : SyncResult ) : SyncResult {
143145 const warnings = [ ...( a . warnings || [ ] ) , ...( b . warnings || [ ] ) ] ;
146+ const messages = [ ...( a . messages || [ ] ) , ...( b . messages || [ ] ) ] ;
144147 const purgedPaths = [ ...( a . purgedPaths || [ ] ) , ...( b . purgedPaths || [ ] ) ] ;
145148 // Use whichever mcpResult is present (only user-scope sync produces one)
146149 const mcpResult = a . mcpResult ?? b . mcpResult ;
@@ -161,6 +164,7 @@ export function mergeSyncResults(a: SyncResult, b: SyncResult): SyncResult {
161164 totalSkipped : a . totalSkipped + b . totalSkipped ,
162165 totalGenerated : a . totalGenerated + b . totalGenerated ,
163166 ...( warnings . length > 0 && { warnings } ) ,
167+ ...( messages . length > 0 && { messages } ) ,
164168 ...( purgedPaths . length > 0 && { purgedPaths } ) ,
165169 ...( mcpResult && { mcpResult } ) ,
166170 ...( nativeResult && { nativeResult } ) ,
@@ -275,6 +279,13 @@ function collectNativePluginSources(validPlugins: ValidatedPlugin[]): {
275279 return { pluginsByClient, marketplaceSourcesByClient } ;
276280}
277281
282+ function attachNativeClientContext ( result : NativeSyncResult , clientType : ClientType ) : NativeSyncResult {
283+ return {
284+ ...result ,
285+ pluginsFailed : result . pluginsFailed . map ( ( failure ) => ( { ...failure , client : clientType } ) ) ,
286+ } ;
287+ }
288+
278289function collectSyncClients (
279290 clientEntries : ClientEntry [ ] ,
280291 plans : PluginSyncPlan [ ] ,
@@ -1316,6 +1327,7 @@ export async function syncWorkspace(
13161327 ...planWarnings ,
13171328 ...failedValidations . map ( ( v ) => `${ v . plugin } : ${ v . error } (skipped)` ) ,
13181329 ] ;
1330+ const messages : string [ ] = [ ] ;
13191331
13201332 // If ALL plugins failed, abort
13211333 if ( validPlugins . length === 0 && filteredPlans . length > 0 ) {
@@ -1412,7 +1424,7 @@ export async function syncWorkspace(
14121424 if ( ! cliAvailable ) {
14131425 const sources = nativePluginsByClient . get ( clientType ) ;
14141426 if ( sources && sources . length > 0 ) {
1415- warnings . push ( `Native install: ${ clientType } CLI not found, skipping native plugin installation` ) ;
1427+ messages . push ( `Native install: ${ clientType } CLI not found, skipping native plugin installation` ) ;
14161428 }
14171429 continue ;
14181430 }
@@ -1443,7 +1455,12 @@ export async function syncWorkspace(
14431455
14441456 // Install
14451457 if ( currentSources . length > 0 ) {
1446- perClientResults . push ( await nativeClient . syncPlugins ( currentSources , 'project' , { cwd : workspacePath } ) ) ;
1458+ perClientResults . push (
1459+ attachNativeClientContext (
1460+ await nativeClient . syncPlugins ( currentSources , 'project' , { cwd : workspacePath } ) ,
1461+ clientType ,
1462+ ) ,
1463+ ) ;
14471464 }
14481465 }
14491466
@@ -1455,7 +1472,12 @@ export async function syncWorkspace(
14551472 for ( const [ clientType , sources ] of nativePluginsByClient ) {
14561473 const nativeClient = getNativeClient ( clientType ) ;
14571474 if ( nativeClient && sources . length > 0 ) {
1458- perClientResults . push ( await nativeClient . syncPlugins ( sources , 'project' , { cwd : workspacePath , dryRun : true } ) ) ;
1475+ perClientResults . push (
1476+ attachNativeClientContext (
1477+ await nativeClient . syncPlugins ( sources , 'project' , { cwd : workspacePath , dryRun : true } ) ,
1478+ clientType ,
1479+ ) ,
1480+ ) ;
14591481 }
14601482 }
14611483 if ( perClientResults . length > 0 ) {
@@ -1654,6 +1676,7 @@ export async function syncWorkspace(
16541676 totalGenerated,
16551677 purgedPaths,
16561678 ...( warnings . length > 0 && { warnings } ) ,
1679+ ...( messages . length > 0 && { messages } ) ,
16571680 ...( nativeResult && { nativeResult } ) ,
16581681 } ;
16591682}
@@ -1702,6 +1725,7 @@ export async function syncUserWorkspace(
17021725 ...planWarnings ,
17031726 ...failedValidations . map ( ( v ) => `${ v . plugin } : ${ v . error } (skipped)` ) ,
17041727 ] ;
1728+ const messages : string [ ] = [ ] ;
17051729
17061730 // If ALL plugins failed, abort
17071731 if ( validPlugins . length === 0 && pluginPlans . length > 0 ) {
@@ -1808,7 +1832,7 @@ export async function syncUserWorkspace(
18081832 if ( ! cliAvailable ) {
18091833 const sources = nativePluginsByClient . get ( clientType ) ;
18101834 if ( sources && sources . length > 0 ) {
1811- warnings . push ( `Native install: ${ clientType } CLI not found, skipping native plugin installation` ) ;
1835+ messages . push ( `Native install: ${ clientType } CLI not found, skipping native plugin installation` ) ;
18121836 }
18131837 continue ;
18141838 }
@@ -1838,7 +1862,12 @@ export async function syncUserWorkspace(
18381862
18391863 // Install
18401864 if ( currentSources . length > 0 ) {
1841- perClientResults . push ( await nativeClient . syncPlugins ( currentSources , 'user' ) ) ;
1865+ perClientResults . push (
1866+ attachNativeClientContext (
1867+ await nativeClient . syncPlugins ( currentSources , 'user' ) ,
1868+ clientType ,
1869+ ) ,
1870+ ) ;
18421871 }
18431872 }
18441873
@@ -1850,7 +1879,12 @@ export async function syncUserWorkspace(
18501879 for ( const [ clientType , sources ] of nativePluginsByClient ) {
18511880 const nativeClient = getNativeClient ( clientType ) ;
18521881 if ( nativeClient && sources . length > 0 ) {
1853- perClientResults . push ( await nativeClient . syncPlugins ( sources , 'user' , { dryRun : true } ) ) ;
1882+ perClientResults . push (
1883+ attachNativeClientContext (
1884+ await nativeClient . syncPlugins ( sources , 'user' , { dryRun : true } ) ,
1885+ clientType ,
1886+ ) ,
1887+ ) ;
18541888 }
18551889 }
18561890 if ( perClientResults . length > 0 ) {
@@ -1891,6 +1925,7 @@ export async function syncUserWorkspace(
18911925 totalSkipped,
18921926 totalGenerated,
18931927 ...( warnings . length > 0 && { warnings } ) ,
1928+ ...( messages . length > 0 && { messages } ) ,
18941929 ...( mcpResult && { mcpResult } ) ,
18951930 ...( nativeResult && { nativeResult } ) ,
18961931 } ;
0 commit comments