diff options
author | Klemens Nanni <klemens@posteo.de> | 2022-05-29 07:27:21 +0200 |
---|---|---|
committer | Cole Helbling <cole.e.helbling@outlook.com> | 2022-06-03 14:19:52 -0700 |
commit | fa5867073f5f911322d1627b7413f474c9d1556f (patch) | |
tree | 54a29d4cc71c151bd7f3e2c0cd2ad4fe2d484e37 /pkgs/shells | |
parent | 0a8e9a15921d9d478f9313cd655d3e6ea9407235 (diff) | |
download | nixpkgs-fa5867073f5f911322d1627b7413f474c9d1556f.tar nixpkgs-fa5867073f5f911322d1627b7413f474c9d1556f.tar.gz nixpkgs-fa5867073f5f911322d1627b7413f474c9d1556f.tar.bz2 nixpkgs-fa5867073f5f911322d1627b7413f474c9d1556f.tar.lz nixpkgs-fa5867073f5f911322d1627b7413f474c9d1556f.tar.xz nixpkgs-fa5867073f5f911322d1627b7413f474c9d1556f.tar.zst nixpkgs-fa5867073f5f911322d1627b7413f474c9d1556f.zip |
pkgs/shells/fish: Fix completion file generator
Cherry-pick upstream commit to ensure that completions for commands like mkfs.xfs(8) end up in mkfs.xfs.fish by fixing over-eager stripping of file extensions. All mkfs.*(8) (and fsck.*(8), etc.) programs would yield mkfs.fish files with unique `complete -c mkfs ...` lines using the same command. Thus completing `mkfs` in fish would for example yield XFS specific suggestions, given "xfsprogs" was installed **and** won over other packages. Noticed through build logs: ``` building '/nix/store/5fz5jgkd2ycx5fk3lb30my2hr2br639f-system_fish-completions.drv'... warning: collision between `/nix/store/1z01j2pma0l005w3qg6slndn0rp136s8-dosfstools-4.2_fish-completions/mkfs.fish' and `/nix/store/jxxgrng41l6qakg45fksk1qpil976vgi-xfsprogs-5.16.0_fish-completions/mkfs.fish' ```
Diffstat (limited to 'pkgs/shells')
-rw-r--r-- | pkgs/shells/fish/default.nix | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/pkgs/shells/fish/default.nix b/pkgs/shells/fish/default.nix index 3969fdace8b..7207d9b947c 100644 --- a/pkgs/shells/fish/default.nix +++ b/pkgs/shells/fish/default.nix @@ -147,6 +147,16 @@ let sha256 = "sha256-tvI7OEOwTbawqQ/qH28NDkDMAntKcyCYIAhj8oZKlOo="; }; + patches = [ + # merged https://github.com/fish-shell/fish-shell/pull/8978 + # "create_manpage_completions.py: Do not overstrip commands with dots" + (fetchpatch { + name = "fix-cmdname-completeion-generator.patch"; + url = "https://github.com/fish-shell/fish-shell/commit/32d646a5483844e9b1fae4b73f252a34ec0d4c76.patch"; + sha256 = "sha256-51hqgPHQ7oQbl1i3SfqvGsbkYMe2Jh+sEwCRu2kiv1U="; + }) + ]; + # Fix FHS paths in tests postPatch = '' # src/fish_tests.cpp |