Skip to content

Cannot copy in fish anymore #11836

Closed
Closed

Description

@JorySeverijnse

When i try to paste text into fish i got the following

commandline: --insert-smart: unknown option

/usr/share/fish/functions/__fish_paste.fish (line 46):
        commandline --insert-smart -- $data
        ^
in function '__fish_paste' with arguments 'copy doesnt work'

(Type 'help commandline' for related documentation)

Happend after i updated fish shell to the latest version.
Temporary fix is just remove --insert-smart inside /usr/share/fish/functions/__fish_paste.fish manually

fish --version fish, version 4.1.0
echo $version 4.0.8
Linux archlinux 6.16.8-arch3-1 #1 SMP PREEMPT_DYNAMIC Mon, 22 Sep 2025 22:08:35 +0000 x86_64 GNU/Linux

Activity

  1. krobelus commented on Sep 29, 2025

    @krobelus
    Contributor
  2. kiloutyg commented on Sep 30, 2025

    @kiloutyg

    Hello!
    Same issue, same solution!
    A clean reboot and that's it!

    Thanks for the answer!

  3. krobelus commented on Sep 30, 2025

    @krobelus
    Contributor

    no need to restart the whole OS, restarting all instances of fish is enough :)

  4. Yutsuten commented on Oct 6, 2025

    @Yutsuten

    I did a reboot but the issue persists, maybe it's a different one? Should I create a new issue? For me, I'm pasting into a read that is in a fish script (my nnn plugins are fish scripts).

    Using fish 4.1.1

    commandline: Can not set commandline in non-interactive mode
    
    /usr/share/fish/functions/__fish_paste.fish (line 1):
    in command substitution
            called on line 1 of file /usr/share/fish/functions/__fish_paste.fish
    in command substitution
            called on line 17 of file /usr/share/fish/functions/__fish_paste.fish
    in function '__fish_paste' with arguments '00:13:43.423'
            called on line 1 of file ~/.config/nnn/plugins/ffmpeg
    
    (Type 'help commandline' for related documentation)
    __fish_tokenizer_state: expected >= 1 arguments; got 0
    commandline: Can not set commandline in non-interactive mode
    
    /usr/share/fish/functions/__fish_paste.fish (line 1):
    in command substitution
            called on line 40 of file /usr/share/fish/functions/__fish_paste.fish
    in function '__fish_paste' with arguments '00:13:43.423'
            called on line 1 of file ~/.config/nnn/plugins/ffmpeg
    
    (Type 'help commandline' for related documentation)
    commandline: Can not set commandline in non-interactive mode
    
    /usr/share/fish/functions/__fish_paste.fish (line 47):
            commandline --insert-smart -- $data
            ^
    in function '__fish_paste' with arguments '00:13:43.423'
            called on line 1 of file ~/.config/nnn/plugins/ffmpeg
    
    (Type 'help commandline' for related documentation)
  5. krobelus commented on Oct 6, 2025

    @krobelus
    Contributor

    @Yutsuten thanks, that was another regression, I'll push a fix today for the imminent 4.1.2 patch release

  6. seowalex commented on Nov 23, 2025

    @seowalex

    I am still seeing this in fish 4.2.0.

  7. krobelus commented on Nov 23, 2025

    @krobelus
    Contributor

    which issue? if it's the first one, then restart fish. Future upgrades won't have this issue

  8. seowalex commented on Nov 23, 2025

    @seowalex

    Ah, I thought I had killed my tmux session but I had not (and so was using the old version). Apologies for the confusion.

  9. geekscrapy commented on Apr 7, 2026

    @geekscrapy

    Can confirm this is an issue on the following still:

    ❯ commandline: --insert-smart: unknown option
    
    /usr/share/fish/functions/__fish_paste.fish (line 47):
            commandline --insert-smart -- $data
            ^
    in function '__fish_paste' with arguments '<pasted filename>'
    
    (Type 'help commandline' for related documentation)
    
    ❯ fish -v
    fish, version 4.2.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions