← Back to team overview

duplicity-team team mailing list archive

[Merge] lp:~aaron-whitehouse/duplicity/filelist_combine into lp:duplicity

 

Aaron Whitehouse has proposed merging lp:~aaron-whitehouse/duplicity/filelist_combine into lp:duplicity.

Requested reviews:
  duplicity-team (duplicity-team)
Related bugs:
  Bug #1408411 in Duplicity: "Filelist (non-globbing) should include a folder if it contains higher priority included files"
  https://bugs.launchpad.net/duplicity/+bug/1408411
  Bug #1423366 in Duplicity: "--include-globbing-filelist and --exclude-globbing-filelist should be removed (all filelists should be globbing)"
  https://bugs.launchpad.net/duplicity/+bug/1423366
  Bug #1423367 in Duplicity: "--include-filelist-stdin and --exclude-filelist-stdin should be deprecated and ultimately removed"
  https://bugs.launchpad.net/duplicity/+bug/1423367

For more details, see:
https://code.launchpad.net/~aaron-whitehouse/duplicity/filelist_combine/+merge/252814

Merged globbing and non-globbing filelists to use the same code path and all accept globbing characters. Added deprecation warning to the --exclude-globbing-filelist and include-globbing-filelist options in commandline.py and hid them from help output. Updated the manual (and unit tests) accordingly. 

Note that this does trigger a change in behaviour for duplicity. Previously, include patterns in include-filelist did not match files in a directory that was included, so /usr/local in an include file would not have matched /usr/local/doc. Now, this folder would be included, as would occur if --include or the old --include-globbing-filelist was used. Additional lines will therefore need to be added to filelists to unambiguously exclude unwanted subfolders, if this is intended.

Mark --include-filelist-stdin and --exclude-fielist-stdin for deprecation and hide from --help output.
-- 
Your team duplicity-team is requested to review the proposed merge of lp:~aaron-whitehouse/duplicity/filelist_combine into lp:duplicity.
=== modified file 'bin/duplicity.1'
--- bin/duplicity.1	2015-02-08 16:43:23 +0000
+++ bin/duplicity.1	2015-03-12 19:36:56 +0000
@@ -481,28 +481,15 @@
 .TP
 .BI "--exclude-filelist " filename
 Excludes the files listed in
-.IR filename .
-See the
-.B FILE SELECTION
-section for more information.
-
-.TP
-.BI --exclude-filelist-stdin
-Like
-.BI --exclude-filelist,
-but the list of files will be read from standard input.  See the
-.B FILE SELECTION
-section for more information.
-
-.TP
-.BR "--exclude-globbing-filelist " filename
-Like
-.BI --exclude-filelist
-but each line of the filelist will be interpreted according to the
+.IR filename,
+with each line of the filelist interpreted according to the
 same rules as
 .BI --include
 and
 .BI --exclude.
+See the
+.B FILE SELECTION
+section for more information.
 
 .TP
 .BR "--exclude-if-present " filename
@@ -663,22 +650,6 @@
 section for more information.
 
 .TP
-.BI --include-filelist-stdin
-Like
-.BR --include-filelist ,
-but read the list of included files from standard input.
-
-.TP
-.BI "--include-globbing-filelist " filename
-Like
-.BI --include-filelist
-but each line of the filelist will be interpreted according to the
-same rules as
-.BI --include
-and
-.BI --exclude.
-
-.TP
 .BI "--include-regexp " regexp
 Include files matching the regular expression
 .IR regexp .
@@ -746,7 +717,7 @@
 Use nulls (\\0) instead of newlines (\\n) as line separators, which
 may help when dealing with filenames containing newlines.  This
 affects the expected format of the files specified by the
---{include|exclude}-filelist[-stdin] switches as well as the format of
+--{include|exclude}-filelist switches as well as the format of
 the directory statistics file.
 
 .TP
@@ -1337,10 +1308,6 @@
 "03-05-2002", and "2002-3-05" all mean March 5th, 2002.
 
 .SH FILE SELECTION
-duplicity accepts the same file selection options
-.B rdiff-backup
-does, including --exclude, --exclude-filelist-stdin, etc.
-
 When duplicity is run, it searches through the given source
 directory and backs up all the files specified by the file selection
 system.  The file selection system comprises a number of file
@@ -1353,20 +1320,12 @@
 .br
 --exclude-filelist
 .br
---exclude-filelist-stdin
-.br
---exclude-globbing-filelist
-.br
 --exclude-regexp
 .br
 --include
 .br
 --include-filelist
 .br
---include-filelist-stdin
-.br
---include-globbing-filelist
-.br
 --include-regexp
 .RE
 Each file selection condition either matches or doesn't match a given
@@ -1402,9 +1361,9 @@
 The
 .BR include ,
 .BR exclude ,
-.BR include-globbing-filelist ,
+.BR include-filelist ,
 and
-.B exclude-globbing-filelist
+.B exclude-filelist
 options accept some
 .IR "extended shell globbing patterns" .
 These patterns can contain
@@ -1493,34 +1452,18 @@
 
 The
 .BR --include-filelist ,
-.BR --exclude-filelist ,
-.BR --include-filelist-stdin ,
 and
-.BI --exclude-filelist-stdin
+.BI --exclude-filelist ,
 options also introduce file selection conditions.  They direct
 duplicity to read in a file, each line of which is a file
 specification, and to include or exclude the matching files.  Lines
 are separated by newlines or nulls, depending on whether the
---null-separator switch was given.  Each line in a filelist is
-interpreted similarly to the way
-.I extended shell patterns
-are, with a few exceptions:
-.PP
-.B 1.
-Globbing patterns like
-.BR * ,
-.BR ** ,
-.BR ? ,
+--null-separator switch was given.  Each line in the filelist will be
+interpreted as a globbing pattern the way
+.BI --include
 and
-.B [...]
-are not expanded.
-.br
-.B 2.
-Include patterns do not match files in a directory that is included.
-So /usr/local in an include file will not match /usr/local/doc.
-.br
-.B 3.
-Lines starting with "+ " are interpreted as include directives, even
+.BI --exclude
+options are interpreted, except that lines starting with "+ " are interpreted as include directives, even
 if found in a filelist referenced by
 .BR --exclude-filelist .
 Similarly, lines starting with "- " exclude files even if they are
@@ -1544,23 +1487,18 @@
 .B "--include-filelist list.txt"
 would include /usr, /usr/local, and
 /usr/local/bin.  It would exclude /usr/local/doc,
-/usr/local/doc/python, etc.  It neither excludes nor includes
-/usr/local/man, leaving the fate of this directory to the next
-specification condition.  Finally, it is undefined what happens with
+/usr/local/doc/python, etc.  It would also include
+/usr/local/man, as this is included within /user/local.  Finally, it is undefined what happens with
 /var.  A single file list should not contain conflicting file
 specifications.
 
-The
-.BI --include-globbing-filelist
-and
-.BI --exclude-globbing-filelist
-options also specify filelists, but each line in the filelist will be
+Each line in the filelist will also be
 interpreted as a globbing pattern the way
 .BI --include
 and
 .BI --exclude
-options are interpreted (although "+ " and "- " prefixing is still
-allowed).  For instance, if the file "globbing-list.txt" contains the
+options are interpreted.
+For instance, if the file "list.txt" contains the
 lines:
 
 .RS
@@ -1572,7 +1510,7 @@
 .RE
 
 Then
-.B "--include-globbing-filelist globbing-list.txt"
+.B "--include-filelist list.txt"
 would be exactly the same as specifying
 .B "--include dir/foo --include dir/bar --exclude **"
 on the command line.

=== modified file 'duplicity/commandline.py'
--- duplicity/commandline.py	2015-01-31 23:30:49 +0000
+++ duplicity/commandline.py	2015-03-12 19:36:56 +0000
@@ -73,7 +73,26 @@
               "Use of default filenames is strongly suggested.") % opt,
             log.ERROR, force_print=True)
 
-
+<<<<<<< TREE
+
+=======
+def old_globbing_filelist_deprecation(opt):
+    log.Log(_("Warning: Option %s is pending deprecation and will be removed in a future release.\n"
+              "--include-filelist and --exclude-filelist now accept globbing characters and should "
+              "be used instead.") % opt,
+            log.ERROR, force_print=True)
+
+def stdin_deprecation(opt):
+    # See https://bugs.launchpad.net/duplicity/+bug/1423367
+    # In almost all Linux distros stdin is a file represented by /dev/stdin,
+    # so --exclude-file=/dev/stdin will work as a substitute.
+    log.Log(_("Warning: Option %s is pending deprecation and will be removed in a future release.\n"
+              "On many GNU/Linux systems, stdin is represented by /dev/stdin and\n"
+              "--include-filelist=/dev/stdin or --exclude-filelist=/dev/stdin could\n"
+              "be used as a substitute.") % opt,
+            log.ERROR, force_print=True)
+
+>>>>>>> MERGE-SOURCE
 def expand_fn(filename):
     return os.path.expanduser(os.path.expandvars(filename))
 
@@ -307,10 +326,14 @@
 
     parser.add_option("--exclude-filelist-stdin", action="callback", dest="",
                       callback=lambda o, s, v, p: (select_opts.append(("--exclude-filelist", "standard input")),
-                                                   select_files.append(sys.stdin)))
+                                                   select_files.append(sys.stdin),
+                                                   stdin_deprecation(o)),
+                      help=optparse.SUPPRESS_HELP)
 
     parser.add_option("--exclude-globbing-filelist", type="file", metavar=_("filename"),
-                      dest="", action="callback", callback=add_filelist)
+                      dest="", action="callback", callback=lambda o, s, v, p: (add_filelist(o, s, v, p),
+                                                                               old_globbing_filelist_deprecation(s)),
+                      help=optparse.SUPPRESS_HELP)
 
     # TRANSL: Used in usage help to represent the name of a file. Example:
     # --log-file <filename>
@@ -409,9 +432,13 @@
                       dest="", action="callback", callback=add_filelist)
     parser.add_option("--include-filelist-stdin", action="callback", dest="",
                       callback=lambda o, s, v, p: (select_opts.append(("--include-filelist", "standard input")),
-                                                   select_files.append(sys.stdin)))
+                                                   select_files.append(sys.stdin),
+                                                   stdin_deprecation(o)),
+                      help=optparse.SUPPRESS_HELP)
     parser.add_option("--include-globbing-filelist", type="file", metavar=_("filename"),
-                      dest="", action="callback", callback=add_filelist)
+                      dest="", action="callback", callback=lambda o, s, v, p: (add_filelist(o, s, v, p),
+                                                                               old_globbing_filelist_deprecation(s)),
+                      help=optparse.SUPPRESS_HELP)
     parser.add_option("--include-regexp", metavar=_("regular_expression"), dest="",
                       type="string", action="callback", callback=add_selection)
 
@@ -924,7 +951,6 @@
     sel.ParseArgs(select_opts, select_files)
     globals.select = sel.set_iter()
 
-
 def args_to_path_backend(arg1, arg2):
     """
     Given exactly two arguments, arg1 and arg2, figure out which one

=== modified file 'duplicity/selection.py'
--- duplicity/selection.py	2015-01-31 23:30:49 +0000
+++ duplicity/selection.py	2015-03-12 19:36:56 +0000
@@ -102,6 +102,7 @@
 
     def set_iter(self):
         """Initialize generator, prepare to iterate."""
+        # Externally-accessed method
         self.rootpath.setdata()  # this may have changed since Select init
         self.iter = self.Iterate(self.rootpath)
         self.next = self.iter.next
@@ -117,6 +118,8 @@
         scanning" bit.
 
         """
+        # Only called by set_iter. Internal.
+
         def error_handler(exc, path, filename):
             fullpath = os.path.join(path.name, filename)
             try:
@@ -143,6 +146,7 @@
             and should be included iff something inside is included.
 
             """
+            # Only called by Iterate. Internal.
             # todo: get around circular dependency issue by importing here
             from duplicity import robust  # @Reimport
             for filename in robust.listpath(path):
@@ -200,6 +204,7 @@
 
     def Select(self, path):
         """Run through the selection functions and return dominant val 0/1/2"""
+        # Only used by diryield and tests. Internal.
         if not self.selection_functions:
             return 1
         scan_pending = False
@@ -227,6 +232,7 @@
         (option-string, (additional argument, filelist_fp)).
 
         """
+        # Called by commandline.py set_selection. External.
         filelists_index = 0
         try:
             for opt, arg in argtuples:
