- case 'b': /* bootstrap file */
- bsr = parse_bsr(NULL, optarg);
-// dump_bsr(bsr);
- break;
-
- case 'c': /* specify config file */
- if (configfile != NULL) {
- free(configfile);
- }
- configfile = bstrdup(optarg);
- break;
-
- case 'd': /* debug level */
- debug_level = atoi(optarg);
- if (debug_level <= 0)
- debug_level = 1;
- break;
+ case 'b': /* bootstrap file */
+ bsr = parse_bsr(NULL, optarg);
+// dump_bsr(bsr, true);
+ break;
+
+ case 'c': /* specify config file */
+ if (configfile != NULL) {
+ free(configfile);
+ }
+ configfile = bstrdup(optarg);
+ break;
+
+ case 'd': /* debug level */
+ debug_level = atoi(optarg);
+ if (debug_level <= 0)
+ debug_level = 1;
+ break;
+
+ case 'e': /* exclude list */
+ if ((fd = fopen(optarg, "r")) == NULL) {
+ berrno be;
+ Pmsg2(0, "Could not open exclude file: %s, ERR=%s\n",
+ optarg, be.strerror());
+ exit(1);
+ }
+ while (fgets(line, sizeof(line), fd) != NULL) {
+ strip_trailing_junk(line);
+ Dmsg1(900, "add_exclude %s\n", line);
+ add_fname_to_exclude_list(ff, line);
+ }
+ fclose(fd);
+ break;
+
+ case 'i': /* include list */
+ if ((fd = fopen(optarg, "r")) == NULL) {
+ berrno be;
+ Pmsg2(0, "Could not open include file: %s, ERR=%s\n",
+ optarg, be.strerror());
+ exit(1);
+ }
+ while (fgets(line, sizeof(line), fd) != NULL) {
+ strip_trailing_junk(line);
+ Dmsg1(900, "add_include %s\n", line);
+ add_fname_to_include_list(ff, 0, line);
+ }
+ fclose(fd);
+ got_inc = TRUE;
+ break;