如何在 Linux 中符号链接文件? [英] How can I symlink a file in Linux?
本文介绍了如何在 Linux 中符号链接文件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我想在 Linux 中创建一个符号链接.我写了这个 Bash 命令,其中第一个路径是我想要链接到的文件夹,第二个路径是编译源.
I want to make a symbolic link in Linux. I have written this Bash command where the first path is the folder I want link into and the second path is the compiled source.
ln -s '+basebuild+'/IpDome-kernel/kernel /home/build/sandbox/gen2/basebuild/IpDome-kernel/kernal
这是正确的吗?
推荐答案
要创建一个新的符号链接(如果符号链接已经存在,将会失败):
To create a new symlink (will fail if symlink exists already):
ln -s /path/to/file /path/to/symlink
要创建或更新符号链接:
To create or update a symlink:
ln -sf /path/to/file /path/to/symlink
这篇关于如何在 Linux 中符号链接文件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文