Skip to content

Commit

Permalink
ci: linting
Browse files Browse the repository at this point in the history
  • Loading branch information
balupton committed Jul 14, 2023
1 parent 8fc423b commit 4ffba94
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 19 deletions.
14 changes: 7 additions & 7 deletions .trunk/trunk.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# https://features.trunk.io/check/p/trunk-doesnt-work-in-nested-repo
version: 0.1
cli:
version: 1.11.1
version: 1.12.0
plugins:
sources:
- id: trunk
Expand All @@ -20,18 +20,18 @@ actions:
- trunk-upgrade-available
lint:
enabled:
- [email protected].309
- trufflehog@3.42.0
- [email protected].324
- trufflehog@3.44.0
- [email protected]
- black@23.3.0
- eslint@8.43.0
- black@23.7.0
- eslint@8.44.0
- [email protected]
- git-diff-check@SYSTEM
- [email protected]
- [email protected]
- [email protected]
- prettier@2.8.8
- [email protected].275
- prettier@3.0.0
- [email protected].278
- [email protected]
- [email protected]
- [email protected]
Expand Down
1 change: 0 additions & 1 deletion commands/choose-option
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,6 @@ function choose-option() (
# helpers
local saved_results=() saved_visuals=()
function save_result {
# trunk-ignore(shellcheck/SC2034)
local VALUE="$1" LABEL="$2" VISUAL="$3"
local result=''
eval "result=\"$option_return\""
Expand Down
2 changes: 1 addition & 1 deletion commands/config-edit
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ function config-edit() (

if test "${TERM_PROGRAM-}" = 'vscode'; then
# https://github.com/Microsoft/vscode/issues/29523
if [[ "$option_line" = *' '* ]]; then
if [[ $option_line == *' '* ]]; then
option_line="${option_line/ / }"
fi
fi
Expand Down
1 change: 1 addition & 0 deletions commands/echo-escape-regex
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ function echo-escape-regex() (
for ((i = 0; i < ${#input}; i++)); do
char="${input:i:1}"
case "$char" in
# trunk-ignore(shellcheck/SC1001)
\\ | \[ | \] | \{ | \} | \^ | \$ | \. | \* | \+ | \? | \| | \( | \))
printf '%s' "\\$char"
;;
Expand Down
2 changes: 1 addition & 1 deletion commands/is-empty-directory
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ function is-empty-directory() (
# Action

# action
local path results
local path result
for path in "${paths[@]}"; do
if test ! -d "$path"; then
return 1
Expand Down
8 changes: 4 additions & 4 deletions commands/mount-helper
Original file line number Diff line number Diff line change
Expand Up @@ -1400,11 +1400,11 @@ function mount-helper() (
fi

# process check
if [[ "$local_check_status" = *'[source-missing]'* && "$local_check_status" = *'[target-missing]'* ]]; then
if [[ $local_check_status == *'[source-missing]'* && $local_check_status == *'[target-missing]'* ]]; then
echo-style --positive='Source not mounted.' --positive='Target not mounted.'
# echo-style --notice="will prepare..."
break
elif [[ "$local_check_status" = *'[source-found][target-found][valid]'* ]]; then # needs both as unmounting with only --target and no source information is still [valid]
elif [[ $local_check_status == *'[source-found][target-found][valid]'* ]]; then # needs both as unmounting with only --target and no source information is still [valid]
echo-style --positive="Source already mounted to target."
# if the goal is mounting, then check if they want to remount
if test "$option_remount" = 'yes'; then
Expand Down Expand Up @@ -1440,7 +1440,7 @@ function mount-helper() (
return "$confirm_ec"
fi
fi
elif [[ "$local_check_status" = *'[source-missing]'* && "$local_check_status" = *'[target-found]'* ]]; then
elif [[ $local_check_status == *'[source-missing]'* && $local_check_status == *'[target-found]'* ]]; then
echo-style --positive='Source not mounted.' ' ' --negative='Target mounted to an unexpected source.'
confirm_ec=0 && confirm --positive --ppid=$$ -- 'Unmount the target to mount to the correct source?' || confirm_ec="$?"
if test "$confirm_ec" -eq 0; then
Expand All @@ -1453,7 +1453,7 @@ function mount-helper() (
# failure
return "$confirm_ec"
fi
elif [[ "$local_check_status" = *'[source-found]'* && "$local_check_status" = *'[target-missing]'* ]]; then
elif [[ $local_check_status == *'[source-found]'* && $local_check_status == *'[target-missing]'* ]]; then
echo-style --notice='Source mounted to another target.' ' ' --positive='Target not mounted to any source.'
confirm_ec=0 && confirm --positive --ppid=$$ -- 'Prepare the target to be an additional mount for the source?' || confirm_ec="$?"
if test "$confirm_ec" -eq 0; then
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,13 +100,13 @@
],
"devDependencies": {
"@bevry/update-contributors": "^1.22.0",
"@typescript-eslint/eslint-plugin": "^5.59.11",
"@typescript-eslint/parser": "^5.59.11",
"@typescript-eslint/eslint-plugin": "^6.0.0",
"@typescript-eslint/parser": "^6.0.0",
"eslint-config-bevry": "^3.27.0",
"eslint-config-prettier": "^8.8.0",
"eslint-plugin-prettier": "^4.2.1",
"eslint": "^8.42.0",
"prettier": "^2.8.8",
"eslint-plugin-prettier": "^5.0.0",
"eslint": "^8.44.0",
"prettier": "^3.0.0",
"projectz": "^2.23.0",
"valid-directory": "^3.9.0"
},
Expand Down

0 comments on commit 4ffba94

Please sign in to comment.