I've read you can start Google Chrome in kiosk mode in Windows by using the argument --kiosk
.
I know how to do this on Windows, but how can I do this on Mac OS X?
And how can I run Google Chrome with the --kiosk
argument on startup?
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.
Sign up to join this communityI've read you can start Google Chrome in kiosk mode in Windows by using the argument --kiosk
.
I know how to do this on Windows, but how can I do this on Mac OS X?
And how can I run Google Chrome with the --kiosk
argument on startup?
This works with macOS:
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --kiosk
ls /Applications/Google\ Chrome.app/Contents/MacOS
and it printed 'Google Chrome' only. :S
It is probably even better to use the open
command (in case the application is not located in the Application folder). E.g.: open -a "Google Chrome" --args --kiosk http://www.example.com
In AppleScript, paste the following text:
do shell script "/Applications/Google\\ Chrome.app/Contents/MacOS/Google\\ Chrome --kiosk"
Save it as an application and add it to your startup items.
/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --kiosk --app=http://domain.com
put that in a plain txt document, but add the following snippet above the call to Chrome to make it executable,#!/bin/bash
and add it to your startup items, or doublbe click to launch.
You can create an alias to open websites or files via command line. To do this, you can include at the end of your ~/.bashrc
, ~/.bash_profile
or ~/.aliases
the following lines:
# Google Chrome Alias
google-chrome() {
open -a "Google Chrome" "$1"
}
"$1"
is not going to work right when you have more than one param to pass, especially if those params themselves have unquoted values.
"$1"
to "$@"
since you're using bash specifically here). Also probably best it's not in ~/.aliases really. An alias would be something like alias google-chrome='open -a "Google Chrome"'