Single quotes and double quotes in shell

Source: Internet
Author: User

1. http://edsionte.com/techblog/archives/3712 echo and backslash

Group records:

2. This is only a variable. Double quotation marks will prevent shell tokens from echo "a B" and echo a B.
3 --------
4 "a B" is a parameter of echo, while echo a B is two parameters of echo?
5
6
7. What is echo-e "\ tz" explained by shell? Or "\ tz? Then pass "\ tz" to echo?
8 ---------
9 do I understand this ~?
10 I'm SUN crazy. cc <walkerxk@gmail.com> 11:51:31
11 "\ tz" is interpreted as \ tz by shell, and the echo obtained is \ tz.
12 11:45:03 # tp # ~> Echo '"\ tz "'
13 "\ tz"
14 11:51:42 # tp # ~>
15 here echo gets "\ tz"

2. $ @ $ * difference (man special paraments)


Http://blog.sina.com.cn/s/blog_62c5db6e0100hpp8.html

Http://m.oschina.net/blog/35905

Reference code:

2 #! /Usr/bin/env bash
3 echo $ #
4 echo "******"
5 for I in $ *; do echo $ I; done
6 echo "--------"
7 for I in $ @; do echo $ I; done
8 echo "--------"
9 for I in "$ *"; do echo $ I; done
10 echo "--------"
11 for I in "$ @"; do echo $ I; done
12 echo "@@@@@@@@"
13 for I in "a" "bc"; do echo $ I; done
14 exit
15
16 echo $ *
17 echo $ @
18 echo "$ *"
19 echo "$ @"
20
21
22
23 until [-z "$ *"];
24 do
25 echo "$ @"
26 shift
27 done

 

3. About test

Http://17610376.blog.51cto.com/366886/405691

Http://blog.csdn.net/ottocho/article/details/7248041


Http://my.oschina.net/aiguozhe/blog/35937 test [[[differences

Http://www.ibm.com/developerworks/cn/linux/l-bash-test.html ibm: bash testing and comparison functions


Http://hi.baidu.com/richardma_/blog/item/1e3672d6a87d5f0aa18bb7d1.html
 

4. eval shift


Http://www.uplinux.com/shizi/wenxian/3778.html


Http://hi.baidu.com/shenqb/blog/item/613835dd53d6d6d38d1029d9.html/cmtid/367ab064975ffbfff73654d3

5. Double quotation marks


Http://hi.baidu.com/all_around_all/blog/item/13ef6431993f84db9d3d6264.html
 
Http://www.51testing.com /? Uid-47329-action-viewspace-itemid-86711

 
Http://hi.baidu.com/outsmile/blog/item/4f0102c4b5bcbcc139db4985.html

 
Http://www.igigo.net/archives/128 Bash quotes (this blog is awesome)

 

6. About Cat


Http://www.cnblogs.com/xlmeng1988/archive/2012/03/31/cat.html
 

7. IFS


Http://www.haogongju.net/art/591905
 
Recommended http://pkuwwt.blogspot.jp/2010/06/bashifs.html

 

8. Use and principles of screen

Http://doc.chinaunix.net/linux/200904/239872.shtml

 

9. ibm: bash parameter and parameter Extension

Http://www.ibm.com/developerworks/cn/linux/l-bash-parameters.html

Http://www.heartdemon.com/post/87.html

Http://www.cnblogs.com/pengxl/archive/2010/11/30/1887790.html

Http://www.51testing.com /? Uid-61754-action-viewspace-itemid-96942

Http://hi.baidu.com/msingle/blog/item/8fa2b113557b1b2ddd540134.html bash reserved characters

Http://www.chinaunix.net/jh/24/503842.html

10. shell random string

Http://blog.sina.com.cn/s/blog_62c5db6e0100hp61.html

 

11.

 

 

 

 

 

 

 

 

 

 

 

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.