@@ -643,7 +643,7 @@ async function isPackageLinkedLocally(packageName, projectPath) {
643643}
644644
645645async function linkPackagesToTestProjects ( ) {
646- if ( ! watchMode ) hLog ( 0 , true , 'header' , 'npm link' , 'Linking packages to test projects...' , '\n' ) ;
646+ if ( ! isSilent ) hLog ( 0 , true , 'header' , 'npm link' , 'Linking packages to test projects...' , '\n' ) ;
647647 const testDir = path . join ( process . cwd ( ) , 'test' ) ;
648648 if ( ! fs . existsSync ( testDir ) ) {
649649 hLog ( 2 , true , 'warning' , '!' , 'No test directory found, skipping links' ) ;
@@ -655,30 +655,30 @@ async function linkPackagesToTestProjects() {
655655
656656 const globalLinkedPackages = await getGlobalLinkedPackages ( ) ;
657657
658- if ( ! watchMode ) hLog ( 2 , false , 'info' , '→' , 'Registering packages globally...' , '\n' ) ;
658+ if ( ! isSilent ) hLog ( 2 , false , 'info' , '→' , 'Registering packages globally...' , '\n' ) ;
659659
660660 for ( const pkg of packages ) {
661661 const packagePath = path . join ( packagesDir , pkg ) ;
662662 if ( fs . statSync ( packagePath ) . isDirectory ( ) ) {
663663 const packageName = pkg === 'vanilla' ? PROJECT_NAME : `@${ PROJECT_NAME } /${ pkg } ` ;
664664
665665 if ( globalLinkedPackages . has ( packageName ) ) {
666- if ( ! watchMode )
666+ if ( ! isSilent )
667667 hLog ( 4 , false , 'yellow' , '❉' , `Already linked globally: /#package ${ packageName } #/` ) ;
668668 continue ;
669669 }
670670
671671 try {
672672 await runCommand ( 'npm' , [ 'link' , '--silent' ] , packagePath ) ;
673- if ( ! watchMode )
673+ if ( ! isSilent )
674674 hLog ( 4 , false , 'success' , '✓' , `Linked globally: /#package ${ packageName } #/` ) ;
675675 } catch ( error ) {
676676 hLog ( 4 , true , 'error' , 'error' , `Failed to link ${ pkg } : ${ error . message } ` ) ;
677677 }
678678 }
679679 }
680680
681- if ( ! watchMode ) hLog ( 2 , false , 'info' , '→' , 'Linking packages in test projects...' , '\n' ) ;
681+ if ( ! isSilent ) hLog ( 2 , false , 'info' , '→' , 'Linking packages in test projects...' , '\n' ) ;
682682
683683 const testProjects = fs . readdirSync ( testDir ) ;
684684
@@ -687,7 +687,7 @@ async function linkPackagesToTestProjects() {
687687 if ( ! fs . statSync ( testProjectPath ) . isDirectory ( ) ) continue ;
688688 if ( ! fs . existsSync ( path . join ( testProjectPath , 'package.json' ) ) ) continue ;
689689
690- if ( ! watchMode ) hLog ( 4 , false , 'accent' , '◆' , `Test project: /#file ${ testProject } #/` ) ;
690+ if ( ! isSilent ) hLog ( 4 , false , 'accent' , '◆' , `Test project: /#file ${ testProject } #/` ) ;
691691 const packagesToLink = [ ] ;
692692
693693 if ( packages . includes ( testProject ) ) {
@@ -714,7 +714,7 @@ async function linkPackagesToTestProjects() {
714714 const alreadyLinkedLocally = await isPackageLinkedLocally ( packageName , testProjectPath ) ;
715715
716716 if ( alreadyLinkedLocally ) {
717- if ( ! watchMode )
717+ if ( ! isSilent )
718718 hLog (
719719 6 ,
720720 false ,
@@ -727,7 +727,7 @@ async function linkPackagesToTestProjects() {
727727
728728 try {
729729 await runCommand ( 'npm' , [ 'link' , packageName , '--silent' ] , testProjectPath ) ;
730- if ( ! watchMode )
730+ if ( ! isSilent )
731731 hLog (
732732 6 ,
733733 false ,
@@ -741,7 +741,7 @@ async function linkPackagesToTestProjects() {
741741 }
742742 }
743743
744- if ( ! watchMode ) hLog ( 0 , true , 'highlight' , 'done' , 'Package linking finished!' ) ;
744+ if ( ! isSilent ) hLog ( 0 , true , 'highlight' , 'done' , 'Package linking finished!' ) ;
745745}
746746
747747function replaceVersionInAllFiles ( directory , version ) {
@@ -835,7 +835,7 @@ async function build() {
835835 const versionReplace = replaceVersionInAllFiles ( 'packages' , rootPackageJson . version ) ;
836836
837837 if ( versionReplace . count > 0 ) {
838- if ( ! watchMode )
838+ if ( ! isSilent )
839839 hLog (
840840 2 ,
841841 true ,
0 commit comments