Using File Descriptors - English
BASH Tutorials - English 23
-
1Introduction to BASH Shell Scripting
-
2Basics of Shell Scripting
-
3Command Line arguments and Quoting
-
4Globbing and Export statement
-
5Array Operations in BASH
-
6More on Arrays
-
7Conditional execution
-
8Nested and multilevel if elsif statements
-
9Logical Operators
-
10Arithmetic Comparison
-
11String and File attributes
-
12Conditional Loops
-
13More on Loops
-
14Case statement
-
Using File Descriptors
-
16Basics of functions
-
17More on functions
-
18Arrays and functions
-
19Advance topics in a function
-
20Recursive function
-
21Basics of Redirection (error handling)
-
22More on Redirection
-
23Here document and Here string
Outline:
Using File Descriptors Introduction on fd Assign the file descriptor (fd) to file for output(exec fd > filename) Explained using an example of 'date' and 'echo' Closing the output fd(exec fd<&-) Explaination on error for the statements defiened after closing fd Assign the file descriptor (fd) to file for input(exec fd < filename) Closing the input file descriptor(exec fd<&-) Explaination on input fd using 'cat'