adamtabrams / change

A simple tool that automates generating and updating a changelog
GNU General Public License v3.0
75 stars 8 forks source link

Support remote name configuration #21

Open rcisterna opened 2 years ago

rcisterna commented 2 years ago

Existing Problem Currently, change only support a remote named origin. So, if I have only one remote with a different name, it fails with an exit code 1, and a message saying remote origin url isn't set for this repo.

First Solution It would be nice if, instead, change worked something like this:

Alternative Solutions I actually don't have any more ideas.

Further Explaination

Screen Shot 2022-07-12 at 20 29 58
rcisterna commented 2 years ago

If you are open to it, I can help you with this 😁.

adamtabrams commented 1 year ago

I've created a PR that attempts to support this, but with a different strategy. Instead of adding logic to handle different remotes (which I couldn't find a robust way to parse) or adding a config file, this just uses urls instead (as supplied by git ls-remote --get-url).

@rcisterna I'm not sure if this use case is still relevant to you. But if it is, would you be willing to test if these code changes fix the issue?

rcisterna commented 1 year ago

Hi @adamtabrams! It's currently not relevant to me, but it will be a pleasure to help you test the changes.

adamtabrams commented 1 year ago

Does the version here behave as you expect for branches with multiple remotes? Also when there's only one remote, but it isn't named origin?