dDocent
dDocent copied to clipboard
replace ls and rm with find
This PR attempts to fix the issues described in #83 by leveraging find.
- In cases where
lsis used to search for wildcard-ed files,findis restricted to-maxdepth 1(current folder, no recursion),-type f(must be a file, not directory), and has the extra-printfdirective to output only the filename without the path. - In cases where
rmwas used on wildcarded files (e.g. mapped.*.bed),findwas used with the same restrictions, except-printfwas replaced with-delete, which will unsurprisingly delete whatever filesfindidentifies meeting the criteria.
Note I have not tested this yet (I don't have data to test it on atm)