Age | Commit message (Collapse) | Author |
|
|
|
`expiration_date_set_from_file` (#5685)
* fix(aws): fix flaky test `expiration_date_set`
* fix(aws): fix flaky test `expiration_date_set_from_file`
|
|
Adding the AWS SSO CLI env variable to profile list
Adding support for the profile env variable used by https://github.com/synfinatic/aws-sso-cli
|
|
Signed-off-by: bestgopher <84328409@qq.com>
|
|
* feat(aws): support aws sso with automatic authentication refresh
* docs(aws): add sso_session for profile detection
|
|
feat(aws): add support for source_profile (#3834)
Co-authored-by: @luiscamaral
|
|
(#5002)
feat(aws): supports AWS_CREDENTIAL_EXPIRATION environment variable
Adds support for the AWS_CREDENTIAL_EXPIRATION environment variable
which was adopted as the standard way to set the expiration for
temporary credentials. The existing AWS_SESSION_EXPIRATION environment
variable is not dropped for backwards compatibility.
See https://github.com/aws/aws-cli/pull/7398
|
|
(#4805)
chore(aws): fix unintended test failure of `aws::missing_any_credentials`
Because its mocking is not enough, The test may unintentionally fail
if `~/.aws/credentials` exists.
This commit fixes this issue by mocking `credentials` file as well.
|
|
chore: fix new clippy lints
|
|
|
|
* build(deps): update rust crate chrono to 0.4.23
* chore: remove chrono deprecations
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
|
|
|
|
* feat(aws): add a fallback for `expiration`
* fix(aws): intermittent test failures
- extend the time range from `-2s,0s` to `-5s,+2s`
* fix: `docs/config/README.md` readability
Co-authored-by: David Knaack <davidkna@users.noreply.github.com>
Co-authored-by: David Knaack <davidkna@users.noreply.github.com>
|
|
|
|
* fix(aws): use AWS_SHARED_CREDENTIALS_FILE instead
Signed-off-by: Ismayil Mirzali <ismayilmirzeli@gmail.com>
* fix tests & keep support for older variant
Signed-off-by: Ismayil Mirzali <ismayilmirzeli@gmail.com>
Co-authored-by: Ismayil Mirzali <ismayilmirzeli@gmail.com>
|
|
|
|
|
|
|
|
* refactor: replace module_config_derive with serde
Changes include:
* Removing `starship_module_config_derive` and replacing it with `serde::Deserialize`
* Removing `RootModuleConfig::load_config`. While potentially useful, it was only used in tests. And it would require something like `serde::DeserializeSeed` which is not derived by serde.
* Merging `RootModuleConfig` into `ModuleConfig`
* Implementing a `ValueDeserializer` that holds a reference to a `toml::Value` in `serde_utils.rs`
* Deserialization errors (invalid type) are now logged and include the current key and the struct names
* Unknown keys are now considered an error. "Did you mean?"-messages are still possible
* fix typo
Co-authored-by: Matan Kushner <hello@matchai.dev>
Co-authored-by: Matan Kushner <hello@matchai.dev>
|
|
* add option to force AWS display
Even if no credentials or credential_process have been setup
* change README wording
* Include sso_start_url in the description
* Change option name to force_display
|
|
|
|
* fix(aws): Make AWS_REGION orverrides AWS_DEFAULT_REGION (#3619)
* fix(aws): Align the coding style of region and profile env var (#3619)
|
|
* Rename m.aws.alias_region to alias_name
* Add aws profile aliases
* Document aws.profile_aliases, with examples
* Add tests for new aws.profile_aliases feature
* Tidy alias_handling a bit
|
|
* only display aws on credential_process defined
* add check for both credential_process and valid credentials
* fix tests
* update aws module documentation
* add better explanation of requirements to documentation
* add support for AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN, and update docs
* remove credential_process env var
|
|
* ci: Fix aws::expiration_date_set_from_file race
While aws::expiration_date_set_from_file will almost-always work
perfectly locally, it is theoretically possible for the thread running
the test to be scheduled away betwen writing the file with timing
information and then actually reading it, resulting in a
shorter-than-expected time appearing in the module. This can also happen
if the test triggers right at the very end of a second (e.g. at
10:45:47.999995).
This appears to actually happen sometimes on heavily-loaded GitHub
Actions runners. To fix this issue, we allow for up to a two-second
delay between when the file is written and when the test actually fires
(allowing "30m", "29m59s", and "29m58s" as possible values).
* Fix typo
|
|
When opening a directory as a file the intial open works, while
subsequent line-reads will fail with _is a directory_.
Since erroring line-reads were just skipped this lead to an
endless loop.
|
|
|
|
|
|
|
|
|
|
|
|
and also after the symbol when using the Nerd font glyph.
|
|
|
|
* test: avoid setting $HOME
* add comment to get_home
* move everything to context.get_home
|
|
When running the AWS module it will parse the AWS config found in
`~/.aws/config` to get the region. This means that tests that expect no
region to be set will fail if there exists a default profile with a
region set, which is probably true for most AWS users. To avoid this
have set the AWS tests that depend on the non-existance of a
`.aws/config` to be ignored.
|
|
This creates a custom logger for the log crate which logs everything to a file (/tmp/starship/session_$STARSHIP_SESSION_KEY.log) and it logs everything above Warn to stderr, but only if the log file does not contain the line that should be logged resulting in an error or warning to be only logged at the first starship invocation after opening the shell.
|
|
|
|
|
|
`dirs` will be unmaintained for the foreseeable future, so
switch to the maintained fork `dirs-next`.
Closes #1319.
|
|
* Use AWS_VAULT as the profile if set
[aws-vault](https://github.com/99designs/aws-vault) sets
the `AWS_VAULT` env var instead of `AWS_PROFILE` when an
aws-vault session is active.
This PR adds support for reading the AWS profile value from
the `AWS_VAULT` env var, giving priority to `AWS_VAULT` if both
it and `AWS_PROFILE` are set.
* Update docs for AWS_VAULT
|
|
|
|
|
|
|
|
|
|
Changes imports statements to make imports more uniform.
|
|
|
|
This PR refactors config and puts configuration files for all modules in `configs/`.
|
|
Adds a module for displaying the current AWS profile based
on the AWS_PROFILE envar.
|