public PullRequestDiscussion(GithubPlugin plugin, GithubPullRequestInformation githubPullReqInfo, string owner, string repositoryName, string id) { _githubPullReqInfo = githubPullReqInfo; _plugin = plugin; _owner = owner; _repositoryName = repositoryName; _id = id; Load(); }
public GithubHostedRemote(GithubHostedRemoteInformation info, GithubPlugin plugin) { _plugin = plugin; if (string.IsNullOrEmpty(info.NameAtGithub) || string.IsNullOrEmpty(info.Owner)) { throw new ArgumentException("Neither NameAtGithub or Owner can be null"); } Data = info.Owner + "/" + info.NameAtGithub; Name = info.Name; }
public PullRequestDiscussion(GithubPlugin plugin, GithubPullRequestInformation githubPullReqInfo, string owner, string repositoryName, string id) { _githubPullReqInfo = githubPullReqInfo; _plugin = plugin; _owner = owner; _repositoryName = repositoryName; _id = id; TryLoad(); }
public static GithubHostedRepository Convert(GithubPlugin p, GithubSharp.Core.Models.RepositoryFromSearch repo) { return(new GithubHostedRepository(p) { Owner = repo.Username, Name = repo.Name, Description = repo.Description, IsAFork = repo.Fork, Forks = repo.Forks, IsPrivate = false, Homepage = string.Format("https://github.com/{0}/{1}", repo.Username, repo.Name) }); }
public static GithubHostedRepository Convert(GithubPlugin p, GithubSharp.Core.Models.Repository repo) { return(new GithubHostedRepository(p) { Owner = repo.Owner, Name = repo.Name, Description = repo.Description, IsAFork = repo.Fork, Forks = repo.Forks, IsPrivate = repo.Private, Homepage = repo.Homepage }); }
internal GithubPullRequestInformation(string issueOwner, string repoName, PullRequest pullRequestDetails, GithubPlugin plugin) { _pullRequestDetails = pullRequestDetails; _plugin = plugin; Owner = pullRequestDetails.User.Login; Created = pullRequestDetails.Created; Title = pullRequestDetails.Title; Body = pullRequestDetails.Body; Id = pullRequestDetails.Number.ToString(); IssueOwner = issueOwner; RepositoryName = repoName; BaseRepo = GithubHostedRepository.Convert(_plugin, _pullRequestDetails.Base.Repository); BaseSha = _pullRequestDetails.Base.Sha; BaseRef = _pullRequestDetails.Base.Ref; HeadRepo = GithubHostedRepository.Convert(_plugin, _pullRequestDetails.Head.Repository); HeadSha = _pullRequestDetails.Head.Sha; HeadRef = _pullRequestDetails.Head.Ref; }
public GithubPlugin() { if (_instance != null) throw new InvalidOperationException("Can not create this again..."); _instance = this; }
public GithubHostedRepository(GithubPlugin githubPlugin) { _plugin = githubPlugin; }
public static GithubHostedRepository Convert(GithubPlugin p, GithubSharp.Core.Models.RepositoryFromSearch repo) { return new GithubHostedRepository(p) { Owner = repo.Username, Name = repo.Name, Description = repo.Description, IsAFork = repo.Fork, Forks = repo.Forks, IsPrivate = false, Homepage = string.Format("https://github.com/{0}/{1}", repo.Username, repo.Name) }; }
public static GithubHostedRepository Convert(GithubPlugin p, GithubSharp.Core.Models.Repository repo) { return new GithubHostedRepository(p) { Owner = repo.Owner, Name = repo.Name, Description = repo.Description, IsAFork = repo.Fork, Forks = repo.Forks, IsPrivate = repo.Private, Homepage = repo.Homepage }; }