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

ya pack -a creates extra dir for author/repo:plugin typo #1763

Closed
AnirudhG07 opened this issue Oct 11, 2024 · 1 comment · Fixed by #2257
Closed

ya pack -a creates extra dir for author/repo:plugin typo #1763

AnirudhG07 opened this issue Oct 11, 2024 · 1 comment · Fixed by #2257
Labels
bug Something isn't working

Comments

@AnirudhG07
Copy link
Contributor

AnirudhG07 commented Oct 11, 2024

What system are you running Yazi on?

macOS

What terminal are you running Yazi in?

iTerm2

yazi --debug output

Yazi
    Version: 0.3.3 (9483798 2024-09-07)
    Debug  : false
    OS     : macos-aarch64 (unix)

Ya
    Version: 0.3.3 (9483798 2024-09-07)

Emulator
    Emulator.via_env: ("xterm-256color", "iTerm.app")
    Emulator.via_csi: Ok(Iterm2)
    Emulator.detect : Iterm2

Adapter
    Adapter.matches: Iterm2

Desktop
    XDG_SESSION_TYPE           : None
    WAYLAND_DISPLAY            : None
    DISPLAY                    : Some("/private/tmp/com.apple.launchd.heOYLNHbse/org.macports:0")
    SWAYSOCK                   : None
    HYPRLAND_INSTANCE_SIGNATURE: None
    WAYFIRE_SOCKET             : None

SSH
    shared.in_ssh_connection: false

WSL
    WSL: false

Variables
    SHELL              : Some("/bin/zsh")
    EDITOR             : Some("nvim")
    VISUAL             : Some("nvim")
    YAZI_FILE_ONE      : None
    YAZI_CONFIG_HOME   : Some("/Users/anirudhgupta/dotfiles/yazi/.config/yazi")

Text Opener
    default: Some(Opener { run: "${EDITOR:=vi} \"$@\"", block: true, orphan: false, desc: "$EDITOR", for_: None, spread: true })
    block  : Some(Opener { run: "${EDITOR:=vi} \"$@\"", block: true, orphan: false, desc: "$EDITOR", for_: None, spread: true })

Multiplexers
    TMUX               : false
    tmux version       : 3.4
    ZELLIJ_SESSION_NAME: None
    Zellij version     : No such file or directory (os error 2)

Dependencies
    file             : 5.41
    ueberzugpp       : 2.9.2
    ffmpegthumbnailer: 2.2.3
    magick           : 7.1.1-38
    fzf              : 0.54.3
    fd               : 10.2.0
    rg               : 14.1.0
    chafa            : 1.14.4
    zoxide           : 0.9.4
    7z               : 17.05
    7zz              : No such file or directory (os error 2)
    jq               : 1.7.1


--------------------------------------------------
When reporting a bug, please also upload the `yazi.log` log file - only upload the most recent content by time.
You can find it in the "/Users/anirudhgupta/.local/state/yazi" directory.

Did you try the latest nightly build to see if the problem got fixed?

Didn't try

Describe the bug

When you add a plugin with ya pack -a, when you make a typo in the plugin repo name JUST for author/repo:plugin type ones, it creates a directory with plugin name but with only file inside, which is the "DO NOT ...".
When you dont make any typo, it behaves as expected.

Minimal reproducer

Run ya pack -a AnirudhG07/plugins-yazi:copy-file-cont
You will see a copy-file-cont.yazi being formed. The correct plugin name is copy-file-contents

I would expect that no such extra folder is made.

Anything else?

No response

@AnirudhG07 AnirudhG07 added the bug Something isn't working label Oct 11, 2024
evpeople added a commit to evpeople/yazi that referenced this issue Jan 29, 2025
Previously, the deployment logic did not verify the existence of the plugin repository path before attempting to create files. This could lead to redundant file creation operations when the plugin path was invalid.

- Add pre-check for plugin directory existence
- Fail early when plugin path is not found
Fixes sxyazi#1763
evpeople added a commit to evpeople/yazi that referenced this issue Jan 29, 2025
Previously, the deployment logic did not verify the existence of the plugin repository path before attempting to create files. This could lead to redundant file creation operations when the plugin path was invalid.

- Add pre-check for plugin directory existence
- Fail early when plugin path is not found
Fixes sxyazi#1763
@sxyazi
Copy link
Owner

sxyazi commented Jan 29, 2025

Please try #2257 - thanks to @evpeople for the PR!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants