Skip to content

Commit

Permalink
Add batch for manipulating the registry.
Browse files Browse the repository at this point in the history
  • Loading branch information
jrfonseca committed May 17, 2013
1 parent a5f87ea commit 98e39bc
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
*.reg -crlf
*.cmd -crlf
27 changes: 27 additions & 0 deletions setup.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
@echo off

setlocal

set KeyName=HKLM\Software\Microsoft\Windows NT\CurrentVersion\AeDebug
if "%PROCESSOR_ARCHITECTURE%"=="AMD64" set KeyName=HKLM\Software\Wow6432Node\Microsoft\Windows NT\CurrentVersion\AeDebug

goto option_%1
goto option_status

:option_install
reg add "%KeyName%" /v "Auto" /t REG_SZ /d "1" /f
reg add "%KeyName%" /v "Debugger" /t REG_SZ /d "%CD%\drmingw.exe -p %%ld -e %%ld" /f
goto option_status

:option_uninstall
:option_reset
reg add "%KeyName%" /v "Auto" /t REG_SZ /d "0" /f
reg delete "%KeyName%" /v "Debugger" /f
goto option_status

:option_
:option_status
reg query "%KeyName%" /v "Auto"
reg query "%KeyName%" /v "Debugger"

endlocal

0 comments on commit 98e39bc

Please sign in to comment.