• Chap3:文件系统中跳转[The Linux Command Line]


    1 introduce the following commands

      pwd - Print name of current working directory

      cd-Change directory

      ls-List directory contents

    2 understand the file system tree

      Unix-like systems such as Linux always have a single file system tree, regardless of how many drives or storage devices are attached to the computer.Storage devices are attached(or morer correctly,mounted) at various points on the tree according to the whims of the system administrator, the person(or persons) reponsible for the maintenance of the system.

    the current working directory

      Imagine that the file system is a  maze shaped like an upside-down tree and we are able to stand in the middle of it. At any given time ,we are inside a single directory and we can see the files contained in the directory and the pathway to the directory above us(called the parent directory) and any subdirectories below us.The directory we are standing in is called the current working directory.To display the current working directory,we use the pwd(print working directory) command.

    4 home directory

      When we first log in to our system(or start a terminal emulator session) our current working directory is set to our home directorty. Each user account is given its own home directory and when operating as a regulat user, the home directory is the only place the user is allowed to write files.

    5 list the files and directories

      we use the ls command.

    6 change working directory

      we use the cd command. To do this , type cd followed by the pathname of the desired working directory.A pathname is the route we take along the branches of the tree to get to the directory we want. Pathnames can be specified in one of two different ways;as absolute pathnames or as relative pathnames.

      6.1 absolute pathname

        begins with  the root directory and follow the tree branch by branch until the path to the desired directory or file is completed.

      6.2 relative pathname

        starts from the working directory.(we can use the one that requies the least typing)

    7 Importance Facts About Filenames

      (1)Filenames that begin with a period character are  hidden.This only means that ls will not list them unless you say ls-a.

      (2)Filenames and commands in Linux,like Unix, are case sensitive.

      (3)Linux has no concept of a "file extension" like some other operating system.

      (4)Though Linux suports long filenames which may contain embedded spaces and punctuation characters,limit the punctuation characters in the names of files you create to period(.),dash(-),and underscore(_).

  • 相关阅读:
    Python_01安装与配置
    数据库的事务日志已满,起因为"LOG_BACKUP"
    百度网盘视频在线倍速播放的方法——Js 一行代码实现
    Socket里Client和Server
    Python自动化执行遍历点击列表的前20行每一行
    pyhton判断闰年
    Python程序结构-包
    试题 历届试题 错误票据
    试题 历届试题 剪格子
    试题 历届试题 打印十字图
  • 原文地址:https://www.cnblogs.com/ERFishing/p/10054836.html
Copyright © 2020-2023  润新知