Skip to content

Instantly share code, notes, and snippets.

@cicorias
Created January 26, 2016 23:26
Show Gist options
  • Save cicorias/43ec793527f7662bec3c to your computer and use it in GitHub Desktop.
Save cicorias/43ec793527f7662bec3c to your computer and use it in GitHub Desktop.
dumping devenv.exe for hang or regular using sysinternals procdump
@echo off
SETLOCAL
SET PATH=%~dp0\sysinternalssuite;%PATH% > NUL
choice /C HR /T 5 /d R /M "HangDump [H] CD or [R] Regular"
IF ERRORLEVEL 2 GOTO REG
IF ERRORLEVEL 1 GOTO HANG
:REG
ECHO Will dump current process
sysinternalssuite\procdump.exe -ma devenv.exe e:\temp\devenv.dmp
GOTO END
:HANG
ECHO Dumping Hang Process
sysinternalssuite\procdump.exe -ma -h devenv.exe e:\temp\devenv.dmp
GOTO END
:END
ENDLOCAL
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment