|
diff --git a/cmd.c b/cmd.c index 489a11c..e0eacbe 100644 --- a/ cmd.c+++ b/ cmd.c |
|
@@ -1,34 +1,45 @@ |
1 | /* cmd.c: the cgit command dispatcher |
1 | /* cmd.c: the cgit command dispatcher |
2 | * |
2 | * |
3 | * Copyright (C) 2008 Lars Hjemli |
3 | * Copyright (C) 2008 Lars Hjemli |
4 | * |
4 | * |
5 | * Licensed under GNU General Public License v2 |
5 | * Licensed under GNU General Public License v2 |
6 | * (see COPYING for full license text) |
6 | * (see COPYING for full license text) |
7 | */ |
7 | */ |
8 | |
8 | |
9 | #include "cgit.h" |
9 | #include "cgit.h" |
10 | #include "cmd.h" |
10 | #include "cmd.h" |
| |
11 | #include "ui-blob.h" |
| |
12 | #include "ui-commit.h" |
| |
13 | #include "ui-diff.h" |
| |
14 | #include "ui-log.h" |
| |
15 | #include "ui-patch.h" |
| |
16 | #include "ui-refs.h" |
| |
17 | #include "ui-repolist.h" |
| |
18 | #include "ui-snapshot.h" |
| |
19 | #include "ui-summary.h" |
| |
20 | #include "ui-tag.h" |
| |
21 | #include "ui-tree.h" |
11 | |
22 | |
12 | static void blob_fn(struct cgit_context *ctx) |
23 | static void blob_fn(struct cgit_context *ctx) |
13 | { |
24 | { |
14 | cgit_print_blob(ctx->qry.sha1, ctx->qry.path); |
25 | cgit_print_blob(ctx->qry.sha1, ctx->qry.path); |
15 | } |
26 | } |
16 | |
27 | |
17 | static void commit_fn(struct cgit_context *ctx) |
28 | static void commit_fn(struct cgit_context *ctx) |
18 | { |
29 | { |
19 | cgit_print_commit(ctx->qry.sha1); |
30 | cgit_print_commit(ctx->qry.sha1); |
20 | } |
31 | } |
21 | |
32 | |
22 | static void diff_fn(struct cgit_context *ctx) |
33 | static void diff_fn(struct cgit_context *ctx) |
23 | { |
34 | { |
24 | cgit_print_diff(ctx->qry.sha1, ctx->qry.sha2, ctx->qry.path); |
35 | cgit_print_diff(ctx->qry.sha1, ctx->qry.sha2, ctx->qry.path); |
25 | } |
36 | } |
26 | |
37 | |
27 | static void repolist_fn(struct cgit_context *ctx) |
38 | static void repolist_fn(struct cgit_context *ctx) |
28 | { |
39 | { |
29 | cgit_print_repolist(); |
40 | cgit_print_repolist(); |
30 | } |
41 | } |
31 | |
42 | |
32 | static void log_fn(struct cgit_context *ctx) |
43 | static void log_fn(struct cgit_context *ctx) |
33 | { |
44 | { |
34 | cgit_print_log(ctx->qry.sha1, ctx->qry.ofs, ctx->cfg.max_commit_count, |
45 | cgit_print_log(ctx->qry.sha1, ctx->qry.ofs, ctx->cfg.max_commit_count, |
|