dedukun / bookmarks.yazi

MIT License
43 stars 1 forks source link

Persistency doesnt work for me, "ya" not set #18

Open danscheer opened 2 weeks ago

danscheer commented 2 weeks ago

I followed the installation proecesses (yazi 0.2.5). Besides that "ya" for the package manager doesnt exist in a normal yazi installation for the package manager command (maybe you set an alias that i dont know of), ya seems also to be used inside of the plugins init.lua, and maybe therefore the persistence feature set in the yazi/init.lua doesnt work?

dedukun commented 2 weeks ago

Hey,

The ya command doesn't exist in 0.2.5, at the moment you need to install the latest commit of yazi if you want to use it, if you use cargo you need to install both yazi-fm as well as yazi-cli.

If you have the plugin installed manually, you should just need to run the setup function in yazi/init.lua with the desired persistency mode, aka all or vim. Does the plugin work correctly besides the persistency?

danscheer commented 2 weeks ago

Thanks for reply.

The ya command doesn't exist in 0.2.5, at the moment you need to install the latest commit of yazi if you want to use it, if you use cargo you need to install both yazi-fm as well as yazi-cli.

Thanks for the clarification!

If you have the plugin installed manually, you should just need to run the setup function in yazi/init.lua with the desired persistency mode, aka all or vim. Does the plugin work correctly besides the persistency?

Yes, besides the persistency everything works. Dont know if i have to activate something for the DDS, maybe there is the Problem. I switched to Yet Another Bookmark plugin, it works with persistency, but i would like to use your plugin for ease of use.

dedukun commented 2 weeks ago

Ok, can you send some debug information? It would be helpful to get the following:

And this is just to make sure, but you are in the latest commit of the plugin right?

AnirudhG07 commented 1 week ago

I am also facing this issue, I am using v0.2.5 on macOS, and I would like to use "vim" mode for persistency, but when I do it, it creates a process and shows "99% 1 left" (in red color), but doesnt completes the process.

AnirudhG07 commented 1 week ago
❯ yazi --debug                                                                                                                                                                ─╯

Yazi
    Version: 0.2.5 (Homebrew 2024-04-23)
    OS: macos-aarch64 (unix)
    Debug: false

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

Adaptor
    Adaptor.matches: Iterm2

Desktop
    XDG_SESSION_TYPE: None
    WAYLAND_DISPLAY: None
    DISPLAY: None

SSH
    shared.in_ssh_connection: false

WSL
    /proc/sys/fs/binfmt_misc/WSLInterop: false

Variables
    SHELL: Some("/bin/zsh")
    EDITOR: Some("nvim")
    ZELLIJ_SESSION_NAME: None
    YAZI_FILE_ONE: None
    YAZI_CONFIG_HOME: None

file(1)
    Version: Ok(Output { status: ExitStatus(unix_wait_status(0)), stdout: "file-5.41\nmagic file from /usr/share/file/magic\n", stderr: "" })

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 })

tmux
    TMUX: false

Ueberzug++
    Version: Err(Os { code: 2, kind: NotFound, message: "No such file or directory" })

--------------------------------------------------
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.

The init.lua is -

require("full-border"):setup()
-- ~/.config/yazi/init.lua
require("bookmarks"):setup({
    save_last_directory = false,
    persist = "vim",
    desc_format = "full",
    notify = {
        enable = true,
        timeout = 5,
        message = {
            new = "New bookmark '<key>' -> '<folder>'",
            delete = "Deleted bookmark in '<key>'",
            delete_all = "Deleted all bookmarks",
        },
    },
})

Its very small(just started using yazi) so I dont mind if you see it.

  2024-06-25T07:18:42.793206Z ERROR yazi::lives::lives: Kind must be alphanumeric with dashes
stack traceback:
    [C]: in field 'pub_to'
    [string "yazi-plugin/src/loader/loader.rs:66:28"]:86: in function <[string "yazi-plugin/src/loader/loader.rs:66:28"]:66>
    >[C]: in upvalue '_save_state'
    [string "yazi-plugin/src/loader/loader.rs:66:28"]:128: in function <[string "yazi-plugin/src/loader/loader.rs:66:28"]:111>

    at yazi-fm/src/lives/lives.rs:68

This is the text that pops up in yazi.log when I run the process.

dedukun commented 1 week ago

You must have updated the plugin with my commit from a couple of days ago right?

Upstream changed how DDS works a couple of days ago, seeing that you are in yazi v0.2.5 please checkout the plugin to the tag 0.2.5, you were probably having a different issue before.

If you could do that and then resend the yazi.log again it would be very helpful.

You config looks correct, so I don't think that it has anything to do with that. The only thing that I see is that you are using the vim persist method, so only upper case letters are saved to persistent memory.

Urie96 commented 1 week ago

Same problem. Finally solved by rm ~/.local/state/yazi/.dds

AnirudhG07 commented 1 week ago

You must have updated the plugin with my commit from a couple of days ago right?

Upstream changed how DDS works a couple of days ago, seeing that you are in yazi v0.2.5 please checkout the plugin to the tag 0.2.5, you were probably having a different issue before.

If you could do that and then resend the yazi.log again it would be very helpful.

You config looks correct, so I don't think that it has anything to do with that. The only thing that I see is that you are using the vim persist method, so only upper case letters are saved to persistent memory.

2024-06-28T08:10:22.932115Z ERROR yazi::lives::lives: Kind must be alphanumeric with dashes
stack traceback:
    [C]: in field 'pub_to'
    [string "yazi-plugin/src/loader/loader.rs:66:28"]:88: in function <[string "yazi-plugin/src/loader/loader.rs:66:28"]:68>
    >[C]: in upvalue '_save_state'
    [string "yazi-plugin/src/loader/loader.rs:66:28"]:130: in function <[string "yazi-plugin/src/loader/loader.rs:66:28"]:113>

    at yazi-fm/src/lives/lives.rs:68

I deleted and redownloaded ur plugin. Here is the log. the vim mode seems more useful to me than all

dedukun commented 1 week ago

You must have updated the plugin with my commit from a couple of days ago right? Upstream changed how DDS works a couple of days ago, seeing that you are in yazi v0.2.5 please checkout the plugin to the tag 0.2.5, you were probably having a different issue before. If you could do that and then resend the yazi.log again it would be very helpful. You config looks correct, so I don't think that it has anything to do with that. The only thing that I see is that you are using the vim persist method, so only upper case letters are saved to persistent memory.

2024-06-28T08:10:22.932115Z ERROR yazi::lives::lives: Kind must be alphanumeric with dashes
stack traceback:
  [C]: in field 'pub_to'
  [string "yazi-plugin/src/loader/loader.rs:66:28"]:88: in function <[string "yazi-plugin/src/loader/loader.rs:66:28"]:68>
  >[C]: in upvalue '_save_state'
  [string "yazi-plugin/src/loader/loader.rs:66:28"]:130: in function <[string "yazi-plugin/src/loader/loader.rs:66:28"]:113>

    at yazi-fm/src/lives/lives.rs:68

I deleted and redownloaded ur plugin. Here is the log. the vim mode seems more useful to me than all

@AnirudhG07 Can you git checkout yazi-0.2.5 in the plugin folder and try again. (You might also need to fetch the branch)

That seems to be the same issue as before, which is because I had to update the plugin to support upstream Yazi, so you should be in branch [yazi-0.2.5](https://github.com/dedukun/bookmarks.yazi/tree/yazi-0.2.5) of this plugin for it to work.