Commit Graph
348 Commits
Author SHA1 Message Date
Kenneth SkovhedeandGitHub 19851c88f0 Merge pull request #3227 from warwickmm/use_string_builder
Replace string concatenation with StringBuilder
2018-05-23 11:10:36 +02:00
Kenneth Hsu 0b016cea2c Replace string concatenation with StringBuilder.
When appending to a string in a loop, using a StringBuilder should in
general yield better performance.
2018-05-19 15:36:00 -07:00
verhoek 2f41e02ca9 Merge branch 'master' into refactored 2018-05-18 08:05:19 +02:00
verhoek 8a4031f66b Added skipped file in comparison spelling correction commit. 2018-05-16 20:24:31 +02:00
verhoek 143725c0b9 Removed some duplication. 2018-05-16 20:10:06 +02:00
verhoek 30cd41585b Corrected spelling function name. 2018-05-16 20:08:40 +02:00
verhoek be79384966 Removed duplicate ? when building urls with query parameters. 2018-05-15 21:50:14 +02:00
verhoek c5783b2ae4 Merge branch 'master' into webapi/googledrive 2018-05-15 20:31:58 +02:00
verhoek bbf489c86f Corrected appending paths to urls. 2018-05-14 22:53:13 +02:00
verhoek 6dd64a553d Fixed code quality issues. 2018-05-14 21:01:18 +02:00
Kenneth Hsu 9c6bccf478 Use braces to improve readability.
Previously, the indentation of the following code block gave the
impression that it was part of the foreach loop when in fact it would
only be executed once.
2018-05-13 14:24:13 -07:00
verhoek 007e4c0829 Cleaned up imports. 2018-05-13 12:48:00 +02:00
verhoek 6539c36e51 Merge branch 'master' into webapi/googledrive 2018-05-12 09:30:57 +02:00
verhoek 44b5b00276 Renamed some googledriveapi var names. Modified ListFolder to be more readable. 2018-05-11 19:57:09 +02:00
verhoek 78a46c3a5c Renamed misspelled class urluttility to urlutility and newly added urlutility to uriutility. 2018-05-11 19:09:14 +02:00
verhoek d303db30d6 Replacing magic strings in google drive rest calls by query key value pairs. 2018-05-11 18:23:16 +02:00
Kenneth Skovhede 2b54bb9415 Removed the redundant byte-array-to-string method from the MD5 module, and added a using directive.
Added some additional logging to better diagnose issues with VSS/LVM snapshots.
2018-05-09 10:44:32 +02:00
Daniel Gehriger 33d64ee442 Reduced number of affected files by PR 2018-04-26 23:12:39 +02:00
Daniel Gehriger 1af7f9e0ca Merge remote-tracking branch 'upstream/master' into feature/usn 2018-04-23 22:28:27 +02:00
Kenneth Skovhede 914b17055c Merge branch 'master' into concurrent_processing 2018-04-23 09:57:49 +02:00
Daniel Gehriger a7d60d88d7 Fixed post-processing of modified file list obtain from USN 2018-04-22 23:03:15 +02:00
Daniel Gehriger 8c1322273e Updated comment to retrigger AppVeyor 2018-04-20 23:51:26 +02:00
Daniel Gehriger b97d4e0dbb Correctly filtering list of changed files / folders using exclusion filter 2018-04-20 17:30:08 +02:00
Daniel Gehriger 8af63b1d5d Fixed some of the issues reported by codacy. The others are incorrect warnings. 2018-04-20 09:17:06 +02:00
Daniel Gehriger 2c1a0ddb4e Implemented backup based on changes recorded in NTFS USN journal 2018-04-19 22:59:28 +02:00
Tyler Gill c38654a314 Replace constant strings with cached readonly values. 2018-04-18 10:29:14 -06:00
Tyler Gill 10cfc28fb5 Use Utility.AppendDirSeparator to create SpecialFolder default filters. 2018-04-18 10:28:14 -06:00
Tyler Gill f2d7283be5 Fix folder path getter to not have an infinite recusion problem. 2018-04-16 13:07:12 -06:00
Tyler Gill 5185ee881d The way Duplicati matches folders against filters, the filter needs to either end with a wildcard or a slash in order to match.
However, the 'control_dir_v2', 'Windows.old', and the various Environment.SpecialFolders filters did not have trailing slashes, leading to these filters not actually applying when they should.
This change fix the few specific filters that need this specification, and adds a new utiltiy method to produce filters for SpecialFolders in a way that makes sure they end with a trailing slash.
2018-04-16 13:04:19 -06:00
Kenneth Skovhede cdd3c7b63c Merge branch 'master' into concurrent_processing 2018-04-12 15:10:03 +02:00
Kenneth SkovhedeandGitHub b3d1f19177 Merge pull request #3169 from tygill/feature/filter-groups
Add filter groups to replace default filters
2018-04-12 15:09:10 +02:00
Kenneth Skovhede 4e5f4a12bf Merge branch 'master' into feature/filters-for-sendmail
Integrated changes to support log-lines and to have a common shared module for reporters

# Conflicts:
#	Duplicati/Library/Modules/Builtin/Duplicati.Library.Modules.Builtin.csproj
#	Duplicati/Library/Modules/Builtin/RunScript.cs
#	Duplicati/Library/Modules/Builtin/SendHttpMessage.cs
#	Duplicati/Library/Modules/Builtin/SendJabberMessage.cs
#	Duplicati/Library/Modules/Builtin/SendMail.cs
2018-04-12 11:16:57 +02:00
Kenneth Skovhede 79f7b22e0f Merge branch 'master' into concurrent_processing
Changed a few things on the way, removing the log process

