diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4dcc8676f..a3398dfa9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -68,13 +68,6 @@ jobs: lib node_modules - - name: Cleanup Generated Branches - uses: dawidd6/action-delete-branch@v3.1.0 - continue-on-error: true - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - branches: gh-pages - integration: runs-on: ubuntu-latest needs: build @@ -120,7 +113,8 @@ jobs: - name: Tweak content to publish to existing branch if: ${{ matrix.branch == 'gh-pages' }} run: | - echo "" >> integration/index.html + RANDOM_CHAR=$(echo $RANDOM | tr -dc 'a-zA-Z0-9' | fold -w 1 | head -n 1) + echo "" >> integration/index.html - name: Deploy with modifications to existing branch id: modified diff --git a/src/worktree.ts b/src/worktree.ts index 7a7589cd0..ec94670c6 100644 --- a/src/worktree.ts +++ b/src/worktree.ts @@ -101,8 +101,7 @@ export async function generateWorktree( 'Error encountered while checking out branch. Attempting to continue with a new branch name.' ) branchName = `temp-${Date.now()}` - checkout.orphan = true - checkout = new GitCheckout(branchName, `origin/${action.branch}`) + checkout = new GitCheckout(branchName) await execute( checkout.toString(),