Hello Bastian, Thanks for your patch, i think that we will be able to commit it shortly.
FYI, the src/dird/ua_input.c file contains lots of useful functions to parse arguments. For example, instead of using : if ((strncasecmp(ua->argv[i], "yes", strlen(ua->argv[i])) == 0) || (strncasecmp(ua->argv[i], _("yes"), strlen(ua->argv[i])) == 0) || (strncmp(ua->argv[i], "1", strlen(ua->argv[i])) == 0)) { rc.spool_data = 1; rc.spool_data_set = 1; kw_ok = true; else if ((strncasecmp(ua->argv[i], "no", strlen(ua->argv[i])) == 0) || (strncasecmp(ua->argv[i], _("no"), strlen(ua->argv[i])) == 0) || (strncmp(ua->argv[i], "0", strlen(ua->argv[i])) == 0)) { rc.spool_data = 0; rc.spool_data_set = 1; kw_ok = true; } else { ua->send_msg(_("Invalid spooldata flag.\n")); } You can use something like (without the support of 0/1 value which is not common in bacula) rc.spool_data_set = is_yesno(ua->argv[i], &rc.spool_data); Could you also write something for the manual ? Else, users will have to read the code to find this option... (since we removed it from the menu). Maybe somewhere in the console chapter http://www.bacula.org/manuals/en/console/console/Bacula_Console.html#SECTION00450000000000000000 and in the spooling chapter part http://www.bacula.org/manuals/en/concepts/concepts/Data_Spooling.html I can integrate your text in LaTeX files if you want. Thanks in advance. Bye Le Wednesday 05 November 2008 08:17:52 Bastian Friedrich, vous avez écrit : > Hi, > > On Tuesday 04 November 2008, Kern Sibbald wrote: > > On Tuesday 04 November 2008 15:44:27 Bastian Friedrich wrote: > > > Hi Eric et al., > > > > > > On Tuesday 04 November 2008, Eric Bollengier wrote: > > > > Le Tuesday 04 November 2008 15:14:40 Bastian Friedrich, vous avez > > écrit : > > > > > currently, Bacula accepts a "Spool data" flag for storages within > > > > > job ressources, and in Run statements in a schedule. Modifying the > > > > > Spooling statement while calling "run" inside bconsole is not > > > > > available. > > > > > > > > > > Doing so is sensible in a number of cases; often, Full backups may > > > > > be non-spooled, while incrementals should be spooled. Defining a > > > > > Job as "to disk" per default, but enabling spooling when running > > > > > the same job to tape, is quite sensible. > > > > > > > > > > The attached patch > > > > > a) adds a "spooldata={yes|1|no|0}" to the run statement on the > > > > > bconsole CLI > > [...] > > > A patch that just adds a command line spooling option (no prompts, ...) > > would be something I would be in favor of adding. > > The attached version is stripped down to the non-interactive parts only. > > Thx & Best regards > Bastian ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Bacula-devel mailing list Bacula-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-devel