forked from mirrors/nixpkgs
autojump: include a way to find the share dir
autojump-share is a new script that gives you the path to autojump's shared directory. It can then be used in the various shell's rc files to find and source the autojump integration. Eg: source "$(autojump-share)/autojump.bash" Fixes #3239
This commit is contained in:
parent
eecd06409f
commit
5901a8c63b
|
@ -22,9 +22,13 @@ in
|
|||
mkdir -p "$out/etc/bash_completion.d"
|
||||
cp -v $out/share/autojump/autojump.bash "$out/etc/bash_completion.d"
|
||||
|
||||
# FIXME: What's the right place for `autojump.zsh'?
|
||||
# This can be used as a workaround in .zshrc:
|
||||
# . $HOME/.nix-profile/share/autojump/autojump.zsh
|
||||
cat <<SCRIPT > $out/bin/autojump-share
|
||||
#!/bin/sh
|
||||
# Run this script to find the autojump shared folder where all the shell
|
||||
# integration scripts are living.
|
||||
echo $out/share/autojump
|
||||
SCRIPT
|
||||
chmod +x $out/bin/autojump-share
|
||||
'';
|
||||
|
||||
meta = {
|
||||
|
|
Loading…
Reference in a new issue