Hi,
I changed the branch of a certain plugin, and it downloaded the right branch and the code is updated, but on the plugins page it always says that I'm on master branch.
That's because you don't have the branch header correctly added to the specific branch. If no branch header is present the default is 'master'. GHU gets the branch info from this header.
I have included an explanation in the wiki too. https://github.com/afragen/github-updater/wiki/Versions-and-Branches
Would it make sense to save the branch name in wp_options when we switch branches and show that information instead?
I think branches are very dynamic, you create a lot of them to create new features and most of the times I think developers won't change that header.
At least for me, when I'm developing a new plugin I'm always updating the code via Branch Switching and it would be interesting to not have to change that header every time I create a new branch. (just a suggestion)
Would it be useful to do a pull request with this or you think it makes more sense to read the branch name always from the header?
Thanks!
I understand the difficulty, especially when you are creating many temporary branches. Let me think about how best to implement this.
@dbeja check out the branch branch. Make sure you refresh your cache after after you switch.
The primary drawback is that if you have users test specific branches you can get them back on a different branch by pushing a commit with a different branch header and a version bump. Well you have to do that twice. I don鈥檛 think that鈥檚 possible any with this change.
Hmm we always deploy from a deploy branch so I'm not sure I'd use this feature... but I don't think it would negatively impact my process in any significant way so I'm neutral/in favor of this change.
This branch and concept means that Branch headers would be supported but unnecessary and overwritten.
Great! For me, it's more useful this way!
I found one bug:
Should be fixed, https://github.com/afragen/github-updater/commit/d54a7d98871c68c90e2ef2f3075cae103153595c, https://github.com/afragen/github-updater/commit/655fef94ce34332997cbdc4031ffec49e6ccd37e, https://github.com/afragen/github-updater/commit/356c50372f2fe214a92ca95e712b5824353d76cf
Please test again and let me know.
Yes, did some tests and worked very well!
I think I've got most of the bugs worked out. Hammer on it. Find all the issues.
I made a few, likely inconsequential, changes. If I don't hear of any issues I'll likely merge into develop this weekend.
All the tests I did worked perfectly.