Ejemplo n.º 1
0
 internal GitCommit(Commit commit)
 {
     Sha = commit.Sha;
     Author = new GitSignature(commit.Author.Email, commit.Author.Name, commit.Author.When);
     Committer = new GitSignature(commit.Committer.Email, commit.Committer.Name, commit.Committer.When);
     Message = commit.Message;
     MessageShort = commit.MessageShort;
 }
Ejemplo n.º 2
0
 internal GitCommit(Commit commit)
 {
     Sha          = commit.Sha;
     Author       = new GitSignature(commit.Author.Email, commit.Author.Name, commit.Author.When);
     Committer    = new GitSignature(commit.Committer.Email, commit.Committer.Name, commit.Committer.When);
     Message      = commit.Message;
     MessageShort = commit.MessageShort;
 }
Ejemplo n.º 3
0
        internal GitCommit(Commit commit)
        {
            if (commit == null)
            {
                throw new ArgumentException("Source commit can't be null.", nameof(commit));
            }

            Sha          = commit.Sha;
            Author       = new GitSignature(commit.Author.Email, commit.Author.Name, commit.Author.When);
            Committer    = new GitSignature(commit.Committer.Email, commit.Committer.Name, commit.Committer.When);
            Message      = commit.Message;
            MessageShort = commit.MessageShort;
        }
Ejemplo n.º 4
0
        internal GitCommit(Commit commit)
        {
            if (commit == null)
            {
                throw new ArgumentException("Source commit can't be null.", nameof(commit));
            }

            Sha          = commit.Sha;
            Author       = new GitSignature(commit.Author.Email, commit.Author.Name, commit.Author.When);
            Committer    = new GitSignature(commit.Committer.Email, commit.Committer.Name, commit.Committer.When);
            Message      = commit.Message;
            MessageShort = commit.MessageShort;
            Parents      = commit.Parents.Any() ? commit.Parents.Select(p => new GitCommit(p)).ToList() : new List <GitCommit>();
        }