diff options
Diffstat (limited to 'cmd.c')
-rw-r--r-- | cmd.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -10,6 +10,7 @@ | |||
10 | #include "cmd.h" | 10 | #include "cmd.h" |
11 | #include "cache.h" | 11 | #include "cache.h" |
12 | #include "ui-shared.h" | 12 | #include "ui-shared.h" |
13 | #include "ui-atom.h" | ||
13 | #include "ui-blob.h" | 14 | #include "ui-blob.h" |
14 | #include "ui-clone.h" | 15 | #include "ui-clone.h" |
15 | #include "ui-commit.h" | 16 | #include "ui-commit.h" |
@@ -29,6 +30,11 @@ static void HEAD_fn(struct cgit_context *ctx) | |||
29 | cgit_clone_head(ctx); | 30 | cgit_clone_head(ctx); |
30 | } | 31 | } |
31 | 32 | ||
33 | static void atom_fn(struct cgit_context *ctx) | ||
34 | { | ||
35 | cgit_print_atom(ctx->qry.head, ctx->qry.path, 10); | ||
36 | } | ||
37 | |||
32 | static void about_fn(struct cgit_context *ctx) | 38 | static void about_fn(struct cgit_context *ctx) |
33 | { | 39 | { |
34 | if (ctx->repo) | 40 | if (ctx->repo) |
@@ -125,6 +131,7 @@ struct cgit_cmd *cgit_get_cmd(struct cgit_context *ctx) | |||
125 | { | 131 | { |
126 | static struct cgit_cmd cmds[] = { | 132 | static struct cgit_cmd cmds[] = { |
127 | def_cmd(HEAD, 1, 0), | 133 | def_cmd(HEAD, 1, 0), |
134 | def_cmd(atom, 1, 0), | ||
128 | def_cmd(about, 0, 1), | 135 | def_cmd(about, 0, 1), |
129 | def_cmd(blob, 1, 0), | 136 | def_cmd(blob, 1, 0), |
130 | def_cmd(commit, 1, 1), | 137 | def_cmd(commit, 1, 1), |