Introduction to Bash Scripting

Start Free Preview

Buying via our links supports this free directory · Affiliate disclosure.
Course facts
  • Payment: Free Preview (Paid Upgrade)
  • Learning style: Self-paced, start anytime
  • Format: Text & Interactive
  • Video access: Streaming Only
  • Before you start: Introduction to Shell
DataCamp details
  • Chapters: 4
Created byDataCamp
Available onDataCamp

Course Details
Learning Style

Start Anytime

Level

Intermediate

Study Mode

100% Online

Duration

Short (< 10 Hours)

Languages
Audio Language

English

Outcomes
Certificate

Certificate of Completion

Price & Terms
Pricing Model

Free Preview (Paid Upgrade)

Technical
Content Medium

Text & Interactive

Video Access

Streaming Only

Specification
Access

Subscription

SKU: introduction-bash-scripting Category: Tags: , Brand:

Learn to write Bash scripts that take arguments, use variables, arrays, loops and conditionals, and run on a schedule with cron.

At a glance
Duration4 hrs
LevelIntermediate
CertificateCertificate of Completion
LanguageEnglish
Taught byAlex Scriven
AccessSubscription
Add your review
Add to wishlistAdded to wishlistRemoved from wishlist 0
Add to compare

Bash scripting saves time on complex, repetitive command-line tasks by turning them into scripts. Short shell pipelines become reusable scripts that take arguments, store values in variables and arrays, branch on conditions and loop over files. The exercises work on practical data tasks, such as extracting scores, sorting model results and cleaning up a directory, and the final step is scheduling scripts with cron so they run without anyone starting them.

What You Will Achieve

  • Convert a shell pipeline you already use into a Bash script that reads arguments
  • Capture command output in variables and run calculations such as converting temperatures
  • Write scripts that choose between actions and repeat steps, for example to sort results or clean up a directory
  • Turn frequent tasks into reusable functions and set a script to run automatically at fixed times with cron


Program Overview

Bash Script Structure, Streams, and Arguments

A refresher on common command-line programs leads into writing first scripts and turning shell pipelines into saved Bash scripts.

  • Common command-line programs and arguments
  • Turning shell pipelines into scripts
  • Standard streams
  • Feeding arguments to a script, including HR data

Variables and Arrays in Bash

Creating and using string and numeric variables, doing calculations with them, and storing groups of values in arrays.

  • String and numeric variables
  • Shell within a shell
  • Calculations such as Fahrenheit to Celsius
  • Arrays and associative arrays

Control Statements, Functions, and Cron

Conditional logic and loops shape the flow of a script, then functions package repeated work and cron runs scripts on a schedule.

  • IF and CASE statements
  • FOR loops and WHILE statements
  • Function arguments, return values, and scope
  • Scheduling cronjobs with crontab

Certificate Awarded (Paid)


Job Outlook

Bash scripts are used wherever data and files live on Linux systems, for example in analytics pipelines in the cloud, routine file cleanup and scheduled data processing jobs.


Our take

Good for: Analysts and data workers who repeat the same file and data steps by hand and want them saved as scripts that can run on their own.

Keep in mind: Despite the intermediate label, it covers the basics of Bash scripting, and its exercises center on data files such as HR records, climate figures and model results.

Bottom line: A compact path to writing Bash scripts for data work, with cron scheduling as the piece that lets those scripts run unattended.

Frequently Asked Questions

What does shell within a shell mean in Bash?

It is a way of running one command inside another so that its output can be placed in a variable or an expression. The chapter on variables introduces it as a base for more advanced scripts.

What kind of data do the exercises work with?

The lessons use small, concrete tasks: extracting scores, searching the text of a book, passing HR data as arguments, converting Fahrenheit to Celsius, climate calculations, sorting and moving model results, and a sports analytics function.

What does the functions chapter teach beyond basic syntax?

After the basic structure of a function, the lessons deal with arguments, return values and scope, and practice them with a percentage calculator, a function that sums an array, and one that gets the current day.

User Reviews

0.0 out of 5
★★★★★
0
★★★★★
0
★★★★★
0
★★★★★
0
★★★★★
0

No reviews yet. Be the first to review this course.

There are no reviews yet.

Write your review

Reviews can only be posted by registered learners. Log in or create a free account, then you will return here to post.

×

    Report this page
    Introduction to Bash Scripting
    Introduction to Bash Scripting
    LiveTalent
    Logo
    Compare items
    • Total (0)
    Compare
    0