Skip to content

Instantly share code, notes, and snippets.

@mfyuce
Created September 24, 2020 11:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mfyuce/294420910dfc76524e998de3b6295d63 to your computer and use it in GitHub Desktop.
Save mfyuce/294420910dfc76524e998de3b6295d63 to your computer and use it in GitHub Desktop.
Make Windows Folder Case Sensitive (as in Linux)
param (
[Parameter(Mandatory=$true)][string]$dir = "."
)
fsutil.exe file setCaseSensitiveInfo "$($dir)" enable
# Create an array of folders
$folders = Get-ChildItem -Path $dir -Recurse -Directory -Force -ErrorAction SilentlyContinue
# Perform iteration to create the same file in each folder
foreach ($i in $folders.FullName) {
fsutil.exe file setCaseSensitiveInfo "$($i)" enable
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment