Get in Touch

Course Outline

The simplest script

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

Invoking the script

External and built-in commands

Notable special characters

  • Comments (#)
  • End of Line (;)
  • Empty statement (:)
  • Input/Output redirection (>, <, >>)
  • Redirecting output
  • Redirection of input
  • Piping streams (|)
  • Executing processes in the background (&)

Variables and Parameters

  • Removing variables (unset)
  • Variables with null values
  • Storing results in variables (backquotes ``)
  • Accessing parameters ($ 0, $ #, $ 1, $ 2, $ 3 ...)
  • Manual shifting
  • Quoting mechanisms.
  • Escape character (\)

Regular Expressions

Conditional Logic

  • The if\/then structure
  • The if\/then\/else structure
  • Nested if statements
  • The if\/elif structure
  • The case statement
  • Comparison operators
  • Logical operators and/or (&&, | |)
  • The test command

Script Termination

The exit statement

Utilizing the program's completion status within a script ($?)

Tests and Operators

  • Text file operators
  • Verifying file types
  • Testing file attributes

Comparison Operators

  • Arithmetic comparisons using the if command
  • Integer comparison operators
  • String comparisons
  • Complex comparisons (and, or)
  • Nesting comparison operators
  • The assignment operator
  • Arithmetic operators
  • Bitwise operators for bit operations
  • 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
  • Cut, Paste, Join, Wc, Tr

Text search (grep)

Stream Editor (sed)

Interactive programs

  • The Read command
  • User selection

Additional Features

The Sleep command

Troubleshooting non-functional scripts (debugging)

Requirements

  • Familiarity with fundamental Linux commands and file system navigation
  • Practical experience with shell usage and basic text editing on Linux
  • Previous completion of the "Introduction to Linux" module is advisable, though not mandatory

Target Audience

  • Linux users aiming to automate tasks through shell scripting
  • System administrators focused on optimizing server management and operational efficiency
  • Developers and IT professionals looking to elevate their Linux programming proficiency
 14 Hours

Number of participants


Price per participant

Upcoming Courses

Related Categories