Tag: scripting

Browse all articles, tutorials, and guides about scripting

Guides

Posts

Linux
2024-12-12|7 min read

How to Loop Through File Content in Bash

Learn different methods to iterate through file content line by line in Bash scripts, including handling special characters and processing large files efficiently.

Docker
2024-12-10|7 min read

How to Execute Multiple Commands in Docker Compose

Learn different techniques for running multiple commands in Docker Compose services, from simple command chaining to advanced multi-stage initialization scripts.

Linux
2024-12-03|8 min read

How to Loop Through an Array of Strings in Bash

Learn various methods to iterate through string arrays in Bash, including indexed arrays, associative arrays, and advanced looping techniques with practical examples.

Linux
2024-12-02|7 min read

How to Pipe to and from Clipboard in Bash Scripts

Learn how to integrate clipboard functionality into your Bash scripts using xclip, xsel, pbcopy, and pbpaste for seamless data transfer between terminal and GUI applications.

Bash
2024-11-15|8 min read

How to Check if a Variable is Set in Bash

Learn multiple methods to check if variables are set, unset, empty, or have specific values in Bash scripts with practical examples and best practices.

Bash
2024-10-22|7 min read

How to Concatenate String Variables in Bash

Learn multiple ways to combine string variables in Bash scripts, from simple concatenation to complex string operations with practical examples.

Bash
2024-10-01|7 min read

How to Set a Variable to the Output of a Command in Bash

Learn multiple methods to capture command output in Bash variables using command substitution, including best practices and error handling techniques.

Linux
2024-09-05|9 min read

How to Parse Command Line Arguments in Bash

Learn various methods to parse command line arguments in Bash scripts, including positional parameters, getopts, and advanced argument handling techniques.

Bash
2024-07-08|7 min read

How to Extract Filename and Extension in Bash

Learn multiple methods to extract filenames, extensions, and directory paths from file paths in Bash using parameter expansion and basename commands.

Bash
2024-06-12|8 min read

How to Split a String on a Delimiter in Bash

Learn multiple methods to split strings using delimiters in Bash, including IFS, parameter expansion, and array techniques with practical examples.

Bash
2024-05-03|7 min read

How to Check if a Program Exists from a Bash Script

Learn multiple reliable methods to check if a command or program is available on your system from within Bash scripts, including using which, command, and type.

Bash
2024-03-08|5 min read

How to Iterate Over a Range of Numbers in Bash Using Variables

Learn different methods to loop through number ranges defined by variables in Bash, from simple for loops to advanced sequence generation techniques.

Bash
2024-01-22|6 min read

Looping Through File Content Line by Line in Bash

Learn multiple techniques to read and process file content line by line in Bash scripts, including handling special characters and preserving whitespace.