Using svn:global-ignores for Project-Wide Ignore Patterns

Note to self:

If you’re using Subversion and want ignore patterns that apply to your entire repository and work for all team members, svn:global-ignores is the solution. Unlike client-side configuration (like TortoiseSVN‘s global ignore settings), this property lives in the repository itself.

Setting It Up

Set the property on your repository root:

svn propset svn:global-ignores "*.*~
*.~*
*.identcache
*.drc
__history
__recovery
*.dsk
*.local
*.tvsconfig
*.ddp
*.stat" .

Then commit:

svn commit -m "Add svn:global-ignores for build artifacts" .

The Critical Detail: Newline-Separated Patterns

Similar to svn:ignore each pattern must be on its own line. Space-separated patterns do not work.

Wrong:

*.obj *.dcu __history

Correct:

*.obj
*.dcu
__history

Verifying It Works

Check inheritance in subdirectories:

svn propget svn:global-ignores path/to/subdir --show-inherited-props

Verify files are ignored (should show I instead of ?):

svn status --no-ignore

Requirements

  • Subversion 1.8 or newer client
  • The property can only be set on directories
  • Patterns combine with (don’t replace) client-side global-ignores and svn:ignore

Why Use This?

  • Works for everyone: No per-developer configuration needed
  • Inherited automatically: Applies to all subdirectories
  • Version controlled: Changes to ignore patterns are tracked

This is particularly useful for IDE-generated files that vary by developer machine but shouldn’t be committed. (For Delphi that’s the list in the first example.)

(I had Claude Code generate this blog post. But I proofread and adapted it so any remaining errors are mine.)