Document how to verify something is encrypted
- Dominant language
- C++
- Stars
- 9.9k
- Forks
- 544
- PR merge metrics
- No merged PRs in 30d
Description
The readme should encourage you to double check if something is encrypted after writing the .gitattributes file.
You can verify the filter is being matching by doing:
```
git check-attr -a --
```
An easier method (assuming you don't have other gitattributes!) I have found is to make sure the hash of the plain file DOES NOT match the hash of the object in the tree:
```
# Make sure these hashes DO NOT MATCH
$ git hash-object secretfile
eedff305e146f749da4253aafc7340845a72cec7
$ cat secretfile | git hash-object --stdin
eedff305e146f749da4253aafc7340845a72cec7 ### YOUR GIT ATTRIBUTE DID NOT WORK, your file is not encrypted
```
If you encrypt the file successfully the hashes will not match:
```
$ git hash-object secretfile
1ced004ffd1578dd783ada1e6ffc8b7c41717800
$ cat secretfile | git hash-object --stdin
eedff305e146f749da4253aafc7340845a72cec7
```
Contributor guide
Assessment
This issue has not been assessed yet.