synfinatic / aws-sso-cli

A powerful tool for using AWS Identity Center for the CLI and web console.
https://synfinatic.github.io/aws-sso-cli/
GNU General Public License v3.0
413 stars 49 forks source link

use SSO name for config-profiles block #871

Closed synfinatic closed 3 weeks ago

synfinatic commented 1 month ago

Deal with users with multiple SSOConfig's and who use config-profiles command. We no longer will replace the previous config block in the ~/.aws/config file.

codecov[bot] commented 1 month ago

Codecov Report

Attention: Patch coverage is 74.13793% with 15 lines in your changes missing coverage. Please review.

Project coverage is 82.93%. Comparing base (0d9616d) to head (4b100c7).

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871/graphs/tree.svg?width=650&height=150&src=pr&token=F8454GS4HS&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner)](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner) ```diff @@ Coverage Diff @@ ## main #871 +/- ## ========================================== + Coverage 81.56% 82.93% +1.36% ========================================== Files 38 38 Lines 2723 2741 +18 ========================================== + Hits 2221 2273 +52 + Misses 427 383 -44 - Partials 75 85 +10 ``` | [Flag](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner) | `82.93% <74.14%> (+1.36%)` | :arrow_up: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner#carryforward-flags-in-the-pull-request-comment) to find out more. | [Files](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner) | Coverage Δ | | |---|---|---| | [internal/awsconfig/config.go](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?src=pr&el=tree&filepath=internal%2Fawsconfig%2Fconfig.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner#diff-aW50ZXJuYWwvYXdzY29uZmlnL2NvbmZpZy5nbw==) | `80.65% <100.00%> (+0.65%)` | :arrow_up: | | [sso/awssso\_auth.go](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?src=pr&el=tree&filepath=sso%2Fawssso_auth.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner#diff-c3NvL2F3c3Nzb19hdXRoLmdv) | `85.29% <100.00%> (+0.26%)` | :arrow_up: | | [internal/predictor/predictor.go](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?src=pr&el=tree&filepath=internal%2Fpredictor%2Fpredictor.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner#diff-aW50ZXJuYWwvcHJlZGljdG9yL3ByZWRpY3Rvci5nbw==) | `84.78% <50.00%> (+2.76%)` | :arrow_up: | | [internal/utils/fileedit.go](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?src=pr&el=tree&filepath=internal%2Futils%2Ffileedit.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner#diff-aW50ZXJuYWwvdXRpbHMvZmlsZWVkaXQuZ28=) | `70.48% <79.17%> (+1.48%)` | :arrow_up: | | [internal/helper/helper.go](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?src=pr&el=tree&filepath=internal%2Fhelper%2Fhelper.go&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner#diff-aW50ZXJuYWwvaGVscGVyL2hlbHBlci5nbw==) | `69.00% <61.90%> (+40.28%)` | :arrow_up: | ... and [1 file with indirect coverage changes](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner) ------ [Continue to review full report in Codecov by Sentry](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner). > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner) > `Δ = absolute (impact)`, `ø = not affected`, `? = missing data` > Powered by [Codecov](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?dropdown=coverage&src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner). Last update [0d9616d...4b100c7](https://app.codecov.io/gh/synfinatic/aws-sso-cli/pull/871?dropdown=coverage&src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Aaron+Turner).
synfinatic commented 1 month ago

This is still not working, correctly because we will dump multiple SSO instances in each config block.