1)您需要确保您在注册表中注册了正确的 CLSID - 所以我的安装程序插入以下(假)值:
(我认为这应该等同于运行 RegASM,详见issue-tracker-plugins.txt文件的底部。
安装程序注册表更改图像 http://img291.imageshack.us/img291/1618/registryinstaller.png
您应该能够导入此注册表文件以帮助您开始:
(您可能必须根据 dll 的安装位置动态更新 CodeBase 位置)
Windows 注册表编辑器版本 5.00
[HKEY_CLASSES_ROOT\CLSID{AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA}] @="FogBugzPlugin.MyPlugin"
[HKEY_CLASSES_ROOT\CLSID{AAAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA}\实现的类别]
[HKEY_CLASSES_ROOT\CLSID{AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA}\实施的类别{3494FA92-B139-4730-9591-01135D5E7831}]
[HKEY_CLASSES_ROOT\CLSID{AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA}\实现的类别{62C8FE65-4EBB-45E7-B440-6E39B2CDBF29}]
[HKEY_CLASSES_ROOT\CLSID{AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA}\InprocServer32] @="mscoree.dll" "ThreadingModel"="Both" "Class"="FogBugzPlugin.MyPlugin" "Assembly"="MyAssemblyName, Version= 1.0.0.0,Culture=neutral,PublicKeyToken=31286c9d1d5aa00a" "RuntimeVersion"="v2.0.50727" "CodeBase"="file:///C:/Program Files/folder/AAAAAAAAAAAAA/MyAssemblyName.dll"
[HKEY_CLASSES_ROOT\CLSID{AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA}\InprocServer32\1.0.0.0] "Class"="FogBugzPlugin.MyPlugin" "Assembly"="MyAssemblyName, Version=1.0.0.0, Culture=neutral, PublicKeyToken= 31286c9d1d5aa00a" "RuntimeVersion"="v2.0.50727" "CodeBase"="file:///C:/Program Files/folder/AAAAAAAAAAAAA/MyAssemblyName.dll"
[HKEY_CLASSES_ROOT\CLSID{AAAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA}\ProgId] @="FogBugzPlugin.MyPlugin"
2) 您需要确保用户将 BugTraq 关联添加到注册表中:
[HKEY_CURRENT_USER\Software\TortoiseSVN\BugTraq Associations\0] "Provider"="{AAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAA}" "WorkingCopy"="c:\" "Parameters"=""
(这也可以由用户手动完成,方法是转到 TSVN -> Settings -> Hook Scripts -> Issue Tracker Integration -> Add
其中“{AAAAAAA-AAAA-AAAA-AAAA-AAAAAAAAAAAAA}”是您创建的提供程序的 GUID。
一切顺利,该插件现在应该可供用户使用。当他们打开提交对话框时。
更新:
对上面看到的“提供程序显示为 GUID”问题进行故障排除...
好的...所以假设您的提供商 GUID 是
{0DA7E319-1DCE-4A94-65555B5B6CE5}
你应该检查:
您的插件实现了 IBugTraqProvider 和 IBugTraqProvider2 并应用了 GUID:
namespace FogBugzPlugin
{
[ComVisible(true),
Guid("0DA7E319-1DCE-4A94-65555B5B6CE5"),
ClassInterface(ClassInterfaceType.None)]
public class MyPlugin : IBugTraqProvider, IBugTraqProvider2
所以现在你应该有: GUID: 0DA7E319-1DCE-4A94-65555B5B6CE5 PluginName: FogBugzPlugin.MyPlugin
转到 regedit 并查看注册表中的内容。它应该遵循以下原则:
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\CLSID\{0DA7E319-1DCE-4A94-65555B5B6CE5}]
@="FogBugzPlugin.MyPlugin"
[HKEY_CLASSES_ROOT\CLSID\{0DA7E319-1DCE-4A94-65555B5B6CE5}\Implemented Categories]
[HKEY_CLASSES_ROOT\CLSID\{0DA7E319-1DCE-4A94-65555B5B6CE5}\Implemented Categories\{3494FA92-B139-4730-9591-01135D5E7831}]
[HKEY_CLASSES_ROOT\CLSID\{0DA7E319-1DCE-4A94-65555B5B6CE5}\Implemented Categories\{62C8FE65-4EBB-45E7-B440-6E39B2CDBF29}]
[HKEY_CLASSES_ROOT\CLSID\{0DA7E319-1DCE-4A94-65555B5B6CE5}\InprocServer32]
@="mscoree.dll"
"ThreadingModel"="Both"
"Class"="FogBugzPlugin.MyPlugin"
"Assembly"="FogBugz2Tortoise, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31286c9d1d5aa00a"
"RuntimeVersion"="v2.0.50727"
"CodeBase"="file:///C:/Program Files/folder/FogBugz2Tortoise/FogBugz2Tortoise.dll"
[HKEY_CLASSES_ROOT\CLSID\{0DA7E319-1DCE-4A94-65555B5B6CE5}\InprocServer32\1.0.0.0]
"Class"="FogBugzPlugin.MyPlugin"
"Assembly"="FogBugz2Tortoise, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31286c9d1d5aa00a"
"RuntimeVersion"="v2.0.50727"
"CodeBase"="file:///C:/Program Files/folder/FogBugz2Tortoise/FogBugz2Tortoise.dll"
[HKEY_CLASSES_ROOT\CLSID\{0DA7E319-1DCE-4A94-65555B5B6CE5}\ProgId]
@="FogBugzPlugin.MyPlugin"
您还应该在 HKCR 下直接拥有 ProgID / CLSID 条目:
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\FogBugzPlugin.MyPlugin]
@="FogBugzPlugin.MyPlugin"
[HKEY_CLASSES_ROOT\FogBugzPlugin.MyPlugin\CLSID]
@="{0DA7E319-1DCE-4A94-65555B5B6CE5}"
希望这会有所帮助 - 我会先检查最后一点。