[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Auto-emptying of trash.



That's strange, since "rmdir --ignore-fail-on-non-empty" seemingly
shouldn't remove the directory. I wasn't aware about this, so I tested
it, resp. compared it to "rm -r" [1].

Perhaps you should post the complete script, the culprit seems not to be
"rmdir".

[1]
[rocketmouse@archlinux ~]$ touch ~/Desktop/test ~/Desktop/.test
[rocketmouse@archlinux ~]$ ls -hAl Desktop
total 0
-rw-r--r-- 1 rocketmouse rocketmouse 0 Jun  8 10:33 test
-rw-r--r-- 1 rocketmouse rocketmouse 0 Jun  8 10:33 .test
[rocketmouse@archlinux ~]$ rm -r ~/Desktop
[rocketmouse@archlinux ~]$ ls -hAld Desktop
ls: cannot access Desktop: No such file or directory
[rocketmouse@archlinux ~]$ mkdir Desktop ; touch ~/Desktop/test ~/Desktop/.test
[rocketmouse@archlinux ~]$ ls -hAl Desktop
total 0
-rw-r--r-- 1 rocketmouse rocketmouse 0 Jun  8 10:34 test
-rw-r--r-- 1 rocketmouse rocketmouse 0 Jun  8 10:34 .test
[rocketmouse@archlinux ~]$ rmdir --ignore-fail-on-non-empty ~/Desktop
[rocketmouse@archlinux ~]$ ls -hAld Desktop
drwxr-xr-x 2 rocketmouse rocketmouse 4.0K Jun  8 10:34 Desktop


Reply to: