3

In terminal, I do like this and it works fine:

$startx google-chrome-stable 

It brings up chrome (just as an example) fine. But lets say I want to do with some arguments:

$startx google-chrome-stable -incognito

It fails, because it thinks -incognito is an argument for startx rather than chrome.

Whats the solution?

1
  • 1
    You could try something like bash -c "google-chrome-stable -incognito". Nov 14, 2015 at 16:44

2 Answers 2

5

Use the following command

startx google-chrome-stable -incognito --

From man startx

The special argument '--' marks the end of client arguments and the
beginning of server options.
1
  • 1
    THis does not seem to work for me. "startx mono /app/app.exe --" results in only mono be run, without the file argument Sep 27, 2016 at 16:14
1

For others that may wonder, you should be using the full path to Google Chrome instead. If not, google-chrome-stable is passed as an argument to the default client.

To run Chrome as the client:

startx /usr/bin/google-chrome-stable -incognito

or, if you don't know where it is located:

startx `which google-chrome-stable` -incognito
0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .