Skip to content

Commit

Permalink
Fix linting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
CLHatch committed Feb 2, 2025
1 parent b28792c commit c266afd
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 14 deletions.
5 changes: 3 additions & 2 deletions .scripts/app_is_disabled.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ IFS=$'\n\t'

app_is_disabled() {
local APPNAME=${1-}
local APP_ENABLED=$(run_script 'env_get' "${APPNAME}__ENABLED")
if [[ ! ${APP_ENABLED} = "true" ]]; then
local APP_ENABLED
APP_ENABLED=$(run_script 'env_get' "${APPNAME}__ENABLED")
if [[ ! ${APP_ENABLED} == "true" ]]; then
return 0
else
return 1
Expand Down
5 changes: 3 additions & 2 deletions .scripts/app_is_enabled.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ IFS=$'\n\t'

app_is_enabled() {
local APPNAME=${1-}
local APP_ENABLED=$(run_script 'env_get' "${APPNAME}__ENABLED")
if [[ ${APP_ENABLED} = "true" ]]; then
local APP_ENABLED
APP_ENABLED=$(run_script 'env_get' "${APPNAME}__ENABLED")
if [[ ${APP_ENABLED} == "true" ]]; then
return 0
else
return 1
Expand Down
21 changes: 11 additions & 10 deletions .scripts/apps_list.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,24 @@ IFS=$'\n\t'

apps_list() {
local -a APPS
local APPS=($(run_script 'builtin_apps'))
local APPS
readarray -t APPS < <(run_script 'builtin_apps')
for index in "${!APPS[@]}"; do
local APPNAME=${APPS[$index]}
local APPNAME=${APPS[index]}
APPS[$index]+=','
if run_script 'app_is_installed' ${APPNAME}; then
if run_script 'app_is_installed' "${APPNAME}"; then
APPS[$index]+='*INSTALLED*,'
if run_script 'app_is_enabled' ${APPNAME}; then
APPS[$index]+='*ENABLED*'
if run_script 'app_is_enabled' "${APPNAME}"; then
APPS[index]+='*ENABLED*'
else
APPS[$index]+='*DISABLED*'
APPS[index]+='*DISABLED*'
fi
else
APPS[$index]+=','
APPS[index]+=','
fi
APPS[$index]+=','
#if run_script 'app_is_depreciated' ${APPNAME}; then
# APPS[$index]+='(DEPRECIATED)'
APPS[index]+=','
#if run_script 'app_is_depreciated' "${APPNAME}"; then
# APPS[index]+='(DEPRECIATED)'
#fi
done
printf '%s\n' "${APPS[@]}" | column -t -s ','
Expand Down

0 comments on commit c266afd

Please sign in to comment.