O'Reilly logo

Korn Shell: Unix and Linux Programming Manual, Third Edition, The by Anatole Olczak

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

File Name Substitution

File name substitution is a feature which allows strings to be substituted for patterns and special characters. This provides greater flexibility and saves a lot of typing time. Most frequently this feature is used to match file names in the current directory, but can also be used to match arguments in case and [[...]] commands.

The syntax for file name substitution is not the same as regular expression syntax used in some Unix commands like ed, grep, and sed. The examples in the following sections assume that the following files exist in the current directory:

					$ ls —a
					.      .molog  abc     dabkup3  mobkup1
					..     a       dabkup1 dabkup4  mobkup2
					.dalog ab      dabkup2 dabkup5
				

The * Character

The * character matches any zero or more characters. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required