Created
November 27, 2023 06:36
-
-
Save Syakhisk/3e5db025b11eb4334de6cf28dd80b8ca to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Google Account Auto Switcher | |
// @namespace http://tampermonkey.net/ | |
// @version 0.1 | |
// @description try to take over the world! | |
// @author You | |
// @match https://calendar.google.com/calendar/u/0/* | |
// @match https://drive.google.com/drive/u/0/* | |
// @match https://mail.google.com/mail/u/0/* | |
// @icon https://www.google.com/s2/favicons?sz=64&domain=google.com | |
// @grant none | |
// @run-at document-start | |
// @noframes | |
// ==/UserScript== | |
(async function () { | |
"use strict"; | |
const targetAccountNumber = 1; | |
const url = new URL(window.location.href); | |
url.pathname = url.pathname.replace( | |
/\/u\/\d+\//, | |
`/u/${targetAccountNumber}/`, | |
); | |
window.location.replace(url); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment