Closed Lansoweb closed 6 years ago
@Lansoweb I took the liberty of finishing this up for you, as I merged #24 earlier today. In particular:
Config
and ConfigCommand
classes.Provider\GetProviderTrait
to GetConfigValuesTrait
, updated it to use the ConfigFileTrait
, and added the methods prepareConfig()
and getToken()
. I updated getProvider()
to also accept a Config
instance, which is queried for the provider. Essentially, you call prepareConfig()
to get a Config
instance, and then pull the token and provider from that; the method grabs the configuration, and then overrides it with values passed via options if present.ReleaseCommand
and EntryCommand
to use the methods introduced above for the purpose of getting tokens and/or providers.Thanks a ton for this!
@Lansoweb I took the liberty of finishing this up for you, as I merged #24 earlier today. In particular:
- I added tests for the
Config
andConfigCommand
classes.- I renamed
Provider\GetProviderTrait
toGetConfigValuesTrait
, updated it to use theConfigFileTrait
, and added the methodsprepareConfig()
andgetToken()
. I updatedgetProvider()
to also accept aConfig
instance, which is queried for the provider. Essentially, you callprepareConfig()
to get aConfig
instance, and then pull the token and provider from that; the method grabs the configuration, and then overrides it with values passed via options if present.- I updated the
ReleaseCommand
andEntryCommand
to use the methods introduced above for the purpose of getting tokens and/or providers.- I ensured all tests pass.
- I did a few other minor refactors for readability and maintainability.
Thanks a ton for this!
Thanks a lot for this tool :)
Provide a narrative description of what you are trying to accomplish:
[ ] Are you fixing a bug?
master
branch, and submit against that branch.CHANGELOG.md
entry for the fix.[X] Are you creating a new feature?
develop
branch, and submit against that branch.CHANGELOG.md
entry for the new feature.The
config
command provides a config file per project. So you can have a global github token and a gitlab one for a project.[ ] Is this related to quality assurance?
[ ] Is this related to documentation?