Skip to content

Commit 9bdad7b

Browse files
author
Tulga Tsogtgerel
committed
refactor: remove rebase logic, rely on workflow checkout instead
- Remove git pull --rebase step from commitAndPush - Workflow now ensures latest PR state is checked out - Simpler and more reliable approach
1 parent 4eb4a8d commit 9bdad7b

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

assistant/src/index.ts

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -253,19 +253,9 @@ Automatically generated by Auggie Assistant`;
253253

254254
await exec.exec('git', ['commit', '-m', commitMessage]);
255255

256-
// Pull latest changes from remote branch with rebase to avoid conflicts
257-
core.info(`🔄 Pulling latest changes from ${headBranch}...`);
258-
const remoteUrl = `https://x-access-token:${githubToken}@github.com/${owner}/${repo}.git`;
259-
260-
try {
261-
await exec.exec('git', ['pull', '--rebase', remoteUrl, headBranch]);
262-
core.info('✅ Successfully rebased on latest changes');
263-
} catch (error) {
264-
core.warning('Pull with rebase failed, attempting to push anyway');
265-
}
266-
267256
// Push changes
268257
core.info(`🚀 Pushing to ${headBranch}...`);
258+
const remoteUrl = `https://x-access-token:${githubToken}@github.com/${owner}/${repo}.git`;
269259
await exec.exec('git', ['push', remoteUrl, `HEAD:${headBranch}`]);
270260

271261
core.info('✅ Changes committed and pushed successfully');

0 commit comments

Comments
 (0)