Skip to content

envkernel.sh: support sourcing from symlink

Administrator requested to merge fix-envkernel-readlink into master

Use readlink -f to resolve all symlinks in the envkernel.sh path.

Example:

$ ln -s ~/code/pmbootstrap/helpers/envkernel.sh ~/.local/bin
$ cd ~/code/linux
$ source ~/.local/bin/envkernel.sh

Please note that "source envkernel.sh" will only work with bash, as we can use its ${BASH_SOURCE[0]} variable. For other shells, I would recommend to set up an alias instead, e.g. for .zshrc:

alias envkernel="source ~/code/pmbootstrap/helpers/envkernel.sh"
Edited by Administrator

Merge request reports

Loading