mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-24 05:35:00 +00:00
feature: supports the commit hash issue tracker (#382)
Using issue tracker instead of built-in supported commit web link is based on the following reasons * repo may have multiple remotes * it is not good to open an context menu to choose which web to visit with multiple remotes * some remote servers are not supported by this app
This commit is contained in:
parent
7b26589485
commit
48adad53b4
6 changed files with 22 additions and 0 deletions
|
@ -125,6 +125,19 @@ namespace SourceGit.Models
|
|||
return rule;
|
||||
}
|
||||
|
||||
public IssueTrackerRule AddCommitLinkIssueTracker()
|
||||
{
|
||||
var rule = new IssueTrackerRule()
|
||||
{
|
||||
Name = "Commit Link",
|
||||
RegexString = @"\b([0-9a-fA-F]{8,40})\b",
|
||||
URLTemplate = "https://test/$1",
|
||||
};
|
||||
|
||||
IssueTrackerRules.Add(rule);
|
||||
return rule;
|
||||
}
|
||||
|
||||
public IssueTrackerRule AddGithubIssueTracker(string repoURL)
|
||||
{
|
||||
var rule = new IssueTrackerRule()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue