Given a directory /fruits
with files apple.js, banana.js and orange.js
is there an indicator to distinguish between these two pull requests
/fruits
has files apple.js, banana.js and orange.js
removed/fruits
is deleted along with apple.js, banana.js orange.js
apple.js, banana.js, and orange.js
have their content completely wiped but the file remains (empty file)I'm currently looking at a PR where the directory was was removed along with its contents but in my experience it looks identical to a PR where the files contents would have been removed.
In Git, you cannot commit empty folders, because Git does not actually save folders, only files. Therefore removing all files in a directory will effectively "delete" it from your repository. This means that your examples 1. and 2. are identical.
Example 3. will be different: a file with only its contents deleted will show you a diff of all deleted lines, but a deleted file would show you a message: "This file was deleted", it looks like this:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With