repo: Document non-obvious way to list all commits
authorColin Walters <walters@verbum.org>
Thu, 9 Jun 2022 22:34:25 +0000 (18:34 -0400)
committerColin Walters <walters@verbum.org>
Thu, 9 Jun 2022 22:34:51 +0000 (18:34 -0400)
I was going to add an API for this and then realized the empty
string does it.

src/libostree/ostree-repo.c

index e823e19e2ec040ad7db381bac5b5fa971d6e2855..9b29bd3f24f56d88767470874c0d66918ad6fc60 100644 (file)
@@ -4999,7 +4999,7 @@ ostree_repo_list_objects (OstreeRepo                  *self,
 /**
  * ostree_repo_list_commit_objects_starting_with:
  * @self: Repo
- * @start: List commits starting with this checksum
+ * @start: List commits starting with this checksum (empty string for all)
  * @out_commits: (out) (transfer container) (element-type GVariant GVariant):
  * Map of serialized commit name to variant data
  * @cancellable: Cancellable
@@ -5008,6 +5008,8 @@ ostree_repo_list_objects (OstreeRepo                  *self,
  * This function synchronously enumerates all commit objects starting
  * with @start, returning data in @out_commits.
  *
+ * To list all commit objects, provide the empty string `""` for @start.
+ *
  * Returns: %TRUE on success, %FALSE on error, and @error will be set
  */
 gboolean