Browse Source
Merge pull request #3345 from AvaloniaUI/fixes/filter-snap-dir-linux
Exclude snap directories in Managed Dialogs volume enumeration
pull/3359/head
danwalmsley
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
2 additions and
1 deletions
-
src/Avalonia.FreeDesktop/LinuxMountedVolumeInfoListener.cs
|
|
|
@ -47,7 +47,8 @@ namespace Avalonia.FreeDesktop |
|
|
|
|
|
|
|
var fProcMounts = File.ReadAllLines(ProcMountsDir) |
|
|
|
.Select(x => x.Split(' ')) |
|
|
|
.Select(x => (x[0], x[1])); |
|
|
|
.Select(x => (x[0], x[1])) |
|
|
|
.Where(x => !x.Item2.StartsWith("/snap/", StringComparison.InvariantCultureIgnoreCase)); |
|
|
|
|
|
|
|
var labelDirEnum = Directory.Exists(DevByLabelDir) ? |
|
|
|
new DirectoryInfo(DevByLabelDir).GetFiles() : Enumerable.Empty<FileInfo>(); |
|
|
|
|