mirror of
https://github.com/koalaman/shellcheck.git
synced 2025-10-03 19:29:44 +08:00
Add highlighting to code-blocks
@@ -2,13 +2,13 @@
|
|||||||
|
|
||||||
### Problematic code:
|
### Problematic code:
|
||||||
|
|
||||||
```
|
```sh
|
||||||
if [ "$STUFF" = ""]; then
|
if [ "$STUFF" = ""]; then
|
||||||
```
|
```
|
||||||
|
|
||||||
### Correct code:
|
### Correct code:
|
||||||
|
|
||||||
```
|
```sh
|
||||||
if [ "$STUFF" = "" ]; then
|
if [ "$STUFF" = "" ]; then
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -16,11 +16,10 @@ if [ "$STUFF" = "" ]; then
|
|||||||
Bourne shells are very whitespace sensitive. Adding or removing spaces can drastically alter the meaning of a script. In these cases, ShellCheck has noticed that you're missing a space at the position indicated.
|
Bourne shells are very whitespace sensitive. Adding or removing spaces can drastically alter the meaning of a script. In these cases, ShellCheck has noticed that you're missing a space at the position indicated.
|
||||||
|
|
||||||
### Exceptions
|
### Exceptions
|
||||||
none.
|
None.
|
||||||
|
|
||||||
### Ignore
|
### Ignore
|
||||||
```
|
```sh
|
||||||
# shellcheck disable=SC1020
|
# shellcheck disable=SC1020
|
||||||
if [ "$STUFF" = ""]; then
|
if [ "$STUFF" = ""]; then
|
||||||
...
|
|
||||||
```
|
```
|
Reference in New Issue
Block a user