diff options
author | Kenneth Skovhede <kenneth@hexad.dk> | 2021-03-06 17:02:01 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-06 17:02:01 +0300 |
commit | ecc2cc57ef9d2a5613d0c38ea8c332fa753f0fd2 (patch) | |
tree | 79c94b931e0d27c36c90223e42ddc39fbd12f075 /Duplicati | |
parent | 2d7b40d0793f96bf6766ee78b9d7c1adca943319 (diff) | |
parent | 6ddcdfb403a2048180dee9503a41d173d692233e (diff) |
Merge pull request #4401 from warwickmm/cache_dir_environment_variable
Add $XDG_CACHE_HOME to Linux CacheFiles filter
Diffstat (limited to 'Duplicati')
-rw-r--r-- | Duplicati/Library/Utility/FilterGroups.cs | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Duplicati/Library/Utility/FilterGroups.cs b/Duplicati/Library/Utility/FilterGroups.cs index 9ed80e069..e59255453 100644 --- a/Duplicati/Library/Utility/FilterGroups.cs +++ b/Duplicati/Library/Utility/FilterGroups.cs @@ -547,7 +547,7 @@ namespace Duplicati.Library.Utility yield return FilterGroups.CreateWildcardFilter(@"/sbin/");
yield return FilterGroups.CreateWildcardFilter(@"/var/");
}
-
+
if (group.HasFlag(FilterGroup.TemporaryFiles))
{
yield return FilterGroups.CreateWildcardFilter(@"*/lost+found/");
@@ -556,6 +556,11 @@ namespace Duplicati.Library.Utility }
if (group.HasFlag(FilterGroup.CacheFiles))
{
+ string cacheHome = Environment.GetEnvironmentVariable("XDG_CACHE_HOME");
+ if (cacheHome != null)
+ {
+ yield return FilterGroups.CreateWildcardFilter(cacheHome);
+ }
yield return FilterGroups.CreateWildcardFilter(@"*/.cache/");
yield return FilterGroups.CreateWildcardFilter(@"*/.config/google-chrome/Default/Cookies");
yield return FilterGroups.CreateWildcardFilter(@"*/.config/google-chrome/Default/Cookies-journal");
|