Title: Git diff - ignore specific texts per file type
Tags: git;diff;atlassian-sourcetree;git-config
Question: What I am trying to do is to have git ignore specific pieces of text per file type, and store those settings so can be used through out a project.

The issue is that my IDE adds specific lines/text on files, that I would like Git to ignore and not count as changes. For example:

for .xml files, ignore text like this: ```<modified&gt;2019-01-01</modified&gt;```. 

for .txt files, ignore text like this: ```"# last comment by" and "sequence:"```

for .properties files, ignore text like this: ```"some text to ignore"```

etc etc

So, using the examples above, if the only change to an .xml file is the ```<modified&gt;``` tag data, git should not consider this as a modified file.

What I would like to do is store those settings in a config file so that can be used though out the project. I am currently using SourceTree so if there is a SourceTree specific solution it would be nice to use but I couldn't find anything.

Comment: Possible duplicate of [Can git ignore a specific line?](https://stackoverflow.com/questions/6557467/can-git-ignore-a-specific-line)

Comment: Possible duplicate of [How to tell git to ignore individual lines, i.e. gitignore for specific lines of code](https://stackoverflow.com/questions/16244969/how-to-tell-git-to-ignore-individual-lines-i-e-gitignore-for-specific-lines-of) or of https://stackoverflow.com/questions/6557467/can-git-ignore-a-specific-line (better)



{'source': 'StackExchangeDataset', 'subset': 'stackoverflow.com', 'metadata': {'AnswerCount': 0, 'CommentCount': 2, 'ContentLicense': 'CC BY-SA 4.0', 'CreationDate': '2019:00:06/07/19', 'FavoriteCount': None, 'PostTypeId': 1, 'Tags': '<git><diff><atlassian-sourcetree><git-config>', 'Title': 'Git diff - ignore specific texts per file type', 'ViewCount': 140, 'id': 56499769, 'user_AboutMe': None, 'user_AccountId': 2644322.0, 'user_DisplayName': 'user2287359', 'user_Reputation': 457.0, 'user_Views': 31.0, 'user_id': 2287359.0}}