Closed Cactusbone closed 5 months ago
Good catch! Mind making an MR for this?
I think I can get this fixed.
Is there a reason a lot of the the git commands end in Oh, I see. It redirects stdout and stderr.&>/dev/null
instead of >/dev/null
? Unless it's some obscure syntax, I don't see much of a reason to run all the commands in the background. It might even be detrimental when you checkout a new commit before the pull finishes.
See https://github.com/dokku/plugn/blob/3cb228fbfea4f76473b8b9bc7bd29f701f859a32/bashenv/plugn.bash#L53
git checkout master &> /dev/null
does not work when no 'master' branch exists. (newly created github projects usesmain
as default)Seen here: https://github.com/dokku/dokku/discussions/5041
However to work around it, I changed my default branch to 'master'.
Using something like
git checkout refs/remotes/origin/HEAD
should work