Skip to content

Commit

Permalink
Update worktree.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
JamesIves committed Sep 29, 2024
1 parent 84c87e3 commit 422f948
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions src/worktree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,13 +101,11 @@ export async function generateWorktree(
'Error encountered while checking out branch. Attempting to continue with a new branch name.'
)

if (branchExists) {
await execute(
`git fetch --no-recurse-submodules --depth=1 origin ${action.branch}`,
`${action.workspace}/${worktreedir}`,
action.silent
)
}
await execute(
`git fetch`,
`${action.workspace}/${worktreedir}`,
action.silent
)

branchName = `temp-${Date.now()}`
checkout = new GitCheckout(branchName, `origin/${action.branch}`)
Expand Down

0 comments on commit 422f948

Please sign in to comment.