Skip to main content
For repos that have been configured for Git Sync, you can force a pull with this command. It throws an error in any situation that doesn’t indicate a successful pull.
console.log(repo.listCommits());

// Re-pull the repo to get the freshest commits
await repo.pullUpstream();

console.log(repo.listCommits());
Note this method is useful when you want to trigger Git Sync on demand or when you manage GitHub webhook delivery yourself.

Options

ref
string
Branch or ref to pull from upstream. Defaults to the repo default branch.
ttl
string
Token TTL for this invocation in seconds.

Response

Returns void. Throws an error if the pull fails or if the repository is not configured for Git Sync.