forked from extern/ohmyzsh
feat(command-not-found): add support for Termux (#9666)
This commit is contained in:
parent
b54a6dab9c
commit
6ae78695ef
@ -28,5 +28,6 @@ It works out of the box with the command-not-found packages for:
|
|||||||
- [macOS (Homebrew)](https://github.com/Homebrew/homebrew-command-not-found)
|
- [macOS (Homebrew)](https://github.com/Homebrew/homebrew-command-not-found)
|
||||||
- [Fedora](https://fedoraproject.org/wiki/Features/PackageKitCommandNotFound)
|
- [Fedora](https://fedoraproject.org/wiki/Features/PackageKitCommandNotFound)
|
||||||
- [NixOS](https://github.com/NixOS/nixpkgs/tree/master/nixos/modules/programs/command-not-found)
|
- [NixOS](https://github.com/NixOS/nixpkgs/tree/master/nixos/modules/programs/command-not-found)
|
||||||
|
- [Termux](https://github.com/termux/command-not-found)
|
||||||
|
|
||||||
You can add support for other platforms by submitting a Pull Request.
|
You can add support for other platforms by submitting a Pull Request.
|
||||||
|
@ -53,3 +53,10 @@ if [[ -x /run/current-system/sw/bin/command-not-found ]]; then
|
|||||||
/run/current-system/sw/bin/command-not-found -- "$@"
|
/run/current-system/sw/bin/command-not-found -- "$@"
|
||||||
}
|
}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Termux: https://github.com/termux/command-not-found
|
||||||
|
if [[ -x /data/data/com.termux/files/usr/libexec/termux/command-not-found ]]; then
|
||||||
|
command_not_found_handler() {
|
||||||
|
/data/data/com.termux/files/usr/libexec/termux/command-not-found -- "$1"
|
||||||
|
}
|
||||||
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user