Get in Touch

Course Outline

The simplest script

Choosing the shell (magic number #!, Sha-bang)

Executing the script

External and built-in commands

Key special characters

  • Comments (#)
  • End of line (;)
  • Empty statement (:)
  • Input/output redirection (>, <, >>)
  • Output redirection
  • Input redirection
  • Streams (|)
  • Running processes in the background (&)

Variables and Parameters

  • Removing variables (unset)
  • Variables with null values
  • Storing results in variables (backquotes ``)
  • Parameter references ($ 0, $ #, $ 1, $ 2, $ 3 ...)
  • Manual shifting of parameters
  • Quoting strategies
  • Escape characters (\)

Regular Expressions

Conditional statements

  • The if / then construct
  • The if / then / else construct
  • Nesting if statements
  • The if / elif construct
  • Case statements
  • Logical operators
  • AND, OR operators (&&, ||)
  • The test command

Completing scripts

The exit statement

Utilizing the script's exit status ($?)

Tests and Operators

  • File operator tests
  • File type tests
  • File attribute tests

Comparison operators

  • Arithmetic comparisons using the if command
  • Integer comparison operators
  • String comparisons
  • Complex comparisons (AND, OR)
  • Nesting comparison operators
  • Assignment operators
  • Arithmetic operators
  • Bitwise operators
  • Logical operators
  • Numeric constants

Loops

  • The for / in loop
  • The seq command
  • The while loop
  • The until loop
  • Loop control (break, continue)

Text Processing

  • head and tail commands
  • sort, uniq, expand, unexpand commands
  • cut, paste, join, wc, tr commands

Text searching (grep)

Stream editor (sed)

Interactive programs

  • read command
  • select command

Features

sleep command

Troubleshooting (debugging)

Requirements

  • Familiarity with basic Linux commands and file system navigation.
  • Experience using shells and performing simple text editing on Linux.
  • Completion of the "Introduction to Linux" course is recommended but not mandatory.

Audience

  • Linux users aiming to automate tasks through shell scripting.
  • System administrators seeking to optimize server management and operations.
  • Developers and IT professionals looking to strengthen their Linux programming skills.
 14 Hours

Number of participants


Price per participant

Upcoming Courses

Related Categories