Skip to content

Instantly share code, notes, and snippets.

@ludndev
Created January 14, 2026 10:20
Show Gist options
  • Select an option

  • Save ludndev/e0e032b55e6b5e0cc540413ab650878f to your computer and use it in GitHub Desktop.

Select an option

Save ludndev/e0e032b55e6b5e0cc540413ab650878f to your computer and use it in GitHub Desktop.
Git: Ignore local changes to a tracked file

Git: Ignore local changes to a tracked file

Useful for local config overrides.

Ignore local modifications.

git update-index --assume-unchanged path/to/file.ext

Re-enable change tracking for the file.

git update-index --no-assume-unchanged path/to/file.ext
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment