User Tools

Site Tools


ops102:filesystem_basics

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
ops102:filesystem_basics [2024/01/15 04:22] – [Basic Commands for Dealing with Files and Directories] chrisops102:filesystem_basics [2024/05/04 01:41] (current) – external edit 127.0.0.1
Line 13: Line 13:
 =====  Filenames  ===== =====  Filenames  =====
  
-The rules for valid filenames vary with the filesystem, but generally, filenames may include letters, numbers, dashes, underscores, and periods. Other punctuation marks may be acceptable in some filesystems but not in others, and are therefore best avoided, especially if files may be transferred between different types of filesystems or between computers.+The rules for valid filenames vary with the type of filesystem, but generally, filenames may include letters, numbers, dashes, underscores, and periods. Other punctuation marks may be acceptable in some filesystems but not in others, and are therefore best avoided, especially if files may be transferred between different types of filesystems or between computers.
  
 Spaces may be included in filenames, but may require quoting if accessed from the command-line, so that the shell does not interpret the filename as two or more separate filenames. For example, the filename "red leaf" may be interpreted as two separate filenames if written without quoting: Spaces may be included in filenames, but may require quoting if accessed from the command-line, so that the shell does not interpret the filename as two or more separate filenames. For example, the filename "red leaf" may be interpreted as two separate filenames if written without quoting:
Line 59: Line 59:
   cd ops102   cd ops102
  
-To see the name of the current directory, use 'pwd' (Print Working Directory) on Linux or 'cd' on Windows.+To see the name of the current directory, use the command ''pwd'' (Print Working Directory) on Linux or ''cd'' on Windows.
  
-To change your current directory to your home directory on Linux, use the 'cd' command by itself (with no arguments).+To change your current directory to your home directory on Linux, use the ''cd'' command by itself (with no arguments).
  
 =====  Pathnames  ===== =====  Pathnames  =====
Line 180: Line 180:
  
 Relative pathnames are often the shortest form of pathname //if// the target file is in the current working directory or a subdirectory of the current working directory, but the meaning of a relative pathname changes based on the current working directory. Relative pathnames are often the shortest form of pathname //if// the target file is in the current working directory or a subdirectory of the current working directory, but the meaning of a relative pathname changes based on the current working directory.
 +
 +===== Directory vs File Names =====
 +
 +It is often impossible to tell whether a pathname refers to a file or to a directory. For example, the Linux pathname ''/home/chris/presentation'' might refer to a file named ''presentation'' or to a directory named ''presentation''.
 +
 +If you wish to explicitly indicate that a pathname refers to a directory, append a slash or backslash to the pathname.
  
 =====  Volume Designators  ===== =====  Volume Designators  =====
Line 203: Line 209:
  
 ^ Description ^ Linux Command ^ Windows Command ^ Notes ^ ^ Description ^ Linux Command ^ Windows Command ^ Notes ^
-| Make Directory | mkdir //directory// | mkdir //directory// | | +| Make Directory | mkdir //directory// | mkdir //directory// | | 
-| Remove (EmptyDirectory | rmdir //directory// | rmdir //directory// | |+| Remove a Directory (Must be empty)| rmdir //directory// | rmdir //directory// | |
 | Change (Working) Directory | cd //directory// | cd //directory// | | | Change (Working) Directory | cd //directory// | cd //directory// | |
 | Print Current Working Directory | pwd | cd | | | Print Current Working Directory | pwd | cd | |
ops102/filesystem_basics.1705292533.txt.gz · Last modified: 2024/04/16 18:10 (external edit)

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki