summaryrefslogtreecommitdiff
path: root/pretty.h
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2022-02-25 15:47:36 -0800
committerLibravatar Junio C Hamano <gitster@pobox.com>2022-02-25 15:47:36 -0800
commit0a01df08c03fe707e22795de7bd1d763ed02e9e1 (patch)
treeb9ff98081b5cacb5106d303d21378cc5aeb99278 /pretty.h
parentMerge branch 'jc/name-rev-stdin' (diff)
parentdate API: add and use a date_mode_release() (diff)
downloadtgif-0a01df08c03fe707e22795de7bd1d763ed02e9e1.tar.xz
Merge branch 'ab/date-mode-release'
Plug (some) memory leaks around parse_date_format(). * ab/date-mode-release: date API: add and use a date_mode_release() date API: add basic API docs date API: provide and use a DATE_MODE_INIT date API: create a date.h, split from cache.h cache.h: remove always unused show_date_human() declaration
Diffstat (limited to 'pretty.h')
-rw-r--r--pretty.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/pretty.h b/pretty.h
index 2f16acd213..f34e24c53a 100644
--- a/pretty.h
+++ b/pretty.h
@@ -2,6 +2,7 @@
#define PRETTY_H
#include "cache.h"
+#include "date.h"
#include "string-list.h"
struct commit;
@@ -163,4 +164,13 @@ int format_set_trailers_options(struct process_trailer_options *opts,
const char **arg,
char **invalid_arg);
+/*
+ * Like show_date, but pull the timestamp and tz parameters from
+ * the ident_split. It will also sanity-check the values and produce
+ * a well-known sentinel date if they appear bogus.
+ */
+const char *show_ident_date(const struct ident_split *id,
+ const struct date_mode *mode);
+
+
#endif /* PRETTY_H */