@@ -219,6 +219,7 @@ private static Commit LookUpCommit(IRepository repository, string committish)
219219 /// <param name="repository">The <see cref="Repository"/> being worked with.</param>
220220 /// <param name="message">The description of why a change was made to the repository.</param>
221221 /// <returns>The generated <see cref="LibGit2Sharp.Commit"/>.</returns>
222+ [ Obsolete ( "This method will be removed in the next release. Please use Commit(string, Signature, Signature) instead." ) ]
222223 public static Commit Commit ( this IRepository repository , string message )
223224 {
224225 return repository . Commit ( message , ( CommitOptions ) null ) ;
@@ -234,6 +235,7 @@ public static Commit Commit(this IRepository repository, string message)
234235 /// <param name="message">The description of why a change was made to the repository.</param>
235236 /// <param name="options">The <see cref="CommitOptions"/> that specify the commit behavior.</param>
236237 /// <returns>The generated <see cref="LibGit2Sharp.Commit"/>.</returns>
238+ [ Obsolete ( "This method will be removed in the next release. Please use Commit(string, Signature, Signature, CommitOptions) instead." ) ]
237239 public static Commit Commit ( this IRepository repository , string message , CommitOptions options )
238240 {
239241 Signature author = repository . Config . BuildSignatureOrThrow ( DateTimeOffset . Now ) ;
@@ -251,6 +253,7 @@ public static Commit Commit(this IRepository repository, string message, CommitO
251253 /// <param name="author">The <see cref="Signature"/> of who made the change.</param>
252254 /// <param name="message">The description of why a change was made to the repository.</param>
253255 /// <returns>The generated <see cref="LibGit2Sharp.Commit"/>.</returns>
256+ [ Obsolete ( "This method will be removed in the next release. Please use Commit(string, Signature, Signature) instead." ) ]
254257 public static Commit Commit ( this IRepository repository , string message , Signature author )
255258 {
256259 return repository . Commit ( message , author , ( CommitOptions ) null ) ;
@@ -267,13 +270,29 @@ public static Commit Commit(this IRepository repository, string message, Signatu
267270 /// <param name="message">The description of why a change was made to the repository.</param>
268271 /// <param name="options">The <see cref="CommitOptions"/> that specify the commit behavior.</param>
269272 /// <returns>The generated <see cref="LibGit2Sharp.Commit"/>.</returns>
273+ [ Obsolete ( "This method will be removed in the next release. Please use Commit(string, Signature, Signature, CommitOptions) instead." ) ]
270274 public static Commit Commit ( this IRepository repository , string message , Signature author , CommitOptions options )
271275 {
272276 Signature committer = repository . Config . BuildSignatureOrThrow ( DateTimeOffset . Now ) ;
273277
274278 return repository . Commit ( message , author , committer , options ) ;
275279 }
276280
281+ /// <summary>
282+ /// Stores the content of the <see cref="Repository.Index"/> as a new <see cref="LibGit2Sharp.Commit"/> into the repository.
283+ /// The tip of the <see cref="Repository.Head"/> will be used as the parent of this new Commit.
284+ /// Once the commit is created, the <see cref="Repository.Head"/> will move forward to point at it.
285+ /// </summary>
286+ /// <param name="repository">The <see cref="IRepository"/> being worked with.</param>
287+ /// <param name="message">The description of why a change was made to the repository.</param>
288+ /// <param name="author">The <see cref="Signature"/> of who made the change.</param>
289+ /// <param name="committer">The <see cref="Signature"/> of who added the change to the repository.</param>
290+ /// <returns>The generated <see cref="LibGit2Sharp.Commit"/>.</returns>
291+ public static Commit Commit ( this IRepository repository , string message , Signature author , Signature committer )
292+ {
293+ return repository . Commit ( message , author , committer , default ( CommitOptions ) ) ;
294+ }
295+
277296 /// <summary>
278297 /// Fetch from the specified remote.
279298 /// </summary>
@@ -601,21 +620,6 @@ public static void Reset(this IRepository repository, Commit commit)
601620 repository . Index . Replace ( commit , null , null ) ;
602621 }
603622
604- /// <summary>
605- /// Stores the content of the <see cref="Repository.Index"/> as a new <see cref="LibGit2Sharp.Commit"/> into the repository.
606- /// The tip of the <see cref="Repository.Head"/> will be used as the parent of this new Commit.
607- /// Once the commit is created, the <see cref="Repository.Head"/> will move forward to point at it.
608- /// </summary>
609- /// <param name="repository">The <see cref="IRepository"/> being worked with.</param>
610- /// <param name="message">The description of why a change was made to the repository.</param>
611- /// <param name="author">The <see cref="Signature"/> of who made the change.</param>
612- /// <param name="committer">The <see cref="Signature"/> of who added the change to the repository.</param>
613- /// <returns>The generated <see cref="LibGit2Sharp.Commit"/>.</returns>
614- public static Commit Commit ( this IRepository repository , string message , Signature author , Signature committer )
615- {
616- return repository . Commit ( message , author , committer , null ) ;
617- }
618-
619623 /// <summary>
620624 /// Find where each line of a file originated.
621625 /// </summary>
0 commit comments