Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thinking out loud, why isn't
git diff --name-only
good enough here ?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The issue here is that the GitHub Actions environment does not have the branch information for Git, which causes an error when using
git diff
to compare the differences. To resolve this, I simply added agit fetch
command to retrieve the branch information from the remote repository. For further debugging information, you can refer to this link: https://github.com/zaunist/gateway/actions/runs/6262614026/job/17005194717.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@zaunist im suggesting removing the older command and replacing with something simpler
git diff --name-only
which doesnt require branch info, do you see any issue with this approach ?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@arkodg If we don't provide branch information, how can we compare the differences between the fork and main branches? I'm not quite understanding this point. Could you provide an example, please?