cross-posted from: https://lemmy.ml/post/61051
Hi. Please can someone help me with setting up my zsh? I’m having two problems:
When using the powerline10k theme, the shell gets stuck on
fetching gitstatusd
The prompt shows those weird characters in the screenshot
I have already installed powerline fonts. I don’t know what to do next… I appreciate any help. Thanks.
Hmm, you might have to edit the config file
~/.zshrc
and add theGITSTATUS_LOG_LEVEL=DEBUG
parameter for further output about the specific part of “initialization” that failed. Otherwise, it’s hard to determine what exactly happened.You’re right! I edited the post including the link to the logs. Thanks!
Ok, sorry for the late response. Looking through the logs, it seems that the problem may be
curl
somehow failing to fetchgitstatusd
. The script tries fetchinggitstatusd-linux-x86_64.tar.gz
at several mirrors, from what I can gather, and all of them fail.This might be because
curl
itself is not working. I recall that there were reports ofcurl
not working on Cygwin which I read about somewhere, and Cygwin seems to be what you’re on. I’d check if you can run thecurl
commands used in the logs manually to fetch the resources at those URLs. So try running:curl -q -kfsSL -- https://gitee.com/romkatv/gitstatus/raw/release-v1.3.1/release/gitstatusd-linux-x86_64.tar.gz
Or:
curl -q -kfsSL -- https://github.com/romkatv/gitstatus/releases/download/v1.3.1/gitstatusd-linux-x86_64.tar.gz
Or any one of those mirror links in the logs, and see what happens.
Thanks for the response. You’re right: curl fails to fetch that file. However, I could manually download it. Do you know where I should extract it to? Thanks.
This thread provides a “manual installation method” you could try before attempting to manually download (as things could go wrong):
git -C ~/.oh-my-zsh/custom/themes/powerlevel10k pull
~/.oh-my-zsh/custom/themes/powerlevel10k/gitstatus/install -f
So in your case, you could modify this to update your powerlevel10k and then run the install script:
$ git -C zsh_dir/custom/themes/powerlevel10k pull $ zsh_dir/custom/themes/powerlevel10k/gitstatus/install -f
The install script can be found here on Github, which also provides clues to how
gitstatusd
is fetched: it’s actually a binary executable that is placed in a cache directory by the install script. This cache folder is referenced as"${GITSTATUS_CACHE_DIR:-${XDG_CACHE_HOME:-$HOME/.cache}/gitstatus}"
. So, probably yourCygwin home folder/.cache/gitstatus
should be where you should try to extractgitstatusd
manually.Extracting the binary to
~/.cache/gitstatus
worked! Thank you very much!!! Now there’s only that ugly symbols in the prompt :(No problem, glad it worked! For the symbols, try installing this font (“Meslo Nerd Font patched for Powerlevel10k”) and see if it helps.
I installed this font, but the problem persists :( Could it be something related to the terminal? I’m using GNOME Terminal 2.31.3