8000 Fixed missing syntax highlighting and return conditional text. by ImKelp · Pull Request #51 · bobbyiliev/introduction-to-bash-scripting · GitHub
[go: up one dir, main page]

Skip to content

Fixed missing syntax highlighting and return conditional text. #51

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 21, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions ebook/en/content/010-bash-conditionals.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,29 +132,29 @@ A quick rundown of the structure:

Here is an example of a Bash `case` statement:

```
```bash
#!/bin/bash

echo -n "Enter the name of a car brand: "
read car
read -p "Enter the name of your car brand: " car

case $car in

Tesla)
echo -n "${car}'s factory in the USA."
echo -n "${car}'s car factory is in the USA."
;;

BMW | Mercedes | Audi | Porsche)
echo -n "${car}'s factory in Germany."
echo -n "${car}'s car factory is in Germany."
;;

Toyoda | Mazda | Mitsubishi | Subaru)
echo -n "${car}'s factory in Japan."
Toyota | Mazda | Mitsubishi | Subaru)
echo -n "${car}'s car factory is in Japan."
;;

*)
echo -n "${car} is an unknown car brand."
echo -n "${car} is an unknown car brand"
;;

esac
```

Expand Down
0