Skip to content
This repository has been archived by the owner on May 16, 2023. It is now read-only.

Commit

Permalink
fix: profile to command line parser
Browse files Browse the repository at this point in the history
While trying out the command with the `--profile` flag with traces on,
I've noticed the profile wasn't passed through the AWS call.

`AWS_PROFILE` could override it, and looking at the code, it looks like
an omission (region was there twice).

Feel free to discard this PR if this was intentional.

Co-authored-by: Daniel Iziourov <[email protected]>
  • Loading branch information
sledigabel and danmx authored Oct 27, 2021
1 parent b85584e commit 13a9a13
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ func initConfig(cmd *cobra.Command) error {
}).Error(err)
return err
}
for _, key := range []string{"region", "config-profile", "region"} {
for _, key := range []string{"region", "config-profile", "profile"} {
if err := cfg.BindPFlag(key, cmd.PersistentFlags().Lookup(key)); err != nil {
log.WithFields(log.Fields{
"flag": key,
Expand Down

0 comments on commit 13a9a13

Please sign in to comment.