Skip to content

improve aws profile autocomplete #1

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

Merged
merged 2 commits into from
Aug 3, 2023
Merged

Conversation

sanyer
Copy link
Contributor

@sanyer sanyer commented Mar 14, 2018

search also ~/.aws/config file

look in config also;
merge findings and return unique ones;
@halostatue
Copy link

This could also be written , for Fish v3, as:

cat ~/.aws/{config,credentials} | string replace -r -f "^\[(profile[[:space:]]*)*(.*)\]" '$2' | sort -u

@rohan-buechner
Copy link

Any update on this? The above code seems to work fine... what do we need to get it merged in? 🙏

@scorphus
Copy link
Member

scorphus commented Mar 1, 2022

Hey, @rohan-buchner. Thanks for the ping regarding this PR.

I've took the liberty of updating it, as you can see. I would appreciate if you could give it a try and let me know if it works as expected.

Also let me know in case you need help testing this PR on your local/testing environment.

Thanks!

@rohan-buechner
Copy link

@scorphus the profiles below are all in the .aws/config file, thus the code works as is expected. Please see the little recording below.

Screen.Recording.2022-03-03.at.14.27.48.mov

FWIW, I was not too sure how to test these dev plugin versions omf install (I assume there is a way I could do that). But I just manually applied the change in the PR to my local plugin.

@Jomik
Copy link

Jomik commented Aug 3, 2023

Can we merge this ? 😄

Copy link
Member

@scorphus scorphus left a comment

Choose a reason for hiding this comment

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

Thanks for contributing, @sanyer!

@scorphus scorphus merged commit e53a1de into oh-my-fish:master Aug 3, 2023
@scorphus
Copy link
Member

scorphus commented Aug 3, 2023

Thanks for the nudge, @Jomik

@sanyer
Copy link
Contributor Author

sanyer commented Sep 1, 2023

oh wow, it's been a while now @scorphus
I've changed two jobs already 😂
Awesome that this is fixed now!

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.

5 participants