Skip to content

Commit

Permalink
Don't ever warn about some specific files
Browse files Browse the repository at this point in the history
  • Loading branch information
tbradsha committed Feb 7, 2025
1 parent af2df47 commit 426b4c4
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions tools/cli/commands/rsync.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,13 @@ export async function rsyncInit( argv ) {

const paths = await rsyncToDest( sourcePluginPath, finalDest );

// Warn but don't fail if file was intentionally not synced.
if ( event === 'change' && ! paths.has( eventfile ) ) {
// Warn but don't fail if file was intentionally not synced. We still want to sync
// if a change event occurs, as other change events could have been debounced.
if (
event === 'change' &&
! paths.has( eventfile ) &&
! [ '../../../.git/index', '.gitignore', '.gitattributes' ].includes( eventfile ) // ignore some specific files
) {
let unsync_reason;
if ( ! ( await isFileTracked( sourcePluginPath + eventfile ) ) ) {
unsync_reason = 'not tracked by git';
Expand Down

0 comments on commit 426b4c4

Please sign in to comment.