April 2018
Beginner
284 pages
7h 3m
English
Using the double brackets, we can do more than just match strings, we can use pattern matching. For example, we may need to work exclusively with Perl scripts, files that end with .pl. We will be able to implement this easily within a condition by including the pattern as a match, as shown in the following example:
$ [[ $FILE = *.pl ]] && cp"$FILE" scripts/