Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Patch to allow %Path% references to Commands.xml

  • Loading branch information...
commit b61a00a9d1980422a2ca70daa7599bd5648eb71d 1 parent 0e4f4fa
rolenun authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 CLI/CommandCatalog.cs
View
4 CLI/CommandCatalog.cs
@@ -41,6 +41,7 @@
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.IO;
+using System.Reflection;
using System.Text;
using System.Xml;
using GitSharp;
@@ -72,7 +73,8 @@ public class CommandCatalog
public CommandCatalog()
{
XmlDocument doc = new XmlDocument();
- doc.Load("Commands.xml");
+ string path = Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().GetName().CodeBase),"Commands.xml");
+ doc.Load(path);
XmlNodeList xmlNodeList = doc.SelectNodes("/root/CommandList/Command");
foreach (XmlNode node in xmlNodeList)
Please sign in to comment.
Something went wrong with that request. Please try again.