Files
Overview
The UNIX directory
hierarchy
Filesystems
Manipulating files
Creating
directories
Creating files
links
'Dot' files
Protecting files
Groups
File access
control
Changing
privileges
File
contents
Text files
Comparing
files
Filtering
files
Non-text files
Printing
files
File archives and file
compression
Other relevant commands
Summary
Exercises
|
Exercises
-
Write a script to list the three most recently altered files
(including 'dot' files) in the current directory.
View solution
-
What type of file is /bin/id ?
-
List the files (excluding 'dot' files) in the current directory,
together with their inodes, in numerical order of the inodes.
View solution
-
How many subdirectories are there in /usr ?
-
Write a script to display the owner of the current directory
only.
View solution
-
Write a script to display the names of files in
/bin and /usr/bin that have the same
name.
-
Write a script to list the files in the current directory
(excluding 'dot' files) in 'long' format (that is, including the
information that ls provides with option
-l ), and in increasing order of size
(difficult).
View solution
-
List (without duplication) the groups that own the files in the
current directory.
|