2011-12-14 87 views
0

我有這種性質兩個txt文件:與bash腳本錯誤比較文件

ENSG00000002587 
ENSG00000002746 
ENSG00000008300 
ENSG00000015413 

當我嘗試使用該腳本

$ comm -23 <(sort file1.txt|uniq)> <(sort file2.txt|uniq)> 

我去對它們進行比較如下:

bash: syntax error near unexpected token 'newline' 

我最近換了電腦;這在我以前的電腦上工作得很好。任何意見,將不勝感激。

回答

3

你的命令看起來不合適我。刪除>process substitution的語法是<(command_list),而不是<(command_list)>

嘗試:

comm -23 <(sort file1.txt|uniq) <(sort file2.txt|uniq) 
+0

優秀。謝謝你的幫助。 – user1038055 2011-12-14 16:18:03