fastForwardDefaultBranch
fastForwardDefaultBranch(
dir,branch):Promise<PullResult>
Defined in: src/pull.ts:82
Fast-forward the local default-branch checkout in dir to origin/<branch>.
Fails closed and NEVER throws — any error maps to { ok:false }:
- HEAD not on
branch→ wrong_branch (normal for a feature checkout) - working tree dirty → dirty
merge --ff-onlynon-zero → diverged- any other throw/timeout → error Every git step is async so neither the network fetch nor a slow local status/merge on a large repo can block the single-threaded event loop.
Parameters
Section titled “Parameters”string
branch
Section titled “branch”string
Returns
Section titled “Returns”Promise<PullResult>