# Conflicts:
#	Duplicati/Library/Main/Controller.cs
#	Duplicati/Library/Main/Database/ExtensionMethods.cs
#	Duplicati/Library/Main/Database/LocalBackupDatabase.cs
#	Duplicati/Library/Main/Duplicati.Library.Main.csproj
#	Duplicati/Library/Main/Operation/BackupHandler.cs
#	Duplicati/Library/Main/Operation/FilelistProcessor.cs
#	Duplicati/Library/Main/Operation/PurgeBrokenFilesHandler.cs
#	Duplicati/Library/Main/Operation/TestFilterHandler.cs
#	Duplicati/Library/Main/Options.cs
#	Duplicati/Library/Main/ResultClasses.cs
#	Duplicati/UnitTest/BasicSetupHelper.cs
2018-04-11 23:02:47 +02:00
Fish 03fe3729cf Cache IsFSCaseSensitive to speed up file counting.
"IsFSCaseSensitive" used to call GetEnvironmentVariable() every time it
was accessed, which unnecessarily slows down the file counting procedure.
Caching the value of this environment variable speeds up things quite a
bit.
2018-04-10 20:46:03 -07:00
Tyler Gill a3a98c644a Merge branch 'master' of https://github.com/duplicati/duplicati into feature/filter-groups 2018-04-10 10:48:46 -06:00
Kenneth Skovhede 731ecfc47d Rewrote the report modules to use a shared base class with all the non-sending specific code.
Change the logic for how the log data is included. It is now added as log lines _after_ the normal messages.
Added support for limiting the number of log lines sent.
Added support for setting the log levels on the modules.
Added support for setting a log filter on the modules.
Added support for sending log data as JSON from the http module.
2018-04-10 12:58:06 +02:00
Kenneth Skovhede e0c3168f13 Merge branch 'feature/fix_log_spam' into feature/filters-for-sendmail 2018-04-09 14:31:50 +02:00
Kenneth Hsu cb0a3ed2a1 Make constructors for abstract classes protected.
While this does not affect any behavior, it more accurately describes
the accessibility.  Since abstract classes can only be instantiated by
an instance of a derived type, the constructors should at most have
protected access.
2018-04-07 18:04:41 -07:00
Kenneth Skovhede bceed2ffbe Work on adding filters to send-mail 2018-04-02 11:20:46 +02:00
Tyler Gill 81a1bf9024 Clean up names of default filter groups.
Rename 'DefaultExclude' to 'DefaultExcludes' (and the same for 'DefaultInclude').
Rename 'TemporaryFolders' to 'TemporaryFiles' to align with other groups ('CacheFiles', 'SystemFiles', etc.)
Added some more shorter aliases for groups, 'Sys', 'Tmp', etc.
2018-03-23 10:29:12 -06:00
Tyler Gill 07cfd65942 Add some more default filters for Windows, mostly based on files I've seen fail to backup due to being locked / in-use by other common processes (Google Chrome, Dropbox, OneDrive, Windows, etc.) 2018-03-22 10:28:55 -06:00
Tyler Gill 2d429f65a1 Removed the All FilterGroup, since it becomes ambiguous in light of the DefaultExclude and DefaultInclude groups. 2018-03-21 16:52:25 -06:00
Tyler Gill c63597ab6a Clean up some filters on Windows.
This includes prefixing registry filters with '?:' (to match existing filters and make sure Duplicati respects them).
It also includes removing absolute drive paths ("C:\Program Files") when there is an identical wildcard drive path ("?:\Program Files").
2018-03-21 16:43:22 -06:00
Tyler Gill e6aab76d8d Update documentation related to filter groups.
This removes the documentation for default filters, and replaces it with documentation about filter groups (based in large part on what was already included with the initial filter groups change).
All documentation about the --include and --exclude parameters should now mention (at least in passing) the option to use filter groups.
2018-03-21 16:40:42 -06:00
Tyler Gill 66cb44ead2 Rename FilterGroup.Default to DefaultExclude (since it will contain the default set of filters related to excluding files).
This way, we can still add future filter groups for types of files that should be backed up (e.g., documents, pictures, etc.)
In light of this, I think the All group is somewhat problematic, since if we add new groups that are designed for inclusion, we don't want people accidentally excluding them (because they --exclude={all}).
2018-03-21 16:21:30 -06:00
Tyler Gill 0f9be9e440 Remove code related to the --default-filters parameter.
The UI work to change over from the initial default filters UI still needs to be done.
2018-03-21 16:18:14 -06:00
Tyler Gill fc23a2dbbd FilterEntry should use FilterGroups.ParseFilterList instead of Enum.TryParse directly.
Additionally, ParseFilterList now supports a number of (shorter) aliases for each group.
2018-03-21 15:08:10 -06:00
Tyler Gill baeb7e6a7c Added a new FilterType which is used by FilterEntry to represent a filter that should affect all files in one of the built-in filter groups.
This allows filter groups to be intermingled with other filters using the '{groupName}' syntax proposed by kenkendk.
It also means that when the filter that caused a file to be ignored is reported, it can report the name of the group, rather than a large and unreadable list of wildcard and regex patterns.
This is still missing several things (better documentation, removing the old --default-filters parameter, updating the UI), but should be another step in the right direction.
There might also might easily be other side effects that I haven't considered here that will need to be teased out and fixed.
2018-03-21 14:53:45 -06:00
Tyler Gill 03df606a80 Merge branch 'feature/filter_groups' of https://github.com/duplicati/duplicati into feature/filter-groups 2018-03-21 12:23:03 -06:00
Tyler Gill 4578a5bd91 Merge branch 'master' of https://github.com/duplicati/duplicati into feature/ms-graph-backends 2018-03-20 14:24:48 -06:00