sequencer - simplified sqn-completion naming

This commit is contained in:
2022-03-15 09:44:53 +01:00
parent 9c8e0ab741
commit 48b5965969
2 changed files with 4 additions and 4 deletions

View File

@@ -1,10 +1,10 @@
#!/bin/bash
# Get script working directory
WDIR="$(cd "$(dirname -- "$(realpath "${BASH_SOURCE[0]}")")" >>/dev/null 2>&1 && pwd)"
sq_dir="$(cd "$(dirname -- "$(realpath "${BASH_SOURCE[0]}")")" >>/dev/null 2>&1 && pwd)"
_sequencerCompletion() {
local SEQCOMP_LOC="${WDIR}/sqnall-completion.bash"
local SEQCOMP_LOC="${sq_dir}/sqn-completion.bash"
local SEQCOMP_LOADER="$HOME/.bashrc"
local SEQCOMP_SOURCE=". \"$SEQCOMP_LOC\""

View File

@@ -1,6 +1,6 @@
#/usr/bin/env bash
_sqnall_completions()
_sqn_completions()
{
# Current search string
local cur=${COMP_WORDS[COMP_CWORD]}
@@ -58,7 +58,7 @@ installCompletion() {
SEQSHORT[$i]="${SEQPREFIX}${SEQLIST[$i]}"
alias ${SEQSHORT[$i]}="_SQN_ALIAS=\"${SEQSHORT[$i]}\" $SEQBASE/${SEQLIST[$i]}.sh"
done
complete -o nosort -o bashdefault -o default -F _sqnall_completions ${SEQSHORT[@]}
complete -o nosort -o bashdefault -o default -F _sqn_completions ${SEQSHORT[@]}
}
installCompletion