Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple merges in single commit breaks commit graph #6

Open
eightfingers89 opened this issue Jun 20, 2019 · 0 comments
Open

Multiple merges in single commit breaks commit graph #6

eightfingers89 opened this issue Jun 20, 2019 · 0 comments

Comments

@eightfingers89
Copy link

When more that one branch is merged as part of a single commit, the text output of "git log --graph" appears something like the following:
* | | b9783c0c2
* | | c6c684cd7
| | *-------. f91f7549e Interesting commit
| | |\ \ \ \ \
| | | | | | | * 57759c11a
| | | | | | | * 9f1924f08

The parsing of the graph in public/vendor/plugins/gitgraph/gitgraph.js does not handle the "-" characters properly, resulting in an error that prevents display of commits subsequent to the line with the merge.

At line 390, changing:
color = flows[colomnIndex].color;
to:
if (colomn === "-") {
currentRow.splice(colomnIndex + 1, 1);
color = flows[colomnIndex+1].color;
}
else {
color = flows[colomnIndex].color;
}
Corrects the display, in our repository, but I am unsure of any side effects, particularly with the flows array.

zeripath added a commit to zeripath/gitgraph.js that referenced this issue Jun 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant