Skip to content

Instantly share code, notes, and snippets.

View vrumger's full-sized avatar
😄
Having fun!

Avrumy vrumger

😄
Having fun!
View GitHub Profile
@vrumger
vrumger / playback-rate.js
Last active August 21, 2021 22:58
A tampermonkey script to automatically set the playback on YouTube
// ==UserScript==
// @name YouTube playback rate
// @namespace https://lungers.com
// @version 0.1
// @description Automatically set the playback on YouTube
// @author Andrew Lane
// @match https://www.youtube.com/watch?v=*
// @run-at document-end
// @grant none
// ==/UserScript==
set -euo pipefail
run_cmd() {
echo "$ $@"
"$@"
echo
}
run_cmd git checkout .
run_cmd git pull
@vrumger
vrumger / google.js
Last active November 20, 2023 15:59
Create a google account and go to youtube with puppeteer.
const puppeteer = require('puppeteer');
const uuid = require('uuid');
const sleep = ms => new Promise(r => setTimeout(r, ms));
(async () => {
const browser = await puppeteer.launch({ headless: false });
const page = await browser.newPage();
const id = uuid.v4();
from telethon import TelegramClient, events
import asyncio
client = TelegramClient(name, api_id, api_hash)
client.start(phone_number)
@client.on(events.NewMessage(pattern='(?i)!type (.+)'))
async def typewriter(event):
sleep_time = 0.3
text = event.pattern_match.group(1)
{
"hello_world": "Hello World",
"hi": "Hi {{name}}!"
}