Exclude ./nancy.db from FSEntry.from_path() scanning by default
This commit is contained in:
parent
183e3ed613
commit
a750b53a10
@ -100,7 +100,7 @@ class FSEntry:
|
||||
self.sha256 = self.latest_version.sha256
|
||||
|
||||
@classmethod
|
||||
def from_path(cls, root, relpath='.', filestat=None):
|
||||
def from_path(cls, root, relpath='.', filestat=None, exclude=['./nancy.db']):
|
||||
"""
|
||||
Scan a path to instantiate (recursive).
|
||||
"""
|
||||
@ -137,7 +137,8 @@ class FSEntry:
|
||||
relpath=os.path.join(relpath, e.name),
|
||||
filestat=e.stat(),
|
||||
)
|
||||
for e in direntries
|
||||
for e in direntries \
|
||||
if os.path.join(relpath, e.name) not in exclude
|
||||
]
|
||||
for c in children: # now hash concatenated sorted hashes
|
||||
# hash on perms+sha256 to enable recursively detecting perm
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user