@@ -236,11 +242,9 @@
                     self.add_selection_func(self.present_get_sf(arg, 0))
                 elif opt == "--exclude-device-files":
                     self.add_selection_func(self.devfiles_get_sf())
-                elif opt == "--exclude-filelist":
-                    self.add_selection_func(self.filelist_get_sf(
-                        filelists[filelists_index], 0, arg))
-                    filelists_index += 1
-                elif opt == "--exclude-globbing-filelist":
+                elif (opt == "--exclude-filelist") or (opt == "--exclude-globbing-filelist"):
+                    # --exclude-globbing-filelist is now deprecated, as all filelists are globbing
+                    # but keep this here for the short term for backwards-compatibility
                     for sf in self.filelist_globbing_get_sfs(filelists[filelists_index], 0, arg):
                         self.add_selection_func(sf)
                     filelists_index += 1
@@ -252,11 +256,9 @@
                     self.add_selection_func(self.exclude_older_get_sf(arg))
                 elif opt == "--include":
                     self.add_selection_func(self.glob_get_sf(arg, 1))
-                elif opt == "--include-filelist":
-                    self.add_selection_func(self.filelist_get_sf(
-                        filelists[filelists_index], 1, arg))
-                    filelists_index += 1
-                elif opt == "--include-globbing-filelist":
+                elif (opt == "--include-filelist") or (opt == "--include-globbing-filelist"):
+                    # --include-globbing-filelist is now deprecated, as all filelists are globbing
+                    # but keep this here for the short term for backwards-compatibility
                     for sf in self.filelist_globbing_get_sfs(filelists[filelists_index], 1, arg):
                         self.add_selection_func(sf)
                     filelists_index += 1
@@ -271,6 +273,7 @@
 
     def parse_catch_error(self, exc):
         """Deal with selection error exc"""
