在 ubuntu 中,如果我为一个未安装的应用程序键入命令,但它从数据库中知道,它会给我一条消息:
~ $ kate
The program 'kate' is currently not installed. You can install it by typing:
sudo apt-get install kate
Run Code Online (Sandbox Code Playgroud)
有没有办法在 Arch Linux 中获得类似的消息?
小智 1
正在寻找完全相同的解决方案,在这里找到了出色的解决方案: https://bbs.archlinux.org/viewtopic.php? pid=874678#p874678
安装 pkgtools 时,会弹出更多信息:
(2/2) installing pkgtools
- Make sure to run pkgfile --update before use
- pkgfile includes a "command not found" hook for both zsh and bash.
This will automatically run pkgfile whenever you run
a command which the shell cannot find. If you want
this functionality, set CMD_SEARCH_ENABLED to 1 in
/etc/pkgtools/pkgfile.conf (or per-user by copying
that file to ${XDG_CONFIG_HOME}/pkgtools/pkgfile.conf), then
in your current shell run:
source /etc/profile
- An entry has been placed in /etc/cron.daily to run pkgfile --update
If you do not want this functionality, set UPDATE_CRON=0 in /etc/pkgtools/pkgfile.conf
Run Code Online (Sandbox Code Playgroud)
归档时间: |
|
查看次数: |
3050 次 |
最近记录: |