tokuhirom / Minilla

Authorizing tool for CPAN modules
https://metacpan.org/release/Minilla
Other
97 stars 65 forks source link

Allow configuring Git remote used to generate meta resources #242

Open nohuhu opened 6 years ago

nohuhu commented 6 years ago

When Git remote pointing to the master repo is not origin (say, upstream), Minilla will try to override meta resources with Git URLs generated from origin remote.

Allowing to configure what remote is used solves this problem.

Grinnz commented 6 years ago

I'm not sure this is the optimal way to configure this. Remember the minil.toml is committed, and so needs to work for the owner as well as any contributors, who may have different remote setups.

nohuhu commented 6 years ago

Right, I was writing a comment describing the changes and realized that this might be the case. Any input on how to make this configurable on local basis? Environment variable perhaps?

Grinnz commented 6 years ago

There's two ways it could be configured in minil.toml that would work for all users. Either setting the github user (or perhaps user/repo) to override the one found in the origin remote (only if it's a github URL, of course) or setting the URL to use as a whole.

nohuhu commented 6 years ago

I see another way: add optional and non-committed minil_local.toml that would override config values in the main minil.toml. That would make it easy to change any values without conflicting with other people's repo forks.

@tokuhirom Thoughts?