Skip to content

Instantly share code, notes, and snippets.

@mandx
Created July 21, 2017 21:41
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mandx/c87ccc4b41aa7a358ecd8698c575886a to your computer and use it in GitHub Desktop.
Save mandx/c87ccc4b41aa7a358ecd8698c575886a to your computer and use it in GitHub Desktop.
Simple Python 3 script to launch a new, clean Chrome instance
from subprocess import run
from tempfile import TemporaryDirectory
if __name__ == '__main__':
with TemporaryDirectory() as tempdir:
run([
'google-chrome',
'--user-data-dir==' + tempdir,
'--incognito',
'--no-default-browser-check',
'--no-first-run',
'--disable-default-apps',
'--disable-popup-blocking',
'--disable-translate',
])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment