[X] I have commented my code in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
Description
The preview for branches (when using gbd or gcb) did not work for branches that have the same name as a file in the repository.
The preview creates the following error message when adding a branch called 'LICENSE' to this repository and trying to preview it:
fatal: ambiguous argument 'LICENSE': both revision and filename
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
This PR fixes this behavior by separating files and revisions with '--' as git suggests, while leaving the files blank to keep matching all files.
Check list
Description
The preview for branches (when using
gbd
orgcb
) did not work for branches that have the same name as a file in the repository. The preview creates the following error message when adding a branch called 'LICENSE' to this repository and trying to preview it:This PR fixes this behavior by separating files and revisions with '--' as git suggests, while leaving the files blank to keep matching all files.
Type of change
Test environment