1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-06-18 23:07:45 +02:00

All: Add support for sync target lock

The goal is to allow locking a sync target so that maintenance
operations, such as upgrading the target to a more efficient format,
can be done. For now, only the lock mechanism is in place, as a way to
evaluate it, and to see if it can cause any issue.
This commit is contained in:
Laurent Cozic
2020-07-10 23:42:03 +01:00
parent 003ead2511
commit 51235f191d
16 changed files with 522 additions and 87 deletions

View File

@ -128,6 +128,7 @@ class FileApi {
if (!options) options = {};
if (!('includeHidden' in options)) options.includeHidden = false;
if (!('context' in options)) options.context = null;
if (!('includeDirs' in options)) options.includeDirs = true;
this.logger().debug(`list ${this.baseDir()}`);
@ -141,6 +142,10 @@ class FileApi {
result.items = temp;
}
if (!options.includeHidden) {
result.items = result.items.filter(f => !f.isDir);
}
return result;
}