lib/helpers: fix `_bash-it-get-component-name-from-path()`

Use `${BASH_IT_LOAD_PRIORITY_SEPARATOR}`
pull/1933/head
John D Pell 2021-09-21 23:24:31 -07:00
parent 5fcd16e6cf
commit 1f2d3f4a2c
1 changed files with 2 additions and 1 deletions

View File

@ -7,10 +7,11 @@
###########################################################################
function _bash-it-get-component-name-from-path() {
local filename
# filename without path
filename="${1##*/}"
# filename without path or priority
filename="${filename##*---}"
filename="${filename##*${BASH_IT_LOAD_PRIORITY_SEPARATOR?}}"
# filename without path, priority or extension
echo "${filename%.*.bash}"
}