Posts Tagged ‘ one-liner ’
Here’s a quick one-line script I’ve been using to clean up some old computer accounts in active directory. It requires the dsquery and dsrm tools from the Server 2003 Admin Pack or the Remote Server Administration Toolkit. @for /f %%a in ('DSQUERY COMPUTER -NAME *%1') do (dsrm %%a) Save that in as a batch file and it’ll [ READ MORE ]