-
-
Save briangreenery/cc2dc1c8611dbe507d31 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
set BADFOLDER=example\node_modules\sqlite3\node_modules\node-pre-gyp\node_modules\tar-pack\node_modules\readable-stream\node_modules\core-util-is | |
set BADFILE=%BADFOLDER%\badfile | |
if "%1" == "setup" ( | |
mkdir %BADFOLDER% | |
echo hello > %BADFILE% | |
Icacls %BADFILE% /deny "Everyone:(D)" | |
npm install rimraf@2.3.1 | |
echo require^('rimraf'^)^('example', console.error^); > index.js | |
) else if "%1" == "cleanup" ( | |
Icacls %BADFILE% /remove Everyone | |
rmdir example /s /q | |
) else ( | |
echo Usage: repro setup^|cleanup | |
exit /b 1 | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment