Medium

Showing all detectors for the Shell language with medium severity.

Avoid LS-Grep

Prefer globs or loops over ls-grep.

Incorrectly used escape sequences

The problem involves replacing literal '\t' with actual tab characters using the command $(printf '\t').

Expr Modernization

Replace 'expr' with modern shell constructs.

Unquoted Special Parameters

Use quoted special parameters to prevent word splitting and globbing.

Single-Iteration Loop

Ensure for loops iterate over multiple values.

Prefer Find Over LS

Use 'find' for file operations instead of 'ls'.

Unquoted Array Expansion

Missing quotes around array expansion.

PS Grep Alternative

Use pgrep for process lookup.

Unquoted Find Patterns

Lack of quotes around pattern arguments in 'find' command.

Use of if and then

The problem involves checking the exit code or output of a command in a shell script using different conditional constructs.

Read Lines with While Loop

Use while loop for line-by-line processing.

Incorrect Quoting in Trap Commands

Using single quotes instead of double quotes in trap commands to prevent premature expansion of variables and commands.

Command Substitution Syntax

Use '$(...)' instead of backticks for command substitution.