1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

change to non-complete shallow watching

Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
Sebastian Malton 2021-04-29 08:48:16 -04:00
parent d410596997
commit 2085383987
2 changed files with 2 additions and 4 deletions

View File

@ -216,10 +216,8 @@ function diffChangedConfig(filePath: string, source: RootSource, port: number):
function watchFileChanges(filePath: string, port: number): [IComputedValue<CatalogEntity[]>, Disposer] {
const watcher = watch(filePath, {
followSymlinks: true,
depth: 0, // shallow
depth: 1, // shallow
disableGlobbing: true,
alwaysStat: false,
ignoreInitial: false,
});
const rootSource = new ExtendedObservableMap<string, ObservableMap<string, RootSourceValue>>(observable.map);
const derivedSource = computed(() => Array.from(iter.flatMap(rootSource.values(), from => iter.map(from.values(), child => child[1]))));

View File

@ -168,7 +168,7 @@ export class KubeconfigSyncs extends React.Component {
onClick={() => void this.openFileDialog()}
/>
<div className="hint">
Sync an individual file or folder shallowly.
Sync an individual file or folders (and subfolders to a depth of 1).
</div>
{this.renderEntries()}
</section>