+        # Internal, used by ParseArgs.
         if isinstance(exc, FilePrefixError):
             log.FatalError(_("""\
 Fatal Error: The file specification
@@ -288,6 +291,7 @@
 
     def parse_last_excludes(self):
         """Exit with error if last selection function isn't an exclude"""
+        # Internal. Used by ParseArgs.
         if (self.selection_functions and
                 not self.selection_functions[-1].exclude):
             log.FatalError(_("""\
@@ -301,11 +305,13 @@
 
     def add_selection_func(self, sel_func, add_to_start=None):
         """Add another selection function at the end or beginning"""
+        # Internal. Used by ParseArgs.
         if add_to_start:
             self.selection_functions.insert(0, sel_func)
         else:
             self.selection_functions.append(sel_func)
 
+<<<<<<< TREE
     def filelist_get_sf(self, filelist_fp, inc_default, filelist_name):
         """Return selection function by reading list of files
 
@@ -371,6 +377,8 @@
         if filelist_fp not in (sys.stdin,) and filelist_fp.close():
             log.Warn(_("Error closing filelist %s") % filelist_name)
         return (tuple_list, something_excluded)
+=======
+>>>>>>> MERGE-SOURCE
 
     def filelist_sanitise_line(self, line, include_default):
         """
@@ -379,6 +387,7 @@
         The aim is to parse filelists in a consistent way, prior to the interpretation of globbing statements.
         The function removes whitespace, comment lines and processes modifiers (leading +/-) and quotes.
         """
+        # Internal. Used by filelist_globbing_get_sfs
 
         line = line.strip()
         if not line:  # skip blanks
@@ -400,59 +409,6 @@
 
         return line, include
 
-    def filelist_parse_line(self, line, include):
-        """Parse a single line of a filelist, returning a pair or None if the line is blank/a comment
-
-        Pair will be of form (index, include), where index is another
-        tuple, and include is 1 if the line specifies that we are
-        including a file.  The default is given as an argument.
-        prefix is the string that the index is relative to.
-
-        """
-
-        line, include = self.filelist_sanitise_line(line, include)
-
-        if not line:
-            # Skip blanks and comments
-            return None
-
-        if not line.startswith(self.prefix):
-            raise FilePrefixError(line)
-        line = line[len(self.prefix):]  # Discard prefix
-        index = tuple(filter(lambda x: x, line.split("/")))  # remove empties
-        return (index, include)
-
-    def filelist_pair_match(self, path, pair):
-        """Matches a filelist tuple against a path
-
-        Returns a pair (include, move_on).  include is None if the
-        tuple doesn't match either way, and 0/1 if the tuple excludes
-        or includes the path.
-
-        move_on is true if the tuple cannot match a later index, and
-        so we should move on to the next tuple in the index.
-
-        """
-        index, include = pair
-        if include == 1:
-            if index < path.index:
-                return (None, True)
-            if index == path.index:
-                return (1, True)
-            elif index[:len(path.index)] == path.index:
-                return (1, False)  # /foo/bar implicitly includes /foo
-            else:
-                return (None, False)  # path greater, not initial sequence
-        elif include == 0:
-            if path.index[:len(index)] == index:
-                return (0, False)  # /foo implicitly excludes /foo/bar
-            elif index < path.index:
-                return (None, True)
-            else:
-                return (None, False)  # path greater, not initial sequence
-        else:
-            assert 0, "Include is %s, should be 0 or 1" % (include,)
-
     def filelist_globbing_get_sfs(self, filelist_fp, inc_default, list_name):
         """Return list of selection functions by reading fileobj
 
@@ -462,6 +418,7 @@
         See the man page on --[include/exclude]-globbing-filelist
 
         """
+        # Internal. Used by ParseArgs.
         log.Notice(_("Reading globbing filelist %s") % list_name)
         separator = globals.null_separator and "\0" or "\n"
         for line in filelist_fp.read().split(separator):
@@ -473,6 +430,7 @@
 
     def other_filesystems_get_sf(self, include):
         """Return selection function matching files on other filesystems"""
+        # Internal. Used by ParseArgs and unit tests.
         assert include == 0 or include == 1
         root_devloc = self.rootpath.getdevloc()
 
@@ -488,6 +446,7 @@
 
     def regexp_get_sf(self, regexp_string, include):
         """Return selection function given by regexp_string"""
+        # Internal. Used by ParseArgs and unit tests.
         assert include == 0 or include == 1
         try:
             regexp = re.compile(regexp_string)
@@ -507,6 +466,7 @@
 
     def devfiles_get_sf(self):
         """Return a selection function to exclude all dev files"""
+        # Internal. Used by ParseArgs.
         if self.selection_functions:
             log.Warn(_("Warning: exclude-device-files is not the first "
                        "selector.\nThis may not be what you intended"))
@@ -523,6 +483,7 @@
 
     def glob_get_sf(self, glob_str, include):
         """Return selection function given by glob string"""
+        # Internal. Used by ParseArgs, filelist_globbing_get_sfs and unit tests.
         assert include == 0 or include == 1
         if glob_str == "**":
             sel_func = lambda path: include
@@ -539,6 +500,7 @@
 
     def present_get_sf(self, filename, include):
         """Return selection function given by existence of a file in a directory"""
+        # Internal. Used by ParseArgs.
         assert include == 0 or include == 1
 
         def exclude_sel_func(path):
@@ -572,6 +534,8 @@
         globbing characters are used.
 
         """
+        # Internal. Used by glob_get_sf and unit tests.
+
         if not filename.startswith(self.prefix):
             raise FilePrefixError(filename)
         index = tuple(filter(lambda x: x,
@@ -580,6 +544,7 @@
 
     def glob_get_tuple_sf(self, tuple, include):
         """Return selection function based on tuple"""
+        # Internal. Used by glob_get_filename_sf.
         def include_sel_func(path):
             if (path.index == tuple[:len(path.index)] or
                     path.index[:len(tuple)] == tuple):
@@ -616,6 +581,7 @@
         things similar to this.
 
         """
+        # Internal. Used by glob_get_sf and unit tests.
         if glob_str.lower().startswith("ignorecase:"):
             re_comp = lambda r: re.compile(r, re.I | re.S)
             glob_str = glob_str[len("ignorecase:"):]
@@ -656,6 +622,7 @@
 
     def exclude_older_get_sf(self, date):
         """Return selection function based on files older than modification date """
+        # Internal. Used by ParseArgs.
 
         def sel_func(path):
             if not path.isreg():
@@ -673,6 +640,7 @@
 
     def glob_get_prefix_res(self, glob_str):
         """Return list of regexps equivalent to prefixes of glob_str"""
+        # Internal. Used by glob_get_normal_sf.
         glob_parts = glob_str.split("/")
         if "" in glob_parts[1:-1]:
             # "" OK if comes first or last, as in /foo/
@@ -696,6 +664,7 @@
         by Donovan Baarda.
 
         """
+        # Internal. Used by glob_get_normal_sf, glob_get_prefix_res and unit tests.
         i, n, res = 0, len(pat), ''
         while i < n:
             c, s = pat[i], pat[i:i + 2]

=== modified file 'po/duplicity.pot'
--- po/duplicity.pot	2015-03-11 12:27:42 +0000
+++ po/duplicity.pot	2015-03-12 19:36:56 +0000
@@ -8,7 +8,11 @@
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: Kenneth Loafman <kenneth@xxxxxxxxxxx>\n"
+<<<<<<< TREE
 "POT-Creation-Date: 2015-03-11 07:21-0500\n"
+=======
+"POT-Creation-Date: 2015-03-12 18:33+0000\n"
+>>>>>>> MERGE-SOURCE
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@xxxxxx>\n"
@@ -371,7 +375,11 @@
 msgid "Backend error detail: %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../bin/rdiffdir:61 ../duplicity/commandline.py:241
+=======
+#: ../bin/rdiffdir:56 ../duplicity/commandline.py:249
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Error opening file %s"
 msgstr ""
@@ -693,11 +701,36 @@
 "Use of default filenames is strongly suggested."
 msgstr ""
 
+#: ../duplicity/commandline.py:76
+#, python-format
+msgid ""
+"Warning: Option %s is pending deprecation and will be removed in a future "
+"release.\n"
+"--include-filelist and --exclude-filelist now accept globbing characters and "
+"should be used instead."
+msgstr ""
+
+#: ../duplicity/commandline.py:85
+#, python-format
+msgid ""
+"Warning: Option %s is pending deprecation and will be removed in a future "
+"release.\n"
+"On many GNU/Linux systems, stdin is represented by /dev/stdin and\n"
+"--include-filelist=/dev/stdin or --exclude-filelist=/dev/stdin could\n"
+"be used as a substitute."
+msgstr ""
+
 #. Used in usage help to represent a Unix-style path name. Example:
 #. --archive-dir <path>
+<<<<<<< TREE
 #: ../duplicity/commandline.py:262 ../duplicity/commandline.py:272
 #: ../duplicity/commandline.py:289 ../duplicity/commandline.py:359
 #: ../duplicity/commandline.py:560 ../duplicity/commandline.py:774
+=======
+#: ../duplicity/commandline.py:270 ../duplicity/commandline.py:280
+#: ../duplicity/commandline.py:297 ../duplicity/commandline.py:371
+#: ../duplicity/commandline.py:576 ../duplicity/commandline.py:790
+>>>>>>> MERGE-SOURCE
 msgid "path"
 msgstr ""
 
@@ -707,9 +740,15 @@
 #. --hidden-encrypt-key <gpg_key_id>
 #. Used in usage help to represent an ID for a GnuPG key. Example:
 #. --encrypt-key <gpg_key_id>
+<<<<<<< TREE
 #: ../duplicity/commandline.py:284 ../duplicity/commandline.py:291
 #: ../duplicity/commandline.py:381 ../duplicity/commandline.py:544
 #: ../duplicity/commandline.py:747
+=======
+#: ../duplicity/commandline.py:292 ../duplicity/commandline.py:299
+#: ../duplicity/commandline.py:393 ../duplicity/commandline.py:560
+#: ../duplicity/commandline.py:763
+>>>>>>> MERGE-SOURCE
 msgid "gpg-key-id"
 msgstr ""
 
@@ -717,43 +756,74 @@
 #. matching one or more files, as described in the documentation.
 #. Example:
 #. --exclude <shell_pattern>
+<<<<<<< TREE
 #: ../duplicity/commandline.py:299 ../duplicity/commandline.py:406
 #: ../duplicity/commandline.py:797
+=======
+#: ../duplicity/commandline.py:307 ../duplicity/commandline.py:418
+#: ../duplicity/commandline.py:813
+>>>>>>> MERGE-SOURCE
 msgid "shell_pattern"
 msgstr ""
 
 #. Used in usage help to represent the name of a file. Example:
 #. --log-file <filename>
+<<<<<<< TREE
 #: ../duplicity/commandline.py:305 ../duplicity/commandline.py:312
 #: ../duplicity/commandline.py:317 ../duplicity/commandline.py:408
 #: ../duplicity/commandline.py:413 ../duplicity/commandline.py:424
 #: ../duplicity/commandline.py:743
+=======
+#: ../duplicity/commandline.py:313 ../duplicity/commandline.py:322
+#: ../duplicity/commandline.py:329 ../duplicity/commandline.py:420
+#: ../duplicity/commandline.py:427 ../duplicity/commandline.py:440
+#: ../duplicity/commandline.py:759
+>>>>>>> MERGE-SOURCE
 msgid "filename"
 msgstr ""
 
 #. Used in usage help to represent a regular expression (regexp).
+<<<<<<< TREE
 #: ../duplicity/commandline.py:324 ../duplicity/commandline.py:415
+=======
+#: ../duplicity/commandline.py:336 ../duplicity/commandline.py:431
+>>>>>>> MERGE-SOURCE
 msgid "regular_expression"
 msgstr ""
 
 #. Used in usage help to represent a time spec for a previous
 #. point in time, as described in the documentation. Example:
 #. duplicity remove-older-than time [options] target_url
+<<<<<<< TREE
 #: ../duplicity/commandline.py:328 ../duplicity/commandline.py:371
 #: ../duplicity/commandline.py:486 ../duplicity/commandline.py:829
+=======
+#: ../duplicity/commandline.py:340 ../duplicity/commandline.py:383
+#: ../duplicity/commandline.py:502 ../duplicity/commandline.py:845
+>>>>>>> MERGE-SOURCE
 msgid "time"
 msgstr ""
 
 #. Used in usage help. (Should be consistent with the "Options:"
 #. header.) Example:
 #. duplicity [full|incremental] [options] source_dir target_url
+<<<<<<< TREE
 #: ../duplicity/commandline.py:377 ../duplicity/commandline.py:466
 #: ../duplicity/commandline.py:489 ../duplicity/commandline.py:552
 #: ../duplicity/commandline.py:762
+=======
+#: ../duplicity/commandline.py:389 ../duplicity/commandline.py:482
+#: ../duplicity/commandline.py:505 ../duplicity/commandline.py:568
+#: ../duplicity/commandline.py:778
+>>>>>>> MERGE-SOURCE
 msgid "options"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:392
+=======
+#: ../duplicity/commandline.py:404
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid ""
 "Running in 'ignore errors' mode due to %s; please re-consider if this was "
@@ -761,152 +831,261 @@
 msgstr ""
 
 #. Used in usage help to represent an imap mailbox
+<<<<<<< TREE
 #: ../duplicity/commandline.py:404
+=======
+#: ../duplicity/commandline.py:416
+>>>>>>> MERGE-SOURCE
 msgid "imap_mailbox"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:418
+=======
+#: ../duplicity/commandline.py:434
+>>>>>>> MERGE-SOURCE
 msgid "file_descriptor"
 msgstr ""
 
 #. Used in usage help to represent a desired number of
 #. something. Example:
 #. --num-retries <number>
+<<<<<<< TREE
 #: ../duplicity/commandline.py:429 ../duplicity/commandline.py:451
 #: ../duplicity/commandline.py:463 ../duplicity/commandline.py:472
 #: ../duplicity/commandline.py:510 ../duplicity/commandline.py:515
 #: ../duplicity/commandline.py:519 ../duplicity/commandline.py:588
 #: ../duplicity/commandline.py:757
+=======
+#: ../duplicity/commandline.py:445 ../duplicity/commandline.py:467
+#: ../duplicity/commandline.py:479 ../duplicity/commandline.py:488
+#: ../duplicity/commandline.py:526 ../duplicity/commandline.py:531
+#: ../duplicity/commandline.py:535 ../duplicity/commandline.py:604
+#: ../duplicity/commandline.py:773
+>>>>>>> MERGE-SOURCE
 msgid "number"
 msgstr ""
 
 #. Used in usage help (noun)
+<<<<<<< TREE
 #: ../duplicity/commandline.py:432
+=======
+#: ../duplicity/commandline.py:448
+>>>>>>> MERGE-SOURCE
 msgid "backup name"
 msgstr ""
 
 #. noun
+<<<<<<< TREE
 #: ../duplicity/commandline.py:528 ../duplicity/commandline.py:531
 #: ../duplicity/commandline.py:728
+=======
+#: ../duplicity/commandline.py:544 ../duplicity/commandline.py:547
+#: ../duplicity/commandline.py:744
+>>>>>>> MERGE-SOURCE
 msgid "command"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:534
+=======
+#: ../duplicity/commandline.py:550
+>>>>>>> MERGE-SOURCE
 msgid "pyrax|cloudfiles"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:555
+=======
+#: ../duplicity/commandline.py:571
+>>>>>>> MERGE-SOURCE
 msgid "pem formatted bundle of certificate authorities"
 msgstr ""
 
 #. Used in usage help. Example:
 #. --timeout <seconds>
+<<<<<<< TREE
 #: ../duplicity/commandline.py:565 ../duplicity/commandline.py:791
+=======
+#: ../duplicity/commandline.py:581 ../duplicity/commandline.py:807
+>>>>>>> MERGE-SOURCE
 msgid "seconds"
 msgstr ""
 
 #. abbreviation for "character" (noun)
+<<<<<<< TREE
 #: ../duplicity/commandline.py:571 ../duplicity/commandline.py:725
+=======
+#: ../duplicity/commandline.py:587 ../duplicity/commandline.py:741
+>>>>>>> MERGE-SOURCE
 msgid "char"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:691
+=======
+#: ../duplicity/commandline.py:707
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Using archive dir: %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:692
+=======
+#: ../duplicity/commandline.py:708
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Using backup name: %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:699
+=======
+#: ../duplicity/commandline.py:715
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Command line error: %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:700
+=======
+#: ../duplicity/commandline.py:716
+>>>>>>> MERGE-SOURCE
 msgid "Enter 'duplicity --help' for help screen."
 msgstr ""
 
 #. Used in usage help to represent a Unix-style path name. Example:
 #. rsync://user[:password]@other_host[:port]//absolute_path
+<<<<<<< TREE
 #: ../duplicity/commandline.py:713
+=======
+#: ../duplicity/commandline.py:729
+>>>>>>> MERGE-SOURCE
 msgid "absolute_path"
 msgstr ""
 
 #. Used in usage help. Example:
 #. tahoe://alias/some_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:717
+=======
+#: ../duplicity/commandline.py:733
+>>>>>>> MERGE-SOURCE
 msgid "alias"
 msgstr ""
 
 #. Used in help to represent a "bucket name" for Amazon Web
 #. Services' Simple Storage Service (S3). Example:
 #. s3://other.host/bucket_name[/prefix]
+<<<<<<< TREE
 #: ../duplicity/commandline.py:722
+=======
+#: ../duplicity/commandline.py:738
+>>>>>>> MERGE-SOURCE
 msgid "bucket_name"
 msgstr ""
 
 #. Used in usage help to represent the name of a container in
 #. Amazon Web Services' Cloudfront. Example:
 #. cf+http://container_name
+<<<<<<< TREE
 #: ../duplicity/commandline.py:733
+=======
+#: ../duplicity/commandline.py:749
+>>>>>>> MERGE-SOURCE
 msgid "container_name"
 msgstr ""
 
 #. noun
+<<<<<<< TREE
 #: ../duplicity/commandline.py:736
+=======
+#: ../duplicity/commandline.py:752
+>>>>>>> MERGE-SOURCE
 msgid "count"
 msgstr ""
 
 #. Used in usage help to represent the name of a file directory
+<<<<<<< TREE
 #: ../duplicity/commandline.py:739
+=======
+#: ../duplicity/commandline.py:755
+>>>>>>> MERGE-SOURCE
 msgid "directory"
 msgstr ""
 
 #. Used in usage help, e.g. to represent the name of a code
 #. module. Example:
 #. rsync://user[:password]@other.host[:port]::/module/some_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:752
+=======
+#: ../duplicity/commandline.py:768
+>>>>>>> MERGE-SOURCE
 msgid "module"
 msgstr ""
 
 #. Used in usage help to represent an internet hostname. Example:
 #. ftp://user[:password]@other.host[:port]/some_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:766
+=======
+#: ../duplicity/commandline.py:782
+>>>>>>> MERGE-SOURCE
 msgid "other.host"
 msgstr ""
 
 #. Used in usage help. Example:
 #. ftp://user[:password]@other.host[:port]/some_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:770
+=======
+#: ../duplicity/commandline.py:786
+>>>>>>> MERGE-SOURCE
 msgid "password"
 msgstr ""
 
 #. Used in usage help to represent a TCP port number. Example:
 #. ftp://user[:password]@other.host[:port]/some_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:778
+=======
+#: ../duplicity/commandline.py:794
+>>>>>>> MERGE-SOURCE
 msgid "port"
 msgstr ""
 
 #. Used in usage help. This represents a string to be used as a
 #. prefix to names for backup files created by Duplicity. Example:
 #. s3://other.host/bucket_name[/prefix]
+<<<<<<< TREE
 #: ../duplicity/commandline.py:783
+=======
+#: ../duplicity/commandline.py:799
+>>>>>>> MERGE-SOURCE
 msgid "prefix"
 msgstr ""
 
 #. Used in usage help to represent a Unix-style path name. Example:
 #. rsync://user[:password]@other.host[:port]/relative_path
+<<<<<<< TREE
 #: ../duplicity/commandline.py:787
+=======
+#: ../duplicity/commandline.py:803
+>>>>>>> MERGE-SOURCE
 msgid "relative_path"
 msgstr ""
 
 #. Used in usage help to represent the name of a single file
 #. directory or a Unix-style path to a directory. Example:
 #. file:///some_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:802
+=======
+#: ../duplicity/commandline.py:818
+>>>>>>> MERGE-SOURCE
 msgid "some_dir"
 msgstr ""
 
@@ -914,14 +1093,22 @@
 #. directory or a Unix-style path to a directory where files will be
 #. coming FROM. Example:
 #. duplicity [full|incremental] [options] source_dir target_url
+<<<<<<< TREE
 #: ../duplicity/commandline.py:808
+=======
+#: ../duplicity/commandline.py:824
+>>>>>>> MERGE-SOURCE
 msgid "source_dir"
 msgstr ""
 
 #. Used in usage help to represent a URL files will be coming
 #. FROM. Example:
 #. duplicity [restore] [options] source_url target_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:813
+=======
+#: ../duplicity/commandline.py:829
+>>>>>>> MERGE-SOURCE
 msgid "source_url"
 msgstr ""
 
@@ -929,75 +1116,127 @@
 #. directory or a Unix-style path to a directory. where files will be
 #. going TO. Example:
 #. duplicity [restore] [options] source_url target_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:819
+=======
+#: ../duplicity/commandline.py:835
+>>>>>>> MERGE-SOURCE
 msgid "target_dir"
 msgstr ""
 
 #. Used in usage help to represent a URL files will be going TO.
 #. Example:
 #. duplicity [full|incremental] [options] source_dir target_url
+<<<<<<< TREE
 #: ../duplicity/commandline.py:824
+=======
+#: ../duplicity/commandline.py:840
+>>>>>>> MERGE-SOURCE
 msgid "target_url"
 msgstr ""
 
 #. Used in usage help to represent a user name (i.e. login).
 #. Example:
 #. ftp://user[:password]@other.host[:port]/some_dir
+<<<<<<< TREE
 #: ../duplicity/commandline.py:834
+=======
+#: ../duplicity/commandline.py:850
+>>>>>>> MERGE-SOURCE
 msgid "user"
 msgstr ""
 
 #. Header in usage help
+<<<<<<< TREE
 #: ../duplicity/commandline.py:852
+=======
+#: ../duplicity/commandline.py:868
+>>>>>>> MERGE-SOURCE
 msgid "Backends and their URL formats:"
 msgstr ""
 
 #. Header in usage help
+<<<<<<< TREE
 #: ../duplicity/commandline.py:881
+=======
+#: ../duplicity/commandline.py:897
+>>>>>>> MERGE-SOURCE
 msgid "Commands:"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:905
+=======
+#: ../duplicity/commandline.py:921
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Specified archive directory '%s' does not exist, or is not a directory"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:914
+=======
+#: ../duplicity/commandline.py:930
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid ""
 "Sign key should be an 8, 16 alt. 40 character hex string, like 'AA0E73D2'.\n"
 "Received '%s' instead."
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:974
+=======
+#: ../duplicity/commandline.py:989
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid ""
 "Restore destination directory %s already exists.\n"
 "Will not overwrite."
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:979
+=======
+#: ../duplicity/commandline.py:994
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Verify directory %s does not exist"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:985
+=======
+#: ../duplicity/commandline.py:1000
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Backup source directory %s does not exist."
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:1016
+=======
+#: ../duplicity/commandline.py:1029
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Command line warning: %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:1016
+=======
+#: ../duplicity/commandline.py:1029
+>>>>>>> MERGE-SOURCE
 msgid ""
 "Selection options --exclude/--include\n"
 "currently work only when backing up,not restoring."
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:1064
+=======
+#: ../duplicity/commandline.py:1077
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid ""
 "Bad URL '%s'.\n"
@@ -1005,7 +1244,11 @@
 "\"file:///usr/local\".  See the man page for more information."
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/commandline.py:1089
+=======
+#: ../duplicity/commandline.py:1102
+>>>>>>> MERGE-SOURCE
 msgid "Main action: "
 msgstr ""
 
@@ -1250,18 +1493,31 @@
 msgid "Error initializing file %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/selection.py:133 ../duplicity/selection.py:154
+=======
+#: ../duplicity/selection.py:133 ../duplicity/selection.py:155
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Error accessing possibly locked file %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/selection.py:169
+=======
+#: ../duplicity/selection.py:170
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Warning: base %s doesn't exist, continuing"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/selection.py:172 ../duplicity/selection.py:190
 #: ../duplicity/selection.py:193
+=======
+#: ../duplicity/selection.py:173 ../duplicity/selection.py:191
+#: ../duplicity/selection.py:194
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Selecting %s"
 msgstr ""
@@ -1284,7 +1540,11 @@
 "%s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/selection.py:293
+=======
+#: ../duplicity/selection.py:294
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid ""
 "Last selection expression:\n"
@@ -1294,6 +1554,7 @@
 "probably isn't what you meant."
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/selection.py:319
 #, python-format
 msgid "Reading filelist %s"
@@ -1321,16 +1582,27 @@
 msgstr ""
 
 #: ../duplicity/selection.py:465
+=======
+#: ../duplicity/selection.py:351
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Reading globbing filelist %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/selection.py:495
+=======
+#: ../duplicity/selection.py:381
+>>>>>>> MERGE-SOURCE
 #, python-format
 msgid "Error compiling regular expression %s"
 msgstr ""
 
+<<<<<<< TREE
 #: ../duplicity/selection.py:511
+=======
+#: ../duplicity/selection.py:398
+>>>>>>> MERGE-SOURCE
 msgid ""
 "Warning: exclude-device-files is not the first selector.\n"
 "This may not be what you intended"

=== modified file 'testing/functional/test_selection.py'
--- testing/functional/test_selection.py	2015-01-31 16:19:46 +0000
+++ testing/functional/test_selection.py	2015-03-12 19:36:56 +0000
@@ -24,7 +24,6 @@
 
 from . import FunctionalTestCase
 
-
 class IncludeExcludeFunctionalTest(FunctionalTestCase):
     """
     This contains methods used in the tests below for testing the include, exclude and various filelist features.
@@ -235,13 +234,13 @@
         self.assertEqual(restored, self.expected_restored_tree_with_trailing_space)
 
 
-class TestExcludeGlobbingFilelistTest(IncludeExcludeFunctionalTest):
+class TestExcludeFilelistTest(IncludeExcludeFunctionalTest):
     """
-    Test --exclude-globbing-filelist using duplicity binary.
+    Test --exclude-filelist using duplicity binary.
     """
 
-    def test_exclude_globbing_filelist(self):
-        """Test that exclude globbing filelist works in the basic case """
+    def test_exclude_filelist(self):
+        """Test that exclude filelist works in the basic case """
         # As this is an exclude filelist any lines with no +/- modifier should be treated as if they have a -.
         # Create a filelist
         with open('testfiles/exclude.txt', 'w') as f:
@@ -264,7 +263,50 @@
                     '+ testfiles/select2/3\n'
                     '+ testfiles/select2/1\n'
                     'testfiles/select2/**')
-        self.backup("full", "testfiles/select2", options=["--exclude-globbing-filelist=testfiles/exclude.txt"])
+        self.backup("full", "testfiles/select2", options=["--exclude-filelist=testfiles/exclude.txt"])
+        self.restore()
+        restore_dir = 'testfiles/restore_out'
+        restored = self.directory_tree_to_list_of_lists(restore_dir)
+        self.assertEqual(restored, self.expected_restored_tree)
+
+    def test_exclude_filelist_combined_imperfections(self):
+        """Test that exclude filelist works with imperfections in the input file"""
+        # This is a combined test for speed reasons. The individual imperfections are tested as unittests in
+        # unit/test_selection.
+        # Imperfections tested are;
+        # * Leading space/spaces before the modifier
+        # * Trailing space/spaces after the filename (but before the newline)
+        # * Blank lines (newline character only)
+        # * Line only containing spaces
+        # * Full-line comments with # as the first character and with leading/trailing spaces
+        # * Unnecessarily quoted filenames with/without modifier (both " and ')
+
+        # Create a filelist
+        with open('testfiles/exclude.txt', 'w') as f:
+            f.write('+ testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
+                    'testfiles/select2/3/3sub3/3sub3sub2\n'
+                    '+ testfiles/select2/3/3sub2/3sub2sub2\n'
+                    ' + testfiles/select2/3/3sub3\n'  # Note leading space added here
+                    '- testfiles/select2/3/3sub1\n'
+                    '  testfiles/select2/2/2sub1/2sub1sub3\n'  # Note leading spaces added here
+                    '\n'
+                    'testfiles/select2/2/2sub1/2sub1sub2\n'
+                    ' + testfiles/select2/2/2sub1 \n'  # Note added trailing/leading space here
+                    '- "testfiles/select2/1/1sub3/1sub3sub2"\n'  # Unnecessary quotes
+                    '# Testing a full-line comment\n'
+                    "'testfiles/select2/1/1sub3/1sub3sub1'  \n"  # Note added spaces and quotes here
+                    'testfiles/select2/1/1sub2/1sub2sub3\n'
+                    '    \n'
+                    '+ testfiles/select2/1/1sub2/1sub2sub1\n'
+                    '- testfiles/select2/1/1sub1/1sub1sub3/1sub1sub3_file.txt\n'
+                    'testfiles/select2/1/1sub1/1sub1sub2\n'
+                    '     # Testing a full-line comment with leading and trailing spaces     \n'
+                    'testfiles/select2/1/1sub2  \n'  # Note added spaces here
+                    '+ testfiles/select2/1.py\n'
+                    '+ testfiles/select2/3 \n'  # Note added space here
+                    '+ testfiles/select2/1\n'
+                    '- testfiles/select2/**')
+        self.backup("full", "testfiles/select2", options=["--exclude-filelist=testfiles/exclude.txt"])
         self.restore()
         restore_dir = 'testfiles/restore_out'
         restored = self.directory_tree_to_list_of_lists(restore_dir)
@@ -272,6 +314,8 @@
 
     def test_exclude_globbing_filelist_combined_imperfections(self):
         """Test that exclude globbing filelist works with imperfections in the input file"""
+        # Identical to test_exclude_filelist_combined_imperfections and included to ensure that
+        # the deprecated --exclude-globbing-filelist function works as expected until it is deliberately removed.
         # This is a combined test for speed reasons. The individual imperfections are tested as unittests in
         # unit/test_selection.
         # Imperfections tested are;
@@ -313,7 +357,7 @@
         restored = self.directory_tree_to_list_of_lists(restore_dir)
         self.assertEqual(restored, self.expected_restored_tree)
 
-    def test_exclude_globbing_filelist_trailing_whitespace_folders_work_with_quotes(self):
+    def test_exclude_filelist_trailing_whitespace_folders_work_with_quotes(self):
         """Test that folders with trailing whitespace in the names work correctly if they are enclosed in quotes"""
         # Create a filelist
         with open('testfiles/exclude.txt', 'w') as f:
@@ -339,17 +383,17 @@
                     '+ testfiles/select2/3\n'
                     '+ testfiles/select2/1\n'
                     'testfiles/select2/**')
-        self.backup("full", "testfiles/select2", options=["--exclude-globbing-filelist=testfiles/exclude.txt"])
+        self.backup("full", "testfiles/select2", options=["--exclude-filelist=testfiles/exclude.txt"])
         self.restore()
         restore_dir = 'testfiles/restore_out'
         restored = self.directory_tree_to_list_of_lists(restore_dir)
         self.assertEqual(restored, self.expected_restored_tree_with_trailing_space)
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_progress_option(self):
-        """Test that exclude globbing filelist is unaffected by the --progress option"""
+    def test_exclude_filelist_progress_option(self):
+        """Test that exclude filelist is unaffected by the --progress option"""
         # ToDo - currently fails. Bug #1264744 (https://bugs.launchpad.net/duplicity/+bug/1264744)
-        # Create a filelist identical to that used in test_exclude_globbing_filelist
+        # Create a filelist identical to that used in test_exclude_filelist
         with open('testfiles/exclude.txt', 'w') as f:
             f.write('+ testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
                     'testfiles/select2/3/3sub3/3sub3sub2\n'
@@ -371,170 +415,94 @@
                     '+ testfiles/select2/1\n'
                     'testfiles/select2/**')
 
-        # Backup the files exactly as in test_exclude_globbing_filelist, but with the --progress option
-        self.backup("full", "testfiles/select2", options=["--exclude-globbing-filelist=testfiles/exclude.txt",
+        # Backup the files exactly as in test_exclude_filelist, but with the --progress option
+        self.backup("full", "testfiles/select2", options=["--exclude-filelist=testfiles/exclude.txt",
                                                           "--progress"])
         self.restore()
         restore_dir = 'testfiles/restore_out'
         restored = self.directory_tree_to_list_of_lists(restore_dir)
-        # The restored files should match those restored in test_exclude_globbing_filelist
-        self.assertEqual(restored, self.expected_restored_tree)
-
-class TestIncludeGlobbingFilelistTest(IncludeExcludeFunctionalTest):
-    """
-    Test --include-globbing-filelist using duplicity binary.
-    """
-
-    def test_include_globbing_filelist(self):
-        """Test that include globbing filelist works in the basic case"""
-        # See test_exclude_globbing_filelist above for explanation of what is expected. As this is an include filelist
-        # any lines with no +/- modifier should be treated as if they have a +.
-        # Create a filelist
-        with open('testfiles/include.txt', 'w') as f:
-            f.write('testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
-                    '- testfiles/select2/3/3sub3/3sub3sub2\n'
-                    'testfiles/select2/3/3sub2/3sub2sub2\n'
-                    '+ testfiles/select2/3/3sub3\n'  # + added to ensure it makes no difference
-                    '- testfiles/select2/3/3sub1\n'
-                    '- testfiles/select2/2/2sub1/2sub1sub3\n'
-                    '- testfiles/select2/2/2sub1/2sub1sub2\n'
-                    'testfiles/select2/2/2sub1\n'
-                    '- testfiles/select2/1/1sub3/1sub3sub2\n'
-                    '- testfiles/select2/1/1sub3/1sub3sub1\n'
-                    '- testfiles/select2/1/1sub2/1sub2sub3\n'
-                    '+ testfiles/select2/1/1sub2/1sub2sub1\n'  # + added to ensure it makes no difference
-                    '- testfiles/select2/1/1sub1/1sub1sub3/1sub1sub3_file.txt\n'
-                    '- testfiles/select2/1/1sub1/1sub1sub2\n'
-                    '- testfiles/select2/1/1sub2\n'
-                    'testfiles/select2/1.py\n'
-                    'testfiles/select2/3\n'
-                    'testfiles/select2/1\n'
-                    '- testfiles/select2/**')
-        self.backup("full", "testfiles/select2", options=["--include-globbing-filelist=testfiles/include.txt"])
-        self.restore()
-        restore_dir = 'testfiles/restore_out'
-        restored = self.directory_tree_to_list_of_lists(restore_dir)
-        self.assertEqual(restored, self.expected_restored_tree)
-
-    def test_include_globbing_filelist_combined_imperfections(self):
-        """Test that include globbing filelist works with imperfections in the input file"""
-        # This is a combined test for speed reasons. The individual imperfections are tested as unittests in
-        # unit/test_selection.
-        # Imperfections tested are;
-        # * Leading space/spaces before the modifier
-        # * Trailing space/spaces after the filename (but before the newline)
-        # * Blank lines (newline character only)
-        # * Line only containing spaces
-        # * Full-line comments with # as the first character and with leading/trailing spaces
-        # * Unnecessarily quoted filenames with/without modifier  (both " and ')
-        # Create a filelist
-        with open('testfiles/include.txt', 'w') as f:
-            f.write('testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
-                    '- testfiles/select2/3/3sub3/3sub3sub2\n'
-                    '"testfiles/select2/3/3sub2/3sub2sub2"\n'
-                    '  + testfiles/select2/3/3sub3\n'  # + added to ensure it makes no difference
-                    '- testfiles/select2/3/3sub1\n'
-                    '- testfiles/select2/2/2sub1/2sub1sub3\n'
-                    ' - "testfiles/select2/2/2sub1/2sub1sub2"\n'
-                    'testfiles/select2/2/2sub1  \n'
-                    '\n'
-                    '- testfiles/select2/1/1sub3/1sub3sub2\n'
-                    '- testfiles/select2/1/1sub3/1sub3sub1 \n'
-                    "- 'testfiles/select2/1/1sub2/1sub2sub3'\n"
-                    '             \n'
-                    ' + testfiles/select2/1/1sub2/1sub2sub1 \n'  # + added to ensure it makes no difference
-                    '- testfiles/select2/1/1sub1/1sub1sub3/1sub1sub3_file.txt\n'
-                    '  - testfiles/select2/1/1sub1/1sub1sub2  \n'
-                    '# Testing full-line comment\n'
-                    '- testfiles/select2/1/1sub2\n'
-                    "'testfiles/select2/1.py'\n"
-                    'testfiles/select2/3\n'
-                    '        #  Testing another full-line comment      \n'
-                    'testfiles/select2/1\n'
-                    '- testfiles/select2/**')
-        self.backup("full", "testfiles/select2", options=["--include-globbing-filelist=testfiles/include.txt"])
-        self.restore()
-        restore_dir = 'testfiles/restore_out'
-        restored = self.directory_tree_to_list_of_lists(restore_dir)
-        self.assertEqual(restored, self.expected_restored_tree)
-
+        # The restored files should match those restored in test_exclude_filelist
+        self.assertEqual(restored, self.expected_restored_tree)
 
 class TestIncludeFilelistTest(IncludeExcludeFunctionalTest):
     """
     Test --include-filelist using duplicity binary.
     """
-    @unittest.expectedFailure
+
     def test_include_filelist(self):
         """Test that include filelist works in the basic case"""
-        # See test_exclude_globbing_filelist above for explanation of what is expected. As this is an include filelist
+        # See test_exclude_filelist above for explanation of what is expected. As this is an include filelist
         # any lines with no +/- modifier should be treated as if they have a +.
-        # ToDo Currently fails - Bug #1408411 (https://bugs.launchpad.net/duplicity/+bug/1408411)
-        # Create a filelist
-        with open('testfiles/include.txt', 'w') as f:
-            f.write('testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
-                    '- testfiles/select2/3/3sub3/3sub3sub2\n'
-                    'testfiles/select2/3/3sub2/3sub2sub2\n'
-                    '+ testfiles/select2/3/3sub3\n'  # + added to ensure it makes no difference
-                    '- testfiles/select2/3/3sub1\n'
-                    '- testfiles/select2/2/2sub1/2sub1sub3\n'
-                    '- testfiles/select2/2/2sub1/2sub1sub2\n'
-                    'testfiles/select2/2/2sub1\n'
-                    '- testfiles/select2/1/1sub3/1sub3sub2\n'
-                    '- testfiles/select2/1/1sub3/1sub3sub1\n'
-                    '- testfiles/select2/1/1sub2/1sub2sub3\n'
-                    '+ testfiles/select2/1/1sub2/1sub2sub1\n'  # + added to ensure it makes no difference
-                    '- testfiles/select2/1/1sub1/1sub1sub3/1sub1sub3_file.txt\n'
-                    '- testfiles/select2/1/1sub1/1sub1sub2\n'
-                    '- testfiles/select2/1/1sub2\n'
-                    'testfiles/select2/1.py\n'
-                    'testfiles/select2/3\n'
-                    '- testfiles/select2/2\n'  # es instead of ea as no globbing - **
-                    'testfiles/select2/1\n'
-                    '- "testfiles/select2/trailing_space "\n'  # es instead of ea as no globbing - **
-                    '- testfiles/select2/1.doc')  # es instead of ea as no globbing - **
-        self.backup("full", "testfiles/select2", options=["--include-filelist=testfiles/include.txt"])
-        self.restore()
-        restore_dir = 'testfiles/restore_out'
-        restored = self.directory_tree_to_list_of_lists(restore_dir)
-        self.assertEqual(restored, self.expected_restored_tree)
-
-    def test_include_filelist_workaround(self):
-        """Test that include filelist works in the basic case"""
-        # This is a modified version of test_include_filelist that passes, despite Bug #1408411
-        # It is still a valid test, it just does not test as many selection features as the above.
-        # Create a filelist
-        with open('testfiles/include.txt', 'w') as f:
-            f.write('testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
-                    #  '- testfiles/select2/3/3sub3/3sub3sub2\n'  # Commented out because of Bug #1408411
-                    'testfiles/select2/3/3sub2/3sub2sub2\n'
-                    '+ testfiles/select2/3/3sub3\n'  # + added to ensure it makes no difference
-                    '- testfiles/select2/3/3sub1\n'
-                    '- testfiles/select2/2/2sub1/2sub1sub3\n'
-                    '- testfiles/select2/2/2sub1/2sub1sub2\n'
-                    'testfiles/select2/2/2sub1\n'
-                    '- testfiles/select2/2/2sub3\n'  # Added because of Bug #1408411
-                    '- testfiles/select2/2/2sub2\n'  # Added because of Bug #1408411
-                    '- testfiles/select2/1/1sub3/1sub3sub2\n'
-                    '- testfiles/select2/1/1sub3/1sub3sub1\n'
-                    '- testfiles/select2/1/1sub2/1sub2sub3\n'
-                    '- testfiles/select2/1/1sub2/1sub2sub2\n'  # Added because of Bug #1408411
-                    '+ testfiles/select2/1/1sub2/1sub2sub1\n'  # + added to ensure it makes no difference
-                    '- testfiles/select2/1/1sub1/1sub1sub3/1sub1sub3_file.txt\n'
-                    '- testfiles/select2/1/1sub1/1sub1sub2\n'
-                    #  '- testfiles/select2/1/1sub2\n'  # Commented out because of Bug #1408411
-                    'testfiles/select2/1.py\n'
-                    'testfiles/select2/3\n'
-                    #  '- testfiles/select2/2\n' # Commented out because of Bug #1408411
-                    'testfiles/select2/1\n'
-                    '- "testfiles/select2/trailing_space "\n'  # es instead of ea as no globbing - **
-                    '- testfiles/select2/1.doc')  # es instead of ea as no globbing - **
-        self.backup("full", "testfiles/select2", options=["--include-filelist=testfiles/include.txt"])
-        self.restore()
-        restore_dir = 'testfiles/restore_out'
-        restored = self.directory_tree_to_list_of_lists(restore_dir)
-        self.assertEqual(restored, self.expected_restored_tree)
-
-    def test_include_filelist_workaround_combined_imperfections(self):
+        # Create a filelist
+        with open('testfiles/include.txt', 'w') as f:
+            f.write('testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
+                    '- testfiles/select2/3/3sub3/3sub3sub2\n'
+                    'testfiles/select2/3/3sub2/3sub2sub2\n'
+                    '+ testfiles/select2/3/3sub3\n'  # + added to ensure it makes no difference
+                    '- testfiles/select2/3/3sub1\n'
+                    '- testfiles/select2/2/2sub1/2sub1sub3\n'
+                    '- testfiles/select2/2/2sub1/2sub1sub2\n'
+                    'testfiles/select2/2/2sub1\n'
+                    '- testfiles/select2/1/1sub3/1sub3sub2\n'
+                    '- testfiles/select2/1/1sub3/1sub3sub1\n'
+                    '- testfiles/select2/1/1sub2/1sub2sub3\n'
+                    '+ testfiles/select2/1/1sub2/1sub2sub1\n'  # + added to ensure it makes no difference
+                    '- testfiles/select2/1/1sub1/1sub1sub3/1sub1sub3_file.txt\n'
+                    '- testfiles/select2/1/1sub1/1sub1sub2\n'
+                    '- testfiles/select2/1/1sub2\n'
+                    'testfiles/select2/1.py\n'
+                    'testfiles/select2/3\n'
+                    'testfiles/select2/1\n'
+                    '- testfiles/select2/**')
+        self.backup("full", "testfiles/select2", options=["--include-filelist=testfiles/include.txt"])
+        self.restore()
+        restore_dir = 'testfiles/restore_out'
+        restored = self.directory_tree_to_list_of_lists(restore_dir)
+        self.assertEqual(restored, self.expected_restored_tree)
+
+    def test_include_filelist_combined_imperfections(self):
+        """Test that include filelist works with imperfections in the input file"""
+        # This is a combined test for speed reasons. The individual imperfections are tested as unittests in
+        # unit/test_selection.
+        # Imperfections tested are;
+        # * Leading space/spaces before the modifier
+        # * Trailing space/spaces after the filename (but before the newline)
+        # * Blank lines (newline character only)
+        # * Line only containing spaces
+        # * Full-line comments with # as the first character and with leading/trailing spaces
+        # * Unnecessarily quoted filenames with/without modifier  (both " and ')
+        # Create a filelist
+        with open('testfiles/include.txt', 'w') as f:
+            f.write('testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
+                    '- testfiles/select2/3/3sub3/3sub3sub2\n'
+                    '"testfiles/select2/3/3sub2/3sub2sub2"\n'
+                    '  + testfiles/select2/3/3sub3\n'  # + added to ensure it makes no difference
+                    '- testfiles/select2/3/3sub1\n'
+                    '- testfiles/select2/2/2sub1/2sub1sub3\n'
+                    ' - "testfiles/select2/2/2sub1/2sub1sub2"\n'
+                    'testfiles/select2/2/2sub1  \n'
+                    '\n'
+                    '- testfiles/select2/1/1sub3/1sub3sub2\n'
+                    '- testfiles/select2/1/1sub3/1sub3sub1 \n'
+                    "- 'testfiles/select2/1/1sub2/1sub2sub3'\n"
+                    '             \n'
+                    ' + testfiles/select2/1/1sub2/1sub2sub1 \n'  # + added to ensure it makes no difference
+                    '- testfiles/select2/1/1sub1/1sub1sub3/1sub1sub3_file.txt\n'
+                    '  - testfiles/select2/1/1sub1/1sub1sub2  \n'
+                    '# Testing full-line comment\n'
+                    '- testfiles/select2/1/1sub2\n'
+                    "'testfiles/select2/1.py'\n"
+                    'testfiles/select2/3\n'
+                    '        #  Testing another full-line comment      \n'
+                    'testfiles/select2/1\n'
+                    '- testfiles/select2/**')
+        self.backup("full", "testfiles/select2", options=["--include-filelist=testfiles/include.txt"])
+        self.restore()
+        restore_dir = 'testfiles/restore_out'
+        restored = self.directory_tree_to_list_of_lists(restore_dir)
+        self.assertEqual(restored, self.expected_restored_tree)
+
+    def test_include_filelist_workaround_combined_imperfections_no_wildcards(self):
         """Test that include filelist works with imperfections in the input file"""
         # This is a modified version of test_include_filelist that passes, despite Bug #1408411
         # It is still a valid test, it just does not test as many selection features as the above.
@@ -574,14 +542,58 @@
                     'testfiles/select2/3\n'
                     #  '- testfiles/select2/2\n' # Commented out because of Bug #1408411
                     'testfiles/select2/1\n'
-                    '- "testfiles/select2/trailing_space "\n'  # es instead of ea as no globbing - **
-                    '- testfiles/select2/1.doc')  # es instead of ea as no globbing - **
+                    '- "testfiles/select2/trailing_space "\n'  # es instead of ea as no wildcard - **
+                    '- testfiles/select2/1.doc')  # es instead of ea as no wildcard - **
         self.backup("full", "testfiles/select2", options=["--include-filelist=testfiles/include.txt"])
         self.restore()
         restore_dir = 'testfiles/restore_out'
         restored = self.directory_tree_to_list_of_lists(restore_dir)
         self.assertEqual(restored, self.expected_restored_tree)
 
+    def test_include_globbing_filelist_combined_imperfections(self):
+        """Test that include globbing filelist works with imperfections in the input file"""
+        # Identical to test_include_filelist_combined_imperfections and included to ensure that
+        # the deprecated --include-globbing-filelist function works as expected until it is deliberately removed.
+        # This is a combined test for speed reasons. The individual imperfections are tested as unittests in
+        # unit/test_selection.
+        # Imperfections tested are;
+        # * Leading space/spaces before the modifier
+        # * Trailing space/spaces after the filename (but before the newline)
+        # * Blank lines (newline character only)
+        # * Line only containing spaces
+        # * Full-line comments with # as the first character and with leading/trailing spaces
+        # * Unnecessarily quoted filenames with/without modifier  (both " and ')
+        # Create a filelist
+        with open('testfiles/include.txt', 'w') as f:
+            f.write('testfiles/select2/3/3sub3/3sub3sub2/3sub3sub2_file.txt\n'
+                    '- testfiles/select2/3/3sub3/3sub3sub2\n'
+                    '"testfiles/select2/3/3sub2/3sub2sub2"\n'
+                    '  + testfiles/select2/3/3sub3\n'  # + added to ensure it makes no difference
+                    '- testfiles/select2/3/3sub1\n'
+                    '- testfiles/select2/2/2sub1/2sub1sub3\n'
+                    ' - "testfiles/select2/2/2sub1/2sub1sub2"\n'
+                    'testfiles/select2/2/2sub1  \n'
+                    '\n'
+                    '- testfiles/select2/1/1sub3/1sub3sub2\n'
+                    '- testfiles/select2/1/1sub3/1sub3sub1 \n'
+                    "- 'testfiles/select2/1/1sub2/1sub2sub3'\n"
+                    '             \n'
+                    ' + testfiles/select2/1/1sub2/1sub2sub1 \n'  # + added to ensure it makes no difference
+                    '- testfiles/select2/1/1sub1/1sub1sub3/1sub1sub3_file.txt\n'
+                    '  - testfiles/select2/1/1sub1/1sub1sub2  \n'
+                    '# Testing full-line comment\n'
+                    '- testfiles/select2/1/1sub2\n'
+                    "'testfiles/select2/1.py'\n"
+                    'testfiles/select2/3\n'
+                    '        #  Testing another full-line comment      \n'
+                    'testfiles/select2/1\n'
+                    '- testfiles/select2/**')
+        self.backup("full", "testfiles/select2", options=["--include-globbing-filelist=testfiles/include.txt"])
+        self.restore()
+        restore_dir = 'testfiles/restore_out'
+        restored = self.directory_tree_to_list_of_lists(restore_dir)
+        self.assertEqual(restored, self.expected_restored_tree)
+
 
 class TestIncludeExcludedForContents(IncludeExcludeFunctionalTest):
     """ Test to check that folders that are excluded are included if they contain includes of higher priority.
@@ -614,28 +626,28 @@
 
     def test_include_globbing_filelist(self):
         """test an excluded folder is included for included contents with an include-globbing-filelist """
+        # Deprecated, but include for now to ensure it keeps working until it is deliberately removed.
         self.write_filelist("testfiles/include.txt")
         self.backup("full", "testfiles/select/1", options=["--include-globbing-filelist=testfiles/include.txt"])
         self.restore_and_check()
 
     def test_exclude_globbing_filelist(self):
         """test an excluded folder is included for included contents with an exclude-globbing-filelist """
+        # Deprecated, but include for now to ensure it keeps working until it is deliberately removed.
         self.write_filelist("testfiles/exclude.txt")
         self.backup("full", "testfiles/select/1", options=["--exclude-globbing-filelist=testfiles/exclude.txt"])
         self.restore_and_check()
 
-    @unittest.expectedFailure
     def test_include_filelist(self):
         """test an excluded folder is included for included contents with an include-filelist (non-globbing) """
-        # ToDo - currently fails - Bug #1408411 (https://bugs.launchpad.net/duplicity/+bug/1408411)
+        # Regression test for Bug #1408411 (https://bugs.launchpad.net/duplicity/+bug/1408411)
         self.write_filelist("testfiles/include.txt")
         self.backup("full", "testfiles/select/1", options=["--include-filelist=testfiles/include.txt"])
         self.restore_and_check()
 
-    @unittest.expectedFailure
     def test_exclude_filelist(self):
         """test an excluded folder is included for included contents with an exclude-filelist  (non-globbing) """
-        # ToDo - currently fails - Bug #1408411 (https://bugs.launchpad.net/duplicity/+bug/1408411)
+        # Regression test for Bug #1408411 (https://bugs.launchpad.net/duplicity/+bug/1408411)
         self.write_filelist("testfiles/exclude.txt")
         self.backup("full", "testfiles/select/1", options=["--exclude-filelist=testfiles/exclude.txt"])
         self.restore_and_check()
@@ -653,38 +665,38 @@
         restored = self.directory_tree_to_list_of_lists(restore_dir)
         self.assertEqual(restored, [['2'], ['1']])
 
-    def test_exclude_globbing_filelist_asterisks_none(self):
-        """Basic exclude globbing filelist."""
+    def test_exclude_filelist_asterisks_none(self):
+        """Basic exclude filelist."""
         with open("testfiles/filelist.txt", 'w') as f:
             f.write("+ testfiles/select/1/2/1\n"
                     "- testfiles/select/1/2\n"
                     "- testfiles/select/1/1\n"
                     "- testfiles/select/1/3")
-        self.backup("full", "testfiles/select/1", options=["--exclude-globbing-filelist=testfiles/filelist.txt"])
+        self.backup("full", "testfiles/select/1", options=["--exclude-filelist=testfiles/filelist.txt"])
         self.restore_and_check()
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_asterisks_single(self):
-        """Exclude globbing filelist with asterisks replacing folders."""
+    def test_exclude_filelist_asterisks_single(self):
+        """Exclude filelist with asterisks replacing folders."""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
         with open("testfiles/filelist.txt", 'w') as f:
             f.write("+ */select/1/2/1\n"
                     "- */select/1/2\n"
                     "- testfiles/*/1/1\n"
                     "- */*/1/3")
-        self.backup("full", "testfiles/select/1", options=["--exclude-globbing-filelist=testfiles/filelist.txt"])
+        self.backup("full", "testfiles/select/1", options=["--exclude-filelist=testfiles/filelist.txt"])
         self.restore_and_check()
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_asterisks_double_asterisks(self):
-        """Exclude globbing filelist with double asterisks replacing folders."""
+    def test_exclude_filelist_asterisks_double_asterisks(self):
+        """Exclude filelist with double asterisks replacing folders."""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
         with open("testfiles/filelist.txt", 'w') as f:
             f.write("+ **/1/2/1\n"
                     "- **/1/2\n"
                     "- **/select/1/1\n"
                     "- testfiles/select/1/3")
-        self.backup("full", "testfiles/select/1", options=["--exclude-globbing-filelist=testfiles/filelist.txt"])
+        self.backup("full", "testfiles/select/1", options=["--exclude-filelist=testfiles/filelist.txt"])
         self.restore_and_check()
 
     def test_commandline_asterisks_single_excludes_only(self):
@@ -738,43 +750,43 @@
         restored = self.directory_tree_to_list_of_lists(restore_dir)
         self.assertEqual(restored, [['2'], ['1']])
 
-    def test_exclude_globbing_filelist_trailing_slashes(self):
-        """test_exclude_globbing_filelist_asterisks_none with trailing slashes."""
+    def test_exclude_filelist_trailing_slashes(self):
+        """test_exclude_filelist_asterisks_none with trailing slashes."""
         with open("testfiles/filelist.txt", 'w') as f:
             f.write("+ testfiles/select/1/2/1/\n"
                     "- testfiles/select/1/2/\n"
                     "- testfiles/select/1/1/\n"
                     "- testfiles/select/1/3/")
-        self.backup("full", "testfiles/select/1", options=["--exclude-globbing-filelist=testfiles/filelist.txt"])
+        self.backup("full", "testfiles/select/1", options=["--exclude-filelist=testfiles/filelist.txt"])
         self.restore_and_check()
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_trailing_slashes_single_wildcards_excludes(self):
-        """test_exclude_globbing_filelist_trailing_slashes with single wildcards in excludes."""
+    def test_exclude_filelist_trailing_slashes_single_wildcards_excludes(self):
+        """test_exclude_filelist_trailing_slashes with single wildcards in excludes."""
         # Todo: Bug #932482 (https://bugs.launchpad.net/duplicity/+bug/932482)
         with open("testfiles/filelist.txt", 'w') as f:
             f.write("+ testfiles/select/1/2/1/\n"
                     "- */select/1/2/\n"
                     "- testfiles/*/1/1/\n"
                     "- */*/1/3/")
-        self.backup("full", "testfiles/select/1", options=["--exclude-globbing-filelist=testfiles/filelist.txt"])
+        self.backup("full", "testfiles/select/1", options=["--exclude-filelist=testfiles/filelist.txt"])
         self.restore_and_check()
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_trailing_slashes_double_wildcards_excludes(self):
-        """test_exclude_globbing_filelist_trailing_slashes with double wildcards in excludes."""
+    def test_exclude_filelist_trailing_slashes_double_wildcards_excludes(self):
+        """test_exclude_filelist_trailing_slashes with double wildcards in excludes."""
         # Todo: Bug #932482 (https://bugs.launchpad.net/duplicity/+bug/932482)
         with open("testfiles/filelist.txt", 'w') as f:
             f.write("+ testfiles/select/1/2/1/\n"
                     "- **/1/2/\n"
                     "- **/1/1/\n"
                     "- **/1/3/")
-        self.backup("full", "testfiles/select/1", options=["--exclude-globbing-filelist=testfiles/filelist.txt"])
+        self.backup("full", "testfiles/select/1", options=["--exclude-filelist=testfiles/filelist.txt"])
         self.restore_and_check()
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_trailing_slashes_double_wildcards_excludes(self):
-        """test_exclude_globbing_filelist_trailing_slashes with double wildcards in excludes."""
+    def test_exclude_filelist_trailing_slashes_double_wildcards_excludes(self):
+        """test_exclude_filelist_trailing_slashes with double wildcards in excludes."""
         # Todo: Bug #932482 (https://bugs.launchpad.net/duplicity/+bug/932482) and likely
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
         with open("testfiles/filelist.txt", 'w') as f:
@@ -782,11 +794,11 @@
                     "- **/1/2/\n"
                     "- **/1/1/\n"
                     "- **/1/3/")
-        self.backup("full", "testfiles/select/1", options=["--exclude-globbing-filelist=testfiles/filelist.txt"])
+        self.backup("full", "testfiles/select/1", options=["--exclude-filelist=testfiles/filelist.txt"])
         self.restore_and_check()
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_trailing_slashes_wildcards(self):
+    def test_exclude_filelist_trailing_slashes_wildcards(self):
         """test_commandline_asterisks_single_excludes_only with trailing slashes."""
          # Todo: Bug #932482 (https://bugs.launchpad.net/duplicity/+bug/932482)
         self.backup("full", "testfiles/select/1",
@@ -796,7 +808,5 @@
                              "--exclude", "*/select/1/3/"])
         self.restore_and_check()
 
-
-
 if __name__ == "__main__":
     unittest.main()

=== added file 'testing/stdin_test.sh'
--- testing/stdin_test.sh	1970-01-01 00:00:00 +0000
+++ testing/stdin_test.sh	2015-03-12 19:36:56 +0000
@@ -0,0 +1,203 @@
+#!/bin/sh
+# Script to show the current behaviour of duplicity's --include/exclude-filelist-stdin 
+# function. This is currently hard to show in functional tests because the stdin-processing
+# logic is in the commandline parser. 
+# (c) 2015 Aaron Whitehouse <aaron@xxxxxxxxxxxxxxxxxx>
+# GPLv2 or any later version
+export PASSPHRASE=test
+
+TESTDIR=/tmp/duplicity_test
+mkdir $TESTDIR
+SOURCEDIR=$TESTDIR/dup_source
+mkdir $SOURCEDIR
+TARGETDIR=$TESTDIR/dup_target
+mkdir $TARGETDIR
+RESTOREDIR=$TESTDIR/dup_restore
+mkdir $RESTOREDIR
+
+tar -C $SOURCEDIR -xvf testfiles.tar.gz testfiles/select 
+
+DUPLICITY_CMD="../bin/duplicity"
+export PYTHONPATH=../
+
+$DUPLICITY_CMD -V
+
+echo "==========="
+echo "FIRST TEST."
+echo "==========="
+TEST1="Test with exclude-globbing"
+echo "${TEST1}"
+echo "+ $SOURCEDIR/testfiles/select/1/1" > $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/1/2" >> $TESTDIR/exclude.txt
+echo "+ $SOURCEDIR/testfiles/select/1/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/**" >> $TESTDIR/exclude.txt
+
+$DUPLICITY_CMD --exclude-globbing-filelist $TESTDIR/exclude.txt $SOURCEDIR file://$TARGETDIR
+$DUPLICITY_CMD file://$TARGETDIR $RESTOREDIR
+echo "Number of files/folders:"
+OUTPUT_TEST1="$(find $RESTOREDIR | wc -l)"
+echo "${OUTPUT_TEST1}"
+
+rm -r $TESTDIR
+
+echo "==========="
+echo "SECOND TEST."
+echo "==========="
+TEST2="Test with exclude"
+echo "${TEST2}"
+
+mkdir $TESTDIR
+mkdir $SOURCEDIR
+mkdir $TARGETDIR
+mkdir $RESTOREDIR
+tar -C $SOURCEDIR -xvf testfiles.tar.gz testfiles/select 
+
+echo "+ $SOURCEDIR/testfiles/select/1/1" > $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/1/2" >> $TESTDIR/exclude.txt
+echo "+ $SOURCEDIR/testfiles/select/1/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/**" >> $TESTDIR/exclude.txt
+
+$DUPLICITY_CMD --exclude-filelist $TESTDIR/exclude.txt $SOURCEDIR file://$TARGETDIR
+$DUPLICITY_CMD file://$TARGETDIR $RESTOREDIR
+echo "Number of files/folders:"
+find $RESTOREDIR | wc -l
+OUTPUT_TEST2="$(find $RESTOREDIR | wc -l)"
+echo "${OUTPUT_TEST2}"
+
+rm -r $TESTDIR
+
+echo "==========="
+echo "THIRD TEST."
+echo "==========="
+TEST3="Test with stdin with exclude"
+echo "${TEST3}"
+mkdir $TESTDIR
+mkdir $SOURCEDIR
+mkdir $TARGETDIR
+mkdir $RESTOREDIR
+tar -C $SOURCEDIR -xvf testfiles.tar.gz testfiles/select 
+
+echo "+ $SOURCEDIR/testfiles/select/1/1" > $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/1/2" >> $TESTDIR/exclude.txt
+echo "+ $SOURCEDIR/testfiles/select/1/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/**" >> $TESTDIR/exclude.txt
+
+cat $TESTDIR/exclude.txt | $DUPLICITY_CMD --exclude-filelist-stdin $SOURCEDIR file://$TARGETDIR
+$DUPLICITY_CMD file://$TARGETDIR $RESTOREDIR
+echo "Number of files/folders:"
+OUTPUT_TEST3="$(find $RESTOREDIR | wc -l)"
+echo "${OUTPUT_TEST3}"
+
+rm -r $TESTDIR
+
+echo "==========="
+echo "FOURTH TEST."
+echo "==========="
+TEST4="Test with nothing"
+echo "${TEST4}"
+mkdir $TESTDIR
+mkdir $SOURCEDIR
+mkdir $TARGETDIR
+mkdir $RESTOREDIR
+tar -C $SOURCEDIR -xvf testfiles.tar.gz testfiles/select 
+
+echo "+ $SOURCEDIR/testfiles/select/1/1" > $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/1/2" >> $TESTDIR/exclude.txt
+echo "+ $SOURCEDIR/testfiles/select/1/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/**" >> $TESTDIR/exclude.txt
+
+$DUPLICITY_CMD $SOURCEDIR file://$TARGETDIR
+$DUPLICITY_CMD file://$TARGETDIR $RESTOREDIR
+echo "Number of files/folders:"
+OUTPUT_TEST4="$(find $RESTOREDIR | wc -l)"
+echo "${OUTPUT_TEST4}"
+
+rm -r $TESTDIR
+
+echo "==========="
+echo "FIFTH TEST."
+echo "==========="
+TEST5="Test using /dev/stdin as a substitute for --exclude-filelist-stdin"
+echo "${TEST5}"
+mkdir $TESTDIR
+mkdir $SOURCEDIR
+mkdir $TARGETDIR
+mkdir $RESTOREDIR
+tar -C $SOURCEDIR -xvf testfiles.tar.gz testfiles/select 
+
+echo "+ $SOURCEDIR/testfiles/select/1/1" > $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/1/2" >> $TESTDIR/exclude.txt
+echo "+ $SOURCEDIR/testfiles/select/1/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/testfiles/select/3" >> $TESTDIR/exclude.txt
+echo "- $SOURCEDIR/**" >> $TESTDIR/exclude.txt
+
+cat $TESTDIR/exclude.txt | $DUPLICITY_CMD --exclude-filelist /dev/stdin $SOURCEDIR file://$TARGETDIR
+$DUPLICITY_CMD file://$TARGETDIR $RESTOREDIR
+echo "Number of files/folders:"
+OUTPUT_TEST5="$(find $RESTOREDIR | wc -l)"
+echo "${OUTPUT_TEST5}"
+
+rm -r $TESTDIR
+
+echo "==========="
+echo "SIXTH TEST."
+echo "==========="
+TEST6="Test with stdin with include"
+echo "${TEST6}"
+mkdir $TESTDIR
+mkdir $SOURCEDIR
+mkdir $TARGETDIR
+mkdir $RESTOREDIR
+tar -C $SOURCEDIR -xvf testfiles.tar.gz testfiles/select 
+
+echo "+ $SOURCEDIR/testfiles/select/1/1" > $TESTDIR/include.txt
+echo "- $SOURCEDIR/testfiles/select/1/2" >> $TESTDIR/include.txt
+echo "+ $SOURCEDIR/testfiles/select/1/3" >> $TESTDIR/include.txt
+echo "- $SOURCEDIR/testfiles/select/3" >> $TESTDIR/include.txt
+echo "- $SOURCEDIR/**" >> $TESTDIR/include.txt
+
+cat $TESTDIR/include.txt | $DUPLICITY_CMD --include-filelist-stdin $SOURCEDIR file://$TARGETDIR
+$DUPLICITY_CMD file://$TARGETDIR $RESTOREDIR
+echo "Number of files/folders:"
+OUTPUT_TEST6="$(find $RESTOREDIR | wc -l)"
+echo "${OUTPUT_TEST6}"
+
+rm -r $TESTDIR
+
+echo "============"
+echo "SEVENTH TEST."
+echo "============"
+TEST7="Test using /dev/stdin as a substitute for --include-filelist-stdin"
+echo "${TEST7}"
+mkdir $TESTDIR
+mkdir $SOURCEDIR
+mkdir $TARGETDIR
+mkdir $RESTOREDIR
+tar -C $SOURCEDIR -xvf testfiles.tar.gz testfiles/select 
+
+echo "+ $SOURCEDIR/testfiles/select/1/1" > $TESTDIR/include.txt
+echo "- $SOURCEDIR/testfiles/select/1/2" >> $TESTDIR/include.txt
+echo "+ $SOURCEDIR/testfiles/select/1/3" >> $TESTDIR/include.txt
+echo "- $SOURCEDIR/testfiles/select/3" >> $TESTDIR/include.txt
+echo "- $SOURCEDIR/**" >> $TESTDIR/include.txt
+
+cat $TESTDIR/include.txt | $DUPLICITY_CMD --include-filelist /dev/stdin $SOURCEDIR file://$TARGETDIR
+$DUPLICITY_CMD file://$TARGETDIR $RESTOREDIR
+echo "Number of files/folders:"
+OUTPUT_TEST7="$(find $RESTOREDIR | wc -l)"
+echo "${OUTPUT_TEST7}"
+
+rm -r $TESTDIR
+
+unset PASSPHRASE
+echo "1.""${TEST1}" "${OUTPUT_TEST1}"
+echo "2.""${TEST2}" "${OUTPUT_TEST2}"
+echo "3.""${TEST3}" "${OUTPUT_TEST3}"
+echo "4.""${TEST4}" "${OUTPUT_TEST4}"
+echo "5.""${TEST5}" "${OUTPUT_TEST5}"
+echo "6.""${TEST6}" "${OUTPUT_TEST6}"
+echo "7.""${TEST7}" "${OUTPUT_TEST7}"

=== modified file 'testing/unit/test_selection.py'
--- testing/unit/test_selection.py	2015-02-01 17:37:37 +0000
+++ testing/unit/test_selection.py	2015-03-12 19:36:56 +0000
@@ -102,6 +102,7 @@
         assert sf2(self.makeext("what/ever.py")) == 0
         assert sf2(self.makeext("what/ever.py/foo")) == 0
 
+<<<<<<< TREE
     def testFilelistInclude(self):
         """Test included filelist"""
         fp = StringIO.StringIO("""
@@ -407,6 +408,8 @@
         assert sf(self.makeext("2")) is None
         assert sf(self.makeext("3")) == 0
 
+=======
+>>>>>>> MERGE-SOURCE
     def testGlobRE(self):
         """testGlobRE - test translation of shell pattern to regular exp"""
         assert self.Select.glob_to_re("hello") == "hello"
@@ -456,12 +459,15 @@
         assert select.glob_get_sf("**", 0)(root) == 0
         assert select.glob_get_sf("/foo/*", 0)(root) is None
 
+<<<<<<< TREE
         assert select.filelist_get_sf(StringIO.StringIO("/"), 1, "test")(root) == 1
         assert select.filelist_get_sf(StringIO.StringIO("/foo/bar"), 1, "test")(root) == 1
         assert select.filelist_get_sf(StringIO.StringIO("/"), 0, "test")(root) == 0
         assert select.filelist_get_sf(StringIO.StringIO("/foo/bar"), 0,
                                       "test")(root) is None
 
+=======
+>>>>>>> MERGE-SOURCE
     def testOtherFilesystems(self):
         """Test to see if --exclude-other-filesystems works correctly"""
         root = Path("/")
@@ -531,9 +537,9 @@
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')])
 
-    def test_globbing_filelist(self):
+    def test_filelist(self):
         """Filelist glob test similar to above testParse2"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -541,9 +547,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_1_trailing_whitespace(self):
+    def test_include_filelist_1_trailing_whitespace(self):
         """Filelist glob test similar to globbing filelist, but with 1 trailing whitespace on include"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -551,9 +557,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_2_trailing_whitespaces(self):
+    def test_include_filelist_2_trailing_whitespaces(self):
         """Filelist glob test similar to globbing filelist, but with 2 trailing whitespaces on include"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -561,9 +567,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_1_leading_whitespace(self):
+    def test_include_filelist_1_leading_whitespace(self):
         """Filelist glob test similar to globbing filelist, but with 1 leading whitespace on include"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -571,9 +577,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_2_leading_whitespaces(self):
+    def test_include_filelist_2_leading_whitespaces(self):
         """Filelist glob test similar to globbing filelist, but with 2 leading whitespaces on include"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -581,9 +587,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_1_trailing_whitespace_exclude(self):
+    def test_include_filelist_1_trailing_whitespace_exclude(self):
         """Filelist glob test similar to globbing filelist, but with 1 trailing whitespace on exclude"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1 \n"
@@ -591,9 +597,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_2_trailing_whitespace_exclude(self):
+    def test_include_filelist_2_trailing_whitespace_exclude(self):
         """Filelist glob test similar to globbing filelist, but with 2 trailing whitespaces on exclude"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1  \n"
@@ -601,9 +607,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_1_leading_whitespace_exclude(self):
+    def test_include_filelist_1_leading_whitespace_exclude(self):
         """Filelist glob test similar to globbing filelist, but with 1 leading whitespace on exclude"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        [" - testfiles/select/1/1/1\n"
@@ -611,9 +617,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_2_leading_whitespaces_exclude(self):
+    def test_include_filelist_2_leading_whitespaces_exclude(self):
         """Filelist glob test similar to globbing filelist, but with 2 leading whitespaces on exclude"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["  - testfiles/select/1/1/1\n"
@@ -621,9 +627,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_check_excluded_folder_included_for_contents(self):
+    def test_include_filelist_check_excluded_folder_included_for_contents(self):
         """Filelist glob test to check excluded folder is included if contents are"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '1'), ('1', '1', '2'),
                         ('1', '1', '3'), ('1', '2'), ('1', '2', '1'), ('1', '3'), ('1', '3', '1'), ('1', '3', '2'),
                         ('1', '3', '3')],
@@ -632,9 +638,9 @@
                         "testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_with_unnecessary_quotes(self):
+    def test_include_filelist_with_unnecessary_quotes(self):
         """Filelist glob test similar to globbing filelist, but with quotes around one of the paths."""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- 'testfiles/select/1/1/1'\n"
@@ -642,9 +648,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_with_unnecessary_double_quotes(self):
+    def test_include_filelist_with_unnecessary_double_quotes(self):
         """Filelist glob test similar to globbing filelist, but with double quotes around one of the paths."""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ['- "testfiles/select/1/1/1"\n'
@@ -652,9 +658,9 @@
                         '- testfiles/select/1\n'
                         '- **'])
 
