From 37749ec5c115adff9ed10d9a829f9af5f29776f4 Mon Sep 17 00:00:00 2001 From: Patrick Spek Date: Fri, 10 Mar 2023 10:49:16 +0100 Subject: Update new code for shellcheck compliancy --- lib/subcommands/add.bash | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'lib/subcommands/add.bash') diff --git a/lib/subcommands/add.bash b/lib/subcommands/add.bash index 644c04f..db3ec40 100644 --- a/lib/subcommands/add.bash +++ b/lib/subcommands/add.bash @@ -8,6 +8,8 @@ subcommand() { local buffer local missing_vars=0 + local playbook_base + local playbook_registry export BASHTARD_PLAYBOOK="$1" ; shift @@ -17,8 +19,8 @@ subcommand() return 2 fi - local playbook_base="$(playbook_path "base")" - local playbook_registry="$BASHTARD_ETCDIR/registry.d/${BASHTARD_PLATFORM[fqdn]}" + playbook_base="$(playbook_path "base")" + playbook_registry="$BASHTARD_ETCDIR/registry.d/${BASHTARD_PLATFORM[fqdn]}" # Make sure we only run add if the playbook is not in the registry yet if grep -Fqx "$BASHTARD_PLAYBOOK" "$playbook_registry" -- cgit v1.1