Skip to content
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

Refactor package config #427

Merged
merged 25 commits into from
Sep 11, 2018
Merged

Refactor package config #427

merged 25 commits into from
Sep 11, 2018

Conversation

NicolasMahe
Copy link
Member

@NicolasMahe NicolasMahe commented Sep 5, 2018

  • Remove Viper
  • Use envconfig for loading conf fron env
  • Use a dedicated config struct
  • Should use this config struct by using config.Global() anywhere in the codebase

I add a hack that change the config.Path value in order to make tests that used the database works. Otherwise, the tests tried to create the directory /mesg and failed because of permission. This should be removed when the database package in mockable.

-ldflags="-X 'github.com/mesg-foundation/core/config.Path=./'"

@NicolasMahe NicolasMahe added this to the v1.2.0 milestone Sep 5, 2018
@NicolasMahe
Copy link
Member Author

@mesg-foundation/core this PR is ready for reviews

@NicolasMahe
Copy link
Member Author

@mesg-foundation/core ready to review.

@antho1404 antho1404 merged commit 052c4ae into dev Sep 11, 2018
@antho1404 antho1404 deleted the feature/better-config branch September 11, 2018 09:45
@antho1404 antho1404 mentioned this pull request Sep 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants