Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

Coursera

Linux Shell Scripting - Basics

Packt via Coursera

Overview

AI, Data Science & Cloud Certificates from Google, IBM & Meta — 40% Off
One plan covers every Professional Certificate on Coursera. 40% off your first 3 months — limited time.
Unlock All Certificates
This course features Coursera Coach! A smarter way to learn with interactive, real-time conversations that help you test your knowledge, challenge assumptions, and deepen your understanding as you progress through the course. This Linux Shell Scripting course provides you with the essential skills to automate tasks, process data, and manage your system using bash scripting in the Linux operating system. Whether you're an aspiring system administrator or a developer, this course will teach you how to create, debug, and optimize bash scripts. You'll begin by learning basic script-building principles, including script file formats, variables, and performing simple arithmetic. As the course progresses, you will explore more complex concepts such as conditional statements, loops, and user input handling. Additionally, the course will guide you through using advanced techniques like script control, data presentation, and job scheduling, essential for efficient system automation. The course progresses step-by-step, starting with foundational scripting skills and gradually building up to more advanced topics. You'll master scripting logic with conditional statements and loops, and learn how to interact with users through input and output handling. As you reach the later modules, the course emphasizes real-world applications, showing you how to work with scripts in background processes and automate tasks using cron jobs. With hands-on examples and real-world challenges, you’ll gain confidence in writing practical, efficient bash scripts. This course is designed for learners who wish to enhance their scripting skills and automate tasks in the Linux environment. It's ideal for both beginners and intermediate users who have a basic understanding of the Linux operating system. No prior scripting knowledge is required, but familiarity with the Linux command line will be helpful. By the end of the course, you will be able to create and execute bash scripts, handle user input and output, utilize loops and conditional statements for decision-making, automate tasks, manage system processes, and troubleshoot and optimize your scripts for efficiency.

Syllabus

  • Basic Script Building
    • In this module, we will introduce you to the foundational elements of bash scripting, including file formats, script execution, and working with variables. You will learn how to create simple scripts, manage screen outputs, and understand basic control structures.
  • Using Variables
    • In this module, we will explore how to use variables in your shell scripts, understanding both environmental and user-defined variables. You'll also learn about command substitution and the challenges of working with subshells to enhance script flexibility.
  • Performing Math
    • In this module, we will delve into data manipulation through redirection, learn how to perform arithmetic operations in bash, and utilize the Bash Calculator (bc) to tackle more advanced calculations. This will help you manage data flow efficiently in your scripts.
  • Exiting Scripts
    • In this module, we will introduce you to conditional logic, teaching you how to implement different forms of if statements and apply nested conditions. You’ll also learn how to use boolean logic and compound tests to enhance decision-making within scripts.
  • Structured Commands
    • In this module, we will cover the concept of loops, showing you how to implement for, while, and until loops in your scripts. You will also learn how to manage loop execution using break and continue to control the flow of your scripts effectively.
  • Handling User Input
    • In this module, we will teach you how to manage user input using positional parameters, pass options via the command line, and accept input interactively with the read command. Additionally, you will learn how to schedule scripts and manage their execution in the background.
  • Presenting Data
    • In this module, we will focus on presenting data by exploring Linux File Descriptors. You will learn how to redirect and manipulate the data output within your scripts, giving you greater control over script interaction with the terminal.
  • Script Control
    • In this module, we will explore advanced script control techniques, including running scripts in the background, scheduling jobs, and adjusting script priorities. You’ll learn how to ensure scripts run smoothly, even in complex environments.

Taught by

Packt - Course Instructors

Reviews

Start your review of Linux Shell Scripting - Basics

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.