Skip to content

Instantly share code, notes, and snippets.

@searope
Created March 9, 2016 01:08
Show Gist options
  • Select an option

  • Save searope/122e8e2d8af9b16a811d to your computer and use it in GitHub Desktop.

Select an option

Save searope/122e8e2d8af9b16a811d to your computer and use it in GitHub Desktop.
Pushd C:\git\folder\to\copy
set share=\\path\to\a\share
del /s /f /q %share%\*.*
for /f %%f in ('dir /ad /b %share%\') do rd /s /q %share%\%%f
for /f "usebackq tokens=*" %%A in (`git ls-files --modified --others --exclude-standard`) do echo FA|xcopy "%%~fA" "%share%\%%A"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment