Lines Matching defs:dir
28 int fd=dirtree_parentfd(try), dir=S_ISDIR(try->st.st_mode), or=0, using=0;
33 // Intentionally fail non-recursive attempts to remove even an empty dir
35 if (dir && !(toys.optflags & (FLAG_r|FLAG_R))) goto skip;
44 if (!(dir && try->again) && ((or && isatty(0)) || FLAG(i))) {
47 fprintf(stderr, "rm %s%s%s", or ? "ro " : "", dir ? "dir " : "", s);
54 if (dir) {
78 printf("%s%s '%s'\n", toys.which->name, dir ? "dir" : "", s);
82 if (!dir || try->symlink != (char *)2) perror_msg_raw(try->name);
102 // "rm dir/.*" can expand to include .. which generally isn't what you want