linux 安装软件被取代怎么办,linux – 如何让安装的应用程序被rofi检测到...

1. $PATH

PATH is an environmental variable in Linux and other Unix-like

operating systems that tells the shell which directories to search for

executable files (i.e., ready-to-run programs) in response to commands

issued by a user.

由于我决定将软件安装到’/ opt’,我必须确保在PATH中列出’/ opt’;它不是.我修改了’/ etc / profile’文件

:/选择

在PATH变量的末尾.注意:编辑’/ etc / profile’会影响系统上的所有用户,如果您只想为该特定用户更改该文件,则应使用主目录中的文件.

2.符号链接

Symbolic links are like shortcuts or references to the actual file or

directory. Most of the time these links are transparent when working

with them through other programs… Symbolic links are used all the

time to link libraries and make sure files are in consistent places

without moving or copying the original.

修改$PATH变量只解决了部分问题.添加/选择$PATH变量只添加了该目录,而不是位于其中的特定应用程序.我还需要在/ opt目录中创建一个符号链接 – 或符号链接 – 到特定的应用程序,以便可以在我的应用程序启动器中搜索.

ln -s / opt / applicationFolder / executable / opt / applicationName

这将为位于’/ opt /’目录中的’/ opt / applicationFolder’中的可执行文件创建一个符号链接,其名称为’applicationName’.必须注销/重新启动才能看到更改.

资源:

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值