Skip to content
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

[bug]: #286

Closed
2 of 3 tasks
md1440 opened this issue Sep 24, 2023 · 4 comments
Closed
2 of 3 tasks

[bug]: #286

md1440 opened this issue Sep 24, 2023 · 4 comments
Assignees
Labels
bug 🐞 Inconsistencies or issues which will cause a problem for users or implementors. triage 📑 The issue is awaiting investigation.

Comments

@md1440
Copy link

md1440 commented Sep 24, 2023

Environment

Fedora 38 x86_64

Reproduction steps

1. Z-shell is configured with pretty standard settings according to the documentation
2. Start VSCode

Expected behavior

1. Zsh runs in Vscode with z-shell
2. I can execute exec zsh -il without issues

Current behavior

1. When starting VSCode and loading the terminal following output is registered:
/usr/share/autojump/autojump.zsh:13: command not found: uname
/usr/libexec/grepconf.sh: line 5: grep: command not found
/usr/libexec/grepconf.sh: line 5: grep: command not found
/usr/libexec/grepconf.sh: line 5: grep: command not found
/etc/profile.d/kde.sh:7: command not found: grep
zsh: readlink: command not found...
Packages providing this file are:
'coreutils'
'coreutils-single'
zsh: basename: command not found...
Packages providing this file are:
'coreutils'
'coreutils-single'
zsh: awk: command not found...
zsh: grep: command not found...
Install package 'grep' to provide command 'grep'? [N/y] Install package 'gawk' to provide command 'awk'? [N/y] 
2. Regardless of how many times I confirm with y similar information will pop up for each plugin and it will ultimately complete without having z-shell loaded
3. The shell environment will not have access to any standard commands
4. Also, in the normal terminal, when running exec zsh -il I run into similar issues

Code snippet

./zshrc
typeset -A ZI
ZI[BIN_DIR]="${HOME}/.zi/bin"
source "${ZI[BIN_DIR]}/zi.zsh"

autoload -Uz compinit
compinit

(( ${+_comps} )) && _comps[zi]=_zi

if [[ -r "${XDG_CONFIG_HOME:-${HOME}/.config}/zi/init.zsh" ]]; then
source "${XDG_CONFIG_HOME:-${HOME}/.config}/zi/init.zsh" && zzinit
fi

#zi snippet 'https://github.com/robbyrussell/oh-my-zsh/raw/master/plugins/git/git.plugin.zsh'
#zi snippet 'https://github.com/sorin-ionescu/prezto/blob/master/modules/helper/init.zsh'

zi light z-shell/H-S-MW
zi light z-shell/z-a-meta-plugins
zi light-mode for z-shell/z-a-meta-plugins @Annexes @Annexes+ @console-tools @ext-git @fuzzy @prezto @z-shell @z-shell+ @zsh-users+fast @zunit

zstyle ':completion:' completer _complete _match _approximate
zstyle ':completion:
:match:' original only
zstyle -e ':completion:
:approximate:*' max-errors 'reply=($((($#PREFIX+$#SUFFIX)/3>7?7:($#PREFIX+$#SUFFIX)/3))numeric)'

zstyle ':completion::matches' group 'yes'
zstyle ':completion:
:options' description 'yes'
zstyle ':completion::options' auto-description '%d'
zstyle ':completion:
:corrections' format ' %F{green}-- %d (errors: %e) --%f'
zstyle ':completion::descriptions' format ' %F{yellow}-- %d --%f'
zstyle ':completion:
:messages' format ' %F{purple} -- %d --%f'
zstyle ':completion::warnings' format ' %F{red}-- no matches found --%f'
zstyle ':completion:
:default' list-prompt '%S%M matches%s'
zstyle ':completion:' format ' %F{yellow}-- %d --%f'
zstyle ':completion:
' group-name ''
zstyle ':completion:' verbose yes
zstyle ':completion:
' matcher-list 'm:{a-zA-Z}={A-Za-z}' 'r:|[.-]=* r:|=' 'l:|= r:|='
zstyle ':completion:
:functions' ignored-patterns '(
|pre(cmd|exec))'
zstyle ':completion:
' use-cache true
zstyle ':completion:*' rehash true

zstyle ':completion:*' menu select

zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS}

Additional information

❯ zi zstatus
Directories set:
Home: /home/marc/.zi
Binary: /home/marc/.zi/bin
Plugin: /home/marc/.zi/plugins
Snippet: /home/marc/.zi/snippets
Service: /home/marc/.zi/services
Modules: /home/marc/.zi/zmodules
User-land: /home/marc/.zi/polaris
Completions:/home/marc/.zi/completions
Loaded plugins: 42
Light loaded: 41
Downloaded plugins: 44
Compiled plugins: 20
Enabled completions: 163
Disabled completions: 0
Completions available overall: 164
Snippets loaded:
PZTM::archive , PZTM::directory , PZT::modules/helper/init.zsh , PZT::modules/spectrum/init.zsh , PZTM::utility

Self-service

  • I'd be willing to address this documentation request myself.

Have you read the Contributing Guidelines?

Are you familiar with the Contributor Covenant Code of Conduct?

Contact Details

mdafeldecker@gmail.com

@md1440 md1440 added bug 🐞 Inconsistencies or issues which will cause a problem for users or implementors. triage 📑 The issue is awaiting investigation. labels Sep 24, 2023
@md1440
Copy link
Author

md1440 commented Sep 24, 2023

Ok, when open VSCode via the terminal itself from the root of the project via command code . the terminal will load as expected. The error occurred only when starting VSCode via the dash icon. I am not sure if that is expected behavior or not...

@ss-o
Copy link
Member

ss-o commented Sep 24, 2023

Hi @md1440 👋

It seems that the issue is unrelated to Zi, and based on the behavior you provided it appears to be a misconfiguration in VSCode settings or Zsh configuration/environment. There are too many possibilities to guess it.

Verify the configuration or the files/contents that are initialized. I recommend backing up current Zsh configuration/environment files and starting with the vanilla Zsh session in VSCode. If successful, then recover Zsh configuration/environment files in small steps while verifying the contents and periodically restarting the VSCode Zsh session. This should help to identify what causes the issue.

@md1440
Copy link
Author

md1440 commented Sep 24, 2023

Thank you @ss-o , much appreciated. You're correct, it appears to have been some weird misconfiguration. It's all running fine now.

@md1440 md1440 closed this as completed Sep 24, 2023
@github-actions
Copy link

Issue closed and locked due to lack of activity.
If you encounter this same issue, please open a new issue and refer to this closed one.

@github-actions github-actions bot locked and limited conversation to collaborators Oct 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug 🐞 Inconsistencies or issues which will cause a problem for users or implementors. triage 📑 The issue is awaiting investigation.
Projects
None yet
Development

No branches or pull requests

2 participants