sequencer - simplified sqn-completion naming
This commit is contained in:
@@ -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\""
|
||||
|
||||
|
@@ -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
|
Reference in New Issue
Block a user