Created
April 22, 2021 04:28
-
-
Save Akkiesoft/4be0b355db7898204eb2300c7efb40f7 to your computer and use it in GitHub Desktop.
This file contains 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 birds gone somewhere | |
// @include https://twitter.com/intent/tweet* | |
// @include https://twitter.com/share* | |
// ==/UserScript== | |
var base = "https://social.mikutter.hachune.net/share?text="; | |
var url = location.href.split('?')[1].split('&'); | |
var twtext = ""; | |
var twurl = ""; | |
for (var i = 0; i < url.length; i++) { | |
var j = url[i].split('='); | |
if (j[0] == 'text') { | |
twtext = j[1]; | |
} | |
if (j[0] == 'url') { | |
twurl = "%0D%0A" + j[1]; | |
} | |
} | |
var newurl = base + twtext; | |
if (twurl) { newurl += twurl; } | |
location.href = newurl; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment