repo-visualizer
repo-visualizer copied to clipboard
fix: cannot find remote branch
Hi,
Thank you for this amazing library! In terms of getting a fingerprint of the project and its structure, there is nothing that I have come across that is easier to use.
While running this action in one of my repos I faced the following issue which this PR resolves
/usr/bin/git rev-parse --verify <branch-name>
fatal: Needed a single revision
and there after pushing fails since it tries to push to a branch that already exists
/usr/bin/git push --set-upstream origin <branch-name>
To https://github.com/<org>/<repo-name>
! [rejected] visualizer -> visualizer (non-fast-forward)
error: failed to push some refs to 'https://github.com/<org>/<repo-name>'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
Changing to git switch with the --track flag solves the problem.
This PR addresses and solves this issue
@Wattenberger If possible please take a look at this PR
possible to please get a review here?