Bug 1215428 - cnf-rs is not compatible with fish
Summary: cnf-rs is not compatible with fish
Status: RESOLVED FIXED
Alias: None
Product: openSUSE Tumbleweed
Classification: openSUSE
Component: Basesystem (show other bugs)
Version: Current
Hardware: x86-64 openSUSE Tumbleweed
: P5 - None : Normal (vote)
Target Milestone: ---
Assignee: Michal Vyskocil
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-09-18 08:39 UTC by Bruno Pitrus
Modified: 2023-09-21 08:14 UTC (History)
1 user (show)

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bruno Pitrus 2023-09-18 08:39:46 UTC
Since the switch from scout-command-not-found to cnf-rs, the CNF handler has stopped working with fish:

Exammple:

[fish]
╭─bruno at bruno-beit in ~
╰─λ telnet
fish: Unknown command: telnet


[bash]
bruno@bruno-beit:~$ telnet

The program 'telnet' can be found in following packages:
  * busybox-telnet [ path: /usr/bin/telnet, repository: repo-oss ]
  * telnet [ path: /usr/bin/telnet, repository: repo-oss ]

Try installing with:
    sudo zypper install <selected_package>
Comment 1 Michal Vyskocil 2023-09-18 09:57:40 UTC
Hi, thanks for the report. I have double checked the original command not found handler and it does not provide fish integration at all. So I assume this works because of you configured the system as is.

I am willing to add a fish integration into cnf-rs. However I have no clue how to do it. The bash integration is done via openSUSE /etc/bash.bashrc, which reads /etc/bash_command_not_found. Is there a similar machinery to use in a case of fish shell?
Comment 2 Bruno Pitrus 2023-09-18 10:04:18 UTC
scout-command-not-found works with fish out of the box. The integration is defined in /usr/share/fish/functions/fish_command_not_found.fish

cnf-rs fails to provide the `command-not-found` binary which is the API fish uses.
Comment 3 Michal Vyskocil 2023-09-18 11:50:48 UTC
Added the compatibility symlink as a workaround and tested with fish.

michal@osc ~/p/v/o/u/cnf-rs> cmake

The program 'cmake' can be found in following packages:
  * cmake-full [ path: /usr/bin/cmake, repository: repo-oss ]
  * cmake-mini [ path: /usr/bin/cmake, repository: repo-oss ]

Try installing with:
    sudo zypper install <selected_package>

Will submit an update
Comment 4 OBSbugzilla Bot 2023-09-18 12:25:03 UTC
This is an autogenerated message for OBS integration:
This bug (1215428) was mentioned in
https://build.opensuse.org/request/show/1111957 Factory / cnf-rs
Comment 5 OBSbugzilla Bot 2023-09-18 21:35:03 UTC
This is an autogenerated message for OBS integration:
This bug (1215428) was mentioned in
https://build.opensuse.org/request/show/1112082 Factory / cnf-rs
Comment 6 Michal Vyskocil 2023-09-21 08:14:23 UTC
Already in Factory