懒龙谷
  • Home
  • Categories
  • Tags
  • Archives

shell变量空格

shell 字符串变量中的空格

示例:

x=" dokjd    "
  1. 保留全部空格:

    echo "$x"
    
  2. 去除头尾空格:

    echo $x
    

this guy is lazy, nothing leave

Comments
comments powered by Disqus

  • « if_else_elif
  • shell_file »

Published

May 4, 2014

Category

shell

Stay in Touch

  • Powered by Pelican. Theme: Elegant by Talha Mansoor