shell - Pass command line arguments to bash script does not work

902 Views Asked by At

I have a .sh script file and specifically the atguments are not going well, and I do not know the reason --engine = slimerjs and - headless

#!/bin/bash
xterm -e /usr/local/bin/casperjs --engine=slimerjs --headless /home/user/file.js

1

There are 1 best solutions below

0
UtLox On

Put the command in quotation marks:

#!/bin/bash
xterm -e "/usr/local/bin/casperjs --engine=slimerjs --headless /home/user/file.js"