#!/bin/sh

# Reset filesystem permissions in Windows that tend to get randomly messed up
# every now and then for no apparent reason. Using icacls is the most reliable
# method I've found, though in some cases the takeown command may help as well:
# takeown /F file /R

icacls.exe "$@" /T /Q /C /RESET

Add script to fix common windows filesystem permission issues
Add script to fix common windows filesystem permission issues

While working in Windows filesystem permissions seem to have a mind of
their own and occasionally get messed up in one way or another, often
with no apparent cause or reason. This can be fixed through the GUI, but
that is annoying and occasionally impractical if the permissions need to
be changed recursively, but the permissions prevent this. Basically, the
whole thing is a clusterfuck.

Fortunately, there is a command line tool to alter the permissions, and
using it to reset them fixes 99% of all Windows permission issues. This
script is a simple wrapper around that command.
