Compare commits

...

3 Commits

Author SHA1 Message Date
3w36zj6 fcc61195a1
Merge 59ff7f8bef into 7ff836131a 2026-03-11 10:05:41 -03:00
Kevin Ji 7ff836131a
fix(gcloud): prevent gcloud CLI from hanging (#2935)
If the `gcloud` command is interactive (e.g. asks to install a component, or needs an update), the current code will hang forever, and is uninterruptible as `INT` is being swallowed.

Fix this with `</dev/null` and `--quiet`.
2026-03-11 09:09:44 +08:00
3w36zj6 59ff7f8bef docs: add Sheldon to Installation in README 2024-08-15 06:34:14 +09:00
2 changed files with 19 additions and 1 deletions

View File

@ -431,6 +431,7 @@ Powerlevel10k.
- [Arch Linux](#arch-linux)
- [Alpine Linux](#alpine-linux)
- [Fig](#fig)
- [Sheldon](#sheldon)
### Manual
@ -549,6 +550,21 @@ ln -s /usr/share/zsh/plugins/powerlevel10k ~/.local/share/zsh/plugins/
Follow the instructions on
[this page](https://fig.io/plugins/other/powerlevel10k).
### Sheldon
Add the following to the Sheldon config file.
```toml
[plugins.powerlevel10k]
github = "romkatv/powerlevel10k"
```
Or run the following to automatically add it.
```zsh
sheldon add powerlevel10k --github romkatv/powerlevel10k
```
## Configuration
- [For new users](#for-new-users)

View File

@ -4716,7 +4716,9 @@ _p9k_gcloud_prefetch() {
if ! _p9k_cache_stat_get $0 ${CLOUDSDK_CONFIG:-~/.config/gcloud}/configurations/config_$P9K_GCLOUD_CONFIGURATION; then
local pair account project_id
pair="$(gcloud config configurations describe $P9K_GCLOUD_CONFIGURATION \
--format=$'value[separator="\1"](properties.core.account,properties.core.project)')"
--quiet \
--format=$'value[separator="\1"](properties.core.account,properties.core.project)' \
</dev/null)"
(( ! $? )) && IFS=$'\1' read account project_id <<<$pair
_p9k_cache_stat_set "$account" "$project_id"
fi