-    def test_include_globbing_filelist_with_full_line_comment(self):
+    def test_include_filelist_with_full_line_comment(self):
         """Filelist glob test similar to globbing filelist, but with a full-line comment."""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ['- testfiles/select/1/1/1\n'
@@ -663,9 +669,9 @@
                         '- testfiles/select/1\n'
                         '- **'])
 
-    def test_include_globbing_filelist_with_blank_line(self):
+    def test_include_filelist_with_blank_line(self):
         """Filelist glob test similar to globbing filelist, but with a blank line."""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ['- testfiles/select/1/1/1\n'
@@ -674,9 +680,9 @@
                         '- testfiles/select/1\n'
                         '- **'])
 
-    def test_include_globbing_filelist_with_blank_line_and_whitespace(self):
+    def test_include_filelist_with_blank_line_and_whitespace(self):
         """Filelist glob test similar to globbing filelist, but with a blank line and whitespace."""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ['- testfiles/select/1/1/1\n'
@@ -685,19 +691,19 @@
                         '- testfiles/select/1\n'
                         '- **'])
 
-    def test_include_globbing_filelist_asterisk(self):
+    def test_include_filelist_asterisk(self):
         """Filelist glob test with * instead of 'testfiles'"""
         # Thank you to Elifarley Cruz for this test case
         # (https://bugs.launchpad.net/duplicity/+bug/884371).
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '1'),
                         ('1', '1', '2'), ('1', '1', '3')],
                        ["*/select/1/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_asterisk_2(self):
-        """Identical to test_globbing_filelist, but with the exclude 'select' replaced with '*'"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+    def test_include_filelist_asterisk_2(self):
+        """Identical to test_filelist, but with the exclude 'select' replaced with '*'"""
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/*/1/1/1\n"
@@ -706,10 +712,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_asterisk_3(self):
-        """Identical to test_globbing_filelist, but with the auto-include 'select' replaced with '*'"""
+    def test_include_filelist_asterisk_3(self):
+        """Identical to test_filelist, but with the auto-include 'select' replaced with '*'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -718,10 +724,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_asterisk_4(self):
-        """Identical to test_globbing_filelist, but with a specific include 'select' replaced with '*'"""
+    def test_include_filelist_asterisk_4(self):
+        """Identical to test_filelist, but with a specific include 'select' replaced with '*'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -730,10 +736,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_asterisk_5(self):
-        """Identical to test_globbing_filelist, but with all 'select's replaced with '*'"""
+    def test_include_filelist_asterisk_5(self):
+        """Identical to test_filelist, but with all 'select's replaced with '*'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/*/1/1/1\n"
@@ -741,9 +747,9 @@
                         "- testfiles/*/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_asterisk_6(self):
-        """Identical to test_globbing_filelist, but with numerous excluded folders replaced with '*'"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+    def test_include_filelist_asterisk_6(self):
+        """Identical to test_filelist, but with numerous excluded folders replaced with '*'"""
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- */*/1/1/1\n"
@@ -752,10 +758,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_asterisk_7(self):
-        """Identical to test_globbing_filelist, but with numerous included/excluded folders replaced with '*'"""
+    def test_include_filelist_asterisk_7(self):
+        """Identical to test_filelist, but with numerous included/excluded folders replaced with '*'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- */*/1/1/1\n"
@@ -763,9 +769,16 @@
                         "- */*/1\n"
                         "- **"])
 
