f8a6045307
Do not autoload files in $kak_runtime/rc, let the user choose restore the runtime command implemented in shell this time.
23 lines
575 B
Plaintext
23 lines
575 B
Plaintext
def -shell-params runtime %{ %sh{
|
|
while (( "$#" )); do
|
|
echo "source '${kak_runtime}/$1'"
|
|
shift
|
|
done
|
|
}}
|
|
|
|
%sh{
|
|
if [[ -n "${XDG_CONFIG_HOME}" ]]; then
|
|
localconfdir="${XDG_CONFIG_HOME}/kak"
|
|
else
|
|
localconfdir="$HOME/.config/kak"
|
|
fi
|
|
if [[ -f "${localconfdir}/kakrc" ]]; then
|
|
echo "source '${localconfdir}/kakrc'"
|
|
fi
|
|
if [[ -d "${localconfdir}/autoload" ]]; then
|
|
for rcfile in ${localconfdir}/autoload/*; do
|
|
echo "try %{ source '${rcfile}' } catch %{ }";
|
|
done
|
|
fi
|
|
}
|