Fossil

Diff
Login

Differences From Artifact [1b5175679e]:

To Artifact [fe303ecfbb]:


37
38
39
40
41
42
43


44
45


46
47
48
49
50
51
52
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56







+
+


+
+







  const char *zPath;

  file_tree_name(zName, &pathname, 1);
  zPath = blob_str(&pathname);
  if( strcmp(zPath, "manifest")==0
   || strcmp(zPath, "_FOSSIL_")==0
   || strcmp(zPath, "_FOSSIL_-journal")==0
   || strcmp(zPath, "_FOSSIL_-wal")==0
   || strcmp(zPath, "_FOSSIL_-shm")==0
   || strcmp(zPath, ".fos")==0
   || strcmp(zPath, ".fos-journal")==0
   || strcmp(zPath, ".fos-wal")==0
   || strcmp(zPath, ".fos-shm")==0
   || strcmp(zPath, "manifest.uuid")==0
   || blob_compare(&pathname, pOmit)==0
  ){
    fossil_warning("cannot add %s", zPath);
  }else{
    if( !file_is_simple_pathname(zPath) ){
      fossil_fatal("filename contains illegal characters: %s", zPath);
221
222
223
224
225
226
227
228

229
230
231

232
233
234
235
236
237
238
239

240
241
242
243
244
245
246
225
226
227
228
229
230
231

232
233
234

235
236
237
238
239
240
241
242

243
244
245
246
247
248
249
250







-
+


-
+







-
+







  }
  closedir(d);
  blob_reset(&path);
}

/*
** COMMAND: rm
** COMMAND: del
** COMMAND: delete
**
** Usage: %fossil rm FILE...
**    or: %fossil del FILE...
**    or: %fossil delete FILE...
**
** Remove one or more files from the tree.
**
** This command does not remove the files from disk.  It just marks the
** files as no longer being part of the project.  In other words, future
** changes to the named files will not be versioned.
*/
void del_cmd(void){
void delete_cmd(void){
  int i;
  int vid;

  db_must_be_within_tree();
  vid = db_lget_int("checkout", 0);
  if( vid==0 ){
    fossil_panic("no checkout to remove from");