+<<<<<<< TREE
     def test_include_globbing_filelist_double_asterisk_1(self):
         """Identical to test_globbing_filelist, but with the exclude 'select' replaced with '**'"""
         self.ParseTest([("--include-globbing-filelist", "file")],
+=======
+
+    def test_include_filelist_double_asterisk_1(self):
+        """Identical to test_filelist, but with the exclude 'select' replaced with '**'"""
+        self.ParseTest([("--include-filelist", "file")],
+>>>>>>> MERGE-SOURCE
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/**/1/1/1\n"
@@ -774,10 +787,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_double_asterisk_2(self):
-        """Identical to test_globbing_filelist, but with the include 'select' replaced with '**'"""
+    def test_include_filelist_double_asterisk_2(self):
+        """Identical to test_filelist, but with the include 'select' replaced with '**'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -785,9 +798,9 @@
                         "- testfiles/select/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_double_asterisk_3(self):
-        """Identical to test_globbing_filelist, but with the exclude 'testfiles/select' replaced with '**'"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+    def test_include_filelist_double_asterisk_3(self):
+        """Identical to test_filelist, but with the exclude 'testfiles/select' replaced with '**'"""
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- **/1/1/1\n"
@@ -796,10 +809,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_double_asterisk_4(self):
-        """Identical to test_globbing_filelist, but with the include 'testfiles/select' replaced with '**'"""
+    def test_include_filelist_double_asterisk_4(self):
+        """Identical to test_filelist, but with the include 'testfiles/select' replaced with '**'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1\n"
@@ -808,10 +821,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_double_asterisk_5(self):
-        """Identical to test_globbing_filelist, but with all 'testfiles/select's replaced with '**'"""
+    def test_include_filelist_double_asterisk_5(self):
+        """Identical to test_filelist, but with all 'testfiles/select's replaced with '**'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- **/1/1/1\n"
@@ -819,9 +832,9 @@
                         "- **/1\n"
                         "- **"])
 
