Yes, I know, the archive bit is evil.
That being said, is there support for querying it with ‘find’, and modifying it with ‘chmod’?
My googling has turned up nothing……
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
As already mentioned by Jed, you can use attrib both to query and to set the archive bit. You must however remember to use the cygpath tool to convert between cygwin style file names and DOS style names, as required by attrib.
If you convert the output of find with cygpath, invoke attrib for each file name and use egrep to check for lines starting with A (regexp ‘^A’), you should be able to search for files with the archive bit set.