terça-feira, março 29, 2022

Run Google Chrome with different profiles in Windows


 Chrome for Windows 10 supports the mentioned command line argument, --profile-directory. Use it as follows:

chrome.exe --profile-directory="profile name"
  1. Duplicate your existing Chrome shortcut. For example, select it on the Desktop, press Ctrl + C to copy it, then press Ctrl + V to paste. See this article: How to create a copy for a file quickly in Explorer.
  2. Right click the shortcut you created and select Properties from the context menu.
  3. Add the mentioned command line argument to the Target box:It will look as follows:
    chrome.exe --profile-directory="my other profile"

    Correct the profile name according to your preferences.

  4. Repeat these steps for all profiles you need to create and you are done.

Now, you can run different Chrome profiles using shortcuts you created simultaneously.

Run Google Chrome with different profiles on Linux

In Linux, you can create a special *.desktop file to launch the Chrome browser with an alternative profile. Do it as follows.

  1. Open the following folder with your favorite file manager:

  2. Find a file named "google-chrome.desktop" there.
  3. Copy that file to the folder
    /home/your user name/.local/share/applications

    If you don't have such a folder, then just create it.

  4. Rename the ~/.local/share/applications/google-chrome.desktop file to something else to indicate that it will refer to a custom profile.
  5. Edit it with your favorite editor. Change the Name section to something like Google Chrome (My Profile):
  6. Change all the Exec sections in the file to make them look like this:
    /usr/bin/google-chrome-stable --profile-directory="my other profile" %U

    So, you need to add the --profile-directory parameter to Chrome's command line.

  7. Repeat these steps for all profiles you need to create and you are done.

Your custom profiles will be visible in the apps menu of your Desktop environment. Here is how it looks in my XFCE+Whisker menu plugin:

That's it.

Nenhum comentário: