Skip to Content
Learn Linux Shell Scripting - Fundamentals of Bash 4.4
book

Learn Linux Shell Scripting - Fundamentals of Bash 4.4

by Sebastiaan Tammer
December 2018
Beginner
452 pages
12h 17m
English
Packt Publishing
Content preview from Learn Linux Shell Scripting - Fundamentals of Bash 4.4

Chapter 11

  1. How does an if-then(-else) statement end? With the reverse of the word if: fi
  2. How can we use regular expression search patterns in a conditional evaluation? By employing the =~ comparison symbol. For example: [[ ${var} =~ [[:digit:]] ]]
  3. Why do we need the elif keyword? If we want to sequentially test for more than one condition, we can use else if (elif).
  4. What is nesting? Using an if-then-else statement or loop within another if-then-else statement or loop.
  5. How can we get information about how to use shell builtins and keywords? By using the command help, followed by the builtin or keyword we want information about. For example: help [[
  6. What is the opposite keyword of while? until. A while loop runs until the condition is no longer ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Bash Scripting Fundamentals

Bash Scripting Fundamentals

Sander van Vugt

Publisher Resources

ISBN: 9781788995597Supplemental Content