mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-12-06 14:56:23 +01:00
Add live git status indicators (#458)
This commit is contained in:
1 parent
1b154ba550
commit
d7e67cf13c
35 files changed
+1702
-578
No files matched your search
@@ -1,4 +1,5 @@
|
||||
import type { GitCallbacks } from "@yaakapp-internal/git";
|
||||
import { useMemo } from "react";
|
||||
import { sync } from "../../init/sync";
|
||||
import { promptCredentials } from "./credentials";
|
||||
import { promptDivergedStrategy } from "./diverged";
|
||||
@@ -24,3 +25,7 @@ export function gitCallbacks(dir: string): GitCallbacks {
|
||||
forceSync: () => sync({ force: true }),
|
||||
};
|
||||
}
|
||||
|
||||
export function useGitCallbacks(dir: string): GitCallbacks {
|
||||
return useMemo(() => gitCallbacks(dir), [dir]);
|
||||
}
|
||||
Reference in new issue
Block a user