History Of Ticket 2e924cf9b7
Not logged in
Ticket change [decc082846] (rid 4930) by drh on 2009-08-14 16:20:50:
  1. Appended to comment:

    drh added on 2009-08-14 16:20:50:
    Added with check-in 5bc5e88c86130400c184ba93b2470e7009f909c5

  2. Change resolution to "Fixed"
  3. Change status to "Fixed"
Ticket change [b6933dbbc6] (rid 4922) by drh on 2009-08-13 19:45:01:
  1. Change comment to "Currently a recursive add ignores dotfiles. This is annoying when adding for instance an eclipse project on windows (eclipse uses directories starting with . for project settings) I propose to add a flag -dotfiles to add so that when specified .files and .dir will be added as well. Following diff adds the option to fossil add: <verbatim> @@ -65,21 +65,24 @@ ** All content of the zDir directory to the SFILE table. */ void add_directory_content(const char *zDir){ DIR *d; int origSize; + int dotFlag; struct dirent *pEntry; Blob path; + dotFlag = find_option("dotfiles","d",0)!=0; blob_zero(&path); blob_append(&path, zDir, -1); origSize = blob_size(&path); d = opendir(zDir); if( d ){ while( (pEntry=readdir(d))!=0 ){ char *zPath; - if( pEntry->d_name[0]=='.' ) continue; + if( pEntry->d_name[0]=='.' && !dotFlag) continue; + if( strcmp(pEntry->d_name, "..")==0 || strcmp(pEntry->d_name, ".")==0 ) continue; blob_appendf(&path, "/%s", pEntry->d_name); zPath = blob_str(&path); if( file_isdir(zPath)==1 ){ add_directory_content(zPath); }else if( file_isfile(zPath) ){ @@ -112,10 +115,14 @@ ** ** Usage: %fossil add FILE... ** ** Make arrangements to add one or more files to the current checkout ** at the next commit. +** +** When adding files recursively, by default files or directories +** starting with a . (dot), will not be added. This behaviour can be changed +** by the optional -dotfiles flag. */ void add_cmd(void){ int i; int vid; Blob repo; </verbatim>"
  2. Change resolution to "Open"
Ticket change [1f41837fd3] (rid 4921) by mjanssen on 2009-08-13 18:03:00:
  1. Change comment to "Currently a recursive add ignores dotfiles. This is annoying when adding for instance an eclipse project on windows (eclipse uses directories starting with . for project settings) I propose to add a flag -dotfiles to add so that when specified .files and .dir will be added as well. Following diff adds the option to fossil add: <pre> @@ -65,21 +65,24 @@ ** All content of the zDir directory to the SFILE table. */ void add_directory_content(const char *zDir){ DIR *d; int origSize; + int dotFlag; struct dirent *pEntry; Blob path; + dotFlag = find_option("dotfiles","d",0)!=0; blob_zero(&path); blob_append(&path, zDir, -1); origSize = blob_size(&path); d = opendir(zDir); if( d ){ while( (pEntry=readdir(d))!=0 ){ char *zPath; - if( pEntry->d_name[0]=='.' ) continue; + if( pEntry->d_name[0]=='.' && !dotFlag) continue; + if( strcmp(pEntry->d_name, "..")==0 || strcmp(pEntry->d_name, ".")==0 ) continue; blob_appendf(&path, "/%s", pEntry->d_name); zPath = blob_str(&path); if( file_isdir(zPath)==1 ){ add_directory_content(zPath); }else if( file_isfile(zPath) ){ @@ -112,10 +115,14 @@ ** ** Usage: %fossil add FILE... ** ** Make arrangements to add one or more files to the current checkout ** at the next commit. +** +** When adding files recursively, by default files or directories +** starting with a . (dot), will not be added. This behaviour can be changed +** by the optional -dotfiles flag. */ void add_cmd(void){ int i; int vid; Blob repo; </pre>"
  2. Change foundin to "9cbef7a104e5d6168895a1ab99ad0a68484be369"
  3. Change private_contact to "9e3254e6e3c2643cc148bab2d55f46bb4c0446f4"
  4. Change severity to "Minor"
  5. Change status to "Open"
  6. Change title to "Change recursive add to allow inclusion of files starting with dot"
  7. Change type to "Feature_Request"