bash:意外令牌'('附近的语法错误 [英] bash: syntax error near unexpected token `('
本文介绍了bash:意外令牌'('附近的语法错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试安装软件,此错误反复出现,我尝试了一些建议解决类似错误的解决方案,但对我却不起作用.给出以下命令:
I am trying to install a software, this error coming again and again i have tried some solutions which have suggest for similar errors but not working for me. command is given bellow:
sudo su - -c "R -e \\"install.packages('shiny', repos='http://cran.rstudio.com/')\\""
请帮助
错误:
bash: syntax error near unexpected token `('
推荐答案
检查如何转义引号.参数是:
Check how you escape the quotes. The argument is:
"R -e \\"install.packages('shiny', repos='http://cran.rstudio.com/')\\""
这可以分为:
-
"R -e \\"
-
install.packages('shiny',repos ='http://cran.rstudio.com/')
-
\\"
packages
之后的(
是错误的Shell语法.
The (
after packages
is wrong shell syntax.
执行此操作:
sudo su - -c "R -e \"install.packages('shiny', repos='http://cran.rstudio.com/')\""
这篇关于bash:意外令牌'('附近的语法错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文