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

feat: #6 support environment variables #12

Merged
merged 10 commits into from
Jan 24, 2025
Merged

Conversation

miquelbeltran
Copy link
Contributor

feat: #6 support environment variables

Description 📝

  • Purpose: Add support for Environment variables for common config params, e.g. the App ID
  • Approach: Created a config params loading class that uses env variables if the arguments are not provided.

Type of change

  • New feature (non-breaking change which adds functionality)

Updates

  • Created config_props.dart which loads common configuration parameters.
  • Created environment.dart which allows to override Environment variables for testing.
  • Added tests in config_props_test.dart.
  • Modified the commands symbols and sourcemap to use the config props class.
  • Updated documentation.
  • Cleanup the "print usage" method.

Screenshots 📷

e.g. calling to symbols list with env variables:

image

(--verbose prints the config params)

Test plan 🧪

Tested manually and created unit test

Author to check 👓

  • Project and all contained modules builds successfully
  • Self-/dev-tested
  • Unit/UI/Automation/Integration tests provided where applicable
  • Code is written to standards
  • Appropriate documentation written (code comments, internal docs)

Reviewer to check ✔️

  • Project and all contained modules builds successfully
  • Change has been dev-/reviewer-tested, where possible
  • Unit/UI/Automation/Integration tests provided where applicable
  • Code is written to standards
  • Appropriate documentation written (code comments, internal docs)

Copy link

@Olwiba Olwiba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code looks good to me, I will leave an approval for someone else to get a second set of eyes :)

Copy link

@phillip-haydon phillip-haydon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🌯

Copy link

@phillip-haydon phillip-haydon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Woops forgot to change Comment > Approve :)

Edit: Oh it needs @TheRealAgentK to approve too.

Copy link
Contributor

@TheRealAgentK TheRealAgentK left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@TheRealAgentK TheRealAgentK merged commit e43ed29 into main Jan 24, 2025
5 checks passed
@miquelbeltran miquelbeltran deleted the feature/6-env-vars branch January 24, 2025 07:32
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.

4 participants