episoda 0.2.45 → 0.2.46

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -821,14 +821,25 @@ var require_git_executor = __commonJS({
821
821
  const baseBranch = command.baseBranch || "main";
822
822
  try {
823
823
  let stdout;
824
+ let comparisonSucceeded = false;
824
825
  try {
825
- const result = await execAsync2(`git log ${baseBranch}.."${command.branch}" --pretty=format:"%H|%an|%ae|%aI|%s" -n ${limit} --`, { cwd, timeout: options?.timeout || 1e4 });
826
+ const result = await execAsync2(`git log origin/${baseBranch}.."${command.branch}" --pretty=format:"%H|%an|%ae|%aI|%s" -n ${limit} --`, { cwd, timeout: options?.timeout || 1e4 });
826
827
  stdout = result.stdout;
827
- } catch (error) {
828
+ comparisonSucceeded = true;
829
+ } catch {
828
830
  try {
829
- const result = await execAsync2(`git log "${command.branch}" --pretty=format:"%H|%an|%ae|%aI|%s" -n ${limit} --`, { cwd, timeout: options?.timeout || 1e4 });
831
+ const result = await execAsync2(`git log ${baseBranch}.."${command.branch}" --pretty=format:"%H|%an|%ae|%aI|%s" -n ${limit} --`, { cwd, timeout: options?.timeout || 1e4 });
830
832
  stdout = result.stdout;
831
- } catch (branchError) {
833
+ comparisonSucceeded = true;
834
+ } catch {
835
+ stdout = "";
836
+ comparisonSucceeded = false;
837
+ }
838
+ }
839
+ if (!comparisonSucceeded) {
840
+ try {
841
+ await execAsync2(`git rev-parse --verify "${command.branch}"`, { cwd, timeout: options?.timeout || 5e3 });
842
+ } catch {
832
843
  return {
833
844
  success: false,
834
845
  error: "BRANCH_NOT_FOUND",
@@ -2682,7 +2693,7 @@ var require_package = __commonJS({
2682
2693
  "package.json"(exports2, module2) {
2683
2694
  module2.exports = {
2684
2695
  name: "episoda",
2685
- version: "0.2.45",
2696
+ version: "0.2.46",
2686
2697
  description: "CLI tool for Episoda local development workflow orchestration",
2687
2698
  main: "dist/index.js",
2688
2699
  types: "dist/index.d.ts",