z-shell / zi

✨ A Swiss Army Knife for Zsh - Unix Shell
https://wiki.zshell.dev
MIT License
735 stars 42 forks source link

[bug]: `OMZP::` snippets fail to update #318

Open morganmay opened 3 months ago

morganmay commented 3 months ago

Environment

zsh 5.9 (x86_64-pc-linux-gnu) on Arch Linux

Reproduction steps

1. Install Oh My ZSH snippets using `OMZP::` syntax
2. Update snippets with `zi update -a` or `zi update -s`

Expected behavior

1. OMZ plugin snippets are downloaded from GitHub using SVN

Current behavior

1. When I run `zi update -a` or `zi update -s`, `OMZP::` snippets fail to update.
2. For example, when `zi` tries to update `OMZP::alias-finder`, I get this error message:

svn: E170013: Unable to connect to a repository at URL 'https://github.com/ohmyzsh/ohmyzsh/trunk/plugins/alias-finder'
svn: E160013: '/ohmyzsh/ohmyzsh/trunk/plugins/alias-finder' path not found
Updating '.':
svn: E170013: Unable to connect to a repository at URL 'https://github.com/ohmyzsh/ohmyzsh/trunk/plugins/alias-finder'
svn: E160013: '/ohmyzsh/ohmyzsh/trunk/plugins/alias-finder' path not found
  1. All OMZP:: snippets fail to update with similar E160013 and E170013 SVN errors.

Code snippet

omz_plugins=(
  alias-finder
  command-not-found
  common-aliases
  emoji
  extract
  git
  history-substring-search
  urltools
  vi-mode
)
for OMZ_PLUGIN in $omz_plugins; do
  zi ice svn
  zi snippet OMZP::$OMZ_PLUGIN
done

Additional information

This used to work. I'm not sure when it stopped. Poking around in the OMZ repository, it looks like the /trunk/ directory is gone, but all of these plugins are still present, so maybe it's just a case of needing to update the URLs in the ZI_1MAP array?

Self-service

Have you read the Contributing Guidelines?

Are you familiar with the Contributor Covenant Code of Conduct?

DeepBlueRobot commented 2 months ago

I have the same problems. I find this: Subversion has been sunset

weijing24 commented 1 month ago

community version also same problem https://github.com/zdharma-continuum/zinit/issues/504

weijing24 commented 1 month ago

Here is a workaroud, looks ugly, may it be helpful

zi wait'1' lucid for \
 id-as'OMZP::tmux' atclone'rm -rf $ZI[PLUGINS_DIR]/OMZP::tmux;mkdir -p $ZI[PLUGINS_DIR]/OMZP::tmux;wget -q https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/plugins/tmux/{tmux.plugin.zsh,tmux.extra.conf,tmux.only.conf} -P $ZI[PLUGINS_DIR]/OMZP::tmux' atpull'%atclone' atload'[[ -d $ZI[PLUGINS_DIR]/OMZP::tmux ]] && . $ZI[PLUGINS_DIR]/OMZP::tmux/tmux.plugin.zsh' \
    z-shell/null \
 id-as'OMZP::aliases' atclone'rm -rf $ZI[PLUGINS_DIR]/OMZP::aliases;mkdir -p $ZI[PLUGINS_DIR]/OMZP::aliases;wget -q https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/plugins/aliases/{aliases.plugin.zsh,cheatsheet.py,termcolor.py} -P $ZI[PLUGINS_DIR]/OMZP::aliases' atpull'%atclone' atload'[[ -d $ZI[PLUGINS_DIR]/OMZP::aliases ]] && . $ZI[PLUGINS_DIR]/OMZP::aliases/aliases.plugin.zsh' \
    z-shell/null
AtifChy commented 1 month ago

@weijing24 what's the difference between this and the community version?

weijing24 commented 1 month ago

@weijing24 what's the difference between this and the community version?

@AtifChy z-shell/zi and zdharma-continuum/zinit are actually different branches or versions of the same project.

  1. Original Project: Initially, this project was called "zplugin," later renamed to "zinit." It was created by Sebastian Gniazdowski.

  2. zdharma-continuum/zinit:

    • This is a continuation of the original zinit project.
    • When the original author stopped maintaining it, community members took over and created the "zdharma-continuum" organization to continue maintaining the project.
    • This version retains the original "zinit" name.
  3. z-shell/zi:

    • This is another community fork, maintained by some original contributors and community members.
    • They renamed the project to "zi," possibly to avoid name conflicts with the original project.
    • This branch may include some different features or improvements.

Main differences:

  1. Name: One is called "zinit," the other is called "zi."
  2. Maintainers: Although both are community-maintained, the maintenance teams may be slightly different.

Functionally, the core features of these two projects should be very similar since they originate from the same project. Choosing which one to use mainly depends on personal preference and which maintenance team you trust or prefer more.

Personally, I recommend z-shell because its documentation is more readable.

github-actions[bot] commented 1 week ago

There hasn't been any activity on this issue recently, and in order to prioritize active issues, it will be marked as stale. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a 👍 Because this issue is marked as stale, it will be closed and locked in 7 days if no further activity occurs. Thank you for your contributions!