OSDN Git Service

Commit: Made user able to push after successful commit
[tortoisegit/TortoiseGitJp.git] / src / Debug-Hints.txt
1 Debugging hints\r
2 \r
3 Since TortoiseSVN is a shell extension it's not\r
4 as easy to debug as normal applications. The\r
5 TortoiseShell part is only a dll which is \r
6 loaded by the windows explorer. So the first\r
7 thing you need to do is:\r
8 \r
9 - add the following value to the registry:\r
10   HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\DesktopProcess\r
11   (REG_DWORD) = 1\r
12   This will tell windows to start each explorer\r
13   in a separate process instead of one single\r
14   process.\r
15 - register the TortoiseShell dll so that\r
16   the windows explorer loads it. There are\r
17   three files in the folder src\TortoiseShell\r
18   with extension *.registry. Make a copy of\r
19   those files and change the extension to\r
20   *.reg. Then you have to edit those three\r
21   files so that the paths in it reflects\r
22   your source paths exactly.\r
23   Now if you doubleclick on register.reg \r
24   the debug version of the TortoiseSVN.dll\r
25   get's registered. registerrelease.reg \r
26   registers the release version of the\r
27   TortoiseSVN.dll. Don't do it right now!\r
28 - Start VS.NET and load the TortoiseSVN\r
29   solution file. Set the TortoiseShell\r
30   project as "startup project".\r
31 - Close all running instances of windows\r
32   explorer.\r
33 - Now execute the register.reg file. Since\r
34   you already closed all explorer windows\r
35   you'll have to use the windows start\r
36   button, then execute, enter the location\r
37   of the reg file and hit enter.\r
38   Since this is a lot of clicking I made\r
39   a shortcut of those files in the quickstart\r
40   on the taskbar.\r
41 - Hit F5 in the VS.NET IDE (or start\r
42   debugging via menu). The first time\r
43   you do that VS.NET will ask you to\r
44   enter an application to use with the\r
45   TortoiseSVN.dll - enter c:\windows\explorer.exe\r
46   (or whatever path it is on your system).\r
47 - Now you can set breakpoints and debug\r
48   as you like.\r
49 - Don't stop debugging by closing the\r
50   explorer window - this sometimes leads\r
51   to a locked dll and you can't compile/link\r
52   the dll again until you have restarted.\r
53   Always stop debugging with the command\r
54   in the VS.NET IDE (Shift-F5).\r
55 - After debugging, execute the file\r
56   deregister.reg. Do this always _immediately_\r
57   after debugging or you might get a locked\r
58   dll.\r
59 - while debugging, _never_ start another\r
60   explorer instance or internet explorer\r
61   or any other application which uses\r
62   explorer - this includes already running\r
63   applications to open dialogs like "save as"!\r
64 \r
65 To debug the TortoiseProc part of TortoiseSVN\r
66 proceed as with any normal application.\r
67 \r
68 To debug the TSVNCache exit the TSVNCache.exe\r
69 process and proceed as with any normal\r
70 application. Exiting TSVNCache.exe is necessary\r
71 because only one instance of TSVNCache may run\r
72 at a time. To exit the TSVNCache process set\r
73 HKCU\Software\TortoiseSVN\CacheTrayIcon to 1 and\r
74 call "Exit" in the context menu of the tray icon.\r