Fossil

Check-in [975600dd]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Make addremove command to fail if unprocessed arguments (other than options) are specified. To avoid mis-use where a user could think he can specify a list of directory like with many other commands.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:975600dd599fff84c0425fe636bb15cc4a393d79
User & Date: mgagnon 2015-05-12 10:42:20
Context
2015-05-12
13:19
Permit --notfound and --repolist to be used together on "fossil server". Merge changes to always show a piechart for "By User" reports. Fix an uninitialized variable in "fossil rebuild". check-in: 434f7e17 user: drh tags: trunk
10:42
Make addremove command to fail if unprocessed arguments (other than options) are specified. To avoid mis-use where a user could think he can specify a list of directory like with many other commands. check-in: 975600dd user: mgagnon tags: trunk
04:42
Fix compiler warnings with MSVC. check-in: 8ab3f620 user: mistachkin tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/add.c.

630
631
632
633
634
635
636








637
638
639
640
641
642
643
  if( !dryRunFlag ){
    dryRunFlag = find_option("test",0,0)!=0; /* deprecated */
  }

  /* We should be done with options.. */
  verify_all_options();









  db_must_be_within_tree();
  if( zCleanFlag==0 ){
    zCleanFlag = db_get("clean-glob", 0);
  }
  if( zIgnoreFlag==0 ){
    zIgnoreFlag = db_get("ignore-glob", 0);
  }







>
>
>
>
>
>
>
>







630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
  if( !dryRunFlag ){
    dryRunFlag = find_option("test",0,0)!=0; /* deprecated */
  }

  /* We should be done with options.. */
  verify_all_options();

  /* Fail if unprocessed arguments are present, in case user expect the
  ** addremove command to accept a list of file or directory. 
  */
  if( g.argc>2 ){
    fossil_fatal(
        "%s: Can only work on the entire checkout, no arguments supported.",
        g.argv[1]);
  }
  db_must_be_within_tree();
  if( zCleanFlag==0 ){
    zCleanFlag = db_get("clean-glob", 0);
  }
  if( zIgnoreFlag==0 ){
    zIgnoreFlag = db_get("ignore-glob", 0);
  }