How can I prevent OSX .DS_Store files from being created in my PHP projects? It’s so annoying and I have to manually delete them when I want to put my app online or compress it and send it.
Thanks.
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.
Simple answer: you can’t. But, why do you care? They don’t hurt if you deploy them to the web server. Also you can make a script to delete them, especially if you make a script to zip/tar your distribution you can also let it either delete the files or tar/zip in a way ignoring them. Like
tar cfX dist.tar ./.DS_Store *will tar all folders/files in the current directory but exclude (capital X switch) the .DS_Store file.