mirror of
https://git.zx2c4.com/cgit
synced 2025-07-09 17:54:35 +02:00
Grep the source, Luke
This is a PoC for grepping the blobs in the current tree. Signed-off-by: Lars Hjemli <larsh@hjemli.net>
This commit is contained in:
parent
fdfb6a6d80
commit
c028b604ef
5 changed files with 223 additions and 8 deletions
5
cmd.c
5
cmd.c
|
@ -127,7 +127,10 @@ static void tag_fn(struct cgit_context *ctx)
|
|||
|
||||
static void tree_fn(struct cgit_context *ctx)
|
||||
{
|
||||
cgit_print_tree(ctx->qry.sha1, ctx->qry.path);
|
||||
if (ctx->qry.grep)
|
||||
cgit_grep(ctx->qry.sha1, ctx->qry.path, ctx->qry.grep);
|
||||
else
|
||||
cgit_print_tree(ctx->qry.sha1, ctx->qry.path);
|
||||
}
|
||||
|
||||
#define def_cmd(name, want_repo, want_layout, want_vpath, is_clone) \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue