UNPKG

@notes-sync/service

Version:

Background service for AI-powered note synchronization

13 lines (12 loc) 563 B
import { SimpleGit } from 'simple-git'; export declare function isGitRepo(directoryPath: string): boolean; export declare function hasOriginRemote(git: SimpleGit): Promise<boolean>; export declare function createGit(baseDir: string): SimpleGit; /** * Sync the repo with the remote. * * 1) Stage and commit local changes first to ensure clean working tree * 2) Fetch and rebase onto remote, with autostash as a safety net * 3) Push if we are ahead or after creating commits */ export declare function safeSync(git: SimpleGit, reason: string): Promise<void>;