-    def test_include_globbing_filelist_trailing_slashes(self):
+    def test_include_filelist_trailing_slashes(self):
         """Filelist glob test similar to globbing filelist, but with trailing slashes"""
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- testfiles/select/1/1/1/\n"
@@ -830,10 +843,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_trailing_slashes_and_single_asterisks(self):
+    def test_include_filelist_trailing_slashes_and_single_asterisks(self):
         """Filelist glob test similar to globbing filelist, but with trailing slashes and single asterisks"""
         # Todo: Bug #932482 (https://bugs.launchpad.net/duplicity/+bug/932482)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- */select/1/1/1/\n"
@@ -842,10 +855,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_include_globbing_filelist_trailing_slashes_and_double_asterisks(self):
+    def test_include_filelist_trailing_slashes_and_double_asterisks(self):
         """Filelist glob test similar to globbing filelist, but with trailing slashes and double asterisks"""
         # Todo: Bug #932482 (https://bugs.launchpad.net/duplicity/+bug/932482)
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["- **/1/1/1/\n"
@@ -853,9 +866,18 @@
                         "- **/1/\n"
                         "- **"])
 
-    def test_exclude_globbing_filelist(self):
-        """Exclude version of test_globbing_filelist"""
-        self.ParseTest([("--exclude-globbing-filelist", "file")],
+
+    def test_filelist_null_separator(self):
+        """test_filelist, but with null_separator set"""
+        self.set_global('null_separator', 1)
+        self.ParseTest([("--include-filelist", "file")],
+                       [(), ('1',), ('1', '1'), ('1', '1', '2'),
+                        ('1', '1', '3')],
+                       ["\0- testfiles/select/1/1/1\0testfiles/select/1/1\0- testfiles/select/1\0- **\0"])
+
+    def test_exclude_filelist(self):
+        """Exclude version of test_filelist"""
+        self.ParseTest([("--exclude-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["testfiles/select/1/1/1\n"
@@ -863,17 +885,17 @@
                         "testfiles/select/1\n"
                         "- **"])
 
-    def test_exclude_globbing_filelist_asterisk_1(self):
-        """Exclude version of test_include_globbing_filelist_asterisk"""
-        self.ParseTest([("--exclude-globbing-filelist", "file")],
+    def test_exclude_filelist_asterisk_1(self):
+        """Exclude version of test_include_filelist_asterisk"""
+        self.ParseTest([("--exclude-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '1'),
                         ('1', '1', '2'), ('1', '1', '3')],
                        ["+ */select/1/1\n"
                         "- **"])
 
-    def test_exclude_globbing_filelist_asterisk_2(self):
-        """Identical to test_exclude_globbing_filelist, but with the exclude 'select' replaced with '*'"""
-        self.ParseTest([("--exclude-globbing-filelist", "file")],
+    def test_exclude_filelist_asterisk_2(self):
+        """Identical to test_exclude_filelist, but with the exclude 'select' replaced with '*'"""
+        self.ParseTest([("--exclude-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["testfiles/*/1/1/1\n"
@@ -882,10 +904,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_asterisk_3(self):
-        """Identical to test_exclude_globbing_filelist, but with the include 'select' replaced with '*'"""
+    def test_exclude_filelist_asterisk_3(self):
+        """Identical to test_exclude_filelist, but with the include 'select' replaced with '*'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--exclude-globbing-filelist", "file")],
+        self.ParseTest([("--exclude-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["testfiles/select/1/1/1\n"
@@ -893,9 +915,9 @@
                         "testfiles/select/1\n"
                         "- **"])
 
-    def test_exclude_globbing_filelist_asterisk_4(self):
-        """Identical to test_exclude_globbing_filelist, but with numerous excluded folders replaced with '*'"""
-        self.ParseTest([("--exclude-globbing-filelist", "file")],
+    def test_exclude_filelist_asterisk_4(self):
+        """Identical to test_exclude_filelist, but with numerous excluded folders replaced with '*'"""
+        self.ParseTest([("--exclude-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["*/select/1/1/1\n"
@@ -904,10 +926,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_asterisk_5(self):
-        """Identical to test_exclude_globbing_filelist, but with numerous included/excluded folders replaced with '*'"""
+    def test_exclude_filelist_asterisk_5(self):
+        """Identical to test_exclude_filelist, but with numerous included/excluded folders replaced with '*'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--exclude-globbing-filelist", "file")],
+        self.ParseTest([("--exclude-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["*/select/1/1/1\n"
@@ -916,10 +938,10 @@
                         "- **"])
 
     @unittest.expectedFailure
-    def test_exclude_globbing_filelist_double_asterisk(self):
-        """Identical to test_exclude_globbing_filelist, but with all included/excluded folders replaced with '**'"""
+    def test_exclude_filelist_double_asterisk(self):
+        """Identical to test_exclude_filelist, but with all included/excluded folders replaced with '**'"""
         # Todo: Bug #884371 (https://bugs.launchpad.net/duplicity/+bug/884371)
-        self.ParseTest([("--exclude-globbing-filelist", "file")],
+        self.ParseTest([("--exclude-filelist", "file")],
                        [(), ('1',), ('1', '1'), ('1', '1', '2'),
                         ('1', '1', '3')],
                        ["**/1/1/1\n"
@@ -956,9 +978,9 @@
                         ('3', '3'),
                         ('3', '3', '2')])
 
-    def test_globbing_filelist2(self):
+    def test_filelist2(self):
         """Filelist glob test similar to above testGlob"""
-        self.ParseTest([("--exclude-globbing-filelist", "asoeuth")],
+        self.ParseTest([("--exclude-filelist", "asoeuth")],
                        [(), ('1',), ('1', '1'),
                         ('1', '1', '1'), ('1', '1', '2'),
                         ('1', '2'), ('1', '2', '1'), ('1', '2', '2')],
@@ -967,7 +989,7 @@
 + testfiles/select/1
 **
 """])
-        self.ParseTest([("--include-globbing-filelist", "file")],
+        self.ParseTest([("--include-filelist", "file")],
                        [(), ('1',), ('1', '1'),
                         ('1', '1', '2'),
                         ('1', '2'),


Follow ups