feat: add git branch widget
This commit is contained in:
parent
845403f2ae
commit
45574ff5c5
4 changed files with 83 additions and 9 deletions
|
@ -2,7 +2,6 @@ const std = @import("std");
|
|||
const tp = @import("thespian");
|
||||
const cbor = @import("cbor");
|
||||
const tracy = @import("tracy");
|
||||
const git = @import("git");
|
||||
const ripgrep = @import("ripgrep");
|
||||
const root = @import("root");
|
||||
const location_history = @import("location_history");
|
||||
|
@ -828,11 +827,6 @@ const cmds = struct {
|
|||
}
|
||||
pub const find_in_files_query_meta: Meta = .{ .arguments = &.{.string} };
|
||||
|
||||
pub fn git_branch(self: *Self, _: Ctx) Result {
|
||||
try git.get_current_branch(self.allocator);
|
||||
}
|
||||
pub const git_branch_meta: Meta = .{ .description = "Get the current git branch" };
|
||||
|
||||
pub fn shell_execute_log(self: *Self, ctx: Ctx) Result {
|
||||
if (!try ctx.args.match(.{ tp.string, tp.more }))
|
||||
return error.InvalidShellArgument;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue