find: paths must precede expression问题及解决
用find命令查找时 
例如命令
  
会出错,查文档找出 
  find: paths must precede expression 
  Usage: find [-H] [-L] [-P] [-Olevel] [-D help|tree|search|stat|rates|opt|exec] 
  [path…] [expression] 
  This happens because *.c has been expanded by the shell  resulting in find 
  actually receiving a command line like this:
find . -name bigram.c code.c frcode.c locate.c -print
That command is of course not going to work. Instead of doingthings 
  this way, you should enclose the  pattern  in  quotes  or escape the  wildcard:
$ find . -name '*.c' -print 或 $ find . -name \*.c -print
   即出现这个提示是因为星号代表为当前目录下所有的文件,然后被当做shell展开
   这就是网上说的多文件的查找的时候需要增加单引号
 
                    
                     
                    
                 
                    
                 
         
                
            
         浙公网安备 33010602011771号
浙公网安备 33010602011771号