summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRussell Belfer <rb@github.com>2013-06-20 15:10:42 -0700
committerRussell Belfer <rb@github.com>2013-06-20 15:10:42 -0700
commit9280855787fcac1e333b6e7e66d7ba0cd2120a0c (patch)
treeb9ee9ecc9a4f570f933ac16bc1361ded8fa68264
parentf18f772a8ec0cdff9315216886383dadce1379b5 (diff)
downloadlibgit2-9280855787fcac1e333b6e7e66d7ba0cd2120a0c.tar.gz
Fix comment and copyright in example
-rw-r--r--examples/status.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/examples/status.c b/examples/status.c
index 10b1ca8e5..689098415 100644
--- a/examples/status.c
+++ b/examples/status.c
@@ -1,10 +1,9 @@
/*
- * Copyright (C) 2011-2012 the libgit2 contributors
+ * Copyright (C) the libgit2 contributors. All rights reserved.
*
* This file is part of libgit2, distributed under the GNU GPL v2 with
* a Linking Exception. For full terms see the included COPYING file.
*/
-
#include <git2.h>
#include <stdio.h>
#include <stdlib.h>
@@ -19,15 +18,21 @@ enum {
#define MAX_PATHSPEC 8
/*
- * This example demonstrates the use of `git_status_foreach()` to roughly
- * simulate the output of running `git status`. It should serve as a simple
- * example of how to get basic status information.
+ * This example demonstrates the use of the libgit2 status APIs,
+ * particularly the `git_status_list` object, to roughly simulate the
+ * output of running `git status`. It serves as a simple example of
+ * using those APIs to get basic status information.
*
* This does not have:
* - Robust error handling
- * - Any real command line parsing
* - Colorized or paginated output formatting
*
+ * This does have:
+ * - Examples of translating command line arguments to the status
+ * options settings to mimic `git status` results.
+ * - A sample status formatter that matches the default "long" format
+ * from `git status`
+ * - A sample status formatter that matches the "short" format
*/
static void check(int error, const char *message, const char *extra)