Add useful_git_commands.md

Start of adding a set of useful git commands

Signed-off-by: Arif Ali <mail@arif-ali.co.uk>
This commit is contained in:
Arif Ali 2025-02-24 10:52:37 +00:00
parent 7721edf826
commit 5c11421793

19
useful_git_commands.md Normal file
View File

@ -0,0 +1,19 @@
# Useful git commands
Check difference between to branches/tags and will exclude the changelog
```
git diff @..pkg/import/4.8.1-2 -- ':(exclude)debian/changelog'
```
Check only the files, in this example the debian folder
```
git diff @..pkg/import/4.8.1-2 -- 'debian/'
```
Check differences in the debian folder, but exclude the changelog
```
git diff pkg/import/4.8.1-2..@ -- debian/ ':(exclude)debian/changelog'
```