Skip to main content

Recently Updated Pages

Command History

Linux Command Line and Shell Scripting ... Shell

The Mysterious ^[[A First, start a new Shell /bin/sh. /bin/sh Then enter the following command,...

Updated 4 months ago by kugarocks

Basic Operations

Linux Command Line and Shell Scripting ... Shell

Default Shell echo $SHELL /bin/bash If you start a new Shell in the current terminal (e.g., sw...

Updated 4 months ago by kugarocks

Basic Syntax

Linux Command Line and Shell Scripting ... Script

Shebang #!/usr/bin/env bash Variable Assignment No spaces are allowed around the = sign. name=...

Updated 4 months ago by kugarocks

Special Parameters

Linux Command Line and Shell Scripting ... Script

Parameters: $? The exit code of the previous command or script, 0 for success, non-0 for failure...

Updated 4 months ago by kugarocks

Signal

Linux Command Line and Shell Scripting ... Script

Bash Shell By default, the Bash Shell ignores the SIGQUIT(3) and SIGTERM(15) signals, so executi...

Updated 4 months ago by kugarocks

Parameter Expansion

Linux Command Line and Shell Scripting ... Script

In Bash, parameter expansion is a mechanism for manipulating and handling the contents of variabl...

Updated 4 months ago by kugarocks

Output

Linux Command Line and Shell Scripting ... Script

Standard File Descriptors Standard File Descriptors. Name Number Description STDIN 0 Stan...

Updated 4 months ago by kugarocks

Loop

Linux Command Line and Shell Scripting ... Script

For Statement for var in list do ... done The var variable can be normally used outside the...

Updated 4 months ago by kugarocks

Input

Linux Command Line and Shell Scripting ... Script

Positional Parameters Positional Parameters, script positional parameters. $0: script name, inc...

Updated 4 months ago by kugarocks

Function

Linux Command Line and Shell Scripting ... Script

Creating a Function function name { commands } or name() { commands } Function Return...

Updated 4 months ago by kugarocks