Start work on migration to global directory
This commit is contained in:
@@ -186,8 +186,6 @@ _bash-it-migrate() {
|
||||
do
|
||||
typeset ff=$(basename $f)
|
||||
|
||||
# Only process the ones that don't use the new structure
|
||||
if ! [[ $ff =~ ^[0-9]*$BASH_IT_LOAD_PRIORITY_SEPARATOR.*\.bash$ ]] ; then
|
||||
# Get the type of component from the extension
|
||||
typeset single_type=$(echo $ff | sed -e 's/.*\.\(.*\)\.bash/\1/g' | sed 's/aliases/alias/g')
|
||||
typeset component_name=$(echo $ff | cut -d'.' -f1)
|
||||
@@ -199,7 +197,6 @@ _bash-it-migrate() {
|
||||
|
||||
$disable_func $component_name
|
||||
$enable_func $component_name
|
||||
fi
|
||||
done
|
||||
shopt -u nullglob
|
||||
done
|
||||
|
||||
@@ -207,10 +207,10 @@ function local_setup {
|
||||
|
||||
@test "bash-it: run the migrate command without anything to migrate" {
|
||||
run _enable-plugin "ssh"
|
||||
assert [ -L "$BASH_IT/plugins/enabled/250---ssh.plugin.bash" ]
|
||||
assert [ -L "$BASH_IT/enabled/250---ssh.plugin.bash" ]
|
||||
|
||||
run _bash-it-migrate
|
||||
assert [ -L "$BASH_IT/plugins/enabled/250---ssh.plugin.bash" ]
|
||||
assert [ -L "$BASH_IT/enabled/250---ssh.plugin.bash" ]
|
||||
}
|
||||
|
||||
@test "bash-it: verify that existing components are automatically migrated when something is enabled" {
|
||||
|
||||
Reference in New Issue
Block a user