Skip to content

Instantly share code, notes, and snippets.

@monoglo
monoglo / TranslateToChineseOnYouTube.user.js
Created November 18, 2021 08:34 — forked from qwertyuiop6/TranslateToChineseOnYouTube.user.js
Translate to Chinese automatically. youtube自动翻译中文简体
// ==UserScript==
// @name YouTube字幕自动翻译->中文简体
// @namespace http://tampermonkey.net/
// @version 1.0
// @description translate to Chinese automatically. 自动点击字幕翻译到中文简体
// @author qwertyuiop6
// @match https://www.youtube.com/watch*
// @grant none
// ==/UserScript==
@monoglo
monoglo / baidu2google.js
Last active October 27, 2021 01:47
Baidu to Google Tampermonkey
// ==UserScript==
// @name Baidu to Google
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author rankOfMatrix
// @match *://www.baidu.com/
// @match *://www.baidu.com/*
// @icon https://www.google.cn/favicon.ico
// @grant none
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.Semaphore;
public class Semaphoreusage {
public static void main(String[] args) {
ExecutorService executorService = Executors.newCachedThreadPool();
final Semaphore semaphore = new Semaphore(5);
for (int i = 0; i < 30; i++) {