New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a repo-branch argument to with-git which gets the latest revision… #46
Conversation
… of the given branch and passes it on.
Thanks for your pull request! I initially designed this with pipelines in mind that have a I'm guessing you just want to build the latest commit on a branch. That sounds reasonable to me. I just have one doubt: Your pull request would introduce a behavior where How about we give put this into a separate function to make it explicit? I think we can simplify the implementation as well: we don't actually need to find the Also, if you could add a test for your feature that would be awesome! Prevents me from accidently breaking it :) Last but not least, you don't need to bump the version in |
Your assumption is correct: I want to build the latest commit from a branch. Moved and updated the feature to What exactly are you looking for in the test? The only thing that could break is the |
Looks good! I would maybe add an additional test that tests your new feature, that it checks out a repository on that branch and calls steps with a |
Yeah that TODO was throwing me off for writing a test case 😕. Added test cases for checking out a specific branch, checking out a repo with an unknown uri, and checking out a repo with a known uri but unknown branch. |
Add a repo-branch argument to with-git which gets the latest revision…
All good, merged! Thanks for the contribution. Also, I got rid of that confusing TODO. |
Released in version 0.5.3 |
… of the given branch and passes it on. This is useful for those using Gitflow because it is more common to checkout the develop branch instead of the master branch.