Skip to content

Commit dacabc5

Browse files
committed
use reduce-path (combineRewrittenLists) to make git-stacked-rebase work again! 🚀
Signed-off-by: Kipras Melnikovas <[email protected]>
1 parent e5c0a28 commit dacabc5

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

parse-todo-of-stacked-rebase/parseNewGoodCommands.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import Git from "nodegit";
88
import { array } from "nice-comment";
99

1010
import { filenames } from "../filenames";
11+
import { combineRewrittenLists } from "../reduce-path";
1112

1213
import { parseTodoOfStackedRebase } from "./parseTodoOfStackedRebase";
1314
import { GoodCommand, stackedRebaseCommands } from "./validator";
@@ -22,7 +23,8 @@ export function parseNewGoodCommands(
2223

2324
const pathOfRewrittenList: string = path.join(repo.path(), "stacked-rebase", filenames.rewrittenList);
2425
const rewrittenList: string = fs.readFileSync(pathOfRewrittenList, { encoding: "utf-8" });
25-
const rewrittenListLines: string[] = rewrittenList.split("\n").filter((line) => !!line);
26+
const { combinedRewrittenList } = combineRewrittenLists(rewrittenList);
27+
const rewrittenListLines: string[] = combinedRewrittenList.split("\n").filter((line) => !!line);
2628

2729
console.log({ rewrittenListLines });
2830

0 commit comments

Comments
 (0)