zoukankan      html  css  js  c++  java
  • ② linux基础bash shell基础语法

    whoami
    [root@rstx-53 ~]# whoami
    root
    
    创建用户 useradd
    [root@rstx-53 ~]# useradd yangtao
    useradd yangtao
    [root@rstx-53 ~]# passwd yangtao
    passwd yangtao
    Changing password for user yangtao.
    New password:        #不显示密码
    BAD PASSWORD: The password is shorter than 8 characters
    Retype new password:  #确认输入密码
    passwd: all authentication tokens updated successfully.
    

    shell 基础语法

    命令 选项 参数
    command options vars

    [root@rstx-53 opt]# ls             #command
    aliyun.sh  containerd  harbor-v1.10.1  nginx-0.12  src  yilu
    [root@rstx-53 opt]# ls -a          # command + options   调节命令的执行功能
    .   aliyun.sh  certs       harbor          harbor-v2.1.0  nu      src  yilu
    [root@rstx-53 opt]# ls -a /home    # command + options + vars 
    .  ..  jenkins  yangtao
    #命令: 整条shell命令的主题
    #选项: 用于调整命令的执行功能
        -a  短格式参数
        --all 长格式参数
    #参数: 命令操作的具体执行对象
    #命令必须开头  参数和选项的位置可以发生变化
    
  • 相关阅读:
    CentOS7.4安装Docker
    责任链模式
    策略模式
    状态模式
    解释器模式
    备忘录模式
    中介者模式
    观察者模式
    迭代器模式
    private、default、protected和public的作用域
  • 原文地址:https://www.cnblogs.com/yangtao416/p/14446140.html
Copyright © 2011-2022 走看看